Module Name: src Committed By: joerg Date: Fri Aug 10 16:05:27 UTC 2012
Modified Files: src/external/gpl3: Makefile src/external/historical/nawk/bin: Makefile src/external/lgpl3/gmp/lib/libgmp: Makefile src/sys/conf: Makefile.kern.inc src/sys/lib/libkern: Makefile.inc src/sys/lib/libsa: Makefile src/sys/rump: Makefile.rump Log Message: Deal with optional HAVE_GCC. To generate a diff of this commit: cvs rdiff -u -r1.6 -r1.7 src/external/gpl3/Makefile cvs rdiff -u -r1.8 -r1.9 src/external/historical/nawk/bin/Makefile cvs rdiff -u -r1.12 -r1.13 src/external/lgpl3/gmp/lib/libgmp/Makefile cvs rdiff -u -r1.157 -r1.158 src/sys/conf/Makefile.kern.inc cvs rdiff -u -r1.40 -r1.41 src/sys/lib/libkern/Makefile.inc cvs rdiff -u -r1.77 -r1.78 src/sys/lib/libsa/Makefile cvs rdiff -u -r1.62 -r1.63 src/sys/rump/Makefile.rump Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/external/gpl3/Makefile diff -u src/external/gpl3/Makefile:1.6 src/external/gpl3/Makefile:1.7 --- src/external/gpl3/Makefile:1.6 Mon Oct 31 08:14:44 2011 +++ src/external/gpl3/Makefile Fri Aug 10 16:05:26 2012 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.6 2011/10/31 08:14:44 mrg Exp $ +# $NetBSD: Makefile,v 1.7 2012/08/10 16:05:26 joerg Exp $ .include <bsd.own.mk> @@ -6,11 +6,13 @@ SUBDIR+= binutils .endif +.if ${MKGCC} != "no" .if ${HAVE_GCC} == 45 .if ${MKGCCCMDS} != "no" SUBDIR+= gcc .endif .endif +.endif .if ${MKGDB} != "no" .if ${HAVE_GDB} == "7" Index: src/external/historical/nawk/bin/Makefile diff -u src/external/historical/nawk/bin/Makefile:1.8 src/external/historical/nawk/bin/Makefile:1.9 --- src/external/historical/nawk/bin/Makefile:1.8 Tue Aug 16 10:45:37 2011 +++ src/external/historical/nawk/bin/Makefile Fri Aug 10 16:05:26 2012 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.8 2011/08/16 10:45:37 christos Exp $ +# $NetBSD: Makefile,v 1.9 2012/08/10 16:05:26 joerg Exp $ WARNS?= 4 CWARNFLAGS.clang+= -Wno-self-assign @@ -17,9 +17,7 @@ LDADD+= -lm DPADD+= ${LIBM} .endif YHEADER= yes -.if defined(HAVE_GCC) || defined(HAVE_PCC) COPTS+= -Wno-pointer-sign -.endif COPTS.run.c += -Wno-format-nonliteral COPTS.tran.c += -Wno-format-nonliteral Index: src/external/lgpl3/gmp/lib/libgmp/Makefile diff -u src/external/lgpl3/gmp/lib/libgmp/Makefile:1.12 src/external/lgpl3/gmp/lib/libgmp/Makefile:1.13 --- src/external/lgpl3/gmp/lib/libgmp/Makefile:1.12 Wed Sep 21 02:06:42 2011 +++ src/external/lgpl3/gmp/lib/libgmp/Makefile Fri Aug 10 16:05:26 2012 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.12 2011/09/21 02:06:42 mrg Exp $ +# $NetBSD: Makefile,v 1.13 2012/08/10 16:05:26 joerg Exp $ .include <bsd.init.mk> @@ -191,8 +191,6 @@ CLEANFILES+= ${DPSRCS} gen-fac_ui gen-fi # Don't warn about functions which cannot be stack smash protected as # there are a lot of them. -.if defined(HAVE_GCC) || defined(HAVE_PCC) COPTS += -Wno-stack-protector -.endif CWARNFLAGS.clang+= -Wno-unused-value -Wno-tautological-compare Index: src/sys/conf/Makefile.kern.inc diff -u src/sys/conf/Makefile.kern.inc:1.157 src/sys/conf/Makefile.kern.inc:1.158 --- src/sys/conf/Makefile.kern.inc:1.157 Fri Jul 27 05:40:51 2012 +++ src/sys/conf/Makefile.kern.inc Fri Aug 10 16:05:26 2012 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile.kern.inc,v 1.157 2012/07/27 05:40:51 matt Exp $ +# $NetBSD: Makefile.kern.inc,v 1.158 2012/08/10 16:05:26 joerg Exp $ # # This file contains common `MI' targets and definitions and it is included # at the bottom of each `MD' ${MACHINE}/conf/Makefile.${MACHINE}. @@ -70,7 +70,6 @@ CWARNFLAGS+= -Wold-style-definition CWARNFLAGS+= -Wswitch -Wshadow CWARNFLAGS+= -Wcast-qual -Wwrite-strings CWARNFLAGS+= -Wno-unreachable-code -. if defined(HAVE_GCC) || defined(HAVE_PCC) CWARNFLAGS+= -Wno-pointer-sign -Wno-attributes . if ${MACHINE} == "i386" || ${MACHINE_ARCH} == "x86_64" || \ ${MACHINE_ARCH} == "sparc64" || ${MACHINE} == "prep" @@ -79,7 +78,6 @@ CWARNFLAGS+= -Wextra -Wno-unused-paramet . if ${MACHINE} == "i386" || ${MACHINE_ARCH} == "x86_64" CWARNFLAGS+= -Wold-style-definition . endif -. endif # Add -Wno-sign-compare. -Wsign-compare is included in -Wall as of GCC 3.3, # but our sources aren't up for it yet. CWARNFLAGS+= -Wno-sign-compare @@ -96,7 +94,7 @@ CFLAGS+= ${DEBUG} ${COPTS} AFLAGS+= -D_LOCORE -Wa,--fatal-warnings # XXX -.if defined(HAVE_GCC) +.if defined(HAVE_GCC) || defined(HAVE_LLVM) CFLAGS+= -fno-strict-aliasing CFLAGS+= -fno-common .endif @@ -566,11 +564,9 @@ VARSTACK=kern/uipc_socket.c miscfs/genfs uvm/uvm_pager.c dev/ic/aic7xxx.c dev/ic/aic79xx.c arch/xen/i386/gdt.c \ dev/ofw/ofw_subr.c -.if defined(HAVE_GCC) || defined(HAVE_PCC) .for __varstack in ${VARSTACK} COPTS.${__varstack:T} += -Wno-stack-protector .endfor -.endif AFLAGS+= ${AOPTS.${.IMPSRC:T}} CFLAGS+= ${COPTS.${.IMPSRC:T}} ${CPUFLAGS.${.IMPSRC:T}} Index: src/sys/lib/libkern/Makefile.inc diff -u src/sys/lib/libkern/Makefile.inc:1.40 src/sys/lib/libkern/Makefile.inc:1.41 --- src/sys/lib/libkern/Makefile.inc:1.40 Tue Dec 20 19:35:26 2005 +++ src/sys/lib/libkern/Makefile.inc Fri Aug 10 16:05:27 2012 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile.inc,v 1.40 2005/12/20 19:35:26 christos Exp $ +# $NetBSD: Makefile.inc,v 1.41 2012/08/10 16:05:27 joerg Exp $ # # Configuration variables (default values are below): # @@ -47,6 +47,8 @@ KERNMAKE= \ KERNCPPFLAGS=${CPPFLAGS:S@^-I.@-I${KERNDOTDIR}@g:Q} \ KERNMISCCPPFLAGS=${KERNMISCCPPFLAGS:Q} \ LINTFLAGS=${KERNLINTFLAGS:Q} \ + LIBKERN_ARCH=${LIBKERN_ARCH:Q} \ + COMMON_MACHINE_ARCH=${COMMON_MACHINE_ARCH:Q} \ ${KERNMISCMAKEFLAGS} ${KERNLIB}: .NOTMAIN .MAKE __always_make_kernlib Index: src/sys/lib/libsa/Makefile diff -u src/sys/lib/libsa/Makefile:1.77 src/sys/lib/libsa/Makefile:1.78 --- src/sys/lib/libsa/Makefile:1.77 Mon Jan 16 18:44:13 2012 +++ src/sys/lib/libsa/Makefile Fri Aug 10 16:05:27 2012 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.77 2012/01/16 18:44:13 christos Exp $ +# $NetBSD: Makefile,v 1.78 2012/08/10 16:05:27 joerg Exp $ LIB= sa NOPIC= # defined @@ -91,9 +91,7 @@ lib${LIB}.o:: ${OBJS} @rm -f lib${LIB}.o @${LD} -r -o lib${LIB}.o `lorder ${OBJS} | tsort` -.if defined(HAVE_GCC) || defined(HAVE_PCC) CPPFLAGS+= -Wno-pointer-sign -.endif .if defined(HAVE_GCC) && ${HAVE_GCC} >= 45 && ${MACHINE_ARCH} == "vax" COPTS.bootp.c+= -O0 Index: src/sys/rump/Makefile.rump diff -u src/sys/rump/Makefile.rump:1.62 src/sys/rump/Makefile.rump:1.63 --- src/sys/rump/Makefile.rump:1.62 Sun Aug 5 15:37:39 2012 +++ src/sys/rump/Makefile.rump Fri Aug 10 16:05:27 2012 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile.rump,v 1.62 2012/08/05 15:37:39 pooka Exp $ +# $NetBSD: Makefile.rump,v 1.63 2012/08/10 16:05:27 joerg Exp $ # WARNS?= 3 # XXX: src/sys won't compile with -Wsign-compare yet @@ -16,7 +16,7 @@ CPPFLAGS+= -D_RUMP_NATIVE_ABI .endif CFLAGS+= -ffreestanding -fno-strict-aliasing -.if defined(HAVE_GCC) && ${HAVE_GCC} >= 3 +.if (defined(HAVE_GCC) && ${HAVE_GCC} >= 3) || defined(HAVE_LLVM) CFLAGS+= -Wsign-compare CFLAGS+= -Wno-pointer-sign -Wno-attributes CFLAGS+= -std=gnu99