Commit 65a3896a by Caroline Tice Committed by Caroline Tice

Fix PR other/91396 static linke error with -fvtable-verify

Fix a bug where linking with -fvtable-verify  and
-static causes the linker to complain about multiple definitions of
things in the vtv_end*.o files (once from the .o file and once from
libvtv.a).

2019-08-12  Caroline Tice  <cmtice@google.com>

        PR other/91396
        * config/gnu-user.h (GNU_USER_TARGET_ENDFILE_SPEC): Only add the
        vtv_end.o or vtv_end_preinit.o files if !static.

From-SVN: r274386
parent 51ad8481
2019-08-13 Caroline Tice <cmtice@google.com>
PR other/91396
* config/gnu-user.h (GNU_USER_TARGET_ENDFILE_SPEC): Only add the
vtv_end.o or vtv_end_preinit.o files if !static.
2019-08-13 Olivier Hainque <hainque@adacore.com> 2019-08-13 Olivier Hainque <hainque@adacore.com>
* rtl.h (tablejump_casesi_pattern): Move declaration to proper spot. * rtl.h (tablejump_casesi_pattern): Move declaration to proper spot.
......
...@@ -73,9 +73,9 @@ see the files COPYING3 and COPYING.RUNTIME respectively. If not, see ...@@ -73,9 +73,9 @@ see the files COPYING3 and COPYING.RUNTIME respectively. If not, see
GNU userspace "finalizer" file, `crtn.o'. */ GNU userspace "finalizer" file, `crtn.o'. */
#define GNU_USER_TARGET_ENDFILE_SPEC \ #define GNU_USER_TARGET_ENDFILE_SPEC \
"%{fvtable-verify=none:%s; \ "%{!static:%{fvtable-verify=none:%s; \
fvtable-verify=preinit:vtv_end_preinit.o%s; \ fvtable-verify=preinit:vtv_end_preinit.o%s; \
fvtable-verify=std:vtv_end.o%s} \ fvtable-verify=std:vtv_end.o%s}} \
%{static:crtend.o%s; \ %{static:crtend.o%s; \
shared|static-pie|" PIE_SPEC ":crtendS.o%s; \ shared|static-pie|" PIE_SPEC ":crtendS.o%s; \
:crtend.o%s} " \ :crtend.o%s} " \
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment