cla*_*aws 19 python py2exe visual-c++ python-2.7
我正在尝试通过执行从源代码构建一个包 python setup.py py2exe
这是来自setup.py的代码部分,我认为是相关的:
if sys.platform == "win32": # For py2exe.
import matplotlib
sys.path.append("C:\\Program Files\\Microsoft Visual Studio 9.0\\VC\\redist\\x86\\Microsoft.VC90.CRT")
base_path = ""
data_files = [("Microsoft.VC90.CRT", glob.glob(r"C:\Program Files\Microsoft Visual Studio 9.0\VC\redist\x86\Microsoft.VC90.CRT\*.*")),
Run Code Online (Sandbox Code Playgroud)
它显示错误:
*** finding dlls needed ***
error: MSVCP90.dll: No such file or directory
Run Code Online (Sandbox Code Playgroud)
但我已经安装了"Microsoft Visual C++ 2008 Redistributable Package".我在64位Windows 8上运行32位python.我正在尝试构建一个32位的二进制文件.
此外没有这样的文件夹:"C:\ Program Files\Microsoft Visual Studio 9.0\VC\redist \".这是我的电脑包含的内容:

编辑:
在msvcp90.dll我的C:\驱动器上搜索时,我发现它们安装在奇怪的路径中,如下所示:

nne*_*neo 12
我建议完全忽略依赖.添加MSVCP90.dll到dll_excludes给定列表中作为选项py2exe.用户必须安装Microsoft Visual C++ 2008可再发行组件.一个例子:
setup(
options = {
"py2exe":{
...
"dll_excludes": ["MSVCP90.dll", "HID.DLL", "w9xpopen.exe"],
...
}
},
console = [{'script': 'program.py'}]
)
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
18229 次 |
| 最近记录: |