aboutsummaryrefslogtreecommitdiff
path: root/ld/Makefile.in
diff options
context:
space:
mode:
authorNick Clifton <nickc@redhat.com>2016-09-06 17:35:35 +0100
committerNick Clifton <nickc@redhat.com>2016-09-06 17:35:35 +0100
commit22d6c51be8de9a091d89c0e11e6e140f333ade62 (patch)
tree4446d26c5d5432641dd9aa5218bd8601a505ffbc /ld/Makefile.in
parent00d5215ecec4fa0a78dcc37fec9425593753eb66 (diff)
downloadgdb-22d6c51be8de9a091d89c0e11e6e140f333ade62.zip
gdb-22d6c51be8de9a091d89c0e11e6e140f333ade62.tar.gz
gdb-22d6c51be8de9a091d89c0e11e6e140f333ade62.tar.bz2
Do not pass host compiler sanitization flags on to linker testsuite.
* Makefile.am (CFLAGS_FOR_TARGET): Define as a copy of CFLAGS but without any sanitization options. (CXXFLAGS_FOR_TARGET): Define as a copy of CXXFLAGS but without any sanitization options. (check-DEJAGNU): Pass CFLAGS_FOR_TARGET and CXXFLAGS_FOR_TARGET as CFLAGS and CXXFLAGS respectively.
Diffstat (limited to 'ld/Makefile.in')
-rw-r--r--ld/Makefile.in8
1 files changed, 6 insertions, 2 deletions
diff --git a/ld/Makefile.in b/ld/Makefile.in
index 1ce019a..48b7ba7 100644
--- a/ld/Makefile.in
+++ b/ld/Makefile.in
@@ -507,6 +507,10 @@ CXX_FOR_TARGET = ` \
fi; \
fi`
+
+# Strip out sanitization options as they require special host libraries.
+CFLAGS_FOR_TARGET = `echo $(CFLAGS) | sed -e 's/-fsanitize=address//g' -e 's/-fsanitize=undefined//g'`
+CXXFLAGS_FOR_TARGET = `echo $(CXXFLAGS) | sed -e 's/-fsanitize=address//g' -e 's/-fsanitize=undefined//g'`
info_TEXINFOS = ld.texinfo
ld_TEXINFOS = configdoc.texi
noinst_TEXINFOS = ldint.texinfo
@@ -3644,8 +3648,8 @@ check-DEJAGNU: site.exp
runtest=$(RUNTEST); \
if $(SHELL) -c "$$runtest --version" > /dev/null 2>&1; then \
$$runtest --tool $(DEJATOOL) --srcdir $${srcroot}/testsuite \
- CC="$(CC_FOR_TARGET)" CFLAGS="$(CFLAGS)" \
- CXX="$(CXX_FOR_TARGET)" CXXFLAGS="$(CXXFLAGS)" \
+ CC="$(CC_FOR_TARGET)" CFLAGS="$(CFLAGS_FOR_TARGET)" \
+ CXX="$(CXX_FOR_TARGET)" CXXFLAGS="$(CXXFLAGS_FOR_TARGET)" \
CC_FOR_HOST="$(CC)" CFLAGS_FOR_HOST="$(CFLAGS)" \
OFILES="$(OFILES)" BFDLIB="$(TESTBFDLIB)" \
LIBIBERTY="$(LIBIBERTY) $(LIBINTL)" LIBS="$(LIBS)" \