Source-Changes-HG archive

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

[src/trunk]: src convert HAVE_GCC == 7 to HAVE_GCC >= 7.



details:   https://anonhg.NetBSD.org/src/rev/35d36d131349
branches:  trunk
changeset: 454856:35d36d131349
user:      mrg <mrg%NetBSD.org@localhost>
date:      Mon Sep 30 00:06:02 2019 +0000

description:
convert HAVE_GCC == 7 to HAVE_GCC >= 7.

diffstat:

 external/bsd/libpcap/lib/Makefile               |  20 +++++++++-----------
 sys/conf/copts.mk                               |   4 ++--
 sys/external/bsd/drm2/i915drm/files.i915drmkms  |   8 ++++----
 sys/external/bsd/drm2/nouveau/files.nouveau     |   8 ++++----
 sys/external/bsd/drm2/radeon/files.radeon       |  10 +++++-----
 sys/external/bsd/drm2/ttm/files.ttm             |   4 ++--
 sys/external/isc/atheros_hal/conf/files.ath_hal |   6 +++---
 7 files changed, 29 insertions(+), 31 deletions(-)

diffs (168 lines):

diff -r 714d23b94fee -r 35d36d131349 external/bsd/libpcap/lib/Makefile
--- a/external/bsd/libpcap/lib/Makefile Sun Sep 29 23:44:58 2019 +0000
+++ b/external/bsd/libpcap/lib/Makefile Mon Sep 30 00:06:02 2019 +0000
@@ -1,16 +1,9 @@
-# $NetBSD: Makefile,v 1.23 2019/02/05 07:45:35 mrg Exp $       
+# $NetBSD: Makefile,v 1.24 2019/09/30 00:06:02 mrg Exp $       
 
 USE_SHLIBDIR=yes
 .include <bsd.own.mk>
 USE_FORT?= yes # network protocol library
 
-CWARNFLAGS.clang+=     -Wno-format-extra-args \
-                       -Wno-unneeded-internal-declaration
-
-.if defined(HAVE_GCC) && ${HAVE_GCC} == 7 && ${ACTIVE_CC} == "gcc"
-COPTS.gencode.c+=      -Wno-error=implicit-fallthrough
-.endif
-
 CPPFLAGS+= -DPCAP_DONT_INCLUDE_PCAP_BPF_H -DHAVE_CONFIG_H -I${.OBJDIR}
 
 .SUFFIXES: .3 .3pcap
@@ -173,10 +166,15 @@
        cp $? $@
 
 CLEANFILES+=   tokdefs.h scanner.h
-COPTS.bpf_image.c = -Wno-format-nonliteral
+
+COPTS.bpf_image.c+=    -Wno-format-nonliteral
 
-.if defined(HAVE_GCC) && ${HAVE_GCC} == 7 && ${ACTIVE_CC} == "gcc"
-COPTS.pcap.c+= -Wno-error=format-truncation
+.if defined(HAVE_GCC) && ${HAVE_GCC} >= 7 && ${ACTIVE_CC} == "gcc"
+COPTS.pcap.c+=         -Wno-error=format-truncation
+COPTS.gencode.c+=      -Wno-error=implicit-fallthrough
 .endif
 
+CWARNFLAGS.clang+=     -Wno-format-extra-args \
+                       -Wno-unneeded-internal-declaration
+
 .include <bsd.lib.mk>
diff -r 714d23b94fee -r 35d36d131349 sys/conf/copts.mk
--- a/sys/conf/copts.mk Sun Sep 29 23:44:58 2019 +0000
+++ b/sys/conf/copts.mk Mon Sep 30 00:06:02 2019 +0000
@@ -1,11 +1,11 @@
-#      $NetBSD: copts.mk,v 1.3 2019/02/10 05:01:59 mrg Exp $
+#      $NetBSD: copts.mk,v 1.4 2019/09/30 00:06:02 mrg Exp $
 
 # MI per-file compiler options required.
 
 .ifndef _SYS_CONF_COPTS_MK_
 _SYS_CONF_COPTS_MK_=1
 
