我一直在一步一步地关注着名为"django入门"的kennethlove的截屏视频.我陷入了"第6集:通用视图比Namebrand便宜".我正在尝试安装需要"Mercurial"的"django-annoying".
我使用OSX 10.8.2,当我在终端上运行时:pip install mercurial我收到以下消息.
Downloading/unpacking mercurial
Downloading mercurial-2.3.2.tar.gz (3.6MB): 3.6MB downloaded
Running setup.py egg_info for package mercurial
Python headers are required to build Mercurial
Complete output from command python setup.py egg_info:
running egg_info
creating pip-egg-info/mercurial.egg-info
writing pip-egg-info/mercurial.egg-info/PKG-INFO
writing top-level names to pip-egg-info/mercurial.egg-info/top_level.txt
writing dependency_links to pip-egg-info/mercurial.egg-info/dependency_links.txt
writing manifest file 'pip-egg-info/mercurial.egg-info/SOURCES.txt'
warning: manifest_maker: standard file '-c' not found
Python headers are required to build Mercurial
----------------------------------------
Command python setup.py egg_info failed with error code 1 in /Users/gth158a/Sites/official/poll/build/mercurial
Storing complete log in /Users/gth158a/.pip/pip.log
Run Code Online (Sandbox Code Playgroud)
我一直在寻找一个解决方案,我找到的最接近的是有人在Ubuntu中有同样的问题,但他提出的解决方案不适用于我的osx案例.
根据我的研究,我了解到引用的标题是构建应用程序的"C标题".我已经安装了我在pip中找到的包,其描述中有C头但完全没有成功.如果你能指出我正确的方向,我将不胜感激.
小智 22
我在Ubuntu上遇到了同样的问题.我使用以下命令安装了"python-dev"软件包.
sudo apt-get install python-dev
Run Code Online (Sandbox Code Playgroud)
我认为安装相同的内容对任何Linux的风格都有帮助.
小智 12
最有可能的是您没有安装命令行工具.
最简单的安装方法是打开Xcode转到首选项,下载,组件选项卡 - >命令行工具(安装)
| 归档时间: |
|
| 查看次数: |
5676 次 |
| 最近记录: |