Hello,

I'm stuck somewhere between macports and py2app. I'm hopeful that someone here may be able to offer some advice on how to rectify my build environment.

Exporting DYLD_PRINT_LIBRARIES=1 and running a test app built with QtSql support and another one without it, I'm pretty sure that the following line is the clue:

dyld: loaded: /opt/local/libexec/qt4-mac/plugins/sqldrivers/ libqsqlpsql.bundle

My question is, how do I access/get/compile the PSQL support my app requires? My environment's qt4-mac, python26, and py2app are from macports. The qt4-mac has the psql dependency:

        py26-py2app-devel @0.4.2_1 (active)
        py26-pyqt4 @4.5.4_0 (active)
        qt4-mac @4.5.1_0+psql (active)
        
Thanks in advance!
Scott





On Aug 10, 2009, at 8:51 AM, Scott Frankel wrote:


Hello,

I'm troubleshooting a PyQt-PostgreSQL py2app error: "Cannot move to target thread". Note that a test app builds and runs happily. The error only comes up when I add PyQt4.QtSql' to py2app's option includes. eg:

This works:
        OPTIONS = {'argv_emulation': True, 'includes': ['sip', 'PyQt4._qt']}

This doesn't:
OPTIONS = {'argv_emulation': True, 'includes': ['sip', 'PyQt4._qt', 'PyQt4.QtSql']}

Researching the error, I've set DYLD_PRINT_LIBRARIES=1 in my shell and am looking for duplicate instances of Qt libraries. I'm not seeing anything obvious. But I also don't know exactly what to look for.

For example, should I be concerned with dyld output running the app or building it?

I created my build environment using macports. It looks like the correct libs are being accessed. The last of the dyld output looks like this:

dyld: loaded: /opt/local/libexec/qt4-mac/plugins/sqldrivers/ libqsqlpsql.bundle
dyld: loaded: /opt/local/lib/postgresql83/libpq.5.dylib
dyld: loaded: /opt/local/libexec/qt4-mac/lib/QtSql.framework/ Versions/4/QtSql dyld: loaded: /opt/local/libexec/qt4-mac/lib/QtCore.framework/ Versions/4/QtCore
dyld: loaded: /opt/local/lib/libz.1.dylib
dyld: loaded: /opt/local/lib/libssl.0.9.8.dylib
dyld: loaded: /opt/local/lib/libcrypto.0.9.8.dylib
QObject::moveToThread: Current thread (0x1d17d0) is not the object's thread (0x1a7820).
Cannot move to target thread (0x1a7820)


Suggestions?

Thanks in advance!
Scott





_______________________________________________
Pythonmac-SIG maillist  -  Pythonmac-SIG@python.org
http://mail.python.org/mailman/listinfo/pythonmac-sig

_______________________________________________
Pythonmac-SIG maillist  -  Pythonmac-SIG@python.org
http://mail.python.org/mailman/listinfo/pythonmac-sig

Reply via email to