diff options
author | Theo de Raadt <deraadt@cvs.openbsd.org> | 2010-05-24 14:59:17 +0000 |
---|---|---|
committer | Theo de Raadt <deraadt@cvs.openbsd.org> | 2010-05-24 14:59:17 +0000 |
commit | 692ae6fe82dd7e240b408d4ac6bb900a9e450ac0 (patch) | |
tree | c99785bbaccc3c8595e5e85bafd04c13fccb569e /sys/arch/sparc/conf | |
parent | 49384741ccb14f3d28d08ccd3395dfcabeee2828 (diff) |
Reduce differences between the Makefile.* files for all architectures.
ok various people, tested by fewer people, tested by me on 15.
Diffstat (limited to 'sys/arch/sparc/conf')
-rw-r--r-- | sys/arch/sparc/conf/Makefile.sparc | 43 |
1 files changed, 17 insertions, 26 deletions
diff --git a/sys/arch/sparc/conf/Makefile.sparc b/sys/arch/sparc/conf/Makefile.sparc index a8d7f1bef4b..51a733bb915 100644 --- a/sys/arch/sparc/conf/Makefile.sparc +++ b/sys/arch/sparc/conf/Makefile.sparc @@ -1,4 +1,4 @@ -# $OpenBSD: Makefile.sparc,v 1.59 2010/04/28 15:31:34 deraadt Exp $ +# $OpenBSD: Makefile.sparc,v 1.60 2010/05/24 14:59:16 deraadt Exp $ # For instructions on building kernels consult the config(8) and options(4) # manual pages. @@ -25,25 +25,25 @@ _machdir?= $S/arch/${_mach} _archdir?= $S/arch/${_arch} INCLUDES= -nostdinc -I. -I$S -I$S/arch -CPPFLAGS= ${INCLUDES} ${IDENT} -D_KERNEL -D${_mach} -CDIAGFLAGS= -Werror -Wall -Wstrict-prototypes -Wmissing-prototypes \ - -Wno-uninitialized -Wno-format -Wno-main \ - -Wstack-larger-than-2047 +CPPFLAGS= ${INCLUDES} ${IDENT} ${PARAM} -D_KERNEL +CWARNFLAGS= -Werror -Wall -Wstrict-prototypes -Wmissing-prototypes \ + -Wno-main -Wno-uninitialized -Wno-format \ + -Wstack-larger-than-2047 # -Wvariable-decl +CMACHFLAGS= -mno-fpu .if ${IDENT:M-DSUN*} == ${IDENT:M-DSUN4M} -CMACHFLAGS= -mcpu=supersparc -.else -CMACHFLAGS= +CMACHFLAGS+= -mcpu=supersparc .endif +CMACHFLAGS+= -fno-builtin-printf -fno-builtin-snprintf \ + -fno-builtin-vsnprintf -fno-builtin-log \ + -fno-builtin-log2 -fno-builtin-malloc .if ${IDENT:M-DNO_PROPOLICE} CMACHFLAGS+= -fno-stack-protector .endif -CMACHFLAGS+= -fno-builtin-printf -fno-builtin-log -CFLAGS= ${DEBUG} -O2 ${CDIAGFLAGS} ${CMACHFLAGS} ${COPTS} ${PIPE} -# add `-mno-fpu' to work around gcc (last noticed in v2.7.2) bug -CFLAGS+= -mno-fpu -AFLAGS= -x assembler-with-cpp -traditional-cpp -D_LOCORE +COPTS?= -O2 +CFLAGS= ${DEBUG} ${CWARNFLAGS} ${CMACHFLAGS} ${COPTS} ${PIPE} +AFLAGS= -D_LOCORE -x assembler-with-cpp -traditional-cpp ${CMACHFLAGS} LINKFLAGS= -N -e start -Ttext F8004000 STRIPFLAGS= -g -X -x @@ -53,23 +53,14 @@ DB_STRUCTINFO= db_structinfo.h DB_STRUCTINFO= .endif -HOSTCC= ${CC} +HOSTCC?= ${CC} HOSTED_CPPFLAGS=${CPPFLAGS:S/^-nostdinc$//} HOSTED_CFLAGS= ${CFLAGS} - -# compile rules: rules are named ${TYPE}_${SUFFIX}${CONFIG_DEP} -# where TYPE is NORMAL, or PROFILE}; SUFFIX is the file suffix, -# capitalized (e.g. C for a .c file), and CONFIG_DEP is _C if the file -# is marked as config-dependent. +HOSTED_C= ${HOSTCC} ${HOSTED_CFLAGS} ${HOSTED_CPPFLAGS} -c $< NORMAL_C_NOP= ${CC} ${CFLAGS} ${CPPFLAGS} -c $< NORMAL_C= ${CC} ${CFLAGS} ${CPPFLAGS} ${PROF} -c $< -NORMAL_C_C= ${CC} ${CFLAGS} ${CPPFLAGS} ${PROF} ${PARAM} -c $< - NORMAL_S= ${CC} ${AFLAGS} ${CPPFLAGS} -c $< -NORMAL_S_C= ${CC} ${AFLAGS} ${CPPFLAGS} ${PARAM} -c $< - -HOSTED_C= ${HOSTCC} ${HOSTED_CFLAGS} ${HOSTED_CPPFLAGS} -c $< %OBJS @@ -114,7 +105,7 @@ param.c: $S/conf/param.c cp $S/conf/param.c . param.o: param.c Makefile - ${NORMAL_C_C} + ${NORMAL_C} mcount.o: $S/lib/libkern/mcount.c Makefile ${NORMAL_C_NOP} @@ -132,7 +123,7 @@ clean:: [Ee]rrs linterrs makelinks assym.h ${DB_STRUCTINFO} lint: - @lint -hbxncez -DGENERIC -Dvolatile= ${CPPFLAGS} ${PARAM} -UKGDB \ + @lint -hbxncez -Dvolatile= ${CPPFLAGS} -UKGDB \ ${CFILES} ioconf.c param.c | \ grep -v 'static function .* unused' |