问题
I was trying make a file and got this error. I am a newbie. Can any one help me here.
/usr/include/c++/4.6/bits/c++0x_warning.h:32:2: error: #error This
file requires compiler and library support for the upcoming ISO C++
standard, C++0x. This support is currently experimental, and must be
enabled with the -std=c++0x or -std=gnu++0x compiler options.
How to enable with -std=c++0x
?
I used this in my makefile #CXX_VERSION_FLAG = -std=c++0x
but did not work.
Thanks, Addy
回答1:
No, just pass these flags (aka options) to the compiler. Instead of running gcc ...
, run gcc -std=c++0x ...
(or -std=c++11
for newer compilers).
回答2:
Lines in Makefiles that start with '#' are comment lines. Try removing the '#'.
来源:https://stackoverflow.com/questions/12762155/c0x-warning-h312-error