0
reating build/temp.macosx-10.9-intel-2.7
creating build/temp.macosx-10.9-intel-2.7/Cython
creating build/temp.macosx-10.9-intel-2.7/Cython/Plex
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/System/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7 -c Cython/Plex/Scanners.c -o build/temp.macosx-10.9-intel-2.7/Cython/Plex/Scanners.o
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

I got this error while installing Cython from setup.py. I was installing the scikit-learn package while get the same error. (-mno-fused-madd unknown argument)

Is there anything, any package needed before I install cython?

Many thanks

hihell
  • 936
  • 1
  • 10
  • 20
  • You don't actually need Cython to install scikit-learn, only to modify it. – Fred Foo Apr 01 '14 at 09:14
  • It is related to the new xcode command line tools. It broke quite a lot in the python mac world. See here for a solution: http://stackoverflow.com/a/22427311/870769 – sthzg Apr 30 '14 at 17:50

1 Answers1

0

You need probably need to install another C compiler. Try compiling it with GCC.

clang: error: unknown argument: '-mno-fused-madd'

Alternatively, you can edit the configure script and change the compiler flags.

On a side note, this seems like it is a bug you should report.

oz123
  • 27,559
  • 27
  • 125
  • 187
  • would you please indicate which flag I should change to? – hihell Mar 31 '14 at 06:02
  • Just remove the flag. Clang is telling you it does not know this flag. Although clang is gaining ground, GCC is de-facto the standard for many FOSS project. Hence, I would also try compiling it with GCC. – oz123 Mar 31 '14 at 06:15