[Python-modules-commits] r28365 - in packages/qscintilla2/trunk/debian (8 files)

kitterman at users.alioth.debian.org kitterman at users.alioth.debian.org
Sat Mar 29 20:26:00 UTC 2014


    Date: Saturday, March 29, 2014 @ 20:25:59
  Author: kitterman
Revision: 28365

* Add packaging for Qt5
  - Add new binaries: libqt5scintilla2--11, libqt5scintilla2-dev,
    libqt5scintilla2-l10n, and python3-pyqt5.qsci
  - Add qtbase5-dev, python3-pyqt5, and pyqt5-dev to build-depend
  - Add debian/patches/qt5_includes.patch to use correct Qt5 includes for
    the Python bindings
  - Add debian/patches/qt5_libname.patch to change the qscintilla2 library
    name when built with Qt5 so the Qt4 and Qt5 versions are co-installable
  - Update debian/rules to build both Qt4 and Qt5 versions
  - Update package descriptions to make it clear which is for Qt4 and which
    is for Qt5
* Install prf file in libqscintilla2-dev
* Correct symlink for jquery.js in libqscintilla2-doc
* Bump standards version to 3.9.5 without further change

Added:
  packages/qscintilla2/trunk/debian/patches/qt5_includes.patch
  packages/qscintilla2/trunk/debian/patches/qt5_libname.patch
Modified:
  packages/qscintilla2/trunk/debian/changelog
  packages/qscintilla2/trunk/debian/control
  packages/qscintilla2/trunk/debian/libqscintilla2-dev.install
  packages/qscintilla2/trunk/debian/libqscintilla2-doc.links
  packages/qscintilla2/trunk/debian/patches/series
  packages/qscintilla2/trunk/debian/rules

Modified: packages/qscintilla2/trunk/debian/changelog
===================================================================
--- packages/qscintilla2/trunk/debian/changelog	2014-03-29 14:44:53 UTC (rev 28364)
+++ packages/qscintilla2/trunk/debian/changelog	2014-03-29 20:25:59 UTC (rev 28365)
@@ -1,10 +1,24 @@
-qscintilla2 (2.8.1-2) UNRELEASED; urgency=medium
+qscintilla2 (2.8.1-2) unstable; urgency=medium
 
   * Add debian/patches/remove-logo-privacy-issue.diff to remove use of
     http://www.scintilla.org/SciBreak.jpg when the SCintilla docs are
     accessed in order to resolve privacy-breach-logo lintian error
+  * Add packaging for Qt5
+    - Add new binaries: libqt5scintilla2--11, libqt5scintilla2-dev,
+      libqt5scintilla2-l10n, and python3-pyqt5.qsci
+    - Add qtbase5-dev, python3-pyqt5, and pyqt5-dev to build-depend
+    - Add debian/patches/qt5_includes.patch to use correct Qt5 includes for
+      the Python bindings
+    - Add debian/patches/qt5_libname.patch to change the qscintilla2 library
+      name when built with Qt5 so the Qt4 and Qt5 versions are co-installable
+    - Update debian/rules to build both Qt4 and Qt5 versions
+    - Update package descriptions to make it clear which is for Qt4 and which
+      is for Qt5
+  * Install prf file in libqscintilla2-dev
+  * Correct symlink for jquery.js in libqscintilla2-doc
+  * Bump standards version to 3.9.5 without further change
 
- -- Scott Kitterman <scott at kitterman.com>  Wed, 19 Mar 2014 18:05:30 -0400
+ -- Scott Kitterman <scott at kitterman.com>  Sat, 29 Mar 2014 14:34:54 -0400
 
 qscintilla2 (2.8.1-1) unstable; urgency=medium
 