-.if defined(HAVE_GCC) && ${HAVE_GCC} == 7 && ${ACTIVE_CC} == "gcc"
+.if defined(HAVE_GCC) && ${HAVE_GCC} >= 7 && ${ACTIVE_CC} == "gcc"
 COPTS.zlib.c+=         -Wno-error=implicit-fallthrough
 COPTS.pf.c+=           -Wno-error=implicit-fallthrough
 COPTS.radeon_cs.c+=    -Wno-error=implicit-fallthrough
diff -r 714d23b94fee -r 35d36d131349 sys/external/bsd/drm2/i915drm/files.i915drmkms
--- a/sys/external/bsd/drm2/i915drm/files.i915drmkms    Sun Sep 29 23:44:58 2019 +0000
+++ b/sys/external/bsd/drm2/i915drm/files.i915drmkms    Mon Sep 30 00:06:02 2019 +0000
@@ -1,4 +1,4 @@
-#      $NetBSD: files.i915drmkms,v 1.37 2019/02/04 08:18:07 mrg Exp $
+#      $NetBSD: files.i915drmkms,v 1.38 2019/09/30 00:06:02 mrg Exp $
 
 version        20180827
 
@@ -24,9 +24,9 @@
 
 makeoptions    i915drmkms      "CWARNFLAGS.intel_sprite.c"+="${${ACTIVE_CC} == gcc:? -Wno-maybe-uninitialized :}"
 
-makeoptions    i915drmkms      "CWARNFLAGS.intel_ddi.c"+="${${ACTIVE_CC} == gcc && ${HAVE_GCC:U0} == 7:? -Wno-error=implicit-fallthrough :}"
-makeoptions    i915drmkms      "CWARNFLAGS.intel_display.c"+="${${ACTIVE_CC} == gcc && ${HAVE_GCC:U0} == 7:? -Wno-error=implicit-fallthrough :}"
-makeoptions    i915drmkms      "CWARNFLAGS.intel_sdvo.c"+="${${ACTIVE_CC} == gcc && ${HAVE_GCC:U0} == 7:? -Wno-error=implicit-fallthrough :}"
+makeoptions    i915drmkms      "CWARNFLAGS.intel_ddi.c"+="${${ACTIVE_CC} == gcc && ${HAVE_GCC:U0} >= 7:? -Wno-error=implicit-fallthrough :}"
+makeoptions    i915drmkms      "CWARNFLAGS.intel_display.c"+="${${ACTIVE_CC} == gcc && ${HAVE_GCC:U0} >= 7:? -Wno-error=implicit-fallthrough :}"
+makeoptions    i915drmkms      "CWARNFLAGS.intel_sdvo.c"+="${${ACTIVE_CC} == gcc && ${HAVE_GCC:U0} >= 7:? -Wno-error=implicit-fallthrough :}"
 
 file   external/bsd/drm2/i915drm/i915_module.c         i915drmkms
 file   external/bsd/drm2/i915drm/i915_pci.c            i915drmkms
diff -r 714d23b94fee -r 35d36d131349 sys/external/bsd/drm2/nouveau/files.nouveau
--- a/sys/external/bsd/drm2/nouveau/files.nouveau       Sun Sep 29 23:44:58 2019 +0000
+++ b/sys/external/bsd/drm2/nouveau/files.nouveau       Mon Sep 30 00:06:02 2019 +0000
@@ -1,4 +1,4 @@
-#      $NetBSD: files.nouveau,v 1.27 2019/06/24 13:36:07 wiz Exp $
+#      $NetBSD: files.nouveau,v 1.28 2019/09/30 00:06:02 mrg Exp $
 
 version        20180827
 
@@ -28,9 +28,9 @@
 makeoptions    nouveau "CWARNFLAGS.nouveau"+="-Wno-missing-field-initializers"
 makeoptions    nouveau "CWARNFLAGS.nouveau"+="-Wno-shadow"
 makeoptions    nouveau "CWARNFLAGS.nouveau"+="${${ACTIVE_CC} == clang:? -Wno-error=gnu-variable-sized-type-not-at-end :}"
