使用PyInstaller将Tkinter应用程序编译为可执行文件?

时间:2015-08-03 23:38:56

标签: python python-2.7 tkinter pyinstaller

我使用pyinstaller将我的Tkinter应用程序编译为OSX 10.10.3上的独立可执行文件,但是当我运行已编译的应用程序时,我的终端显示

    Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/PyInstaller/loader/pyi_importers.py", line 270, in load_module
    exec(bytecode, module.__dict__)
  File "/Users/rylan/Documents/PingerGUI/build/pingergui/out00-PYZ.pyz/Tkinter", line 39, in <module>
  File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/PyInstaller/loader/pyi_importers.py", line 409, in load_module
    module = imp.load_module(fullname, fp, filename, self._c_ext_tuple)
ImportError: dlopen(/Users/rylan/Documents/PingerGUI/dist/pingergui/_tkinter.so, 2): Library not loaded: @loader_path/Tcl
  Referenced from: /Users/rylan/Documents/PingerGUI/dist/pingergui/_tkinter.so
  Reason: image not found
logout

[Process completed]

我认为这意味着Tkinter没有被加载?有办法解决这个问题吗?

0 个答案:

没有答案