[PyKDE] Building SIP + PyQt [3.2rc4] on Mac OS X

SNYDER, BARRON F (AIT) bs1535 at sbc.com
Fri May 3 16:57:01 BST 2002


Is there any way to get the older PyQt 3.2rc2? The snapshots directory only
shows the latest build of PyQt 3.2rc4.

And before installing an older version (or any version, for that matter), is
it best to uninstall any previous versions? If so, what is the best way to
do this?

Thanks,
Barron

-----Original Message-----
From: Dimitri Papadopoulos [mailto:papadopo at remove.shfj.decoy.cea.fr]
Sent: Thursday, May 02, 2002 12:33 PM
To: pykde at mats.gmd.de
Subject: [PyKDE] Building SIP + PyQt [3.2rc4] on Mac OS X


Hi,

This is a report on building SIP+PyQt on Mac OS X using the following:

Mac OS X 10.1.3
	I understand 10.1 is suggested by Trolltech: 
	http://www.trolltech.com/developer/platforms/osx.html

December 2001 Mac OS X Developer Tools

SIP 3.2rc4
	
http://www.riverbankcomputing.co.uk/download/snapshots/sip-3.2rc1.tar.gz
	Note that SIP 3.1 has a minor bug that results in a
	linker error.
	SIP 3.2rc1 and later fix that issue.
	I suggest you use SIP 3.2rc4.

PyQt 3.2rc4 for Mac OS X
	
http://www.riverbankcomputing.co.uk/download/snapshots/PyQt-3.2rc4-Qt-3.0.2-
MacX.tar.gz
        Note that unfortunately PyQt 3.2rc4 has some problems
	described below.
	--> Maybe it's best to stick to PyQt 3.2rc2 for now.

Qt/Mac evaluation version
        http://www.trolltech.com/products/qt/evaluate.html

Python for Mac OS X
	http://fink.sourceforge.net/pdb/package.php/python
	There are two versions of Python for Mac OS X:
	* the above Python for Mac OS X which can be run
	  from the command line
	* the traditional MacPython that knows nothing of
	  command lines and UNIX
	Because MacPython cannot be called from the command
	line and I couldn't even identify a Python executable,
	and because PyQt requires the Python executable to be
	indetified using the --with-python=FILE option, we
	were not able to configure PyQt with MacPython.
	See also paragraph "MacOS X command-line interpreter"
	on this page:
	http://www.cwi.nl/~jack/macpython.html
	I suggest you use Python for Mac OS X from Fink.


Here's how to build SIP 3.2rc4:

1) First "configure", depending on how Python is set up:
        ./configure
        ./configure --with-python=/sw/bin/python
        ./configure --with-python=/usr/local/python-2.2.1/bin/python
2) The resulting libtool script in the top-level directory is broken,
   probably  because of a bug in autoconf. Please find the line beginning
   with
   archive_cmds="\$nonopt \$(test \\"x\$module\\" = xyes
   and change to
   archive_cmds="\$nonopt \$(test \"x\$module\" = xyes
   If you forget this, the build system will build *.dylib
   shared libraries instead of *.so modules or bundles.
3) Then "make".
4) Then "make install". You should probably be root for that. In any
   case that's how I work here.


Here's how to build PyQt 3.2rc4:
1) First "configure", depending on how Python and Qt are set up:
   	./configure -with-qtdir=/usr/local/qt --with-python=/sw/bin/python
2) The resulting libtool script in the top-level directory is broken,
   probably  because of a bug in autoconf. Please find the line beginning
   with
   archive_cmds="\$nonopt \$(test \\"x\$module\\" = xyes
   and change to
   archive_cmds="\$nonopt \$(test \"x\$module\" = xyes
   If you forget this, the build system will build *.dylib
   shared libraries instead of *.so modules or bundles.
3) Then "make".
   You'll see warnings of the kind described in 
   	http://mats.gmd.de/pipermail/pykde/2002-April/002540.html
   	http://mats.gmd.de/pipermail/pykde/2002-April/002555.html
   and end with:
   	cpp-precomp: warning: errors during smart preprocessing,
   	retrying in basic mode
   These warnings can be safely ignored. They're the result of
   a harmless compiler bug:
   	http://www.wxwindows.org/faqmac.htm#smarterrors
4) Then "make install". You should probably be root for that. In any
   case that's how I work here.
   This will fail and I have no clue for now. It appears that static
   libraries are created instead of modules (bundles) so the test
   scripts that "import qt" fail:
   	$ ls PyQt-3.2rc4/.libs:
	libqtcmodule.a        libqtcmodule.la@      libqtcmodule.lai
5) Using PyQt 3.2rc2 is probably the easiest way to have PyQT up and
   running for now.

_______________________________________________
PyKDE mailing list    PyKDE at mats.gmd.de
http://mats.gmd.de/mailman/listinfo/pykde




More information about the PyQt mailing list