Source-Changes-HG archive

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

[src/trunk]: src/external/bsd/libc++/lib Avoid clang bug on earm with SSP/FOR...



details:   https://anonhg.NetBSD.org/src/rev/0048fe62ab4e
branches:  trunk
changeset: 841274:0048fe62ab4e
user:      christos <christos%NetBSD.org@localhost>
date:      Mon May 06 23:20:51 2019 +0000

description:
Avoid clang bug on earm with SSP/FORTIFY:

rt_libelftc_dem_gnu3.c:3567:3: warning: '__builtin___memset_chk' will always
      overflow destination buffer [-Wbuiltin-memcpy-chk-size]
                      memset(&f, 0, FLOAT_EXTENED_BYTES);

diffstat:

 external/bsd/libc++/lib/Makefile |  5 ++++-
 1 files changed, 4 insertions(+), 1 deletions(-)

diffs (19 lines):

diff -r 050eecf6154b -r 0048fe62ab4e external/bsd/libc++/lib/Makefile
--- a/external/bsd/libc++/lib/Makefile  Mon May 06 19:20:13 2019 +0000
+++ b/external/bsd/libc++/lib/Makefile  Mon May 06 23:20:51 2019 +0000
@@ -1,4 +1,4 @@
-#      $NetBSD: Makefile,v 1.12 2018/07/17 18:58:10 joerg Exp $
+#      $NetBSD: Makefile,v 1.13 2019/05/06 23:20:51 christos Exp $
 
 LIB=           c++
 WARNS=         4
@@ -44,6 +44,9 @@
 CWARNFLAGS.clang+=     -Wno-error=missing-field-initializers -Wno-error=switch
 CWARNFLAGS.clang+=     -Wno-error=implicit-exception-spec-mismatch
 
+# with SSP and FORTIFY, on earm...
+COPTS.rt_libelftc_dem_gnu3.c += ${${ACTIVE_CC} == "clang":? -Wno-error=builtin-memcpy-chk-size :}
+
 .if ${MKSANITIZER} != "yes"
 LDFLAGS+=      -Wl,-z,defs
 .endif



Home | Main Index | Thread Index | Old Index