Frage

I was trying to create a stand alone executable file using Pyinstaller. The process ranging from Configure to Makespec part went fine. But while processing Build.py , the following error was shown.

  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
    checking EXE
    rebuilding outEXE2.toc because countdown missing
    building EXE from outEXE2.toc
    Appending archive to EXE /home/krishna/countdown/pyinstaller-     1.5.1/countdown/build/pyi.linux2/countdown/countdown
    checking COLLECT
    building because outCOLLECT4.toc missing or bad
    building COLLECT outCOLLECT4.toc

I was using Tkinter. Does that create any problem . If Pyinstaller doesn't work which is the other alternative available

The error message i got after using -K option for Makespec.py and following it up with Build.py is

checking Tree
building because outTree4.toc missing or bad
building Tree outTree4.toc
Traceback (most recent call last):
  File "Build.py", line 1494, in <module>
    main(args[0], configfilename=opts.configfile)
  File "Build.py", line 1472, in main
    build(specfile)
  File "Build.py", line 1429, in build
    execfile(spec)
  File "/home/krishna/countdown/pyinstaller-1.5.1/countdown/countdown.spec", line 13, in <module>
    coll = COLLECT(TkTree(), exe,
  File "Build.py", line 1401, in TkTree
    tcltree = Tree(tclroot, tclnm, excludes=['demos','encoding','*.lib'])
  File "Build.py", line 1335, in __init__
    self.__postinit__()
  File "Build.py", line 298, in __postinit__
    self.assemble()
  File "Build.py", line 1374, in assemble
    for fnm in os.listdir(dir):
OSError: [Errno 2] No such file or directory: '/usr/lib/tcl8.5'
War es hilfreich?

Lösung

This is a reported issue. PyInstaller looks in the wrong place for tcl8.5. My guess is that not all Linux distributions keep tcl in the same spot.

One user solved the error by doing this:

for me, pyinstaller is looking in /usr/lib/tcl8.5, when it should be looking in /usr/share/tcltk/tcl8.5 when I hack config.dat to override this path, it works ok

using the ubuntu 11.10

Another user had success with editing Configure.py.

Lizenziert unter: CC-BY-SA mit Zuschreibung
Nicht verbunden mit StackOverflow
scroll top