I would like to have gcc or g++ default to the current standard for
4.8.2. The compiler option -dumpspecs gives (in part):
*cc1:
%{!mandroid|tno-android-cc:%(cc1_cpu) %{profile:-p};:%(cc1_cpu)
%{profile:-p} %{
!mglibc:%{!muclibc:%{!mbionic: -mbionic}}}
%{!fno-pic:%{!fno-PIC:%{!fpic:%{!fPIC
: -fPIC}}}}}
*cc1_options:
%{pg:%{fomit-frame-pointer:%e-pg and -fomit-frame-pointer are
incompatible}} %{!
iplugindir*:%{fplugin*:%:find-plugindir()}} %1 %{!Q:-quiet}
%{!dumpbase:-dumpbas
e %B} %{d*} %{m*} %{aux-info*}
%{fcompare-debug-second:%:compare-debug-auxbase-o
pt(%b)} %{!fcompare-debug-second:%{c|S:%{o*:-auxbase-strip
%*}%{!o*:-auxbase %b
}}}%{!c:%{!S:-auxbase %b}} %{g*} %{O*} %{W*&pedantic*} %{w}
%{std*&ansi&trigrap
hs} %{v:-version} %{pg:-p} %{p} %{f*} %{undef} %{Qn:-fno-ident}
%{Qy:} %{-help:-
-help} %{-target-help:--target-help} %{-version:--version}
%{-help=*:--help=%*}
%{!fsyntax-only:%{S:%W{o*}%{!o*:-o %b.s}}} %{fsyntax-only:-o %j}
%{-param*} %{fm
udflap|fmudflapth:-fno-builtin -fno-merge-constants}
%{coverage:-fprofile-arcs -
ftest-coverage}
*cc1plus:
The cc1plus is empty so I added:
%{!std*:-std=c++11}
and this seems to work for g++ but I am confused as to which cc1
entry to modify and where to modify it. Which cc1 entry should I
modify and where should I modify it?
Also, out of curiosity - when will the -std=c++11 be the default?
--Sidney Marshall