Modified: packages/qscintilla2/trunk/debian/control
===================================================================
--- packages/qscintilla2/trunk/debian/control	2014-03-29 14:44:53 UTC (rev 28364)
+++ packages/qscintilla2/trunk/debian/control	2014-03-29 20:25:59 UTC (rev 28365)
@@ -2,8 +2,8 @@
 Priority: optional
 Maintainer: Debian Python Modules Team <python-modules-team at lists.alioth.debian.org>
 Uploaders: Torsten Marek <shlomme at debian.org>, Gudjon I. Gudjonsson <gudjon at gudjon.org>, Scott Kitterman <scott at kitterman.com>
-Build-Depends: debhelper (>= 9), libqt4-dev (>= 4:4.8.0~), python-all-dev (>= 2.6.6-3~), python-sip-dev (>= 4.10), python-qt4 (>= 4.8.3-3~), python-qt4-dev (>= 4.8.3-3~), python3-all-dev (>= 3.1.3-13~), python3-sip-dev, python3-pyqt4
-Standards-Version: 3.9.4
+Build-Depends: debhelper (>= 9), libqt4-dev (>= 4:4.8.0~), python-all-dev (>= 2.6.6-3~), python-sip-dev (>= 4.10), python-qt4 (>= 4.8.3-3~), python-qt4-dev (>= 4.8.3-3~), python3-all-dev (>= 3.1.3-13~), python3-sip-dev, python3-pyqt4, qtbase5-dev, python3-pyqt5, pyqt5-dev
+Standards-Version: 3.9.5
 Section: libs
 X-Python3-Version: >= 3.1
 Homepage: http://www.riverbankcomputing.co.uk/software/qscintilla
@@ -23,6 +23,19 @@
  of proportional fonts, bold and italics, multiple foreground and background
  colours and multiple fonts.
 
+Package: libqt5scintilla2-11
+Architecture: any
+Depends: ${shlibs:Depends}, ${misc:Depends}, libqt5scintilla2-l10n (>= ${source:Upstream-Version})
+Pre-Depends: ${misc:Pre-Depends}
+Description: Qt5 port of the Scintilla source code editing widget
+ QScintilla is a text editor for Qt5 with features especially useful when
+ writing and debugging source code. These include support for syntax
+ styling, error indicators, code completion, call tips and margins.
+ .
+ Styling choices are more open than with many editors, allowing the use
+ of proportional fonts, bold and italics, multiple foreground and background
+ colours and multiple fonts.
+
 Package: libqscintilla2-l10n
 Architecture: all
 Depends: ${misc:Depends}
@@ -36,6 +49,17 @@
  .
  This package contains translations for libqscintilla2.
 
+Package: libqt5scintilla2-l10n
+Architecture: all
+Depends: ${misc:Depends}
+Suggests: libqscintilla2-qt5-11
+Description: Scintilla source code editing widget for Qt5, translation files
+ QScintilla is a text editor for Qt5 with features especially useful when
+ writing and debugging source code. These include support for syntax
+ styling, error indicators, code completion, call tips and margins.
+ .
+ This package contains translations for libqscintilla2.
+
 Package: libqscintilla2-designer
 Section: misc
 Architecture: any
@@ -61,16 +85,29 @@
  This package contains development headers needed when developing 
  C++ applications that use QScintilla 2.
 
+Package: libqt5scintilla2-dev
+Section: libdevel
+Architecture: all
+Depends: libqt5scintilla2-11 (>= ${source:Upstream-Version}), libqt5scintilla2-11 (<< ${source:Upstream-Version}+1~), qtbase5-dev, ${misc:Depends}
+Description: Scintilla source code editing widget for Qt5, development files
+ QScintilla is a text editor for Qt5 with features especially useful when
+ writing and debugging source code. These include support for syntax
+ styling, error indicators, code completion, call tips and margins.
+ .
+ This package contains development headers needed when developing
+ C++ applications that use QScintilla 2 and Qt 5.
+
 Package: libqscintilla2-doc
 Section: doc
 Architecture: all
 Depends: ${misc:Depends}, libjs-jquery
 Description: API documentation for QScintilla 2
