From 647b98e89e3c9bfa73de421ae7ef731652f1abd5 Mon Sep 17 00:00:00 2001 From: jakub Date: Fri, 9 Feb 2018 06:44:06 +0000 Subject: [PATCH] PR sanitizer/84285 * gcc.c (STATIC_LIBASAN_LIBS, STATIC_LIBTSAN_LIBS, STATIC_LIBLSAN_LIBS, STATIC_LIBUBSAN_LIBS): Handle -static like -static-lib*san. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@257515 138bc75d-0d04-0410-961f-82ee72b054a4 --- gcc/ChangeLog | 5 +++++ gcc/gcc.c | 8 ++++---- 2 files changed, 9 insertions(+), 4 deletions(-) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index e1945fe1997..f255810e18b 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,5 +1,10 @@ 2018-02-09 Jakub Jelinek + PR sanitizer/84285 + * gcc.c (STATIC_LIBASAN_LIBS, STATIC_LIBTSAN_LIBS, + STATIC_LIBLSAN_LIBS, STATIC_LIBUBSAN_LIBS): Handle -static like + -static-lib*san. + PR debug/84252 * var-tracking.c (vt_add_function_parameter): Punt for non-onepart PARALLEL incoming that failed vt_get_decl_and_offset check. diff --git a/gcc/gcc.c b/gcc/gcc.c index f55883a9659..a716f708259 100644 --- a/gcc/gcc.c +++ b/gcc/gcc.c @@ -684,7 +684,7 @@ proper position among the other output files. */ #ifndef LIBASAN_SPEC #define STATIC_LIBASAN_LIBS \ - " %{static-libasan:%:include(libsanitizer.spec)%(link_libasan)}" + " %{static-libasan|static:%:include(libsanitizer.spec)%(link_libasan)}" #ifdef LIBASAN_EARLY_SPEC #define LIBASAN_SPEC STATIC_LIBASAN_LIBS #elif defined(HAVE_LD_STATIC_DYNAMIC) @@ -702,7 +702,7 @@ proper position among the other output files. */ #ifndef LIBTSAN_SPEC #define STATIC_LIBTSAN_LIBS \ - " %{static-libtsan:%:include(libsanitizer.spec)%(link_libtsan)}" + " %{static-libtsan|static:%:include(libsanitizer.spec)%(link_libtsan)}" #ifdef LIBTSAN_EARLY_SPEC #define LIBTSAN_SPEC STATIC_LIBTSAN_LIBS #elif defined(HAVE_LD_STATIC_DYNAMIC) @@ -720,7 +720,7 @@ proper position among the other output files. */ #ifndef LIBLSAN_SPEC #define STATIC_LIBLSAN_LIBS \ - " %{static-liblsan:%:include(libsanitizer.spec)%(link_liblsan)}" + " %{static-liblsan|static:%:include(libsanitizer.spec)%(link_liblsan)}" #ifdef LIBLSAN_EARLY_SPEC #define LIBLSAN_SPEC STATIC_LIBLSAN_LIBS #elif defined(HAVE_LD_STATIC_DYNAMIC) @@ -738,7 +738,7 @@ proper position among the other output files. */ #ifndef LIBUBSAN_SPEC #define STATIC_LIBUBSAN_LIBS \ - " %{static-libubsan:%:include(libsanitizer.spec)%(link_libubsan)}" + " %{static-libubsan|static:%:include(libsanitizer.spec)%(link_libubsan)}" #ifdef HAVE_LD_STATIC_DYNAMIC #define LIBUBSAN_SPEC "%{static-libubsan:" LD_STATIC_OPTION \ "} -lubsan %{static-libubsan:" LD_DYNAMIC_OPTION "}" \ -- 2.11.4.GIT