1

When I try to install numpy in a virtualenv (I can't try a system-wide installation) it fails with the following error:

RuntimeError: Broken toolchain: cannot link a simple C program

here's some output that seems useful:

$ pip install --upgrade numpy | grep -i "error\|gcc\|warning"

warning: no previously-included files matching '*.pyc' found anywhere in distribution
warning: no previously-included files matching '*.pyo' found anywhere in distribution
warning: no previously-included files matching '*.pyd' found anywhere in distribution
/usr/lib64/python2.7/distutils/dist.py:267: UserWarning: Unknown distribution option: 'define_macros'
warnings.warn(msg)
C compiler: gcc -pthread -fno-strict-aliasing -fmessage-length=0 -grecord-gcc-switches -fstack-protector -O2 -Wall -D_FORTIFY_SOURCE=2 -funwind-tables -fasynchronous-unwind-tables -g -DNDEBUG -fmessage-length=0 -grecord-gcc-switches -fstack-protector -O2 -Wall -D_FORTIFY_SOURCE=2 -funwind-tables -fasynchronous-unwind-tables -g -DOPENSSL_LOAD_CONF -fPIC
gcc: _configtest.c
cc1: error: unrecognised debug output level "record-gcc-switches"
cc1: error: unrecognised debug output level "record-gcc-switches"
cc1: error: unrecognised debug output level "record-gcc-switches"
cc1: error: unrecognised debug output level "record-gcc-switches"
raise RuntimeError("Broken toolchain: cannot link a simple C program")
RuntimeError: Broken toolchain: cannot link a simple C program
/usr/lib64/python2.7/distutils/dist.py:267: UserWarning: Unknown distribution option: 'define_macros'
warnings.warn(msg)
C compiler: gcc -pthread -fno-strict-aliasing -fmessage-length=0 -grecord-gcc-switches -fstack-protector -O2 -Wall -D_FORTIFY_SOURCE=2 -funwind-tables -fasynchronous-unwind-tables -g -DNDEBUG -fmessage-length=0 -grecord-gcc-switches -fstack-protector -O2 -Wall -D_FORTIFY_SOURCE=2 -funwind-tables -fasynchronous-unwind-tables -g -DOPENSSL_LOAD_CONF -fPIC
gcc: _configtest.c
cc1: error: unrecognised debug output level "record-gcc-switches"
cc1: error: unrecognised debug output level "record-gcc-switches"
cc1: error: unrecognised debug output level "record-gcc-switches"
cc1: error: unrecognised debug output level "record-gcc-switches"
raise RuntimeError("Broken toolchain: cannot link a simple C program")
RuntimeError: Broken toolchain: cannot link a simple C program

I'm running gcc version 4.4.7 on openSUSE 13.1 (x86_64).

user9886
  • 301
  • 3
  • 11
  • Curious, can we know which version of gcc you are using, and on which OS? I'm assuming you installed gcc from your OS repository and not by hand? – ErlVolton Nov 04 '14 at 16:20
  • @ErlVolton, I've updated my question. I'm running gcc version 4.4.7 on openSUSE 13.1 (x86_64). I assume it was installed from the OS repo. – user9886 Nov 04 '14 at 16:31
  • That's a very old compiler. You might be out of luck. :-( – ams Nov 04 '14 at 16:52
  • If you are really using opensuse 13.1 you can easily install a newer version of gcc http://software.opensuse.org/package/gcc – Christian Rapp Nov 05 '14 at 16:38
  • @ChristianRapp, I could If I had root rights. – user9886 Nov 06 '14 at 10:34

1 Answers1

0

Updating gcc (e.g. to 4.7.4) solves this Problem.

user9886
  • 301
  • 3
  • 11