[PyQt] Need help installing PyQt on Snow Leopard
bruce306 at rogers.com
Sat Dec 19 03:33:09 GMT 2009
Thanks, Darren - That's a good start, and I can try to follow that.
My first challenge is getting back to the 64 bit python. (By the way, is there a way to tell, once I have it, whether it is 32 bit or 64 bit?)
Macport sounds like a WONDERFUL idea! I noticed your comments were prefaced with "if you are not using macports..." I have just installed it, but want to do some sanity checks before I start trashing my system. I did a SEARCH and found Python26 - but there is no reference to it being 32 or 64 bit - how do I know it is the 'right' (64 bit) one?
If I understand your notes below, I should macport "qt4-mac-devel" because the "qt4-mac" is actually 4.5.3 and the one I really want is 4.6.0?
I notice that there is also a py26-sip that macport found - I assume that is the right one to install after python.
I also found a macport for py26-pyqt4. Will macport'ing this complete the installation? (i.e. replace the instructions you gave below?)
Sorry to ask so many dumb questions, but the environment is still a bit alien to me.
From: Darren Dale <dsdale24 at gmail.com>
To: Bruce Anderson <bruce306 at rogers.com>
Cc: pyqt at riverbankcomputing.com
Sent: Fri, December 18, 2009 5:40:06 PM
Subject: Re: [PyQt] Need help installing PyQt on Snow Leopard
On Fri, Dec 18, 2009 at 4:43 PM, Bruce Anderson <bruce306 at rogers.com> wrote:
> I tired the standard instructions from Mark Summerfield's book. Failed - 64
> bit vs 32 bit. I successfully installed a new version of Python (2.6.4),
> the XCode from the install disk, Qt (Carbon, I think - 32 bit?), and SIP.
> Only PyQt failed.
If you installed python-2.6.4 from a binary distributed by python.org,
then that is probably the source of the problem. Their mac binaries do
not support 64 bits at the time of this writing. I suggest either
using the python that ships with snow leopard or using macports,
depending on your preference.
> Then I found Darren Dale's note from Dec 2nd and tried the .dmg that he
> referenced. (Cocoa? - 64 bit)
> That failed too. I've confirmed that PyQt has not been successfully
> installed, but at this point, I don't know what kind of a mess I've left my
> machine in. Do I have to worry about having two versions of Qt on my
> machine? NOTE: I've been in the PC world for decades, but have only been in
> the MAC world since Thursday - so I don't really know my way around yet.
> I have two very explicit questions:
> 1) Can anyone post clear instructions (step by step, including where to put
> things) on how to get PyQt working for the first time on Snow Leopard
> (10.6.1 is what I have).
I don't have time to spell out each step. Here is what I can offer if
you are not using macports or fink:
* for now, use the python installed by snow leopard, not the binaries
distributed at python.org
* 64-bit Qt binary:
python configure.py -n -d /Library/Python/2.6/site-packages -b
/usr/local/bin -e /usr/local/include -v /usr/local/share/sip
--arch=x86_64 -s MacOSX10.6.sdk
python configure.py -d /Library/Python/2.6/site-packages -b
I've also added the following to my ~/.profile, which distutils
respects when compiling extensions (this is probably not terribly
relevant to PyQt4):
export ARCHFLAGS="-arch x86_64"
I don't have experience with Fink, but as of a few days ago I cleaned
out my system and am now using macports. I am not advocating this
approach, since I don't have enough experience with macports to
provide an informed opinion. But for the record, I made a local port
repository and copied the portfile for qt4-mac-devel (which provides
qt-4.6.0 with support for cocoa) and saved it as qt4-mac (the qt4-mac
port provided by macports should provide qt-4.5.3 but I ran into a
compilation problem with that version:
http://trac.macports.org/ticket/22926). PyQt4 appears to be working
with this installation method.
> 2) Do I have to worry about any messes left behind by the failed install
> attempts? Does the new install just clean it up? If YES, how do I go about
> finding the things I have to clean up?
I think the Qt installs probably overwrote each other. But you might
want to delete the old Qt installation (move the folders to the trash)
and reinstall if you continue to have problems. I dont think this
should be necessary.
PyQt mailing list PyQt at riverbankcomputing.com
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the PyQt