[PyQt] pyqt5 dbus module not importable when built with sip 5

Antonio Rojas arojas at archlinux.org
Sat Dec 14 08:25:21 GMT 2019


If pyqt5 is built with sip 5, the dbus module is not importable due to missing PyInit_pyqt5 symbol:

> import dbus.mainloop.pyqt5
ImportError: dynamic module does not define module export function (PyInit_pyqt5)

Looking at the diff between the sip4 and sip5-generated dbus.pro, with sip4 it adds

QMAKE_LFLAGS += -Wl,--version-script=pyqt5.exp

and pyqt5.exp contains

{ global: PyInit_pyqt5; local: *; };

With sip5, it adds

QMAKE_LFLAGS += -Wl,--version-script=dbus.exp

and dbus.exp contains

{ global: PyInit_dbus; local: *; };

which looks wrong.





More information about the PyQt mailing list