Source-Changes-HG archive

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

[src/trunk]: src/external adapt to ${CC_WNO_STRINGOP_OVERFLOW}



details:   https://anonhg.NetBSD.org/src/rev/185ee405ec4d
branches:  trunk
changeset: 376187:185ee405ec4d
user:      lukem <lukem%NetBSD.org@localhost>
date:      Sat Jun 03 21:33:01 2023 +0000

description:
adapt to ${CC_WNO_STRINGOP_OVERFLOW}

Use ${CC_WNO_STRINGOP_OVERFLOW} instead of
the older style more complex expressions.

Remove workarounds if they were only for gcc < 10.

diffstat:

 external/apache2/llvm/Makefile.inc                                        |  5 +----
 external/bsd/compiler_rt/lib/clang/lib/netbsd/xray-profiling-m64/Makefile |  4 ++--
 external/bsd/openldap/lib/slapd/back-mdb/Makefile                         |  4 ++--
 external/mit/xorg/lib/libGL.old/Makefile                                  |  6 ++----
 external/mit/xorg/lib/libGL/Makefile                                      |  6 ++----
 external/mpl/dhcp/bin/server/Makefile                                     |  4 ++--
 6 files changed, 11 insertions(+), 18 deletions(-)

diffs (113 lines):

diff -r 7980cbb30fe8 -r 185ee405ec4d external/apache2/llvm/Makefile.inc
--- a/external/apache2/llvm/Makefile.inc        Sat Jun 03 21:31:45 2023 +0000
+++ b/external/apache2/llvm/Makefile.inc        Sat Jun 03 21:33:01 2023 +0000
@@ -1,4 +1,4 @@
-#      $NetBSD: Makefile.inc,v 1.6 2022/02/28 16:30:10 joerg Exp $
+#      $NetBSD: Makefile.inc,v 1.7 2023/06/03 21:33:01 lukem Exp $
 
 .if !defined(LLVM_TOPLEVEL_MK)
 LLVM_TOPLEVEL_MK=
@@ -19,9 +19,6 @@ CONFIG_DIR:=  ${.PARSEDIR}/autoconf
 
 CPPFLAGS+=     -I. -I${CLANG_SRCDIR}/include -I${LLVM_SRCDIR}/include
 
-# Bogus warning with -O2 in GCC 7 and 8.
-CWARNFLAGS.gcc+=       ${${ACTIVE_CC} == "gcc" && ${HAVE_GCC:U0} < 9:? -Wno-stringop-overflow :}
-
 MODULES_CXXFLAGS=      -fmodules -fcxx-modules -Werror=incomplete-umbrella \
                        -fmodules-validate-system-headers \
                        -Xclang -fmodules-local-submodule-visibility \
diff -r 7980cbb30fe8 -r 185ee405ec4d external/bsd/compiler_rt/lib/clang/lib/netbsd/xray-profiling-m64/Makefile
--- a/external/bsd/compiler_rt/lib/clang/lib/netbsd/xray-profiling-m64/Makefile Sat Jun 03 21:31:45 2023 +0000
+++ b/external/bsd/compiler_rt/lib/clang/lib/netbsd/xray-profiling-m64/Makefile Sat Jun 03 21:33:01 2023 +0000
@@ -1,4 +1,4 @@
-#      $NetBSD: Makefile,v 1.3 2021/09/17 02:18:05 christos Exp $
+#      $NetBSD: Makefile,v 1.4 2023/06/03 21:33:02 lukem Exp $
 
 .include "../common.mk"
 .include "../sources.mk"
@@ -25,7 +25,7 @@ CPPFLAGS+=    -I${TOPDIR}/lib
 CPPFLAGS+=     -I${TOPDIR}/include
 
 CWARNFLAGS.clang+=     -Wno-error=cast-qual-unrelated
-CWARNFLAGS.gcc+=       -Wno-error=stringop-overflow
+CWARNFLAGS.gcc+=       ${CC_WNO_STRINGOP_OVERFLOW}
 
 COPTS+=                -fPIC
 
diff -r 7980cbb30fe8 -r 185ee405ec4d external/bsd/openldap/lib/slapd/back-mdb/Makefile
--- a/external/bsd/openldap/lib/slapd/back-mdb/Makefile Sat Jun 03 21:31:45 2023 +0000
+++ b/external/bsd/openldap/lib/slapd/back-mdb/Makefile Sat Jun 03 21:33:01 2023 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.1 2021/12/28 17:05:44 christos Exp $
+# $NetBSD: Makefile,v 1.2 2023/06/03 21:33:02 lukem Exp $
 
 USE_FORT=yes
 LIBISPRIVATE=yes