- QScintilla is a text editor for Qt4 with features especially useful when 
- writing and debugging source code. These include support for syntax 
+ QScintilla is a text editor for Qt4 and Qt5 with features especially useful
+ when writing and debugging source code. These include support for syntax 
  styling, error indicators, code completion, call tips and margins. 
  . 
- This package contains API documentation and usage examples for QScintilla 2.
+ This package contains API documentation and usage examples for QScintilla 2
+ with both Qt4 and Qt5.
 
 Package: python-qscintilla2
 Section: python
@@ -88,10 +125,22 @@
 Section: python
 Architecture: any
 Depends: ${python3:Depends}, ${shlibs:Depends}, python3-pyqt4, ${sip3:Depends}, ${misc:Depends}
-Description: Python 3 bindings for QScintilla 2
+Description: Python 3 bindings for QScintilla 2 with Qt 4
  QScintilla is a text editor for Qt4 with features especially useful when 
  writing and debugging source code. These include support for syntax 
  styling, error indicators, code completion, call tips and margins. 
  . 
  This package contains Python 3 bindings so QScintilla 2 can be used in
  PyQt4 applications.
+
+Package: python3-pyqt5.qsci
+Section: python
+Architecture: any
+Depends: ${python3:Depends}, ${shlibs:Depends}, python3-pyqt5, ${sip3:Depends}, ${misc:Depends}
+Description: Python 3 bindings for QScintilla 2 with Qt 5
+ QScintilla is a text editor for Qt5 with features especially useful when
+ writing and debugging source code. These include support for syntax
+ styling, error indicators, code completion, call tips and margins.
+ .
+ This package contains Python 3 bindings so QScintilla 2 can be used in
+ PyQt5 applications.

