aboutsummaryrefslogtreecommitdiff
path: root/gold/testsuite
diff options
context:
space:
mode:
Diffstat (limited to 'gold/testsuite')
-rw-r--r--gold/testsuite/Makefile.am15
-rw-r--r--gold/testsuite/Makefile.in14
2 files changed, 21 insertions, 8 deletions
diff --git a/gold/testsuite/Makefile.am b/gold/testsuite/Makefile.am
index aa41290..52cc05e 100644
--- a/gold/testsuite/Makefile.am
+++ b/gold/testsuite/Makefile.am
@@ -19,18 +19,25 @@ AM_CPPFLAGS = \
-DLOCALEDIR="\"$(datadir)/locale\"" \
@INCINTL@
+# Some versions of GCC now automatically enable linker plugins,
+# but we want to run our tests without GCC's plugins.
+if HAVE_NO_USE_LINKER_PLUGIN
+OPT_NO_PLUGINS = -fno-use-linker-plugin
+endif
+
# COMPILE1, LINK1, CXXCOMPILE1, CXXLINK1 are renamed from COMPILE, LINK,
# CXXCOMPILE and CXXLINK generated by automake 1.11.1. FIXME: they should
# be updated if they are different from automake used by gold.
COMPILE1 = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
$(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
-LINK1 = $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@
+LINK1 = $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(OPT_NO_PLUGINS) \
+ $(AM_LDFLAGS) $(LDFLAGS) -o $@
CXXCOMPILE1 = $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
$(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS)
-CXXLINK1 = $(CXXLD) $(AM_CXXFLAGS) $(CXXFLAGS) $(AM_LDFLAGS) $(LDFLAGS) \
- -o $@
+CXXLINK1 = $(CXXLD) $(AM_CXXFLAGS) $(CXXFLAGS) $(OPT_NO_PLUGINS) \
+ $(AM_LDFLAGS) $(LDFLAGS) -o $@
-# Strip out -Wp,-D_FORTIFY_SOURCE=, which is rrelevant for the gold
+# Strip out -Wp,-D_FORTIFY_SOURCE=, which is irrelevant for the gold
# testsuite and incompatible with -O0 used in gold tests, from
# COMPILE, LINK, CXXCOMPILE and CXXLINK.
COMPILE = `echo $(COMPILE1) | sed -e 's/-Wp,-D_FORTIFY_SOURCE=[0-9[0-9]]*//'`
diff --git a/gold/testsuite/Makefile.in b/gold/testsuite/Makefile.in
index 60c2c10..da0a338 100644
--- a/gold/testsuite/Makefile.in
+++ b/gold/testsuite/Makefile.in
@@ -2096,21 +2096,27 @@ AM_CPPFLAGS = \
@INCINTL@
+# Some versions of GCC now automatically enable linker plugins,
+# but we want to run our tests without GCC's plugins.
+@HAVE_NO_USE_LINKER_PLUGIN_TRUE@OPT_NO_PLUGINS = -fno-use-linker-plugin
+
# COMPILE1, LINK1, CXXCOMPILE1, CXXLINK1 are renamed from COMPILE, LINK,
# CXXCOMPILE and CXXLINK generated by automake 1.11.1. FIXME: they should
# be updated if they are different from automake used by gold.
COMPILE1 = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
$(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
-LINK1 = $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@
+LINK1 = $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(OPT_NO_PLUGINS) \
+ $(AM_LDFLAGS) $(LDFLAGS) -o $@
+
CXXCOMPILE1 = $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
$(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS)
-CXXLINK1 = $(CXXLD) $(AM_CXXFLAGS) $(CXXFLAGS) $(AM_LDFLAGS) $(LDFLAGS) \
- -o $@
+CXXLINK1 = $(CXXLD) $(AM_CXXFLAGS) $(CXXFLAGS) $(OPT_NO_PLUGINS) \
+ $(AM_LDFLAGS) $(LDFLAGS) -o $@
-# Strip out -Wp,-D_FORTIFY_SOURCE=, which is rrelevant for the gold
+# Strip out -Wp,-D_FORTIFY_SOURCE=, which is irrelevant for the gold
# testsuite and incompatible with -O0 used in gold tests, from
# COMPILE, LINK, CXXCOMPILE and CXXLINK.
COMPILE = `echo $(COMPILE1) | sed -e 's/-Wp,-D_FORTIFY_SOURCE=[0-9[0-9]]*//'`