在 64 位 Windows 上安装 SetupTools [英] Installing SetupTools on 64-bit Windows
问题描述
我在 64 位 Windows 7 上运行 Python 2.7,当我运行 setuptools 的安装程序时,它告诉我未安装 Python 2.7.具体的错误信息是:
I'm running Python 2.7 on Windows 7 64-bit, and when I run the installer for setuptools it tells me that Python 2.7 is not installed. The specific error message is:
`Python Version 2.7 required which was not found in the registry`
我安装的 Python 版本是:
My installed version of Python is:
`Python 2.7 (r27:82525, Jul 4 2010, 07:43:08) [MSC v.1500 64 bit (AMD64)] on win32`
我正在查看 setuptools 站点,它没有提到任何适用于 64 位 Windows 的安装程序.我错过了什么还是我必须从源代码安装它?
I'm looking at the setuptools site and it doesn't mention any installers for 64-bit Windows. Have I missed something or do I have to install this from source?
推荐答案
显然(在 OS X 上遇到过相关的 64 位和 32 位问题)有一个 Windows 安装程序中的错误.我偶然发现了 这个解决方法,这可能会有所帮助 -基本上,您创建自己的注册表值 HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Python\PythonCore\2.6\InstallPath
并复制 HKEY_LOCAL_MACHINE\SOFTWARE\Python\PythonCore\2.6\InstallPath<中的 InstallPath 值/代码>.有关详细信息,请参阅下面的答案.
Apparently (having faced related 64- and 32-bit issues on OS X) there is a bug in the Windows installer. I stumbled across this workaround, which might help - basically, you create your own registry value HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Python\PythonCore\2.6\InstallPath
and copy over the InstallPath value from HKEY_LOCAL_MACHINE\SOFTWARE\Python\PythonCore\2.6\InstallPath
. See the answer below for more details.
如果您这样做,请注意 setuptools 可能只安装 32 位库.
If you do this, beware that setuptools may only install 32-bit libraries.
注意:下面的回复提供了更多细节,所以也请阅读它们.
NOTE: the responses below offer more detail, so please read them too.
这篇关于在 64 位 Windows 上安装 SetupTools的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!