> Doesn't common.opt serve this purpose? But if I understand you
> correctly, the Ada front end alters semantics of flags in common.opt,
> which means we are in a bit of a difficult position here.
No, I meant splitting cc1_options into a base_options and cc1_options and
adding base_options only
On 04/01/2015 12:02 PM, Eric Botcazou wrote:
>> All the other in-tree front ends use it, including Java, Fortran, and Go.
>
> Out of laziness I'd say. ;-) AFAIK the Ada FE never did it.
Would it make sense to add “%(gnat1_options)”, so that Fedora can use it
specs-file-based injection for Ada pr
> All the other in-tree front ends use it, including Java, Fortran, and Go.
Out of laziness I'd say. ;-) AFAIK the Ada FE never did it.
> Would it be possible to add some other injection mechanism so that it is
> possible customize the gnat1 flags using the specs file mechanism?
Yes, defining a
On 04/01/2015 11:38 AM, Arnaud Charlet wrote:
> Well cc1_options are relevant to C (C family?) language(s), and not
> necessarily
> for Ada.
All the other in-tree front ends use it, including Java, Fortran, and Go.
> In other words, not all C or C++ switches are relevant or recognized
> by gnat
> Can we just add “%(cc1_options)”, or is there a reason why it is missing?
It is not missing, reusing cc1_options is simply problematic because different
FEs can have different needs. In particular, in Ada we need to echo the order
of -g* and -m* switches (the "%{g*&m*}" thing) and cc1_options
> {"@ada",
>"\
> %{pg:%{fomit-frame-pointer:%e-pg and -fomit-frame-pointer are
> incompatible}}\
> %{!S:%{!c:%e-c or -S required for Ada}}\
> gnat1 %{I*} %{k8:-gnatk8} %{Wall:-gnatwa} %{w:-gnatws} %{!Q:-quiet}\
> %{nostdinc*} %{nostdlib*}\
> -dumpbase
> %{.adb:%b.adb}%{.ads:%b.
gcc/ada/gcc-interface/lang-specs.h has this:
{"@ada",
"\
%{pg:%{fomit-frame-pointer:%e-pg and -fomit-frame-pointer are
incompatible}}\
%{!S:%{!c:%e-c or -S required for Ada}}\
gnat1 %{I*} %{k8:-gnatk8} %{Wall:-gnatwa} %{w:-gnatws} %{!Q:-quiet}\
%{nostdinc*} %{nostdlib*}\
-dumpbase