On Sat, 30 Oct 2010 13:02:38 -0500, William Kyngesburye
<[email protected]> wrote:
> I wanted to use a non-default mkspec on OS X.  On OS X 10.6 the default
> GCC is 4.2, but I want to compile with 4.0, which is macx-g++40 in
Qt-land.
> 
> First thing I noticed is that SIP uses its own set of mkspecs.  Why not
> use mkspecs from Qt?

Because SIP is not specific to Qt.

> So, I duplicated SIP's macx-g++ mkspec as macx-g++40 and changed
QMAKE_CC
> and QMAKE_CXX to the 4.0 versioned executables.  Then I use configure -p
> option to set the mkspec for SIP to use.  This all works fine.
> 
> On to PyQt.  It starts out fine, but quickly drops back to using "g++". 
> qpy is the only one that used "g++-4.0" for compilation (maybe it's
getting
> CC/CXX from sipconfig?  I couldn't figure this one out).  All the
libraries
> (frameworks) use "g++".

PyQt uses the spec files from Qt, not the spec files from SIP.

> I traced it to configure.py, get_build_macros(), where it forces
> "macx-g++" for darwin and "default" for everything else.  Why doesn't
PyQt
> use the platform config value from SIP?

Because the default on Mac is to use XCode. Maybe a better thing to do
would be only force macx-g++ when the detected value is macx-xcode.

> Sure, I can set QMAKESPEC in the
> shell environment, but I was expecting PyQt to get everything from SIP.
> 
> 
> I guess the SIP local mkspecs copy is the main problem.  Everything else
I
> can work around with configuration and environment settings, but the SIP
> mkspecs problem requires a hack.

Linux distros have a history of "improving" the spec files. PyQt should be
built with the same compiler flags as Qt, which is why PyQt uses the spec
files from Qt.

Phil
_______________________________________________
PyQt mailing list    [email protected]
http://www.riverbankcomputing.com/mailman/listinfo/pyqt

Reply via email to