-makeoptions    nouveau "CWARNFLAGS.nouveau"+="${${ACTIVE_CC} == gcc && ${HAVE_GCC:U0} == 7:? -Wno-error=implicit-fallthrough :}"
-makeoptions    nouveau "CWARNFLAGS.nouveau_nvkm_subdev_bios_timing.c"+="${${ACTIVE_CC} == gcc && ${HAVE_GCC:U0} == 7:? -Wno-error=int-in-bool-context :}"
-makeoptions    nouveau "CWARNFLAGS.nouveau_nvkm_subdev_clk_gt215.c"+="${${ACTIVE_CC} == gcc && ${HAVE_GCC:U0} == 7:? -Wno-error=int-in-bool-context :}"
+makeoptions    nouveau "CWARNFLAGS.nouveau"+="${${ACTIVE_CC} == gcc && ${HAVE_GCC:U0} >= 7:? -Wno-error=implicit-fallthrough :}"
+makeoptions    nouveau "CWARNFLAGS.nouveau_nvkm_subdev_bios_timing.c"+="${${ACTIVE_CC} == gcc && ${HAVE_GCC:U0} >= 7:? -Wno-error=int-in-bool-context :}"
+makeoptions    nouveau "CWARNFLAGS.nouveau_nvkm_subdev_clk_gt215.c"+="${${ACTIVE_CC} == gcc && ${HAVE_GCC:U0} >= 7:? -Wno-error=int-in-bool-context :}"
 
 file   external/bsd/drm2/nouveau/nouveau_module.c      nouveau
 
diff -r 714d23b94fee -r 35d36d131349 sys/external/bsd/drm2/radeon/files.radeon
--- a/sys/external/bsd/drm2/radeon/files.radeon Sun Sep 29 23:44:58 2019 +0000
+++ b/sys/external/bsd/drm2/radeon/files.radeon Mon Sep 30 00:06:02 2019 +0000
@@ -1,4 +1,4 @@
-#      $NetBSD: files.radeon,v 1.26 2019/06/01 05:55:45 nakayama Exp $
+#      $NetBSD: files.radeon,v 1.27 2019/09/30 00:06:02 mrg Exp $
 
 version        20180827
 
@@ -25,10 +25,10 @@
 
 makeoptions    radeon  "CWARNFLAGS.radeon"+="${${ACTIVE_CC} == gcc:? -Wno-maybe-uninitialized :}"
 
-#makeoptions   i915drmkms      "CWARNFLAGS.radeon_cs.c"+="${${ACTIVE_CC} == gcc && ${HAVE_GCC:U0} == 7:? -Wno-error=implicit-fallthrough :}"
-makeoptions    i915drmkms      "CWARNFLAGS.radeon_evergreen_cs.c"+="${${ACTIVE_CC} == gcc && ${HAVE_GCC:U0} == 7:? -Wno-error=implicit-fallthrough :}"
-makeoptions    i915drmkms      "CWARNFLAGS.radeon_r300.c"+="${${ACTIVE_CC} == gcc && ${HAVE_GCC:U0} == 7:? -Wno-error=implicit-fallthrough :}"
-makeoptions    i915drmkms      "CWARNFLAGS.radeon_r420.c"+="${${ACTIVE_CC} == gcc && ${HAVE_GCC:U0} == 7:? -Wno-error=implicit-fallthrough :}"
+#makeoptions   i915drmkms      "CWARNFLAGS.radeon_cs.c"+="${${ACTIVE_CC} == gcc && ${HAVE_GCC:U0} >= 7:? -Wno-error=implicit-fallthrough :}"
+makeoptions    i915drmkms      "CWARNFLAGS.radeon_evergreen_cs.c"+="${${ACTIVE_CC} == gcc && ${HAVE_GCC:U0} >= 7:? -Wno-error=implicit-fallthrough :}"
+makeoptions    i915drmkms      "CWARNFLAGS.radeon_r300.c"+="${${ACTIVE_CC} == gcc && ${HAVE_GCC:U0} >= 7:? -Wno-error=implicit-fallthrough :}"
+makeoptions    i915drmkms      "CWARNFLAGS.radeon_r420.c"+="${${ACTIVE_CC} == gcc && ${HAVE_GCC:U0} >= 7:? -Wno-error=implicit-fallthrough :}"
 
 file   external/bsd/drm2/radeon/radeon_module.c                radeon
 file   external/bsd/drm2/radeon/radeon_pci.c                   radeon
