summaryrefslogtreecommitdiffstats
path: root/usr.sbin/sade/Makefile
diff options
context:
space:
mode:
authorsam <sam@FreeBSD.org>2006-03-08 18:02:32 +0000
committersam <sam@FreeBSD.org>2006-03-08 18:02:32 +0000
commitfa1fbfedc2f06342ca8bbae5b057d8bd2c14cc59 (patch)
tree87198eeaccc5a4734146e5e9aa6881c4854232fe /usr.sbin/sade/Makefile
parentb19c8d2fcc1540312b520fc757d445026667a6ac (diff)
downloadFreeBSD-src-fa1fbfedc2f06342ca8bbae5b057d8bd2c14cc59.zip
FreeBSD-src-fa1fbfedc2f06342ca8bbae5b057d8bd2c14cc59.tar.gz
Revamp base system packaging of kernels to enable up/smp selection
at runtime and to support distributing additional kernels: o remove kernel from the base tarball o add new kernel tarballs o build + package both SMP and GENERIC kernels when an <arch>/conf/SMP config file is present o add sysinstall support for multiple kernels o update sysinstall to probe for the number of cpus on a system and auto-select smp/up kernel accordingly o add a post-kernels install hook to fixup /boot/kernel o add -ldevinfo to boot crunch for sysinstall's cpu probing logic Notes: 1. On HEAD this code is not currently used because GENERIC kernels include SMP. This work is mainly intended for RELENG_6 where the GENERIC kernel is UP. If HEAD changes to match then just enable WITH_SMP in sysinstall/Makefile. 2. The cpu probing support is done with acpi and MPTable; this means some systems will require work for auto-detection to work. 3. The handling of /boot/kernel may need to be revisited; for now we rename one kernel at the last moment (SMP if installed, otherwise GENERIC). There are other, possibly better, approaches. Lots of help from ru, emaste, scottl, and jhb.
Diffstat (limited to 'usr.sbin/sade/Makefile')
-rw-r--r--usr.sbin/sade/Makefile30
1 files changed, 30 insertions, 0 deletions
diff --git a/usr.sbin/sade/Makefile b/usr.sbin/sade/Makefile
index 751d10c..c735c26 100644
--- a/usr.sbin/sade/Makefile
+++ b/usr.sbin/sade/Makefile
@@ -23,6 +23,36 @@ CFLAGS+= -I${.CURDIR}/../../gnu/lib/libdialog -I.
DPADD= ${LIBDIALOG} ${LIBNCURSES} ${LIBUTIL} ${LIBDISK} ${LIBFTPIO}
LDADD= -ldialog -lncurses -lutil -ldisk -lftpio
+#
+# When distributions have both UP and SMP kernels sysinstall
+# will probe for the number of cpus on the target machine and
+# automatically select which is appropriate. This can be overridden
+# through the menus or both kernels can be installed (with the
+# most "appropriate" one setup as /boot/kernel). For now this
+# is done for i386 and amd64; for other systems support must be
+# added to identify the cpu count if acpi and MPTable probing
+# is insufficient.
+#
+# The unmber of cpus probed is passed through the environment in
+# VAR_NCPUS ("ncpus") to scripts.
+#
+# Note that WITH_SMP is a compile time option that enables the
+# builtin menus for the SMP kernel configuration. If this kernel
+# is not built (see release/Makefile) then this should not be
+# enabled as sysinstall may try to select an SMP kernel config
+# where none is available. This option should not be needed--we
+# should probe for an SMP kernel in the distribution but doing
+# that is painful because of media changes and the structure of
+# sysinstall so for now it's a priori.
+#
+.if ${MACHINE_ARCH} == "i386" || ${MACHINE_ARCH} == "amd64"
+SRCS+= acpi.c biosmptable.c
+# NB: HEAD has SMP in GENERIC so only one kernel
+#CFLAGS+=-DWITH_SMP
+DPADD+= ${LIBDEVINFO}
+LDADD+= -ldevinfo
+.endif
+
CLEANFILES= makedevs.c rtermcap
CLEANFILES+= keymap.tmp keymap.h countries.tmp countries.h
OpenPOWER on IntegriCloud