Thu Oct 10 02:35:45 2019 UTC ()
Only exclude gcc-8 warnings when the gcc we're using is gcc>=8


(kre)
diff -r1.22 -r1.23 src/external/cddl/osnet/lib/libdtrace/Makefile

cvs diff -r1.22 -r1.23 src/external/cddl/osnet/lib/libdtrace/Makefile (expand / switch to unified diff)

--- src/external/cddl/osnet/lib/libdtrace/Makefile 2019/10/09 21:49:50 1.22
+++ src/external/cddl/osnet/lib/libdtrace/Makefile 2019/10/10 02:35:45 1.23
@@ -1,14 +1,14 @@ @@ -1,14 +1,14 @@
1# $NetBSD: Makefile,v 1.22 2019/10/09 21:49:50 christos Exp $ 1# $NetBSD: Makefile,v 1.23 2019/10/10 02:35:45 kre Exp $
2 2
3# $FreeBSD: head/cddl/lib/libdtrace/Makefile 314654 2017-03-04 11:30:04Z ngie $ 3# $FreeBSD: head/cddl/lib/libdtrace/Makefile 314654 2017-03-04 11:30:04Z ngie $
4 4
5WARNS=1 5WARNS=1
6.include <bsd.init.mk> 6.include <bsd.init.mk>
7 7
8LIB= dtrace 8LIB= dtrace
9 9
10SRCS= dt_aggregate.c \ 10SRCS= dt_aggregate.c \
11 dt_as.c \ 11 dt_as.c \
12 dt_buf.c \ 12 dt_buf.c \
13 dt_cc.c \ 13 dt_cc.c \
14 dt_cg.c \ 14 dt_cg.c \
@@ -75,27 +75,27 @@ COPTS.dt_consume.c += -Wno-stack-protect @@ -75,27 +75,27 @@ COPTS.dt_consume.c += -Wno-stack-protect
75COPTS.dt_decl.c += -Wno-stack-protector 75COPTS.dt_decl.c += -Wno-stack-protector
76COPTS.dt_dof.c += -Wno-stack-protector 76COPTS.dt_dof.c += -Wno-stack-protector
77COPTS.dt_handle.c += -Wno-stack-protector 77COPTS.dt_handle.c += -Wno-stack-protector
78COPTS.dt_ident.c += -Wno-stack-protector 78COPTS.dt_ident.c += -Wno-stack-protector
79COPTS.dt_link.c += -Wno-stack-protector 79COPTS.dt_link.c += -Wno-stack-protector
80COPTS.dt_options.c += -Wno-stack-protector 80COPTS.dt_options.c += -Wno-stack-protector
81COPTS.dt_parser.c += -Wno-stack-protector 81COPTS.dt_parser.c += -Wno-stack-protector
82COPTS.dt_pragma.c += -Wno-stack-protector 82COPTS.dt_pragma.c += -Wno-stack-protector
83COPTS.dt_print.c += -Wno-stack-protector 83COPTS.dt_print.c += -Wno-stack-protector
84COPTS.dt_printf.c += -Wno-stack-protector 84COPTS.dt_printf.c += -Wno-stack-protector
85COPTS.dt_program.c += -Wno-stack-protector 85COPTS.dt_program.c += -Wno-stack-protector
86COPTS.dt_provider.c += -Wno-stack-protector 86COPTS.dt_provider.c += -Wno-stack-protector
87COPTS.dt_subr.c += -Wno-stack-protector 87COPTS.dt_subr.c += -Wno-stack-protector
88.if ${ACTIVE_CC} == "gcc" 88.if defined(HAVE_GCC) && ${HAVE_GCC} >= 8 && ${ACTIVE_CC} == "gcc"
89COPTS.dt_lex.c += -Wno-error=stringop-truncation 89COPTS.dt_lex.c += -Wno-error=stringop-truncation
90COPTS.dt_pid.c += -Wno-error=stringop-truncation 90COPTS.dt_pid.c += -Wno-error=stringop-truncation
91.endif 91.endif
92 92
93COPTS.dt_consume.c += -Wno-parentheses 93COPTS.dt_consume.c += -Wno-parentheses
94COPTS.dt_consume.c += ${${ACTIVE_CC} == "gcc" :? -Wno-maybe-uninitialized :} 94COPTS.dt_consume.c += ${${ACTIVE_CC} == "gcc" :? -Wno-maybe-uninitialized :}
95COPTS.dt_options.c += -Wno-parentheses 95COPTS.dt_options.c += -Wno-parentheses
96COPTS.dt_pid.c += ${${ACTIVE_CC} == "gcc" :? -Wno-unused-but-set-variable :} 96COPTS.dt_pid.c += ${${ACTIVE_CC} == "gcc" :? -Wno-unused-but-set-variable :}
97COPTS.dt_isadep.c += -Wno-unused-variable 97COPTS.dt_isadep.c += -Wno-unused-variable
98 98
99.if ${MACHINE_ARCH} == "i386" || ${MACHINE_ARCH} == "x86_64" 99.if ${MACHINE_ARCH} == "i386" || ${MACHINE_ARCH} == "x86_64"
100CPPFLAGS+= -I${OPENSOLARIS_SYS_DISTDIR}/uts/intel 100CPPFLAGS+= -I${OPENSOLARIS_SYS_DISTDIR}/uts/intel
101CPPFLAGS+= -I${.CURDIR}/../../dev/dtrace/x86 101CPPFLAGS+= -I${.CURDIR}/../../dev/dtrace/x86