And*_*ndy 3 python pip windows-7 python-imaging-library
在我的一台Windows 7开发机器上,我正在尝试安装Python Image Library.
我的机器很相似.两者都运行Windows 7 Professional,x64.两者都使用Python 2.7.3(32位).其中一台机器pip install PIL工作正常.另一方面它失败,跟踪结束于此:
build\temp.win-amd64-2.7\Release\_imaging.pyd.manifest : general error c1010070:
Failed to load and parse the manifest. The system cannot find the file specified.
error: command 'mt.exe' failed with exit status 31
Run Code Online (Sandbox Code Playgroud)
我该如何解决这个错误?
frm*_*ryr 31
感谢http://bugs.python.org/issue4431,修改了以下错误:
C:\<Python dir>\Lib\distutils\msvc9compiler.py
Run Code Online (Sandbox Code Playgroud)
并添加:
ld_args.append('/MANIFEST')
Run Code Online (Sandbox Code Playgroud)
在MANIFESTFILE行之后,它看起来像:
# Embedded manifests are recommended - see MSDN article titled
# "How to: Embed a Manifest Inside a C/C++ Application"
# (currently at http://msdn2.microsoft.com/en-us/library/ms235591(VS.80).aspx)
# Ask the linker to generate the manifest in the temp dir, so
# we can embed it later.
temp_manifest = os.path.join(
build_temp,
os.path.basename(output_filename) + ".manifest")
ld_args.append('/MANIFESTFILE:' + temp_manifest)
ld_args.append('/MANIFEST')
Run Code Online (Sandbox Code Playgroud)
如果仍然出现错误,然后更改if arg.startswith("/MANIFESTFILE:")到if arg.startswith("/MANIFEST:")的manifest_get_embed_info(self, target_desc, ld_args)方法.
| 归档时间: |
|
| 查看次数: |
5241 次 |
| 最近记录: |