Question

I am trying to install lxml on 10.9.2 Mavericks and i used all the solutions mentioned here before but i seem to get a different error, the argument '-mno-fused-madd' is unknown, i believe it just triggered a warning back then, but now it throws an error here's the log

cc -fno-strict-aliasing -fno-common -dynamic -arch x86_64 -arch i386 -g -Os -pipe -fno-common -fno-strict-aliasing -fwrapv -mno-fused-madd -DENABLE_DTRACE -DMACOSX -DNDEBUG -Wall -Wstrict-prototypes -Wshorten-64-to-32 -DNDEBUG -g -fwrapv -Os -Wall -Wstrict-prototypes -DENABLE_DTRACE -arch x86_64 -arch i386 -pipe -I/usr/include/libxml2 -I/Users/workspace/mybooktype/build/lxml/src/lxml/includes -I/System/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7 -c src/lxml/lxml.etree.c -o build/temp.macosx-10.9-intel-2.7/src/lxml/lxml.etree.o -w -flat_namespace

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

UPDATE 1 i was originally trying to install the django app booktype so following the instructions i tried first

pip install lxml --install-option="--with-xml2-config=/usr/local/Cellar/libxml2/2.8.0/bin/xml2-config"
Was it helpful?

Solution 2

So the problem had nothing to do with the C compiler, it was in the python version used on the machine, apparently there was a conflict in python versions, a new clean installation of python solved the problem, and the .bash_profile. then we used the original command

pip install lxml

and it was successfully installed

OTHER TIPS

you should install or upgrade command line tool for xcode. please try command in terminal:

xcode-select --install
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top