This is the mail archive of the
gcc-help@gcc.gnu.org
mailing list for the GCC project.
Separate CFLAGS for libgcc?
- From: Fanael Linithien <fanael4 at gmail dot com>
- To: gcc-help at gcc dot gnu dot org
- Date: Mon, 4 Mar 2013 17:12:35 +0100
- Subject: Separate CFLAGS for libgcc?
Hi,
Is it possible to build libgcc with different CFLAGS than the rest of
the target libraries? Specifically, I want to build the target libraries
with -flto, but omit that option for libgcc, because LTO infos in libgcc
cause errors like this one when linking programs:
`__Unwind_Resume' referenced in section `.text' of ccAtADcl.lto.o:
defined in discarded section `.text' of unwind-dw2.o (symbol from
plugin)
Even if not for the errors, I'd still like to know how can I e.g. build
libgcc with -Os, but other libraries (especially libstdc++) with -O2.