New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
BUG: numpy build fails with gcc version 4.9.2 #21302
Comments
@serge-sans-paille should we be adding this flag (on old gccs?) |
This is strange, because we're passing |
Group all C++ flags in one location. This avoids redundancy and makes sure we test the flags we use, and use the flags we test. Fix numpy#21302
#21306 should fix the issue |
Group all C++ flags in one location. This avoids redundancy and makes sure we test the flags we use, and use the flags we test. Fix numpy#21302
Group all C++ flags in one location. This avoids redundancy and makes sure we test the flags we use, and use the flags we test. Fix numpy#21302
@serge-sans-paille it works, thanks! |
Group all C++ flags in one location. This avoids redundancy and makes sure we test the flags we use, and use the flags we test. Fix numpy#21302
Group all C++ flags in one location. This avoids redundancy and makes sure we test the flags we use, and use the flags we test. Fix numpy#21302
Group all C++ flags in one location. This avoids redundancy and makes sure we test the flags we use, and use the flags we test. Fix numpy#21302
Group all C++ flags in one location. This avoids redundancy and makes sure we test the flags we use, and use the flags we test. Fix numpy#21302
Group all C++ flags in one location. This avoids redundancy and makes sure we test the flags we use, and use the flags we test. Fix numpy#21302
Describe the issue:
Numpy fails to build with gcc version 4.9.2 with the following error:
This should not be a problem, because C++11 standard is supported since gcc
4.8.1
.The problem is that when compiling the test code in
numpy/core/setup.py
, the-std=c++11
flag is not passed to the compiler.The default c++ standard was changed in version 6.1 from C++98 to C++14, so this issue might affect all prior gcc versions.
By monkey-patching
setup.py
to include the-std=c++11
flag, the build run successfully.Reproduce the code example:
Error message:
RuntimeError: Broken toolchain: cannot link a simple C++ program. note: A compiler with support for C++11 language features is required.
NumPy/Python version information:
1.22.3 3.8.12 (default, Jan 12 2022, 09:59:17)
[GCC 4.9.2]
The text was updated successfully, but these errors were encountered: