------- Comment #2 from espindola at gcc dot gnu dot org 2010-01-12 16:29 ------- Is the undefined reference to libgcc? Is it being linked statically? When linking libgcc statically the driver has to pass -plugin-opt=-pass-through=/foo/bar/libgcc.a to ld. This is done in gcc.c:
%{static|static-libgcc:-plugin-opt=-pass-through=%(lto_libgcc)} \ %{static:-plugin-opt=-pass-through=-lc} \ So, is there a better way to detect that we are linking libgcc statically? -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=42690