[Python-modules-commits] r25040 - in packages/pyqt5/trunk/debian (5 files)

mitya57-guest at users.alioth.debian.org mitya57-guest at users.alioth.debian.org
Sun Jun 30 07:31:15 UTC 2013


    Date: Sunday, June 30, 2013 @ 07:31:12
  Author: mitya57-guest
Revision: 25040

debian/patches/mainloop_rename.diff: upstream patch to rename
dbus.mainloop.qt module to dbus.mainloop.pyqt5, to prevent conflicts
with PyQt4.

Added:
  packages/pyqt5/trunk/debian/patches/mainloop_rename.diff
Modified:
  packages/pyqt5/trunk/debian/changelog
  packages/pyqt5/trunk/debian/control
  packages/pyqt5/trunk/debian/patches/series
  packages/pyqt5/trunk/debian/rules

Modified: packages/pyqt5/trunk/debian/changelog
===================================================================
--- packages/pyqt5/trunk/debian/changelog	2013-06-30 05:02:25 UTC (rev 25039)
+++ packages/pyqt5/trunk/debian/changelog	2013-06-30 07:31:12 UTC (rev 25040)
@@ -1,5 +1,8 @@
 pyqt5 (5.0-1) UNRELEASED; urgency=low
 
   * Initial release, based on python-qt4 packaging (closes: #712630).
+  * debian/patches/mainloop_rename.diff: upstream patch to rename
+    dbus.mainloop.qt module to dbus.mainloop.pyqt5, to prevent conflicts
+    with PyQt4.
 
  -- Dmitry Shachnev <mitya57 at gmail.com>  Sat, 29 Jun 2013 13:40:16 +0400

Modified: packages/pyqt5/trunk/debian/control
===================================================================
--- packages/pyqt5/trunk/debian/control	2013-06-30 05:02:25 UTC (rev 25039)
+++ packages/pyqt5/trunk/debian/control	2013-06-30 07:31:12 UTC (rev 25040)
@@ -70,30 +70,30 @@
  .
  This package contains the extensions built for the Python 3 debug interpreter.
 
-#Package: python3-dbus.mainloop.pyqt5
-#Architecture: any
-#Depends: python3-dbus,
-#         ${misc:Depends},
-#         ${python3:Depends},
-#         ${shlibs:Depends}
-#Description: D-Bus Support for PyQt5 with Python 3
-# The D-Bus module of PyQt5 provides integration of PyQt5 applications
-# with the D-Bus main loop for Python 3.
+Package: python3-dbus.mainloop.pyqt5
+Architecture: any
+Depends: python3-dbus,
+         ${misc:Depends},
+         ${python3:Depends},
+         ${shlibs:Depends}
+Description: D-Bus Support for PyQt5 with Python 3
+ The D-Bus module of PyQt5 provides integration of PyQt5 applications
+ with the D-Bus main loop for Python 3.
 
-#Package: python3-dbus.mainloop.pyqt5-dbg
-#Architecture: any
-#Priority: extra
-#Section: debug
-#Depends: python3-dbg,
-#         python3-dbus-dbg,
-#         python3-dbus.mainloop.pyqt5 (= ${binary:Version}),
-#         ${misc:Depends},
-#         ${shlibs:Depends}
-#Description: D-Bus Support for PyQt5 (debug extensions for Python 3)
-# The D-Bus module of PyQt5 provides integration of PyQt5 applications
-# with the D-Bus main loop for Python 3.
-# .
-# This package contains the extensions built for the Python debug interpreter.
+Package: python3-dbus.mainloop.pyqt5-dbg
+Architecture: any
+Priority: extra
+Section: debug
+Depends: python3-dbg,
+         python3-dbus-dbg,
+         python3-dbus.mainloop.pyqt5 (= ${binary:Version}),
+         ${misc:Depends},
+         ${shlibs:Depends}
+Description: D-Bus Support for PyQt5 (debug extensions for Python 3)
+ The D-Bus module of PyQt5 provides integration of PyQt5 applications
+ with the D-Bus main loop for Python 3.
+ .
+ This package contains the extensions built for the Python debug interpreter.
 
 Package: python3-pyqt5.qtopengl
 Architecture: any

Added: packages/pyqt5/trunk/debian/patches/mainloop_rename.diff
===================================================================
--- packages/pyqt5/trunk/debian/patches/mainloop_rename.diff	                        (rev 0)
+++ packages/pyqt5/trunk/debian/patches/mainloop_rename.diff	2013-06-30 07:31:12 UTC (rev 25040)
@@ -0,0 +1,261 @@
+Description: rename dbus.mainloop.qt module to dbus.mainloop.pyqt5
+Origin: upstream, changeset b72659988feb
+Last-Update: 2013-06-30
+
+--- a/configure.py
++++ b/configure.py
+@@ -59,7 +59,7 @@
+ 
+ # The module meta-data.
+ MODULE_METADATA = {
+-    'dbus':             ModuleMetadata(qmake_QT=['-gui'], qmake_TARGET='qt',
++    'dbus':             ModuleMetadata(qmake_QT=['-gui'], qmake_TARGET='pyqt5',
+                                 in_consolidated=False),
+     'QAxContainer':     ModuleMetadata(qmake_QT=['axcontainer']),
+     'Qt':               ModuleMetadata(qmake_QT=['-core', '-gui'],
+--- a/dbus/dbus.cpp
++++ b/dbus/dbus.cpp
+@@ -34,13 +34,13 @@
+ extern "C" {static dbus_bool_t add_watch(DBusWatch *watch, void *data);}
+ static dbus_bool_t add_watch(DBusWatch *watch, void *data)
+ {
+-    pyqtDBusHelper *hlp = reinterpret_cast<pyqtDBusHelper *>(data);
++    pyqt5DBusHelper *hlp = reinterpret_cast<pyqt5DBusHelper *>(data);
+ 
+     int fd = dbus_watch_get_fd(watch);
+     unsigned int flags = dbus_watch_get_flags(watch);
+     dbus_bool_t enabled = dbus_watch_get_enabled(watch);
+ 
+-    pyqtDBusHelper::Watcher watcher;
++    pyqt5DBusHelper::Watcher watcher;
+     watcher.watch = watch;
+ 
+     if (flags & DBUS_WATCH_READABLE)
+@@ -67,15 +67,15 @@
+ extern "C" {static void remove_watch(DBusWatch *watch, void *data);}
+ static void remove_watch(DBusWatch *watch, void *data)
+ {
+-    pyqtDBusHelper *hlp = reinterpret_cast<pyqtDBusHelper *>(data);
++    pyqt5DBusHelper *hlp = reinterpret_cast<pyqt5DBusHelper *>(data);
+ 
+     int fd = dbus_watch_get_fd(watch);
+ 
+-    pyqtDBusHelper::Watchers::iterator it = hlp->watchers.find(fd);
++    pyqt5DBusHelper::Watchers::iterator it = hlp->watchers.find(fd);
+ 
+     while (it != hlp->watchers.end() && it.key() == fd)
+     {
+-        pyqtDBusHelper::Watcher &watcher = it.value();
++        pyqt5DBusHelper::Watcher &watcher = it.value();
+ 
+         if (watcher.watch == watch)
+         {
+@@ -99,17 +99,17 @@
+ extern "C" {static void toggle_watch(DBusWatch *watch, void *data);}
+ static void toggle_watch(DBusWatch *watch, void *data)
+ {
+-    pyqtDBusHelper *hlp = reinterpret_cast<pyqtDBusHelper *>(data);
++    pyqt5DBusHelper *hlp = reinterpret_cast<pyqt5DBusHelper *>(data);
+ 
+     int fd = dbus_watch_get_fd(watch);
+     unsigned int flags = dbus_watch_get_flags(watch);
+     dbus_bool_t enabled = dbus_watch_get_enabled(watch);
+ 
+-    pyqtDBusHelper::Watchers::const_iterator it = hlp->watchers.find(fd);
++    pyqt5DBusHelper::Watchers::const_iterator it = hlp->watchers.find(fd);
+ 
+     while (it != hlp->watchers.end() && it.key() == fd)
+     {
+-        const pyqtDBusHelper::Watcher &watcher = it.value();
++        const pyqt5DBusHelper::Watcher &watcher = it.value();
+ 
+         if (watcher.watch == watch)
+         {
+@@ -141,7 +141,7 @@
+     if (!QCoreApplication::instance())
+         return true;
+ 
+-    pyqtDBusHelper *hlp = reinterpret_cast<pyqtDBusHelper *>(data);
++    pyqt5DBusHelper *hlp = reinterpret_cast<pyqt5DBusHelper *>(data);
+ 
+     int id = hlp->startTimer(dbus_timeout_get_interval(timeout));
+ 
+@@ -158,9 +158,9 @@
+ extern "C" {static void remove_timeout(DBusTimeout *timeout, void *data);}
+ static void remove_timeout(DBusTimeout *timeout, void *data)
+ {
+-    pyqtDBusHelper *hlp = reinterpret_cast<pyqtDBusHelper *>(data);
++    pyqt5DBusHelper *hlp = reinterpret_cast<pyqt5DBusHelper *>(data);
+ 
+-    pyqtDBusHelper::Timeouts::iterator it = hlp->timeouts.begin();
++    pyqt5DBusHelper::Timeouts::iterator it = hlp->timeouts.begin();
+ 
+     while (it != hlp->timeouts.end())
+         if (it.value() == timeout)
+@@ -186,7 +186,7 @@
+ extern "C" {static void dbus_qt_delete_helper(void *data);}
+ static void dbus_qt_delete_helper(void *data)
+ {
+-    delete reinterpret_cast<pyqtDBusHelper *>(data);
++    delete reinterpret_cast<pyqt5DBusHelper *>(data);
+ }
+ 
+ 
+@@ -194,7 +194,7 @@
+ extern "C" {static void wakeup_main(void *data);}
+ static void wakeup_main(void *data)
+ {
+-    pyqtDBusHelper *hlp = reinterpret_cast<pyqtDBusHelper *>(data);
++    pyqt5DBusHelper *hlp = reinterpret_cast<pyqt5DBusHelper *>(data);
+ 
+     QTimer::singleShot(0, hlp, SLOT(dispatch()));
+ }
+@@ -208,7 +208,7 @@
+ 
+     Py_BEGIN_ALLOW_THREADS
+ 
+-    pyqtDBusHelper *hlp = reinterpret_cast<pyqtDBusHelper *>(data);
++    pyqt5DBusHelper *hlp = reinterpret_cast<pyqt5DBusHelper *>(data);
+ 
+     hlp->connections.append(conn);
+ 
+@@ -253,13 +253,13 @@
+ 
+ 
+ // Create a new helper instance.
+-pyqtDBusHelper::pyqtDBusHelper() : QObject()
++pyqt5DBusHelper::pyqt5DBusHelper() : QObject()
+ {
+ }
+ 
+ 
+ // Handle a socket being ready to read.
+-void pyqtDBusHelper::readSocket(int fd)
++void pyqt5DBusHelper::readSocket(int fd)
+ {
+     Watchers::const_iterator it = watchers.find(fd);
+ 
+@@ -287,7 +287,7 @@
+ 
+ 
+ // Handle a socket being ready to write.
+-void pyqtDBusHelper::writeSocket(int fd)
++void pyqt5DBusHelper::writeSocket(int fd)
+ {
+     Watchers::const_iterator it = watchers.find(fd);
+ 
+@@ -313,7 +313,7 @@
+ 
+ 
+ // Handoff to the connection dispatcher while there is data.
+-void pyqtDBusHelper::dispatch()
++void pyqt5DBusHelper::dispatch()
+ {
+     for (Connections::const_iterator it = connections.constBegin(); it != connections.constEnd(); ++it)
+         while (dbus_connection_dispatch(*it) == DBUS_DISPATCH_DATA_REMAINS)
+@@ -322,7 +322,7 @@
+ 
+ 
+ // Reimplemented to handle timer events.
+-void pyqtDBusHelper::timerEvent(QTimerEvent *e)
++void pyqt5DBusHelper::timerEvent(QTimerEvent *e)
+ {
+     DBusTimeout *timeout = timeouts.value(e->timerId());
+ 
+@@ -354,7 +354,7 @@
+     if (!PyArg_ParseTupleAndKeywords(args, kwargs, "|i", argnames, &set_as_default))
+         return 0;
+ 
+-    pyqtDBusHelper *hlp = new pyqtDBusHelper;
++    pyqt5DBusHelper *hlp = new pyqt5DBusHelper;
+ 
+     PyObject *mainloop = DBusPyNativeMainLoop_New4(dbus_qt_conn, dbus_qt_srv,
+                 dbus_qt_delete_helper, hlp);
+@@ -405,14 +405,14 @@
+ {
+     static PyModuleDef module_def = {
+         PyModuleDef_HEAD_INIT,
+-        "qt",
++        "pyqt5",
+         NULL,
+         -1,
+         module_functions,
+     };
+ 
+     // Import the generic part of the Python DBus bindings.
+-    if (import_dbus_bindings("dbus.mainloop.qt") < 0)
++    if (import_dbus_bindings("dbus.mainloop.pyqt5") < 0)
+         return 0;
+ 
+     return PyModule_Create(&module_def);
+@@ -421,9 +421,9 @@
+ PyMODINIT_FUNC initqt()
+ {
+     // Import the generic part of the Python DBus bindings.
+-    if (import_dbus_bindings("dbus.mainloop.qt") < 0)
++    if (import_dbus_bindings("dbus.mainloop.pyqt5") < 0)
+         return;
+ 
+-    Py_InitModule("qt", module_functions);
++    Py_InitModule("pyqt5", module_functions);
+ }
+ #endif
+--- a/dbus/helper.h
++++ b/dbus/helper.h
+@@ -33,7 +33,7 @@
+ class QTimerEvent;
+ 
+ 
+-class pyqtDBusHelper : public QObject
++class pyqt5DBusHelper : public QObject
+ {
+     Q_OBJECT
+ 
+@@ -51,7 +51,7 @@
+     typedef QHash<int, DBusTimeout *> Timeouts;
+     typedef QList<DBusConnection *>Connections;
+ 
+-    pyqtDBusHelper();
++    pyqt5DBusHelper();
+ 
+     Watchers watchers;
+     Timeouts timeouts;
+--- a/doc/html/_sources/dbus.txt
++++ b/doc/html/_sources/dbus.txt
+@@ -5,7 +5,7 @@
+ 
+ PyQt5 provides two different modules that implement support for DBus.  The
+ :mod:`~PyQt5.QtDBus` module provides wrappers for the standard Qt DBus classes.
+-The :mod:`dbus.mainloop.qt` module add support for the Qt event loop to the
++The :mod:`dbus.mainloop.pyqt5` module add support for the Qt event loop to the
+ standard ``dbus-python`` Python module.
+ 
+ 
+@@ -62,15 +62,15 @@
+ require if DBus structures are involved.
+ 
+ 
+-:mod:`dbus.mainloop.qt`
+------------------------
++:mod:`dbus.mainloop.pyqt5`
++--------------------------
+ 
+-The :mod:`dbus.mainloop.qt` module provides support for the Qt event loop to
++The :mod:`dbus.mainloop.pyqt5` module provides support for the Qt event loop to
+ ``dbus-python``.  The module's API is almost identical to that of the
+ :mod:`dbus.mainloop.glib` modules that provides support for the GLib event
+ loop.
+ 
+-The :mod:`dbus.mainloop.qt` module contains the following function.
++The :mod:`dbus.mainloop.pyqt5` module contains the following function.
+ 
+ .. function:: DBusQtMainLoop(set_as_default=False)
+ 
+@@ -85,6 +85,6 @@
+ The following code fragment is all that is normally needed to set up the
+ standard ``dbus-python`` language bindings package to be used with PyQt5::
+ 
+-    from dbus.mainloop.qt import DBusQtMainLoop
++    from dbus.mainloop.pyqt5 import DBusQtMainLoop
+ 
+     DBusQtMainLoop(set_as_default=True)

Modified: packages/pyqt5/trunk/debian/patches/series
===================================================================
--- packages/pyqt5/trunk/debian/patches/series	2013-06-30 05:02:25 UTC (rev 25039)
+++ packages/pyqt5/trunk/debian/patches/series	2013-06-30 07:31:12 UTC (rev 25040)
@@ -0,0 +1 @@
+mainloop_rename.diff

Modified: packages/pyqt5/trunk/debian/rules
===================================================================
--- packages/pyqt5/trunk/debian/rules	2013-06-30 05:02:25 UTC (rev 25039)
+++ packages/pyqt5/trunk/debian/rules	2013-06-30 07:31:12 UTC (rev 25040)
@@ -111,7 +111,7 @@
 	dh_prep -a
 	dh_installdirs -a
 	#sed -i -e '/strip/ d' $(CURDIR)/build-$(DEFAULT_PYTHON)/designer/Makefile
-	#rm -f $(CURDIR)/debian/python3-dbus.mainloop.pyqt5.install
+	rm -f $(CURDIR)/debian/python3-dbus.mainloop.pyqt5.install
 	# This is needed to enforce that the install-arch-% rules are
 	# not run in parallel. Both rules install into the same directory,
 	# and therefore might try to access the same files at the same time.
@@ -131,20 +131,20 @@
 install-arch-3.%:
 	$(MAKE) -C build-3.$* install \
 		INSTALL_ROOT=$(CURDIR)/debian/tmp DESTDIR=$(CURDIR)/debian/tmp
-	#if [ -e $(CURDIR)/debian/tmp$(call py3_dbusmoddir,3.$*)/pyqt5.so ]; then \
-	#	mkdir -p $(CURDIR)/debian/tmp/usr/lib/python3.$*/dist-packages/dbus/mainloop; \
-	#	mv $(CURDIR)/debian/tmp$(call py3_dbusmoddir,3.$*)/pyqt5.so \
-	#	$(CURDIR)/debian/tmp/usr/lib/python3.$*/dist-packages/dbus/mainloop; \
-	#	echo 'usr/lib/python3.$*/dist-packages/*' >> $(CURDIR)/debian/python3-dbus.mainloop.pyqt5.install;\
-	#fi
+	if [ -e $(CURDIR)/debian/tmp$(call py3_dbusmoddir,3.$*)/pyqt5.so ]; then \
+		mkdir -p $(CURDIR)/debian/tmp/usr/lib/python3.$*/dist-packages/dbus/mainloop; \
+		mv $(CURDIR)/debian/tmp$(call py3_dbusmoddir,3.$*)/pyqt5.so \
+		$(CURDIR)/debian/tmp/usr/lib/python3.$*/dist-packages/dbus/mainloop; \
+		echo 'usr/lib/python3.$*/dist-packages/*' >> $(CURDIR)/debian/python3-dbus.mainloop.pyqt5.install;\
+	fi
 	ls $(CURDIR)/debian/tmp/usr/lib/python3.$*/dist-packages/PyQt5 > ../list
 
 	$(MAKE) -C dbg-build-3.$* install INSTALL_ROOT=$(CURDIR)/$(d3_qt5_dbg) DESTDIR=$(CURDIR)/$(d3_qt5_dbg)
-	#if [ -e $(CURDIR)/$(d3_qt5_dbg)$(call py3_dbusmoddir,3.$*)/pyqt5.so ]; then \
-	#	mkdir -p $(CURDIR)/debian/python3-dbus.mainloop.pyqt5-dbg/usr/lib/python3.$*/dist-packages/dbus/mainloop; \
-	#	mv $(CURDIR)/debian/python3-pyqt5-dbg$(call py3_dbusmoddir,3.$*)/pyqt5.so \
-	#	$(CURDIR)/debian/python3-dbus.mainloop.pyqt5-dbg/usr/lib/python3.$*/dist-packages/dbus/mainloop; \
-	#fi
+	if [ -e $(CURDIR)/$(d3_qt5_dbg)$(call py3_dbusmoddir,3.$*)/pyqt5.so ]; then \
+		mkdir -p $(CURDIR)/debian/python3-dbus.mainloop.pyqt5-dbg/usr/lib/python3.$*/dist-packages/dbus/mainloop; \
+		mv $(CURDIR)/debian/python3-pyqt5-dbg$(call py3_dbusmoddir,3.$*)/pyqt5.so \
+		$(CURDIR)/debian/python3-dbus.mainloop.pyqt5-dbg/usr/lib/python3.$*/dist-packages/dbus/mainloop; \
+	fi
 
 	# Don't initiate the uic/widget-plugins
 	touch $(CURDIR)/debian/tmp/usr/lib/python3.$*/dist-packages/PyQt5/uic/widget-plugins/.noinit
@@ -191,7 +191,8 @@
 	set -e; \
 	for p in python3-pyqt5 python3-pyqt5.qtopengl python3-pyqt5.qtsql \
 	  python3-pyqt5.qtwebkit python3-pyqt5.qtmultimedia \
-	  python3-pyqt5.qtsvg python3-pyqt5.qtxmlpatterns; do \
+	  python3-pyqt5.qtsvg python3-pyqt5.qtxmlpatterns \
+	  python3-dbus.mainloop.pyqt5; do \
 		DH_OPTIONS= dh_strip -p$$p --dbg-package=$$p-dbg; \
 		rm -rf debian/$$p-dbg/usr/share/doc/$$p-dbg; \
 		mkdir -p debian/$$p-dbg/usr/share/doc; \
@@ -204,13 +205,13 @@
 	rm -rf $(CURDIR)/debian/python3-pyqt5-dbg/usr/share/sip
 	rm -rf $(CURDIR)/debian/python3-pyqt5-dbg/usr/lib/python3/dist-packages/PyQt5/uic
 	rm -rf $(CURDIR)/debian/python3-pyqt5-dbg/usr/lib/python3/dist-packages/dbus
-	#rm -rf $(CURDIR)/debian/python3-dbus.mainloop.pyqt5/usr/bin
-	#rm -rf $(CURDIR)/debian/python3-dbus.mainloop.pyqt5/usr/share/sip
-	#rm -rf $(CURDIR)/debian/python3-dbus.mainloop.pyqt5/usr/lib/python3/dist-packages/PyQt5
-	#rm -rf $(CURDIR)/debian/python3-dbus.mainloop.pyqt5/usr/lib/python3.*/dist-packages/PyQt5
-	#rm -rf $(CURDIR)/debian/python3-dbus.mainloop.pyqt5-dbg/usr/lib/debug/usr/bin
-	#rm -rf $(CURDIR)/debian/python3-dbus.mainloop.pyqt5-dbg/usr/lib/debug/usr/lib/python3/dist-packages/PyQt5
-	#rm -rf $(CURDIR)/debian/python3-dbus.mainloop.pyqt5-dbg/usr/lib/debug/usr/lib/python3.*/dist-packages/PyQt5
+	rm -rf $(CURDIR)/debian/python3-dbus.mainloop.pyqt5/usr/bin
+	rm -rf $(CURDIR)/debian/python3-dbus.mainloop.pyqt5/usr/share/sip
+	rm -rf $(CURDIR)/debian/python3-dbus.mainloop.pyqt5/usr/lib/python3/dist-packages/PyQt5
+	rm -rf $(CURDIR)/debian/python3-dbus.mainloop.pyqt5/usr/lib/python3.*/dist-packages/PyQt5
+	rm -rf $(CURDIR)/debian/python3-dbus.mainloop.pyqt5-dbg/usr/lib/debug/usr/bin
+	rm -rf $(CURDIR)/debian/python3-dbus.mainloop.pyqt5-dbg/usr/lib/debug/usr/lib/python3/dist-packages/PyQt5
+	rm -rf $(CURDIR)/debian/python3-dbus.mainloop.pyqt5-dbg/usr/lib/debug/usr/lib/python3.*/dist-packages/PyQt5
 
 	dh_fixperms
 	dh_compress -X.py -X.bmp -X.ui -X.sql -X.xml -X.qml -X.xpm -X.mng -X.qss. -X.xbel -Xchilling




More information about the Python-modules-commits mailing list