Hi All,
it has been reported by some users of GUI2Exe on Windows, and it
happens to me also on Ubuntu Hardy, that a very simple Setup script
fails with a struct error with PyInstaller. The full build output for
the builtest/test1.py for me is below:
checking Analysis
building Analysis because outAnalysis0.toc non existent
running Analysis outAnalysis0.toc
Analyzing: /usr/lib/python2.5/site-packages/pyinstaller/support/
_mountzlib.py
Analyzing: /usr/lib/python2.5/site-packages/pyinstaller/support/
useUnicode.py
Analyzing: /home/user/Desktop/pyinstaller/buildtests/test1.py
Warnings written to /home/user/Desktop/pyinstaller/buildtests/
warntmpCeuOuF.txt
checking PYZ
rebuilding outPYZ1.toc because outPYZ1.pyz is missing
building PYZ outPYZ1.toc
checking PKG
rebuilding outPKG3.toc because outPKG3.pkg is missing
building PKG outPKG3.pkg
Traceback (most recent call last):
File "/usr/lib/python2.5/site-packages/pyinstaller/Build.py", line
966, in <module>
main(args[0], configfilename=opts.configfile)
File "/usr/lib/python2.5/site-packages/pyinstaller/Build.py", line
954, in main
build(specfile)
File "/usr/lib/python2.5/site-packages/pyinstaller/Build.py", line
922, in build
execfile(spec)
File "/home/user/Desktop/pyinstaller/buildtests/tmpCeuOuF.spec",
line 53, in <module>
version=None)
File "/usr/lib/python2.5/site-packages/pyinstaller/Build.py", line
561, in __init__
strip_binaries=self.strip, upx_binaries=self.upx)
File "/usr/lib/python2.5/site-packages/pyinstaller/Build.py", line
463, in __init__
self.__postinit__()
File "/usr/lib/python2.5/site-packages/pyinstaller/Build.py", line
132, in __postinit__
self.assemble()
File "/usr/lib/python2.5/site-packages/pyinstaller/Build.py", line
519, in assemble
archive.build(self.name, mytoc)
File "/usr/lib/python2.5/site-packages/pyinstaller/archive.py", line
232, in build
self.save_toc(tocpos)
File "/usr/lib/python2.5/site-packages/pyinstaller/carchive.py",
line 246, in save_toc
tocstr = self.toc.tobinary()
File "/usr/lib/python2.5/site-packages/pyinstaller/carchive.py",
line 88, in tobinary
nmlen+entrylen, dpos, dlen, ulen, flag, typcd, nm+pad))
File "/usr/lib/python2.5/struct.py", line 63, in pack
return o.pack(*args)
struct.error: argument for 's' must be a string
And the setup script I am using (automatically generated by GUI2Exe)
is below:
# ======================================================#
# File automagically generated by GUI2Exe version 0.2alpha
# Andrea Gavana, 01 April 2007
# ======================================================#
# Process the includes and excludes first
data_files = []
includes = []
excludes = ['bsddb', 'curses', 'email', '_gtkagg', 'pywin.debugger',
'pywin.debugger.dbgcon', 'pywin.dialogs', 'tcl',
'_tkagg', 'Tkconstants', 'Tkinter']
packages = []
dll_excludes = []
dll_includes = []
# Set up the more obscure PyInstaller runtime options
options = []
# This is a place where the user custom code may go. You can do almost
# whatever you want, even modify the data_files, includes and friends
# here as long as they have the same variable name that the setup call
# below is expecting.
# No custom code added
# The setup for PyInstaller is different from py2exe. Here I am going
to
# use some common spec file declarations
analysis = Analysis([u'/usr/lib/python2.5/site-packages/pyinstaller/
support/_mountzlib.py',
u'/usr/lib/python2.5/site-packages/pyinstaller/support/
useUnicode.py',
'/home/user/Desktop/pyinstaller/buildtests/test1.py'],
pathex=[],
hookspath=[],
excludes=excludes)
pyz = PYZ(analysis.pure, level=9)
executable = EXE( pyz,
analysis.scripts + includes + packages + options,
analysis.binaries - dll_excludes + dll_includes +
data_files,
name=r"test1.exe",
debug=False,
console=False,
strip=False,
upx=False,
icon=None,
version=None)
# This is a place where any post-compile code may go.
# You can add as much code as you want, which can be used, for
example,
# to clean up your folders or to do some particular post-compilation
# actions.
# No post-compilation code added
# And we are done. That's a setup script :-D
Is there anything wrong with my setup file? Am I missing something? I
am using PyInstaller from SVN 528, Python 2.5.2, on Windows and Ubuntu
Hardy (Virtual Machine).
Thank you for your suggestions.
Andrea.
--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---