Details
-
Bug
-
Status: Closed
-
Major - P3
-
Resolution: Won't Fix
-
None
-
None
-
None
-
Fully Compatible
-
ALL
Description
Apparently gcc provided by certain Linux vendors automatically defines _FORTIFY_SOURCE internally. This leads to build failure when not using --disable-warnings-as-errors. The error message leads you to believe your compiler can't be used to build MongoDB:
Checking for glibc with non-broken _FORTIFY_SOURCE...yes
|
Checking if C compiler supports -fno-builtin-memcmp... no
|
Checking for storage class thread_local no
|
Checking for storage class __thread no
|
Checking for storage class __declspec(thread) no
|
Compiler must support a thread local storage class for trivially constructible types
|
See /home/behackett/work/mongo/build/scons/config.log for details
|
This is with gcc 6.3 on Gentoo Linux. I'm attaching the scons config.log for details.
$ gcc --version
|
gcc (Gentoo 6.3.0 p1.0) 6.3.0
|
We should probably fix the redefinition problem, or at least provide a more accurate error message. Building with --disable-warnings-as-errors works around the problem, but scons spews warnings about _FORTIFY_SOURCE non-stop throughout the build.
<command-line>:0:0: warning: "_FORTIFY_SOURCE" redefined
|
<built-in>: note: this is the location of the previous definition
|
<command-line>:0:0: warning: "_FORTIFY_SOURCE" redefined
|
<built-in>: note: this is the location of the previous definition
|
....
|
Attachments
Issue Links
- links to