@@ -13,7 +13,7 @@ LMDB=${LDAP_DISTDIR}/libraries/liblmdb
 
 .PATH: ${BACK_MDB} ${LMDB}
 
-COPTS.mdb.c += -Wno-error=stringop-overflow
+COPTS.mdb.c += ${CC_WNO_STRINGOP_OVERFLOW}
 
 CPPFLAGS+=-I${SLAPD} -I${BACK_MDB} -I${LMDB}
 
diff -r 7980cbb30fe8 -r 185ee405ec4d external/mit/xorg/lib/libGL.old/Makefile
--- a/external/mit/xorg/lib/libGL.old/Makefile  Sat Jun 03 21:31:45 2023 +0000
+++ b/external/mit/xorg/lib/libGL.old/Makefile  Sat Jun 03 21:33:01 2023 +0000
@@ -1,4 +1,4 @@
-#      $NetBSD: Makefile,v 1.3 2022/09/29 18:58:04 rjs Exp $
+#      $NetBSD: Makefile,v 1.4 2023/06/03 21:33:02 lukem Exp $
 
 .include <bsd.own.mk>
 
@@ -231,9 +231,7 @@ PKGCONFIG_SED_FLAGS= \
 
 CWARNFLAGS.clang+=     -Wno-tautological-compare -Wno-format -Wno-constant-conversion \
                        -Wno-error=incompatible-pointer-types -Wno-error=atomic-alignment
-.if ${HAVE_GCC:U0} >= 7
-CWARNFLAGS.gcc+=       -Wno-error=stringop-overflow
-.endif
+CWARNFLAGS.gcc+=       ${CC_WNO_STRINGOP_OVERFLOW}
 
 .include <bsd.x11.mk>
 .include <bsd.lib.mk>
diff -r 7980cbb30fe8 -r 185ee405ec4d external/mit/xorg/lib/libGL/Makefile
--- a/external/mit/xorg/lib/libGL/Makefile      Sat Jun 03 21:31:45 2023 +0000
+++ b/external/mit/xorg/lib/libGL/Makefile      Sat Jun 03 21:33:01 2023 +0000
@@ -1,4 +1,4 @@
-#      $NetBSD: Makefile,v 1.32 2021/07/11 20:52:06 mrg Exp $
+#      $NetBSD: Makefile,v 1.33 2023/06/03 21:33:02 lukem Exp $
 
 .include <bsd.own.mk>
 
@@ -231,9 +231,7 @@ PKGCONFIG_SED_FLAGS= \
 
 CWARNFLAGS.clang+=     -Wno-tautological-compare -Wno-format -Wno-constant-conversion \
                        -Wno-error=incompatible-pointer-types -Wno-error=atomic-alignment
-.if ${HAVE_GCC:U0} >= 7
-CWARNFLAGS.gcc+=       -Wno-error=stringop-overflow
-.endif
+CWARNFLAGS.gcc+=       ${CC_WNO_STRINGOP_OVERFLOW}
 
 .include <bsd.x11.mk>
 .include <bsd.lib.mk>
diff -r 7980cbb30fe8 -r 185ee405ec4d external/mpl/dhcp/bin/server/Makefile
--- a/external/mpl/dhcp/bin/server/Makefile     Sat Jun 03 21:31:45 2023 +0000
+++ b/external/mpl/dhcp/bin/server/Makefile     Sat Jun 03 21:33:01 2023 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.9 2023/06/03 21:27:11 lukem Exp $
+# $NetBSD: Makefile,v 1.10 2023/06/03 21:33:02 lukem Exp $
 
 .include <bsd.own.mk>
 
@@ -16,7 +16,7 @@ FILES=        dhcpd.conf
 .endif
 
 .if !empty(MACHINE_ARCH:Msh3*) || ${MACHINE_ARCH} == "m68000"
-COPTS.ddns.c +=-Wno-stringop-overflow
+COPTS.ddns.c +=                ${CC_WNO_STRINGOP_OVERFLOW}
 .endif
 
 COPTS.omapi.c +=       -Wno-stack-protector



Home | Main Index | Thread Index | Old Index