From 7920b17f9a21c44b39982366c451eb0081bbdd13 Mon Sep 17 00:00:00 2001 From: Yoshihiro Takahashi Date: Sat, 12 Aug 2000 14:21:33 +0000 Subject: [PATCH] - Make both 1.2MB and 1.44MB floppy images for PC-98. - Rename BIGBOOT to FDSIZE for the floppy image size. --- release/Makefile | 27 +++++++++++++------- release/alpha/dokern.sh | 52 +++++++++++++++++++++++++++++++++++++++ release/amd64/dokern.sh | 52 +++++++++++++++++++++++++++++++++++++++ release/i386/dokern.sh | 52 +++++++++++++++++++++++++++++++++++++++ release/pc98/dokern.sh | 52 +++++++++++++++++++++++++++++++++++++++ release/scripts/dokern.sh | 52 +++++++++++++++++++++++++++++++++++++++ 6 files changed, 278 insertions(+), 9 deletions(-) diff --git a/release/Makefile b/release/Makefile index 867ca7b4566a..889fa2e184f9 100644 --- a/release/Makefile +++ b/release/Makefile @@ -95,13 +95,15 @@ MNT= /mnt # Various floppy image parameters. # .if ${MACHINE} == "pc98" -BOOTSIZE= 1200 +SMALLBOOTSIZE= 1200 +BOOTSIZE= 1440 FIXITSIZE= 1440 MFSSIZE= 2880 BOOTINODE= 80000 FIXITINODE= 4000 MFSINODE= 8000 -BOOTLABEL= fd1200 +SMALLBOOTLABEL= fd1200 +BOOTLABEL= fd1440 FIXITLABEL= fd1440 MFSLABEL= minimum2 .else @@ -556,9 +558,12 @@ release.8: write_mfs_in_kernel @gzip -9vc mfsroot > mfsroot.gz @sh -e ${.CURDIR}/scripts/doFS.sh ${RD}/floppies/mfsroot.flp \ ${RD} ${MNT} ${BOOTSIZE} mfsroot.gz ${BOOTINODE} ${BOOTLABEL} +.if ${MACHINE} == "pc98" + @cd ${.CURDIR} && ${MAKE} doMFSKERN FSIMAGE=kern-small FDSIZE=SMALL @cd ${.CURDIR} && ${MAKE} doMFSKERN FSIMAGE=kern -.if ${MACHINE} != "pc98" - @cd ${.CURDIR} && ${MAKE} doMFSKERN FSIMAGE=boot BIGBOOT=YES +.else + @cd ${.CURDIR} && ${MAKE} doMFSKERN FSIMAGE=kern + @cd ${.CURDIR} && ${MAKE} doMFSKERN FSIMAGE=boot FDSIZE=BIG .endif @rm mfsroot mfsroot.gz mfsroot.size @echo "Regular and MFS boot floppies made." @@ -781,13 +786,13 @@ doMFSKERN: @echo "Running doMFSKERN for ${FSIMAGE}" @rm -f ${RD}/kernels/BOOTMFS.${FSIMAGE} @cd ${.CURDIR}/../sys/${MACHINE}/conf && \ - sh ${.CURDIR}/scripts/dokern.sh ${BIGBOOT} < ${KERNCONF} > BOOTMFS && \ + sh ${.CURDIR}/scripts/dokern.sh ${FDSIZE} < ${KERNCONF} > BOOTMFS && \ [ -r ${KERNCONF}.hints ] && cp ${KERNCONF}.hints BOOTMFS.hints .if ${MACHINE_ARCH} == "i386" @echo "options INTRO_USERCONFIG" >> \ ${.CURDIR}/../sys/${MACHINE}/conf/BOOTMFS .endif -.if defined(BIGBOOT) +.if defined(FDSIZE) && ${FDSIZE} == "BIG" @echo "options MD_ROOT_SIZE=`cat mfsroot.size`" >> \ ${.CURDIR}/../sys/${MACHINE}/conf/BOOTMFS .endif @@ -808,7 +813,7 @@ doMFSKERN: ${RD}/kernels/BOOTMFS.${FSIMAGE}.hints > \ ${RD}/image.${FSIMAGE}/boot/device.hints && \ echo "include /boot/device.hints" > ${RD}/image.${FSIMAGE}/boot/loader.rc -.if !defined(BIGBOOT) +.if !defined(FDSIZE) || ${FDSIZE} != "BIG" @echo "load /kernel" >> ${RD}/image.${FSIMAGE}/boot/loader.rc @echo "echo \\007\\007" >> ${RD}/image.${FSIMAGE}/boot/loader.rc @echo "echo Please insert MFS root floppy and press enter:" >> ${RD}/image.${FSIMAGE}/boot/loader.rc @@ -820,17 +825,21 @@ doMFSKERN: .if ${MACHINE_ARCH} == "i386" && ${AUTO_KEYBOARD_DETECT} @echo "-P" >> ${RD}/image.${FSIMAGE}/boot.config .endif -.if defined(BIGBOOT) +.if defined(FDSIZE) && ${FDSIZE} == "BIG" @echo "Writing MFS image into kernel for ${FSIMAGE} floppy" @./write_mfs_in_kernel ${RD}/image.${FSIMAGE}/kernel mfsroot @cp ${RD}/image.${FSIMAGE}/kernel ${RD}/kernels/MFSKERNEL.${FSIMAGE} .endif @gzip -9v ${RD}/image.${FSIMAGE}/kernel @rm -f ${RD}/floppies/${FSIMAGE}.flp -.if defined(BIGBOOT) +.if defined(FDSIZE) && ${FDSIZE} == "BIG" sh -e ${.CURDIR}/scripts/doFS.sh ${RD}/floppies/${FSIMAGE}.flp \ ${RD} ${MNT} ${BIGBOOTSIZE} ${RD}/image.${FSIMAGE} \ ${BOOTINODE} ${BIGBOOTLABEL} +.elif defined(FDSIZE) && ${FDSIZE} == "SMALL" + sh -e ${.CURDIR}/scripts/doFS.sh ${RD}/floppies/${FSIMAGE}.flp \ + ${RD} ${MNT} ${SMALLBOOTSIZE} ${RD}/image.${FSIMAGE} \ + ${BOOTINODE} ${SMALLBOOTLABEL} .else sh -e ${.CURDIR}/scripts/doFS.sh ${RD}/floppies/${FSIMAGE}.flp \ ${RD} ${MNT} ${BOOTSIZE} ${RD}/image.${FSIMAGE} \ diff --git a/release/alpha/dokern.sh b/release/alpha/dokern.sh index af1c4b4b8b8c..efb409d56fbc 100755 --- a/release/alpha/dokern.sh +++ b/release/alpha/dokern.sh @@ -2,11 +2,61 @@ # $FreeBSD$ +if [ $# -lt 1 ]; then + FDSIZE=NORMAL +else + FDSIZE=$1 +fi + ARCH="`uname -m`" # First check for the standard x86 PC class. if [ "${ARCH}" = "i386" ]; then +if [ "${FDSIZE}" = "SMALL" ]; then + +sed -e '/ pci/d' \ + -e '/ adv/d' \ + -e '/ ahc/d' \ + -e '/ amd/d' \ + -e '/ isp/d' \ + -e '/ ncr/d' \ + -e '/ sym/d' \ + -e '/ de/d' \ + -e '/ fxp/d' \ + -e '/ tx/d' \ + -e '/ vx/d' \ + -e '/ wx/d' \ + -e '/ miibus/d' \ + -e '/ dc/d' \ + -e '/ rl/d' \ + -e '/ sf/d' \ + -e '/ sis/d' \ + -e '/ ste/d' \ + -e '/ tl/d' \ + -e '/ vr/d' \ + -e '/ wb/d' \ + -e '/ xl/d' \ + -e '/pty/d' \ + -e '/pass/d' \ + -e '/apm0/d' \ + -e '/ppp/d' \ + -e '/gif/d' \ + -e '/faith/d' \ + -e '/gzip/d' \ + -e '/splash/d' \ + -e '/PROCFS/d' \ + -e '/KTRACE/d' \ + -e '/SYSVMSG/d' \ + -e '/SOFTUPDATES/d' \ + -e '/maxusers/d' \ + -e '/MFS/d' \ + -e '/NFS_ROOT/d' \ + -e '/atapist/d' \ + -e 's/ident.*GENERIC/ident BOOTMFS/g' + +else + sed -e '/pty/d' \ -e '/pass/d' \ -e '/apm0/d' \ @@ -25,6 +75,8 @@ sed -e '/pty/d' \ -e '/atapist/d' \ -e 's/ident.*GENERIC/ident BOOTMFS/g' +fi + echo "options NETGRAPH" echo "options NETGRAPH_ETHER" echo "options NETGRAPH_PPPOE" diff --git a/release/amd64/dokern.sh b/release/amd64/dokern.sh index af1c4b4b8b8c..efb409d56fbc 100755 --- a/release/amd64/dokern.sh +++ b/release/amd64/dokern.sh @@ -2,11 +2,61 @@ # $FreeBSD$ +if [ $# -lt 1 ]; then + FDSIZE=NORMAL +else + FDSIZE=$1 +fi + ARCH="`uname -m`" # First check for the standard x86 PC class. if [ "${ARCH}" = "i386" ]; then +if [ "${FDSIZE}" = "SMALL" ]; then + +sed -e '/ pci/d' \ + -e '/ adv/d' \ + -e '/ ahc/d' \ + -e '/ amd/d' \ + -e '/ isp/d' \ + -e '/ ncr/d' \ + -e '/ sym/d' \ + -e '/ de/d' \ + -e '/ fxp/d' \ + -e '/ tx/d' \ + -e '/ vx/d' \ + -e '/ wx/d' \ + -e '/ miibus/d' \ + -e '/ dc/d' \ + -e '/ rl/d' \ + -e '/ sf/d' \ + -e '/ sis/d' \ + -e '/ ste/d' \ + -e '/ tl/d' \ + -e '/ vr/d' \ + -e '/ wb/d' \ + -e '/ xl/d' \ + -e '/pty/d' \ + -e '/pass/d' \ + -e '/apm0/d' \ + -e '/ppp/d' \ + -e '/gif/d' \ + -e '/faith/d' \ + -e '/gzip/d' \ + -e '/splash/d' \ + -e '/PROCFS/d' \ + -e '/KTRACE/d' \ + -e '/SYSVMSG/d' \ + -e '/SOFTUPDATES/d' \ + -e '/maxusers/d' \ + -e '/MFS/d' \ + -e '/NFS_ROOT/d' \ + -e '/atapist/d' \ + -e 's/ident.*GENERIC/ident BOOTMFS/g' + +else + sed -e '/pty/d' \ -e '/pass/d' \ -e '/apm0/d' \ @@ -25,6 +75,8 @@ sed -e '/pty/d' \ -e '/atapist/d' \ -e 's/ident.*GENERIC/ident BOOTMFS/g' +fi + echo "options NETGRAPH" echo "options NETGRAPH_ETHER" echo "options NETGRAPH_PPPOE" diff --git a/release/i386/dokern.sh b/release/i386/dokern.sh index af1c4b4b8b8c..efb409d56fbc 100755 --- a/release/i386/dokern.sh +++ b/release/i386/dokern.sh @@ -2,11 +2,61 @@ # $FreeBSD$ +if [ $# -lt 1 ]; then + FDSIZE=NORMAL +else + FDSIZE=$1 +fi + ARCH="`uname -m`" # First check for the standard x86 PC class. if [ "${ARCH}" = "i386" ]; then +if [ "${FDSIZE}" = "SMALL" ]; then + +sed -e '/ pci/d' \ + -e '/ adv/d' \ + -e '/ ahc/d' \ + -e '/ amd/d' \ + -e '/ isp/d' \ + -e '/ ncr/d' \ + -e '/ sym/d' \ + -e '/ de/d' \ + -e '/ fxp/d' \ + -e '/ tx/d' \ + -e '/ vx/d' \ + -e '/ wx/d' \ + -e '/ miibus/d' \ + -e '/ dc/d' \ + -e '/ rl/d' \ + -e '/ sf/d' \ + -e '/ sis/d' \ + -e '/ ste/d' \ + -e '/ tl/d' \ + -e '/ vr/d' \ + -e '/ wb/d' \ + -e '/ xl/d' \ + -e '/pty/d' \ + -e '/pass/d' \ + -e '/apm0/d' \ + -e '/ppp/d' \ + -e '/gif/d' \ + -e '/faith/d' \ + -e '/gzip/d' \ + -e '/splash/d' \ + -e '/PROCFS/d' \ + -e '/KTRACE/d' \ + -e '/SYSVMSG/d' \ + -e '/SOFTUPDATES/d' \ + -e '/maxusers/d' \ + -e '/MFS/d' \ + -e '/NFS_ROOT/d' \ + -e '/atapist/d' \ + -e 's/ident.*GENERIC/ident BOOTMFS/g' + +else + sed -e '/pty/d' \ -e '/pass/d' \ -e '/apm0/d' \ @@ -25,6 +75,8 @@ sed -e '/pty/d' \ -e '/atapist/d' \ -e 's/ident.*GENERIC/ident BOOTMFS/g' +fi + echo "options NETGRAPH" echo "options NETGRAPH_ETHER" echo "options NETGRAPH_PPPOE" diff --git a/release/pc98/dokern.sh b/release/pc98/dokern.sh index af1c4b4b8b8c..efb409d56fbc 100755 --- a/release/pc98/dokern.sh +++ b/release/pc98/dokern.sh @@ -2,11 +2,61 @@ # $FreeBSD$ +if [ $# -lt 1 ]; then + FDSIZE=NORMAL +else + FDSIZE=$1 +fi + ARCH="`uname -m`" # First check for the standard x86 PC class. if [ "${ARCH}" = "i386" ]; then +if [ "${FDSIZE}" = "SMALL" ]; then + +sed -e '/ pci/d' \ + -e '/ adv/d' \ + -e '/ ahc/d' \ + -e '/ amd/d' \ + -e '/ isp/d' \ + -e '/ ncr/d' \ + -e '/ sym/d' \ + -e '/ de/d' \ + -e '/ fxp/d' \ + -e '/ tx/d' \ + -e '/ vx/d' \ + -e '/ wx/d' \ + -e '/ miibus/d' \ + -e '/ dc/d' \ + -e '/ rl/d' \ + -e '/ sf/d' \ + -e '/ sis/d' \ + -e '/ ste/d' \ + -e '/ tl/d' \ + -e '/ vr/d' \ + -e '/ wb/d' \ + -e '/ xl/d' \ + -e '/pty/d' \ + -e '/pass/d' \ + -e '/apm0/d' \ + -e '/ppp/d' \ + -e '/gif/d' \ + -e '/faith/d' \ + -e '/gzip/d' \ + -e '/splash/d' \ + -e '/PROCFS/d' \ + -e '/KTRACE/d' \ + -e '/SYSVMSG/d' \ + -e '/SOFTUPDATES/d' \ + -e '/maxusers/d' \ + -e '/MFS/d' \ + -e '/NFS_ROOT/d' \ + -e '/atapist/d' \ + -e 's/ident.*GENERIC/ident BOOTMFS/g' + +else + sed -e '/pty/d' \ -e '/pass/d' \ -e '/apm0/d' \ @@ -25,6 +75,8 @@ sed -e '/pty/d' \ -e '/atapist/d' \ -e 's/ident.*GENERIC/ident BOOTMFS/g' +fi + echo "options NETGRAPH" echo "options NETGRAPH_ETHER" echo "options NETGRAPH_PPPOE" diff --git a/release/scripts/dokern.sh b/release/scripts/dokern.sh index af1c4b4b8b8c..efb409d56fbc 100755 --- a/release/scripts/dokern.sh +++ b/release/scripts/dokern.sh @@ -2,11 +2,61 @@ # $FreeBSD$ +if [ $# -lt 1 ]; then + FDSIZE=NORMAL +else + FDSIZE=$1 +fi + ARCH="`uname -m`" # First check for the standard x86 PC class. if [ "${ARCH}" = "i386" ]; then +if [ "${FDSIZE}" = "SMALL" ]; then + +sed -e '/ pci/d' \ + -e '/ adv/d' \ + -e '/ ahc/d' \ + -e '/ amd/d' \ + -e '/ isp/d' \ + -e '/ ncr/d' \ + -e '/ sym/d' \ + -e '/ de/d' \ + -e '/ fxp/d' \ + -e '/ tx/d' \ + -e '/ vx/d' \ + -e '/ wx/d' \ + -e '/ miibus/d' \ + -e '/ dc/d' \ + -e '/ rl/d' \ + -e '/ sf/d' \ + -e '/ sis/d' \ + -e '/ ste/d' \ + -e '/ tl/d' \ + -e '/ vr/d' \ + -e '/ wb/d' \ + -e '/ xl/d' \ + -e '/pty/d' \ + -e '/pass/d' \ + -e '/apm0/d' \ + -e '/ppp/d' \ + -e '/gif/d' \ + -e '/faith/d' \ + -e '/gzip/d' \ + -e '/splash/d' \ + -e '/PROCFS/d' \ + -e '/KTRACE/d' \ + -e '/SYSVMSG/d' \ + -e '/SOFTUPDATES/d' \ + -e '/maxusers/d' \ + -e '/MFS/d' \ + -e '/NFS_ROOT/d' \ + -e '/atapist/d' \ + -e 's/ident.*GENERIC/ident BOOTMFS/g' + +else + sed -e '/pty/d' \ -e '/pass/d' \ -e '/apm0/d' \ @@ -25,6 +75,8 @@ sed -e '/pty/d' \ -e '/atapist/d' \ -e 's/ident.*GENERIC/ident BOOTMFS/g' +fi + echo "options NETGRAPH" echo "options NETGRAPH_ETHER" echo "options NETGRAPH_PPPOE"