Modified: packages/qscintilla2/trunk/debian/libqscintilla2-dev.install
===================================================================
--- packages/qscintilla2/trunk/debian/libqscintilla2-dev.install	2014-03-29 14:44:53 UTC (rev 28364)
+++ packages/qscintilla2/trunk/debian/libqscintilla2-dev.install	2014-03-29 20:25:59 UTC (rev 28365)
@@ -1,2 +1,3 @@
 usr/include/qt4/Qsci/*.h
 usr/lib/*.so
+usr/share/qt4/mkspecs/features

Modified: packages/qscintilla2/trunk/debian/libqscintilla2-doc.links
===================================================================
--- packages/qscintilla2/trunk/debian/libqscintilla2-doc.links	2014-03-29 14:44:53 UTC (rev 28364)
+++ packages/qscintilla2/trunk/debian/libqscintilla2-doc.links	2014-03-29 20:25:59 UTC (rev 28365)
@@ -1 +1 @@
-/usr/share/javascript/jquery/jquery.min.js usr/share/doc/html-Qt4/jquery.js
+/usr/share/javascript/jquery/jquery.min.js usr/share/doc/libqscintilla2-doc/html-Qt4Qt5/jquery.js

Added: packages/qscintilla2/trunk/debian/patches/qt5_includes.patch
===================================================================
--- packages/qscintilla2/trunk/debian/patches/qt5_includes.patch	                        (rev 0)
+++ packages/qscintilla2/trunk/debian/patches/qt5_includes.patch	2014-03-29 20:25:59 UTC (rev 28365)
@@ -0,0 +1,17 @@
+When building for Qt5, the python extension needs QtWidgets and QtPrintSupport
+because things moved there from QtGui in Qt4.  Sent upstream.
+
+Index: qscintilla2-2.8.1/Python/configure.py
+===================================================================
+--- qscintilla2-2.8.1.orig/Python/configure.py	2014-03-25 03:27:52.000000000 +0000
++++ qscintilla2-2.8.1/Python/configure.py	2014-03-28 04:46:49.862018963 +0000
+@@ -741,6 +741,9 @@
+     if target_config.qscintilla_is_dll:
+         pro.write('DEFINES += QSCINTILLA_DLL\n')
+ 
++    if opts.pyqt_package == 'PyQt5':
++        pro.write('INCLUDEPATH += %s\n' % '/usr/include/qt5/QtWidgets /usr/include/qt5/QtPrintSupport')
++
+     if target_config.qsci_inc_dir is not None:
+         pro.write('INCLUDEPATH += %s\n' % target_config.qsci_inc_dir)
+ 

Added: packages/qscintilla2/trunk/debian/patches/qt5_libname.patch
===================================================================
--- packages/qscintilla2/trunk/debian/patches/qt5_libname.patch	                        (rev 0)
+++ packages/qscintilla2/trunk/debian/patches/qt5_libname.patch	2014-03-29 20:25:59 UTC (rev 28365)
@@ -0,0 +1,57 @@
+Rename library when built with Qt5 for co-installability.  Discussed with
+upstream, but not reviewed as they aren't particularly interested in it.
+Index: qscintilla2-2.8.1/Qt4Qt5/qscintilla.pro
+===================================================================
+--- qscintilla2-2.8.1.orig/Qt4Qt5/qscintilla.pro	2014-03-25 03:47:55.314827158 +0000
++++ qscintilla2-2.8.1/Qt4Qt5/qscintilla.pro	2014-03-29 03:43:03.744577181 +0000
+@@ -36,6 +36,7 @@
+ greaterThan(QT_MAJOR_VERSION, 4) {
+ 	QT += widgets
+ 	QT += printsupport
++	TARGET = qt5scintilla2
+ 
+     greaterThan(QT_MINOR_VERSION, 1) {
+ 	    macx:QT += macextras
+Index: qscintilla2-2.8.1/Qt4Qt5/features/qscintilla2.prf
+===================================================================
+--- qscintilla2-2.8.1.orig/Qt4Qt5/features/qscintilla2.prf	2014-03-14 14:12:58.000000000 +0000
++++ qscintilla2-2.8.1/Qt4Qt5/features/qscintilla2.prf	2014-03-29 15:43:20.429152445 +0000
+@@ -17,5 +17,10 @@
+         }
+     }
+ } else {
++    greaterThan(QT_MAJOR_VERSION, 4) {
++        LIBS += -lqt5scintilla2
++       }
++        else {
+     LIBS += -lqscintilla2
++        }
+ }
+Index: qscintilla2-2.8.1/Python/configure.py
+===================================================================
+--- qscintilla2-2.8.1.orig/Python/configure.py	2014-03-29 03:46:27.368573880 +0000
++++ qscintilla2-2.8.1/Python/configure.py	2014-03-29 15:56:56.917139208 +0000
+@@ -676,7 +676,10 @@
+     pro.write('TEMPLATE = lib\n')
+     pro.write('CONFIG += %s\n' % ('debug' if opts.debug else 'release'))
+     pro.write('CONFIG += %s\n' % ('staticlib' if opts.static else 'plugin'))
+-    pro.write('CONFIG += qscintilla2\n')
++    if opts.pyqt_package == 'PyQt5':
++        pro.write('CONFIG += qst5cintilla2\n')
++    else:
++        pro.write('CONFIG += qscintilla2\n')
+ 
+     if not opts.static:
+         # I don't really understand why the linker needs to find the Python
+@@ -757,7 +760,10 @@
+     if lib_dir is None:
+         lib_dir = target_config.qsci_default_lib_dir
+     else:
+-        pro.write('LIBS += -L%s -lqscintilla2\n' % lib_dir)
++        if opts.pyqt_package == 'PyQt5':
++            pro.write('LIBS += -L%s -lqt5scintilla2\n' % lib_dir)
++        else:
++            pro.write('LIBS += -L%s -lqscintilla2\n' % lib_dir)
+ 
+     if not opts.static:
+         pro.write('''

Modified: packages/qscintilla2/trunk/debian/patches/series
===================================================================
--- packages/qscintilla2/trunk/debian/patches/series	2014-03-29 14:44:53 UTC (rev 28364)
+++ packages/qscintilla2/trunk/debian/patches/series	2014-03-29 20:25:59 UTC (rev 28365)
@@ -2,3 +2,5 @@
 fix-lib-install-dir.diff
 py_conf_inc_dir.diff
 remove-logo-privacy-issue.diff
+qt5_includes.patch
+qt5_libname.patch

Modified: packages/qscintilla2/trunk/debian/rules
===================================================================
--- packages/qscintilla2/trunk/debian/rules	2014-03-29 14:44:53 UTC (rev 28364)
+++ packages/qscintilla2/trunk/debian/rules	2014-03-29 20:25:59 UTC (rev 28365)
@@ -18,12 +18,26 @@
 	LDFLAGS += $(shell dpkg-buildflags --get LDFLAGS)
 endif
 
-PYTHONS := $(shell pyversions -vr debian/control) $(shell py3versions -vr)
+DEB_HOST_MULTIARCH ?= $(shell dpkg-architecture -qDEB_HOST_MULTIARCH)
+DEB_HOST_ARCH ?= $(shell dpkg-architecture -qDEB_HOST_ARCH)
+DEB_HOST_ARCH_OS ?= $(shell dpkg-architecture -qDEB_HOST_ARCH_OS)
+DEB_HOST_ARCH_BITS ?= $(shell dpkg-architecture -qDEB_HOST_ARCH_BITS)
 
+PYTHON3S := $(shell py3versions -vr debian/control) 
+PYTHONS := $(shell pyversions -vr debian/control) $(PYTHON3S)
+
+# Update this on SO name bumps so files get shoved around correctly
+SONAME=11
+
 configure-stamp:
 	dh_testdir
-	cd Qt4Qt5 && qmake-qt4 QMAKE_STRIP=""
-	cd designer-Qt4Qt5 && qmake-qt4 INCLUDEPATH+=../Qt4Qt5 QMAKE_LIBDIR+=../Qt4Qt5 QMAKE_STRIP=""
+	mkdir QSciQt4
+	mkdir QSciQt5
+	cp -r Qt4Qt5/* QSciQt5
+	mkdir designer-Qt4
+	cd Qt4Qt5 && qmake-qt4 QMAKE_STRIP="" DESTDIR=../QSciQt4
+	cd designer-Qt4Qt5 && qmake-qt4 INCLUDEPATH+=../Qt4Qt5 QMAKE_LIBDIR+=../QSciQt4 QMAKE_STRIP="" DESTDIR=../designer-Qt4
+	cd QSciQt5  && qmake -qt=qt5-$(DEB_HOST_MULTIARCH) QMAKE_STRIP="" DESTDIR=../QSciQt5
 	touch $@
 
 configure: configure-stamp $(PYTHONS:%=Python/build-%/configure-stamp)
@@ -32,14 +46,25 @@
 	dh_testdir
 	mkdir -p Python/build-$*
 	cd Python/build-$* \
-		&& python$* ../configure.py -n ../../Qt4Qt5/ -o ../../Qt4Qt5 \
+		&& python$* ../configure.py -n ../../Qt4Qt5/ -o ../../QSciQt4 \
 		--sip-incdir=/usr/include/python$* -c \
 		--destdir=$(CUR_DIR)/usr/lib/python$*/dist-packages/PyQt4
