加入收藏 | 设为首页 | 会员中心 | 我要投稿 李大同 (https://www.lidatong.com.cn/)- 科技、建站、经验、云计算、5G、大数据,站长网!
当前位置: 首页 > 百科 > 正文

xcode – 无法在OSX上构建mercurial – 找不到Python.h

发布时间:2020-12-14 17:10:49 所属栏目:百科 来源:网络整理
导读:对于我所读到的,我需要 Python-Dev,如何在OSX上安装它? 我认为我遇到的问题是,我的Xcode没有正确安装,我没有我应该的路径. 上一个问题: Where is gcc on OSX? I have installed Xcode already 是关于我找不到gcc,现在我找不到Python.h 我应该将我的/ Devel
对于我所读到的,我需要 Python-Dev,如何在OSX上安装它?

我认为我遇到的问题是,我的Xcode没有正确安装,我没有我应该的路径.

上一个问题:

Where is gcc on OSX? I have installed Xcode already

是关于我找不到gcc,现在我找不到Python.h

我应该将我的/ Developer目录链接到/usr/???中的其他位置吗?

这是我的输出:

$sudo easy_install mercurial
Password:
Searching for mercurial
Reading http://pypi.python.org/simple/mercurial/
Reading http://www.selenic.com/mercurial
Best match: mercurial 1.5.1
Downloading http://mercurial.selenic.com/release/mercurial-1.5.1.tar.gz
Processing mercurial-1.5.1.tar.gz
Running mercurial-1.5.1/setup.py -q bdist_egg --dist-dir /tmp/easy_install-_7RaTq/mercurial-1.5.1/egg-dist-tmp-l7JP3u
mercurial/base85.c:12:20: error: Python.h: No such file or directory
...

提前致谢.

解决方法

可能取决于您拥有的Mac OSX版本,我在以下位置拥有它:

/Developer/SDKs/MacOSX10.5.sdk/System/Library/Frameworks/Python.framework/Versions/2.5/include/python2.5/Python.h
/System/Library/Frameworks/Python.framework/Versions/2.5/include/python2.5/Python.h

另外我相信Xcode附带的python版本是一个可以很好地与xcode配合使用的自定义版本,但是如果你使用另一个开发环境,你必须跳过一些箍.

(编辑:李大同)

【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容!

    推荐文章
      热点阅读