py2exe不是一个有效的win32应用程序

问题描述:

我知道这个话题已经讨论过,但它看起来像没有任何解决方案为我工作。py2exe不是一个有效的win32应用程序

我已经创建了一个使用PySide和一些其他模块的python应用程序。 当我编译应用程序时,我没有看到任何错误,并且它在任何64位机器上都没有问题。

然而,当我尝试从一个32位的XP机器启动它,我得到

py2exe not a valid win32 application 

我知道DLL的已经被列入(我没有保存在与微软分dist文件夹文件夹),但我仍然在CMD窗口中看到一条消息,指出某些DLL不包括在内。

这是标准讯息吗?一种提醒,或者如果包含所有的dll,这个消息会消失吗?我没有得到任何错误。

因此,那是我的困惑来自。 我也做了一些关于其他编译器的谷歌搜索,并且遇到了PyInstaller,这显然不适用于Qt

py2exe日志

*** binary dependencies *** 

Your executable(s) also depend on these dlls which are not included, 
you may or may not need to distribute them. 

Make sure you have the license if you distribute any of them, and 
make sure you don't distribute files belonging to the operating system. 

    OLEAUT32.dll - C:\Windows\system32\OLEAUT32.dll 
    USER32.dll - C:\Windows\system32\USER32.dll 
    IMM32.dll - C:\Windows\system32\IMM32.dll 
    SHELL32.dll - C:\Windows\system32\SHELL32.dll 
    ole32.dll - C:\Windows\system32\ole32.dll 
    WINMM.dll - C:\Windows\system32\WINMM.dll 
    MSVCR100.dll - C:\Windows\system32\MSVCR100.dll 
    WSOCK32.dll - C:\Windows\system32\WSOCK32.dll 
    MSVCP100.dll - C:\Windows\system32\MSVCP100.dll 
    COMDLG32.dll - C:\Windows\system32\COMDLG32.dll 
    ADVAPI32.dll - C:\Windows\system32\ADVAPI32.dll 
    WS2_32.dll - C:\Windows\system32\WS2_32.dll 
    WINSPOOL.DRV - C:\Windows\system32\WINSPOOL.DRV 
    GDI32.dll - C:\Windows\system32\GDI32.dll 
    KERNEL32.dll - C:\Windows\system32\KERNEL32.dll 

它实际上与MVS DLL无关! 该DLL问题与Pyside有关。 尽管我从Pyside页面下载了32位版本,但只有从here安装32位Pyside二进制文件后,问题才得到修复!

是否有可能的EXE文件/ DLL是64位的建立?检查您是否在32位Windows XP计算机上部署了正确的体系结构可执行文件。

+0

嗨,谢谢你的回答。这也是我的假设,所以我删除了一切,并重新安装了python和py2exe 32位..现在建成后,我甚至不能在我自己的(64位)机器上运行它。 – T1M

+0

创建一个日志文件包含以下内容: 回溯(最近通话最后一个): 文件“KruttschnittGmbH.py”,1号线,在 文件“Splash.pyc”,1号线,在 文件“ PySide \ QtGui.pyc“,第12行,在 文件”PySide \ QtGui.pyc“,第10行,在__load ImportError:DLL加载失败:%1不是有效的Win32应用程序。 – T1M

+1

你有没有正确的DLLs for pyqt部署到你的64位开发机器? –