Module Name: src
Committed By: mrg
Date: Mon Jun 20 06:52:38 UTC 2011
Modified Files:
src: Makefile
src/lib/csu/common_elf: Makefile.inc
src/lib/i18n_module/UTF7: Makefile
src/lib/libbz2: Makefile
src/share/mk: bsd.own.mk bsd.sys.mk
src/sys/arch/hp700/stand: Makefile.inc
src/sys/arch/i386/stand: Makefile.booters
src/sys/arch/i386/stand/boot: Makefile.boot
src/sys/arch/i386/stand/bootxx: Makefile.bootxx
src/sys/conf: Makefile.kern.inc
Log Message:
remove all the code that supported HAVE_GCC=3. mostly from chuq.
To generate a diff of this commit:
cvs rdiff -u -r1.283 -r1.284 src/Makefile
cvs rdiff -u -r1.32 -r1.33 src/lib/csu/common_elf/Makefile.inc
cvs rdiff -u -r1.3 -r1.4 src/lib/i18n_module/UTF7/Makefile
cvs rdiff -u -r1.14 -r1.15 src/lib/libbz2/Makefile
cvs rdiff -u -r1.670 -r1.671 src/share/mk/bsd.own.mk
cvs rdiff -u -r1.203 -r1.204 src/share/mk/bsd.sys.mk
cvs rdiff -u -r1.7 -r1.8 src/sys/arch/hp700/stand/Makefile.inc
cvs rdiff -u -r1.84 -r1.85 src/sys/arch/i386/stand/Makefile.booters
cvs rdiff -u -r1.52 -r1.53 src/sys/arch/i386/stand/boot/Makefile.boot
cvs rdiff -u -r1.41 -r1.42 src/sys/arch/i386/stand/bootxx/Makefile.bootxx
cvs rdiff -u -r1.139 -r1.140 src/sys/conf/Makefile.kern.inc
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/Makefile
diff -u src/Makefile:1.283 src/Makefile:1.284
--- src/Makefile:1.283 Wed Jun 15 09:45:58 2011
+++ src/Makefile Mon Jun 20 06:52:36 2011
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.283 2011/06/15 09:45:58 mrg Exp $
+# $NetBSD: Makefile,v 1.284 2011/06/20 06:52:36 mrg Exp $
#
# This is the top-level makefile for building NetBSD. For an outline of
@@ -199,10 +199,10 @@
# Targets (in order!) called by "make build".
#
.if defined(HAVE_GCC)
-.if ${HAVE_GCC} == "3"
-LIBGCC_EXT=3
-.else
+.if ${HAVE_GCC} == "4"
LIBGCC_EXT=4
+.else
+LIBGCC_EXT=45
.endif
.endif
@@ -444,10 +444,8 @@
.if defined(HAVE_GCC)
.if ${MKGCC} != "no"
.if ${USE_COMPILERCRTSTUFF} == "yes"
-.if (${HAVE_GCC} == "3" || ${HAVE_GCC} == "4")
${MAKEDIRTARGET} . do-gnu-lib-crtstuff${LIBGCC_EXT}
.endif
-.endif
${MAKEDIRTARGET} . do-gnu-lib-libgcc${LIBGCC_EXT}
.endif
.endif
Index: src/lib/csu/common_elf/Makefile.inc
diff -u src/lib/csu/common_elf/Makefile.inc:1.32 src/lib/csu/common_elf/Makefile.inc:1.33
--- src/lib/csu/common_elf/Makefile.inc:1.32 Sun Dec 13 08:52:38 2009
+++ src/lib/csu/common_elf/Makefile.inc Mon Jun 20 06:52:36 2011
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile.inc,v 1.32 2009/12/13 08:52:38 mrg Exp $
+# $NetBSD: Makefile.inc,v 1.33 2011/06/20 06:52:36 mrg Exp $
.if !defined(ELFSIZE)
ELFSIZE=32
@@ -14,7 +14,7 @@
CPPFLAGS+= -DJCR
CPPFLAGS+= -DDSO_HANDLE
-.if defined(HAVE_GCC) && ${HAVE_GCC} > 3
+.if defined(HAVE_GCC)
CFLAGS+= -fno-unit-at-a-time
.endif
Index: src/lib/i18n_module/UTF7/Makefile
diff -u src/lib/i18n_module/UTF7/Makefile:1.3 src/lib/i18n_module/UTF7/Makefile:1.4
--- src/lib/i18n_module/UTF7/Makefile:1.3 Fri Aug 29 00:02:22 2008
+++ src/lib/i18n_module/UTF7/Makefile Mon Jun 20 06:52:36 2011
@@ -1,8 +1,8 @@
-# $NetBSD: Makefile,v 1.3 2008/08/29 00:02:22 gmcgarry Exp $
+# $NetBSD: Makefile,v 1.4 2011/06/20 06:52:36 mrg Exp $
SRCPRE=citrus_
.include <bsd.lib.mk>
-.if ${MACHINE_ARCH} == "vax" && defined(HAVE_GCC) && ${HAVE_GCC} > 3
+.if ${MACHINE_ARCH} == "vax" && defined(HAVE_GCC)
COPTS.citrus_utf7.c+= -O0
.endif
Index: src/lib/libbz2/Makefile
diff -u src/lib/libbz2/Makefile:1.14 src/lib/libbz2/Makefile:1.15
--- src/lib/libbz2/Makefile:1.14 Fri Aug 29 00:02:22 2008
+++ src/lib/libbz2/Makefile Mon Jun 20 06:52:37 2011
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.14 2008/08/29 00:02:22 gmcgarry Exp $
+# $NetBSD: Makefile,v 1.15 2011/06/20 06:52:37 mrg Exp $
USE_FORT?= yes # data driven bugs?
@@ -22,7 +22,7 @@
# XXX blocksort.c gets mis-compiled with 4.1
.if (${MACHINE_ARCH} == "sh3el" || ${MACHINE_ARCH} == "sh3eb") && \
- (defined(HAVE_GCC) && ${HAVE_GCC} == 4)
+ defined(HAVE_GCC)
COPTS.blocksort.c+= -fno-loop-optimize
.endif
Index: src/share/mk/bsd.own.mk
diff -u src/share/mk/bsd.own.mk:1.670 src/share/mk/bsd.own.mk:1.671
--- src/share/mk/bsd.own.mk:1.670 Wed Jun 15 09:45:59 2011
+++ src/share/mk/bsd.own.mk Mon Jun 20 06:52:37 2011
@@ -1,4 +1,4 @@
-# $NetBSD: bsd.own.mk,v 1.670 2011/06/15 09:45:59 mrg Exp $
+# $NetBSD: bsd.own.mk,v 1.671 2011/06/20 06:52:37 mrg Exp $
# This needs to be before bsd.init.mk
.if defined(BSD_MK_COMPAT_FILE)
@@ -46,7 +46,7 @@
#
TOOLCHAIN_MISSING?= no
-# default to GCC4
+# default to GCC4.1
.if !defined(HAVE_GCC) && !defined(HAVE_PCC)
HAVE_GCC= 4
.endif
@@ -574,7 +574,7 @@
MKISCSI= no
# XXX GCC 4 outputs mcount() calling sequences that try to load values
# from over 64KB away and this fails to assemble.
-.if defined(HAVE_GCC) && (${HAVE_GCC} == 4)
+.if defined(HAVE_GCC)
NOPROFILE= # defined
.endif
.endif
Index: src/share/mk/bsd.sys.mk
diff -u src/share/mk/bsd.sys.mk:1.203 src/share/mk/bsd.sys.mk:1.204
--- src/share/mk/bsd.sys.mk:1.203 Mon May 30 13:56:34 2011
+++ src/share/mk/bsd.sys.mk Mon Jun 20 06:52:37 2011
@@ -1,4 +1,4 @@
-# $NetBSD: bsd.sys.mk,v 1.203 2011/05/30 13:56:34 joerg Exp $
+# $NetBSD: bsd.sys.mk,v 1.204 2011/06/20 06:52:37 mrg Exp $
#
# Build definitions used for NetBSD source tree builds.
@@ -13,7 +13,7 @@
# Enable c99 mode by default.
# This has the side effect of complaining for missing prototypes
# implicit type declarations and missing return statements.
-.if defined(HAVE_GCC) && ${HAVE_GCC} >= 3
+.if defined(HAVE_GCC)
CFLAGS+= -std=gnu99
.endif
@@ -56,7 +56,7 @@
-Wno-deprecated -Woverloaded-virtual -Wsign-promo -Wsynth
CXXFLAGS+= ${${ACTIVE_CXX} == "gcc":? -Wno-non-template-friend -Wno-pmf-conversions :}
.endif
-.if ${WARNS} > 3 && defined(HAVE_GCC) && ${HAVE_GCC} >= 3
+.if ${WARNS} > 3 && defined(HAVE_GCC)
CFLAGS+= -Wsign-compare
CFLAGS+= ${${ACTIVE_CC} == "clang":? -Wpointer-sign :}
.endif
Index: src/sys/arch/hp700/stand/Makefile.inc
diff -u src/sys/arch/hp700/stand/Makefile.inc:1.7 src/sys/arch/hp700/stand/Makefile.inc:1.8
--- src/sys/arch/hp700/stand/Makefile.inc:1.7 Tue Jun 27 06:37:26 2006
+++ src/sys/arch/hp700/stand/Makefile.inc Mon Jun 20 06:52:37 2011
@@ -1,10 +1,8 @@
-# $NetBSD: Makefile.inc,v 1.7 2006/06/27 06:37:26 he Exp $
+# $NetBSD: Makefile.inc,v 1.8 2011/06/20 06:52:37 mrg Exp $
BINDIR= /usr/mdec
.include <bsd.own.mk>
-.if ${HAVE_GCC} > 3
COPTS+= -Wno-pointer-sign
-.endif
COPTS+= -fno-strict-aliasing
Index: src/sys/arch/i386/stand/Makefile.booters
diff -u src/sys/arch/i386/stand/Makefile.booters:1.84 src/sys/arch/i386/stand/Makefile.booters:1.85
--- src/sys/arch/i386/stand/Makefile.booters:1.84 Thu Jun 16 16:39:53 2011
+++ src/sys/arch/i386/stand/Makefile.booters Mon Jun 20 06:52:37 2011
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile.booters,v 1.84 2011/06/16 16:39:53 joerg Exp $
+# $NetBSD: Makefile.booters,v 1.85 2011/06/20 06:52:37 mrg Exp $
.include <bsd.own.mk>
@@ -16,13 +16,9 @@
.if ${MACHINE_ARCH} == "x86_64"
CPUFLAGS= -m32
.else
-.if ${HAVE_GCC} == 3
-CPUFLAGS= -mcpu=i386
-.else
CPUFLAGS= -march=i386 -mtune=i386
.endif
.endif
-.endif
COPTS= ${OPT_SIZE.${ACTIVE_CC}}
I386_STAND_DIR?= $S/arch/i386/stand
Index: src/sys/arch/i386/stand/boot/Makefile.boot
diff -u src/sys/arch/i386/stand/boot/Makefile.boot:1.52 src/sys/arch/i386/stand/boot/Makefile.boot:1.53
--- src/sys/arch/i386/stand/boot/Makefile.boot:1.52 Thu Jun 2 18:48:55 2011
+++ src/sys/arch/i386/stand/boot/Makefile.boot Mon Jun 20 06:52:37 2011
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile.boot,v 1.52 2011/06/02 18:48:55 dsl Exp $
+# $NetBSD: Makefile.boot,v 1.53 2011/06/20 06:52:37 mrg Exp $
S= ${.CURDIR}/../../../../..
@@ -47,13 +47,9 @@
LIBKERN_ARCH=i386
KERNMISCMAKEFLAGS="LIBKERN_ARCH=i386"
.else
-.if ${HAVE_GCC} == 3
-CPUFLAGS= -mcpu=i386
-.else
CPUFLAGS= -march=i386 -mtune=i386
.endif
.endif
-.endif
COPTS+= -ffreestanding
CFLAGS+= -Wall -Wmissing-prototypes -Wstrict-prototypes
Index: src/sys/arch/i386/stand/bootxx/Makefile.bootxx
diff -u src/sys/arch/i386/stand/bootxx/Makefile.bootxx:1.41 src/sys/arch/i386/stand/bootxx/Makefile.bootxx:1.42
--- src/sys/arch/i386/stand/bootxx/Makefile.bootxx:1.41 Thu Jun 16 16:39:53 2011
+++ src/sys/arch/i386/stand/bootxx/Makefile.bootxx Mon Jun 20 06:52:38 2011
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile.bootxx,v 1.41 2011/06/16 16:39:53 joerg Exp $
+# $NetBSD: Makefile.bootxx,v 1.42 2011/06/20 06:52:38 mrg Exp $
S= ${.CURDIR}/../../../../..
@@ -68,13 +68,9 @@
KERNMISCMAKEFLAGS="LIBKERN_ARCH=i386"
.else
CPPFLAGS+= -DEPIA_HACK
-.if ${HAVE_GCC} == 3
-CPUFLAGS= -mcpu=i386
-.else
CPUFLAGS= -march=i386 -mtune=i386
.endif
.endif
-.endif
CFLAGS+= -Wall -Wmissing-prototypes -Wstrict-prototypes
CPPFLAGS+= -nostdinc -D_STANDALONE
Index: src/sys/conf/Makefile.kern.inc
diff -u src/sys/conf/Makefile.kern.inc:1.139 src/sys/conf/Makefile.kern.inc:1.140
--- src/sys/conf/Makefile.kern.inc:1.139 Fri Jun 17 21:19:42 2011
+++ src/sys/conf/Makefile.kern.inc Mon Jun 20 06:52:38 2011
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile.kern.inc,v 1.139 2011/06/17 21:19:42 matt Exp $
+# $NetBSD: Makefile.kern.inc,v 1.140 2011/06/20 06:52:38 mrg Exp $
#
# This file contains common `MI' targets and definitions and it is included
# at the bottom of each `MD' ${MACHINE}/conf/Makefile.${MACHINE}.
@@ -68,7 +68,7 @@
CWARNFLAGS+= -Wswitch -Wshadow
CWARNFLAGS+= -Wcast-qual -Wwrite-strings
CWARNFLAGS+= -Wno-unreachable-code
-. if (defined(HAVE_GCC) && ${HAVE_GCC} > 3) || defined(HAVE_PCC)
+. 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"
@@ -88,7 +88,7 @@
AFLAGS+= -D_LOCORE -Wa,--fatal-warnings
# XXX
-.if defined(HAVE_GCC) && ${HAVE_GCC} > 3
+.if defined(HAVE_GCC)
CFLAGS+= -fno-strict-aliasing
.endif
@@ -99,8 +99,7 @@
# If we want the bpendtsleep: label in kern_synch.c, we need to use
# -fno-reorder-blocks. Don't make this a config(1) defflag without
# making sure this fragment remains valid.
-.if defined(HAVE_GCC) && ${HAVE_GCC} > 3 && \
- !empty(${CFLAGS:M-DKERN_SYNCH_BPENDTSLEEP_LABEL})
+.if defined(HAVE_GCC) && !empty(${CFLAGS:M-DKERN_SYNCH_BPENDTSLEEP_LABEL})
COPTS.kern_synch.c+= -fno-reorder-blocks
.endif
@@ -511,7 +510,7 @@
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) && ${HAVE_GCC} > 3) || defined(HAVE_PCC)
+. if defined(HAVE_GCC) || defined(HAVE_PCC)
.for __varstack in ${VARSTACK}
COPTS.${__varstack:T} += -Wno-stack-protector
.endfor