+	case "$*" in 3*) \
+		mkdir -p Python/buildqt5-$* ; \
+	esac
+	case "$*" in 3*) \
+		cd Python/buildqt5-$* \
+		  && QT_SELECT=qt5-$(DEB_HOST_MULTIARCH) python$* ../configure.py -n ../../QSciQt5/ -o ../../QSciQt5 \
+		  --sip-incdir=/usr/include/python$* -c --pyqt=PyQt5 \
+		   --qmake=/usr/bin/qmake \
+		  --destdir=$(CUR_DIR)/usr/lib/python$*/dist-packages/PyQt5; \
+	esac
 	touch $@
 
 build-library-stamp: configure
 	dh_testdir
 	cd Qt4Qt5 && $(MAKE)
+	cd QSciQt5 && $(MAKE)
 	cd designer-Qt4Qt5 && $(MAKE)
 	touch $@
 
@@ -60,13 +85,17 @@
 	-cd Qt4Qt5 && $(MAKE) distclean
 	-cd designer-Qt4Qt5 && $(MAKE) distclean
 
-	rm -fr $(PYTHONS:%=Python/build-%)
+	rm -rf Python/build*
+	rm -rf QSciQt4
+	rm -rf QSciQt5
+	rm -rf designer-Qt4
 	rm -f *-stamp
 
 	dh_clean 
 
 install-python-%: 
 	$(MAKE) -C Python/build-$* install INSTALL_ROOT=$(CURDIR)/debian/tmp DESTDIR=$(CURDIR)/debian/tmp
