Initiate the de-orbit burn sequence for <bsd.kern.mk>.

Always use sys/conf/kern.mk when building kernel/modules.
<bsd.kern.mk> is only preserved for sys/boot/pc98/boot2
for now, but this will be fixed.  If there are other
users of <bsd.kern.mk>, please let me know.

Reminded by:	bde
This commit is contained in:
Ruslan Ermilov 2003-02-28 22:12:17 +00:00
parent a1ceffbc22
commit ddc474a84b
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=111686
3 changed files with 11 additions and 57 deletions

View File

@ -1,59 +1,13 @@
# $FreeBSD$
#
# Warning flags for compiling the kernel and components of the kernel.
#
# Note that the newly added -Wcast-qual is responsible for generating
# most of the remaining warnings. Warnings introduced with -Wall will
# also pop up, but are easier to fix.
CWARNFLAGS?= -Wall -Wredundant-decls -Wnested-externs -Wstrict-prototypes \
-Wmissing-prototypes -Wpointer-arith -Winline -Wcast-qual \
-fformat-extensions -ansi
#
# The following flags are next up for working on:
# -W
#
# On the i386, do not align the stack to 16-byte boundaries. Otherwise GCC
# 2.95 adds code to the entry and exit point of every function to align the
# stack to 16-byte boundaries -- thus wasting approximately 12 bytes of stack
# per function call. While the 16-byte alignment may benefit micro benchmarks,
# it is probably an overall loss as it makes the code bigger (less efficient
# use of code cache tag lines) and uses more stack (less efficient use of data
# cache tag lines)
#
.if ${MACHINE_ARCH} == "i386"
CFLAGS+= -mno-align-long-strings -mpreferred-stack-boundary=2
# Search for kernel source tree in standard places.
.for _dir in ${.CURDIR}/../.. ${.CURDIR}/../../.. ${.CURDIR}/../../../.. /sys /usr/src/sys
.if !defined(SYSDIR) && exists(${_dir}/conf/kern.mk)
SYSDIR= ${_dir}
.endif
.endfor
.if !defined(SYSDIR) || !exists(${SYSDIR}/kern) || !exists(${SYSDIR}/conf/)
.error "can't find kernel source tree"
.endif
#
# On the alpha, make sure that we don't use floating-point registers and
# allow the use of BWX etc instructions (only needed for low-level i/o).
# Also, reserve register t7 to point at per-cpu global variables.
#
.if ${MACHINE_ARCH} == "alpha"
CFLAGS+= -mno-fp-regs -ffixed-8 -Wa,-mev6
.endif
#
# For IA-64, we use r13 for the kernel globals pointer and we only use
# a very small subset of float registers for integer divides.
#
.if ${MACHINE_ARCH} == "ia64"
CFLAGS+= -ffixed-r13 -mfixed-range=f32-f127 -mno-sdata
.endif
#
# For sparc64 we want medlow code model, and we tell gcc to use floating
# point emulation. This avoids using floating point registers for integer
# operations which it has a tendency to do.
#
.if ${MACHINE_ARCH} == "sparc64"
CFLAGS+= -mcmodel=medlow -msoft-float
.endif
#
# GCC 3.0 and above like to do certain optimizations based on the
# assumption that the program is linked against libc. Stop this.
#
CFLAGS+= -ffreestanding
.include "${SYSDIR}/conf/kern.mk"

View File

@ -221,4 +221,4 @@ majors.c: $S/conf/majors $S/conf/majors.awk
majors.o:
${NORMAL_C}
.include <bsd.kern.mk>
.include "kern.mk"

View File

@ -309,4 +309,4 @@ ${OBJS}: ${SRCS:M*.h}
.endif
.include <bsd.obj.mk>
.include <bsd.kern.mk>
.include "kern.mk"