Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/external/gpl3/gcc/lib Consistently, always link sanitizer ru...



details:   https://anonhg.NetBSD.org/src/rev/d90c7f008c0d
branches:  trunk
changeset: 976202:d90c7f008c0d
user:      kamil <kamil%NetBSD.org@localhost>
date:      Mon Sep 14 15:01:57 2020 +0000

description:
Consistently, always link sanitizer runtime with libm and libpthread

This reflects the behavior from LLVM and avoids issues with dlsym(3) APIs.

diffstat:

 external/gpl3/gcc/lib/libasan/Makefile  |  3 ++-
 external/gpl3/gcc/lib/liblsan/Makefile  |  4 +++-
 external/gpl3/gcc/lib/libtsan/Makefile  |  3 ++-
 external/gpl3/gcc/lib/libubsan/Makefile |  4 +++-
 4 files changed, 10 insertions(+), 4 deletions(-)

diffs (72 lines):

diff -r 71b7b878ed47 -r d90c7f008c0d external/gpl3/gcc/lib/libasan/Makefile
--- a/external/gpl3/gcc/lib/libasan/Makefile    Mon Sep 14 14:58:27 2020 +0000
+++ b/external/gpl3/gcc/lib/libasan/Makefile    Mon Sep 14 15:01:57 2020 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.32 2020/09/07 09:09:40 mrg Exp $
+# $NetBSD: Makefile,v 1.33 2020/09/14 15:01:57 kamil Exp $
 
 UNSUPPORTED_COMPILER.clang=    # defined
 NOSANITIZER=   # defined
@@ -46,6 +46,7 @@
 SRCS+= ${ASAN_SRCS} lsan_common.cc lsan_common_linux.cc
 LIBDPLIBS+= rt ${NETBSDSRCDIR}/lib/librt
 LIBDPLIBS+= m  ${NETBSDSRCDIR}/lib/libm
+LIBDPLIBS+= pthread ${NETBSDSRCDIR}/lib/libpthread
 CPPFLAGS+=-DCAN_SANITIZE_UB=0
 
 .if ${MACHINE_ARCH} == "vax"
diff -r 71b7b878ed47 -r d90c7f008c0d external/gpl3/gcc/lib/liblsan/Makefile
--- a/external/gpl3/gcc/lib/liblsan/Makefile    Mon Sep 14 14:58:27 2020 +0000
+++ b/external/gpl3/gcc/lib/liblsan/Makefile    Mon Sep 14 15:01:57 2020 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.7 2020/05/15 14:29:53 joerg Exp $
+# $NetBSD: Makefile,v 1.8 2020/09/14 15:01:57 kamil Exp $
 
 .include <bsd.own.mk>
 
@@ -23,7 +23,9 @@
 
 LIB=   lsan
 SRCS+= ${LSAN_SRCS}
+LIBDPLIBS+= m ${NETBSDSRCDIR}/lib/libm
 LIBDPLIBS+= rt ${NETBSDSRCDIR}/lib/librt
+LIBDPLIBS+= pthread ${NETBSDSRCDIR}/lib/libpthread
 
 CWARNFLAGS.clang+=     -Wno-error=unused-private-field
 
diff -r 71b7b878ed47 -r d90c7f008c0d external/gpl3/gcc/lib/libtsan/Makefile
--- a/external/gpl3/gcc/lib/libtsan/Makefile    Mon Sep 14 14:58:27 2020 +0000
+++ b/external/gpl3/gcc/lib/libtsan/Makefile    Mon Sep 14 15:01:57 2020 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.14 2020/09/14 14:33:01 kamil Exp $
+# $NetBSD: Makefile,v 1.15 2020/09/14 15:01:58 kamil Exp $
 
 UNSUPPORTED_COMPILER.clang=     # defined
 NOSANITIZER=    # defined
@@ -64,6 +64,7 @@
 SRCS+= ${TSAN_SRCS}
 LIBDPLIBS+= rt ${NETBSDSRCDIR}/lib/librt
 LIBDPLIBS+= m  ${NETBSDSRCDIR}/lib/libm
+LIBDPLIBS+= pthread ${NETBSDSRCDIR}/lib/libpthread
 CPPFLAGS+=-DCAN_SANITIZE_UB=0
 COPTS.tsan_interceptors.cc += -Wno-unused-function
 
diff -r 71b7b878ed47 -r d90c7f008c0d external/gpl3/gcc/lib/libubsan/Makefile
--- a/external/gpl3/gcc/lib/libubsan/Makefile   Mon Sep 14 14:58:27 2020 +0000
+++ b/external/gpl3/gcc/lib/libubsan/Makefile   Mon Sep 14 15:01:57 2020 +0000
@@ -1,4 +1,4 @@
-#      $NetBSD: Makefile,v 1.17 2020/09/05 09:50:15 mrg Exp $
+#      $NetBSD: Makefile,v 1.18 2020/09/14 15:01:58 kamil Exp $
 
 UNSUPPORTED_COMPILER.clang=    # defined
 LIBISCXX = yes
@@ -32,7 +32,9 @@
 
 LIB=   ubsan
 SRCS+= ${UBSAN_SRCS}
+LIBDPLIBS+= m ${NETBSDSRCDIR}/lib/libm
 LIBDPLIBS+= rt ${NETBSDSRCDIR}/lib/librt
+LIBDPLIBS+= pthread ${NETBSDSRCDIR}/lib/libpthread
 CPPFLAGS+=-DCAN_SANITIZE_UB=1
 
 .include <bsd.lib.mk>



Home | Main Index | Thread Index | Old Index