[Pythonmac-SIG] PyQT on Lion?
Arana Fireheart
aranafireheart at mac.com
Tue Jul 10 18:04:31 CEST 2012
Hi,
I have been trying to build a version of Python and PyQT for some time now on my iMac (Core 2 Duo) running 10.7.4
I have not been able to get any configuration(s) to work properly. I am currently trying to build in a virtual environment using homebrew.
I have two problems that I can not seem to resolve. First I can not seem to be able to figure out how to get pyserial to install properly. Also once if I try to comment out the import serial line, I'm told that python can't find PyQT. Any ideas? This is about the fourth build I have tried, and I can't seem to ever get ALL of the pieces to work on my mac (I've build successfully in Ubuntu, running under Paralells)
Arana
Before commenting out import serial:
Aranas-BIG-Toy:GreenHouse arana$ python GreenHouse.pyw
Traceback (most recent call last):
File "GreenHouse.pyw", line 5, in <module>
import serial
ImportError: No module named serial
After commenting out import serial:
Aranas-BIG-Toy:GreenHouse arana$ python GreenHouse.pyw
Traceback (most recent call last):
File "GreenHouse.pyw", line 6, in <module>
from PyQt4 import QtCore
ImportError: No module named PyQt4
Aranas-BIG-Toy:GreenHouse arana$
Code snippet:
#!/usr/bin/env python
import os, sys
import serial
from PyQt4 import QtCore
from PyQt4 import QtGui
from greenHouse_ui import Ui_MainWindow
import GreenHouse_rc
arana$ echo $PATH
/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/usr/X11/bin:/Library/Frameworks/Python.framework/Versions/Current/bin
arana$ echo $PYTHONPATH
/usr/local/lib/python:
arana$ python
Python 2.7.1 (r271:86832, Jul 31 2011, 19:30:53)
[GCC 4.2.1 (Based on Apple Inc. build 5658) (LLVM build 2335.15.00)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
More information about the Pythonmac-SIG
mailing list