02_configure.dpatch by Torsten Marek <shlomme@debian.org>
Updated for Qscintilla 2.8.2 configure.py changes by Scott Kitterman
<scott@kitterman.com>
patch the configure script for the Python bindings to support object dir
builds
Index: Python/configure.py
===================================================================
--- Python/configure.py	2014-07-05 10:02:02.318834374 -0400
+++ Python/configure.py	2014-07-05 10:02:02.306834375 -0400
@@ -31,6 +31,8 @@
 import optparse
 import sys
 
+src_dir = os.path.dirname(os.path.abspath(__file__))
+
 
 ###############################################################################
 # You shouldn't need to modify anything above this line.
@@ -210,6 +212,8 @@
                     "The QScintilla version number could not be determined by "
                     "reading %s." % sciglobal)
 
+        return # Debian: do not check for the installed version, we're good this way.
+
         lib_dir = target_configuration.qsci_lib_dir
         if lib_dir is None:
             lib_dir = target_configuration.qt_lib_dir
@@ -264,7 +268,12 @@
         the target configuration.
         """
 
-        return 'sip/qscimod5.sip' if target_configuration.pyqt_package == 'PyQt5' else 'sip/qscimod4.sip'
+        if target_configuration.pyqt_package == 'PyQt5':
+            return os.path.join(src_dir, 'sip/qscimod5.sip')
+        else:
+            return os.path.join(src_dir, 'sip/qscimod4.sip')
+
+        #return 'sip/qscimod5.sip' if target_configuration.pyqt_package == 'PyQt5' else 'sip/qscimod4.sip'
 
     def get_sip_installs(self, target_configuration):
         """ Return a tuple of the installation directory of the module's .sip

