On 10/8/2010 12:17 PM, Giovanni Bajo wrote:
On 10/8/2010 5:17 PM, Nathan Weston wrote:
I'm trying to package a trivial PyQt app with Python 2.6 on Windows.
As recommended on the Wiki, I'm using the trunk (r897) for WinSxS
support.
My exe builds without errors, but when run it can't find PyQt:
Traceback (most recent call last):
File "<string>", line 14, in<module>
File "C:\home\nathan\src\pyinstaller-trunk-r897\iu.py", line 455, in
importHook
raise ImportError, "No module named %s" % fqname
ImportError: No module named PyQt4.QtCore
The warnings file generated by Build.py includes some Qt-related
messages:
W: no module named PyQt4._qt (top-level import by PyQt4.QtGui)
W: no module named readline (delayed import by pdb)
W: no module named pwd (delayed, conditional import by posixpath)
W: no module named org (top-level import by pickle)
W: no module named posix (delayed, conditional import by iu)
W: no module named PyQt4._qt (top-level import by PyQt4)
W: no module named PyQt4._qt (top-level import by PyQt4.QtCore)
Is this expected to work on the trunk, or should I be using some other
snapshot?
No, this is supposed to work. Are you using the standard GPL installer
of PyQt from Riverbank's site or have you built PyQt yourself?
I'm using the Riverbank installer: PyQt4 GPL v4.7.4 for Python 2.6. I'm
running Windows 7 64-bit, but Python and PyQt are 32-bit.
My program looks like this:
# qthello.py
import sys
import sip
import PyQt4.QtCore
import PyQt4.QtGui
app = PyQt4.QtGui.QApplication(sys.argv)
window = PyQt4.QtGui.QMainWindow()
window.setCentralWidget(PyQt4.QtGui.QLabel("Hello"))
window.show()
sys.exit(app.exec_())
# end of qthello.py
I built it like so:
python Makespec.py qthello.py
python Build.py qthello\qthello.spec
Let me know if there's any other information I can provide.
--
You received this message because you are subscribed to the Google Groups
"PyInstaller" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/pyinstaller?hl=en.