+	$(MAKE) -C Python/buildqt5-$* install INSTALL_ROOT=$(CURDIR)/debian/tmp DESTDIR=$(CURDIR)/debian/tmp
 	case "$*" in 3*) \
 	  ABITAG=`python$* -c "import sysconfig; print(sysconfig.get_config_var('SOABI'))"`; \
           for f in `find debian/tmp/usr/lib/python3* -name '*.so' ! -name '*.cpython*.so'`; do \
@@ -81,6 +110,19 @@
 	dh_prep
 	dh_installdirs
 	cd Qt4Qt5 && $(MAKE) INSTALL_ROOT=$(CURDIR)/debian/tmp install
+	cd QSciQt5 && $(MAKE) INSTALL_ROOT=$(CURDIR)/debian/libqt5scintilla2-$(SONAME) install
+	mkdir -p $(CURDIR)/debian/libqt5scintilla2-dev/usr/include/qt5/Qsci
+	mkdir -p $(CURDIR)/debian/libqt5scintilla2-dev/usr/lib
+	mkdir -p $(CURDIR)/debian/libqt5scintilla2-dev/usr/share/qt5/mkspecs/features
+	mv $(CURDIR)/debian/libqt5scintilla2-$(SONAME)/usr/include/qt5/Qsci/*.h $(CURDIR)/debian/libqt5scintilla2-dev/usr/include/qt5/Qsci/
+	rm -rf $(CURDIR)/debian/libqt5scintilla2-$(SONAME)/usr/include
+	mv $(CURDIR)/debian/libqt5scintilla2-$(SONAME)/usr/lib/*.so $(CURDIR)/debian/libqt5scintilla2-dev/usr/lib
+	mv $(CURDIR)/debian/libqt5scintilla2-$(SONAME)/usr/share/qt5/mkspecs/features/* $(CURDIR)/debian/libqt5scintilla2-dev/usr/share/qt5/mkspecs/features
+	mkdir -p $(CURDIR)/debian/libqt5scintilla2-l10n/usr/share/qt5/translations
+	mv $(CURDIR)/debian/libqt5scintilla2-$(SONAME)/usr/share/qt5/translations/* $(CURDIR)/debian/libqt5scintilla2-l10n/usr/share/qt5/translations
+	mkdir -p $(CURDIR)/debian/libqscintilla2-doc/usr/share/qt5/qsci/api/python
+	mv $(CURDIR)/debian/libqt5scintilla2-$(SONAME)/usr/share/qt5/qsci/api/python/* $(CURDIR)/debian/libqscintilla2-doc/usr/share/qt5/qsci/api/python
+	rm -rf $(CURDIR)/debian/libqt5scintilla2-$(SONAME)/usr/share/qt5
 	cd designer-Qt4Qt5 && $(MAKE) INSTALL_ROOT=$(CURDIR)/debian/tmp install
 	for p in $(PYTHONS) ; do \
                 $(MAKE) -f debian/rules install-python-$$p;\




More information about the Python-modules-commits mailing list