Python 无法在具有buildout的OSX 10.9上安装lxml 3.3.3

Python 无法在具有buildout的OSX 10.9上安装lxml 3.3.3,python,macos,lxml,Python,Macos,Lxml,我看过很多相关的帖子,但都没有成功。日志显示: We have no distributions for lxml that satisfies 'lxml'. Getting distribution for 'lxml'. Running easy_install: "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/Resources/Python.app/Contents/MacOS/Python" "-c" "fro

我看过很多相关的帖子,但都没有成功。日志显示:

We have no distributions for lxml that satisfies 'lxml'.
Getting distribution for 'lxml'.
Running easy_install:
"/opt/local/Library/Frameworks/Python.framework/Versions/2.7/Resources/Python.app/Contents/MacOS/Python" "-c" "from setuptools.command.easy_install import main; main()" "-mZUNxd" "/Users/brad/Development/python/eggs/tmpLpoVC3" "-q" "/var/folders/3c/mdys56lx2wbf9rjlmqy4nhy40000gn/T/tmpZx0t7aget_dist/lxml-3.3.3.tar.gz"
path=/Users/brad/Development/python/eggs/setuptools-0.7.2-py2.7.egg

/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/distutils/dist.py:267: UserWarning: Unknown distribution option: 'bugtrack_url'
  warnings.warn(msg)
In file included from src/lxml/lxml.etree.c:346:
/var/folders/3c/mdys56lx2wbf9rjlmqy4nhy40000gn/T/easy_install-XSC3pm/lxml-3.3.3/src/lxml/includes/etree_defs.h:9:10: fatal error: 'libxml/xmlversion.h' file not found
#include "libxml/xmlversion.h"
         ^
1 error generated.
error: Setup script exited with error: command '/usr/bin/clang' failed with exit status 1Building lxml version 3.3.3.
Building without Cython.
ERROR: /bin/sh: xslt-config: command not found

** make sure the development packages of libxml2 and libxslt are installed **

Using build configuration of libxslt 

An error occurred when trying to install lxml 3.3.3. Look above this message for any errors that were output by easy_install.
While:
  Installing pydev.
  Getting distribution for 'lxml'.
Error: Couldn't install: lxml 3.3.3
我试过他的答案

xcode选择-安装最初工作,直到xcode升级到10.5。然后,即使在重试这一行之后,也没有起作用。现在我总是无法安装该软件,因为软件更新服务器当前不提供该软件

已尝试此静态\u DEPS=true pip安装lxml。安装时出错:

clang: error: unknown argument: '-mno-fused-madd' [-Wunused-command-line-argument-hard-error-in-future]

clang: note: this will be a hard error (cannot be downgraded to a warning) in the future

error: command 'cc' failed with exit status 1

----------------------------------------
Cleaning up...
Command /usr/bin/python -c "import setuptools, tokenize;__file__='/private/var/folders/3c/mdys56lx2wbf9rjlmqy4nhy40000gn/T/pip_build_brad/lxml/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record /var/folders/3c/mdys56lx2wbf9rjlmqy4nhy40000gn/T/pip-4lSNM3-record/install-record.txt --single-version-externally-managed --compile failed with error code 1 in /private/var/folders/3c/mdys56lx2wbf9rjlmqy4nhy40000gn/T/pip_build_brad/lxml
Storing debug log for failure in /Users/brad/Library/Logs/pip.log
该日志文件以以下内容结尾:

创建符号链接也无济于事


感谢大家的想法,谢谢你,好的,所以再次以全新的眼光回到这个问题上来,设法解决了这个问题

错误提示:error:unknown参数:'-mno fused madd'在上面的pip安装lxml期间是关键。我发现了它,但无法让另一个python版本工作。曾尝试过MacPorts和自制软件

最后,一个提示让我删除了macport的lxml和系统安装的pip。然后在fresh上安装自制的python,偶尔强制链接,让我使用它安装的pip来运行bog标准pip安装lxml


现在运行自制的python 2.7.6和pip,用于安装lxml 3.3.3

再次尝试使用MacPorts,只是因为我有更多的历史记录,但似乎没有pip端口。如果使用/usr/local/bin/pip中的MacPorts python覆盖第一行的python解释器,那么使用system easy_install安装pip是可行的。但在尝试pip安装lxml时,由于没有模块pkg_资源,它失败了。所以现在回到自制,但那不起作用!所以我上面的“答案”证明是不可重复的。与原始问题相同的错误。仅供参考:MacPorts为所有受支持的Python版本提供pip端口;对于2.7,端口安装py27 pip。当与Xcode 5.1一起使用时,未知参数错误是苹果系统Python中的一个bug;这在OSX10.9.3中已经修复。
Cleaning up...
  Removing temporary dir /private/var/folders/3c/mdys56lx2wbf9rjlmqy4nhy40000gn/T/pip_build_brad...
Command /usr/bin/python -c "import setuptools, tokenize;__file__='/private/var/folders/3c/mdys56lx2wbf9rjlmqy4nhy40000gn/T/pip_build_brad/lxml/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record /var/folders/3c/mdys56lx2wbf9rjlmqy4nhy40000gn/T/pip-4lSNM3-record/install-record.txt --single-version-externally-managed --compile failed with error code 1 in /private/var/folders/3c/mdys56lx2wbf9rjlmqy4nhy40000gn/T/pip_build_brad/lxml
Exception information:
Traceback (most recent call last):
  File "/Library/Python/2.7/site-packages/pip-1.5.4-py2.7.egg/pip/basecommand.py", line 122, in main
    status = self.run(options, args)
  File "/Library/Python/2.7/site-packages/pip-1.5.4-py2.7.egg/pip/commands/install.py", line 283, in run
    requirement_set.install(install_options, global_options, root=options.root_path)
  File "/Library/Python/2.7/site-packages/pip-1.5.4-py2.7.egg/pip/req.py", line 1435, in install
    requirement.install(install_options, global_options, *args, **kwargs)
  File "/Library/Python/2.7/site-packages/pip-1.5.4-py2.7.egg/pip/req.py", line 706, in install
    cwd=self.source_dir, filter_stdout=self._filter_install, show_stdout=False)
  File "/Library/Python/2.7/site-packages/pip-1.5.4-py2.7.egg/pip/util.py", line 697, in call_subprocess
    % (command_desc, proc.returncode, cwd))
InstallationError: Command /usr/bin/python -c "import setuptools, tokenize;__file__='/private/var/folders/3c/mdys56lx2wbf9rjlmqy4nhy40000gn/T/pip_build_brad/lxml/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record /var/folders/3c/mdys56lx2wbf9rjlmqy4nhy40000gn/T/pip-4lSNM3-record/install-record.txt --single-version-externally-managed --compile failed with error code 1 in /private/var/folders/3c/mdys56lx2wbf9rjlmqy4nhy40000gn/T/pip_build_brad/lxml