summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJeremy Huddleston Sequoia <jeremyhu@macports.org>2015-10-18 21:55:39 -0700
committerPavel Raiskup <praiskup@redhat.com>2015-11-30 09:39:31 +0100
commita5c6466528c060cc4660ad0319c00740db0e42ba (patch)
tree977450d147564b8c36223d45b74b029c523a1bda
parentae816aced1e09adaf38a8d938f226db1cc27e79c (diff)
downloadlibtool-a5c6466528c060cc4660ad0319c00740db0e42ba.tar.gz
libtool: fix GCC/clang linking with -fsanitize=*
References: https://lists.gnu.org/archive/html/libtool/2014-04/msg00026.html * build-aux/ltmain.in (func_mode_link): Pass -fsanitize=* to the linker to allow trivial use of the clang address sanitizer. Signed-off-by: Jeremy Huddleston Sequoia <jeremyhu@macports.org> Copyright-paperwork-exempt: Yes
-rw-r--r--build-aux/ltmain.in3
1 files changed, 2 insertions, 1 deletions
diff --git a/build-aux/ltmain.in b/build-aux/ltmain.in
index 1cbe875d..2a5aaadd 100644
--- a/build-aux/ltmain.in
+++ b/build-aux/ltmain.in
@@ -5382,10 +5382,11 @@ func_mode_link ()
# -O*, -g*, -flto*, -fwhopr*, -fuse-linker-plugin GCC link-time optimization
# -specs=* GCC specs files
# -stdlib=* select c++ std lib with clang
+ # -fsanitize=* Clang/GCC memory and address sanitizer
-64|-mips[0-9]|-r[0-9][0-9]*|-xarch=*|-xtarget=*|+DA*|+DD*|-q*|-m*| \
-t[45]*|-txscale*|-p|-pg|--coverage|-fprofile-*|-F*|@*|-tp=*|--sysroot=*| \
-O*|-g*|-flto*|-fwhopr*|-fuse-linker-plugin|-fstack-protector*|-stdlib=*| \
- -specs=*)
+ -specs=*|-fsanitize=*)
func_quote_arg pretty "$arg"
arg=$func_quote_arg_result
func_append compile_command " $arg"