diff -r 714d23b94fee -r 35d36d131349 sys/external/bsd/drm2/ttm/files.ttm
--- a/sys/external/bsd/drm2/ttm/files.ttm       Sun Sep 29 23:44:58 2019 +0000
+++ b/sys/external/bsd/drm2/ttm/files.ttm       Mon Sep 30 00:06:02 2019 +0000
@@ -1,10 +1,10 @@
-#      $NetBSD: files.ttm,v 1.2 2019/02/04 08:18:08 mrg Exp $
+#      $NetBSD: files.ttm,v 1.3 2019/09/30 00:06:02 mrg Exp $
 
 # TTM, the texture and tiling manager.
 
 define drmkms_ttm: drmkms
 
-makeoptions    drmkms  "CWARNFLAGS.ttm_bo.c"+="${${ACTIVE_CC} == gcc && ${HAVE_GCC:U0} == 7:? -Wno-error=implicit-fallthrough :}"
+makeoptions    drmkms  "CWARNFLAGS.ttm_bo.c"+="${${ACTIVE_CC} == gcc && ${HAVE_GCC:U0} >= 7:? -Wno-error=implicit-fallthrough :}"
 
 file   external/bsd/drm2/ttm/ttm_agp_backend.c                 drmkms_ttm
 file   external/bsd/drm2/dist/drm/ttm/ttm_memory.c             drmkms_ttm
diff -r 714d23b94fee -r 35d36d131349 sys/external/isc/atheros_hal/conf/files.ath_hal
--- a/sys/external/isc/atheros_hal/conf/files.ath_hal   Sun Sep 29 23:44:58 2019 +0000
+++ b/sys/external/isc/atheros_hal/conf/files.ath_hal   Mon Sep 30 00:06:02 2019 +0000
@@ -1,4 +1,4 @@
-#      $NetBSD: files.ath_hal,v 1.7 2019/02/04 08:36:43 mrg Exp $
+#      $NetBSD: files.ath_hal,v 1.8 2019/09/30 00:06:02 mrg Exp $
 
 defflag opt_athhal.h   ATHHAL_ASSERT ATHHAL_DEBUG ATHHAL_DEBUG_ALQ
 defflag opt_athhal.h   ATHHAL_WRITE_EEPROM ATHHAL_WRITE_REGDOMAIN
@@ -93,7 +93,7 @@
 file   external/isc/atheros_hal/dist/ar5212/ar5212_rfgain.c    ath & athhal_ar5212_subr
 file   external/isc/atheros_hal/dist/ar5212/ar5212_xmit.c      ath & athhal_ar5212_subr
 
-makeoptions ath                "CWARNFLAGS.ar5212_xmit.c"+="${${ACTIVE_CC} == gcc && ${HAVE_GCC:U0} == 7:? -Wno-error=implicit-fallthrough :}"
+makeoptions ath                "CWARNFLAGS.ar5212_xmit.c"+="${${ACTIVE_CC} == gcc && ${HAVE_GCC:U0} >= 7:? -Wno-error=implicit-fallthrough :}"
 
 # Atheros AR5312 family
 #
@@ -142,7 +142,7 @@
 file   external/isc/atheros_hal/dist/ar5416/ar9285_attach.c    ath & athhal_ar5416
 file   external/isc/atheros_hal/dist/ar5416/ar9285_reset.c     ath & athhal_ar5416
 
-makeoptions ath                "CWARNFLAGS.ar5416_xmit.c"+="${${ACTIVE_CC} == gcc && ${HAVE_GCC:U0} == 7:? -Wno-error=implicit-fallthrough :}"
+makeoptions ath                "CWARNFLAGS.ar5416_xmit.c"+="${${ACTIVE_CC} == gcc && ${HAVE_GCC:U0} >= 7:? -Wno-error=implicit-fallthrough :}"
 
 #
 #



Home | Main Index | Thread Index | Old Index