This is the mail archive of the libstdc++@sources.redhat.com mailing list for the libstdc++ project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: patch to check ld



fche@redhat.com (Frank Ch. Eigler):
> Phil Edwards <pedwards@disaster.jaj.com> writes:
>
> > Say, during compiling, one would pass -On, and when linking, one would pass
> > -On -Ofinal.  The latter would pass on to the linker all those flags that
> > make sense for linking.  And if -Ofinal were passed during a compile-only
> > step, it would be ignored.
>
> But during a "compile-only step", when is the linker is invoked at all?

It wouldn't.  Thus, it would be ignored [by the compiler driver], e.g.,

   g++ -c -O2 -Ofinal blah.cc

g++ would ignore -Ofinal, and

   g++ -o kapucky -O2 -Ofinal blah.o

would use it in some manner.  (If the -O flags are being generated by a
make rule, then even the nonsense ones should be accepted and discarded,
like passing -L to a compile-only step.)

Just a thought; I doubt it'll happen.


Phil


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]