安装工具 easyinstall mysql-python-1.2.3
我在这里阅读了一些关于 setuptools 的帖子。 很多人似乎不太喜欢它。
但我需要安装MySQL-python-1.2.3。当我这样做时,我收到此错误:
MySQL-python-1.2.3 X$ python setup.py cleanTraceback (most recent call last):
File "setup.py", line 5, in <module>
from setuptools import setup, Extension
ImportError: No module named setuptools
所以看来我需要 setuptools 并且假设它已安装。
setuptools python 主页上显示:
Setuptools 将使用匹配版本的 Python(例如 python2.4)自行安装,并将 easy_install 可执行文件放置在安装 Python 脚本的默认位置(由标准 distutils 配置文件确定,或通过Python安装)。
这是否意味着它将取代 python 中的任何默认轻松安装?
如果是这样我不想使用它。 如果是这样,我可以在不使用 setupttools 的情况下安装 MySQL-python-1.2.3 吗?
谢谢
I have read a bunch of threads on setuptools here.
A lot of people seem not to like it very much.
But I need to install MySQL-python-1.2.3. and when I do that I get this error:
MySQL-python-1.2.3 X$ python setup.py cleanTraceback (most recent call last):
File "setup.py", line 5, in <module>
from setuptools import setup, Extension
ImportError: No module named setuptools
So it seems I need setuptools and that it is assumed that it is installed.
On the setuptools python homepage it says:
Setuptools will install itself using the matching version of Python (e.g. python2.4), and will place the easy_install executable in the default location for installing Python scripts (as determined by the standard distutils configuration files, or by the Python installation).
Does this mean it will replace any default easy install from python?
If so I dont want to use it.
If so can I install MySQL-python-1.2.3 without setupttools?
Thanks
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您应该使用 virtualenv 和 pip.
Virtualenv 会在新环境中自动创建 setuptools 版本,因此默认版本保持不变。
您可能想了解打包和安装的工作原理:1, 2< /a>
You should use virtualenv and pip.
Virtualenv automatically creates a setuptools version within the new environment, so the default one is intact.
You may want to read how the packaging and installing works: 1, 2