The problem with jpeg in Qt is that it's included as a plugin. I don't know about the .dmg installation, as I built mine from source.
I remember that I didn't know how to fix py2app to handle this, so I used this hack: After running, py2app, I copied the contents of the Qt plugins directory to the MacOS folder inside the bundle, used install_name_tool to point the dylibs to the bundle's Qt framework, png and jpeg dylibs; and put an empty qt.conf file in the Resources folder. The other problem I had is if a user has a Qt installation in the same directory you had when you built the bundle, there will be conflicts when loading the libraries. The empty qt.conf should solve that, but qt still searches for the plugins in the installed directory first. On Mar 27, 2008, at 2:01 AM, Lukáš 'Spike' Polívka wrote: > On Sun, Mar 9, 2008 at 2:48 AM, Nathan <[EMAIL PROTECTED]> > wrote: >> On Fri, Mar 7, 2008 at 10:03 PM, Lukáš 'Spike' Polívka >> >> <[EMAIL PROTECTED]> wrote: >> >>> No luck, for some reason. What path do you suggest I should put >>> there, >>> if QtCore.so is placed in >>> Jabbim.app/Contents/Resources/lib/python2.5/lib-dynload/PyQt4/? >>> >>> This is error log from Console: >>> >>> ImportError: '/System/Library/Frameworks/Python.framework/Versions/ >>> 2.5/lib/python2.5/lib-dynload/PyQt4/QtCore.so' >>> not found >> >> Hmm. My missing stuff was pure python packages. I don't know if >> shared libraries are treated the same or not. If that were a python >> package, I would do >> sys.path.insert(0,'../Resources/lib/python2.5/lib-dynload/') >> >> ~ Nathan >> > So, in the end, Nathan was right. The following helped me: > > sys.path.insert(0, '../Resources/lib/python2.5/site-packages.zip') # > for Twisted > sys.path.insert(0, '../Resources/lib/python2.5/lib-dynload') # for > PyQt4 > > The first path is for my Twisted. The corresponding bundle-relative > path already was in sys.path, but after system-wide path. > The second path is for my PyQt4. No bundle-relative path was in > sys.path before, only system-wide (and wrong). > > Putting this to the main py (jabbim.py) seems like a mess to me, > though. > > Now… my next problem is that apparently Qt4 is bundled without > libjpeg. I have installed Trolls' official qt dmg (no compiling on my > part). Outside of the bundle, Jabbim works OK, but when run from the > bundle, JPEGs don't work. Any remedy on that? > > As a side note, setuptools==dev breaks py2app==dev, if anybody cares > to know. > > Thank you guys, you have been 'quite'* helpful so far! :) > > Lukáš > > * read 'very much' > -- > IM (XMPP/Jabber/Google Talk): [EMAIL PROTECTED] > ICQ, AIM, MSN: Never ever! > _______________________________________________ > 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