[PyQt] qtdirs.app can't load QtCore

Phil Thompson phil at riverbankcomputing.com
Thu Jun 25 22:46:07 BST 2009

On Thu, 25 Jun 2009 16:12:17 -0500, Dave Peterson <dpeterson at enthought.com>
> Hi Phil,
> Phil Thompson wrote:
>> I've built and installed Qt in a non-standard directory and PyQt has no
>> problems with it.
> BTW, I want to thank you for making that kind of effort.  I know it 
> takes quite awhile to build Qt from source!
> Anyway, I've temporarily given up on using a custom-compiled, 
> relocatable Qt and just want to get PyQt built.  I'm wondering if it's 
> possible to build sip and PyQt within a virtualenv linked to a 
> Python.framework build?

It's fine as far as I'm aware.

> I notice there is code in sip to try and prevent that, but I didn't see 
> any comments about why it won't work.

No, the check is making sure it *is* a framework build of Python.

> So for grins, I tried commenting 
> out the check for "Python.framework" in sys.executable and building 
> sip.  It builds just fine.  I packaged it in a relocatable egg, and 
> added a post-install script to fixup the _pkg_config dictionary in 
> sipconfig.py when the egg is installed.  There don't seem to be any 
> other paths to fix up in any other text file, nor any lib references in 
> macho headers.
> I then tried to build PyQt with the following configuration command:
> python configure.py --trace --verbose --confirm-license
>   -b /Users/dpeterson/py/qtbuild/tmp/PyQt-4.5.1-1/install/bin
>   -d /Users/dpeterson/py/qtbuild/tmp/PyQt-4.5.1-1/install
>   -p /Users/dpeterson/py/qtbuild/tmp/PyQt-4.5.1-1/install/plugin
>   -v /Users/dpeterson/py/qtbuild/tmp/PyQt-4.5.1-1/install/sip
> which runs just fine.   But the actual build dies with the following 
> error output.  Could this be related to trying to build PyQt within a 
> virtualenv?  Or is it simply something wrong with my sip install?  Or is 
> there some mismatch between PyQt 4.5.1, sip 4.8.1, and Qt 4.5.1 on OS X?
> g++ -c -pipe -fno-strict-aliasing -Os -fPIC -Wall -W -DQT_NO_DEBUG 
> -I/usr/local/Qt4.5/mkspecs/macx-g++ -I. 
> -I/Library/Frameworks/QtCore.framework/Versions/4/Headers 
> -I/usr/include/QtCore 
> -I/Library/Frameworks/QtGui.framework/Versions/4/Headers 
> -I/usr/include/QtGui -I/usr/include 
> -I/Library/Frameworks/Python.framework/Versions/4.3.0/include/python2.5 
> -I../../QtCore -I. -I. -F/Library/Frameworks -o qpycore_chimera.o 
> qpycore_chimera.cpp
> qpycore_chimera.cpp: In member function ‘bool 
> Chimera::parse_cpp_type(const QByteArray&)’:
> qpycore_chimera.cpp:392: error: too few arguments to function
> make[2]: *** [qpycore_chimera.o] Error 1
> make[1]: *** [all] Error 2
> make: *** [all] Error 2

Sound like you've got bits (maybe sip.h) of an older version of SIP lying


More information about the PyQt mailing list