Makefile revision 40277
176082Sbmah# $Id: Makefile,v 1.413 1998/10/10 08:15:38 jkh Exp $ 276082Sbmah# 376082Sbmah# make release CHROOTDIR=/some/dir BUILDNAME=somename [ RELEASETAG=tag ] 476082Sbmah# 576082Sbmah# Where "/some/dir" is the pathname of a directory on a some 676082Sbmah# filesystem with at least 1000MB of free space, "somename" is what 776082Sbmah# you want the release to call itself and, optionally, which CVS "tag" 876082Sbmah# name should be used when checking out the sources to build the release 976082Sbmah# (default is HEAD). 1076082Sbmah# 1176082Sbmah# Please note: the vn driver must also be compiled into your kernel, 1276082Sbmah# otherwise the target 'release.8' and possibly others will fail. 1386157Solgeni# 1476082Sbmah# Set these, release builder! 1576082Sbmah# 1676082Sbmah# Fixed version: 1776082Sbmah#BUILDNAME=2.2-RELEASE 1876082Sbmah# 1976082Sbmah# Automatic SNAP versioning: 2086157SolgeniDATE != date +%Y%m%d 2176082SbmahBASE = 3.0 2276082SbmahBUILDNAME?=${BASE}-${DATE}-SNAP 2376560Sbmah# 2476560Sbmah#CHROOTDIR=/junk/release 2576560Sbmah# If this is a RELEASE, then set 2676560Sbmah#RELEASETAG=RELENG_2_2 2776560Sbmah 2876560Sbmah# If you are using a local CVS repository with components stored in 2976560Sbmah# non-standard modules, override these on the make commandline or 3076082Sbmah# in the environment. 3176082SbmahRELEASESRCMODULE?= src 3276082SbmahRELEASEDOCMODULE?= doc 3376598SbmahRELEASEPORTSMODULE?= ports 3476598Sbmah 3576598Sbmah# Unless set elsewhere, indicate the object format we'll be using. 3676598SbmahOBJFORMAT?= elf 3776082Sbmah 3876082Sbmah# Uncomment this to disable the doc.1 target. It is also an ERROR 3976082Sbmah# to set NOPORTS and not set NODOC since docs depend on ports. 4085416Sbmah#NODOC= YES 4176082Sbmah#NOPORTS= YES 4276082Sbmah# Comment the following if you want the release documentation to be 4376082Sbmah# in English only. 4476560SbmahALLLANG= yes 4576560SbmahDOCPORTS= archivers/unzip textproc/jade textproc/iso8879 \ 4676560Sbmah textproc/linuxdoc textproc/docbook textproc/sgmlformat 4776560Sbmah 4876082Sbmah# Things which without too much trouble can be considered variables 4976082Sbmah# BIN_DISTS are special in that they get full /etc installation sets. 5087808Sbmah# 5176082SbmahCOMPAT_DISTS?= compat1x compat20 compat21 5276082SbmahOTHER_DISTS?= manpages catpages games proflibs dict info doc 5376082SbmahCRYPTO_DISTS?= krb des 5476082SbmahBIN_DISTS?= bin 5576082SbmahDISTRIBUTIONS?= ${BIN_DISTS} ${OTHER_DISTS} ${COMPAT_DISTS} ${CRYPTO_DISTS} 5695526SbmahKERNELS?= GENERIC 5776082Sbmah 5876082Sbmah# Extra source tarballs; each argument is a pair of source dir and 5995526Sbmah# distribution name. The dist name should not exceed 7 characters 6095526Sbmah# (another "s" for "source" will be prepended). 6195526SbmahEXTRA_SRC+= usr.sbin/sendmail/cf smailcf 6276082Sbmah 6376082SbmahBOOT1= etc/protocols etc/rc.conf 6476082Sbmah 6576082Sbmah# mountpoint for filesystems. 6676082SbmahMNT= /mnt 6776082Sbmah 6895526Sbmah# Various floppy image parameters. 6976082Sbmah# 7076082Sbmah# These are adjusted down to the minimum needed by doFS.sh. 7195526Sbmah.if ${MACHINE_ARCH} == "i386" 7276082SbmahBOOTSIZE= 1440 7376082SbmahBOOTMFSSIZE= 1440 7476082SbmahFIXITSIZE= 1440 7576082SbmahBOOTINODE= 1000000 7676082SbmahMFSINODE= 8000 77103657SbmahFIXITINODE= 2000 7876082SbmahBOOTLABEL= fd1440 7976082SbmahBOOTMFSLABEL= minimum 8095526SbmahFIXITLABEL= fd1440 8195526Sbmah.else 8295526SbmahBOOTSIZE= 1440 8376082SbmahBOOTMFSSIZE= 2880 8476082SbmahFIXITSIZE= 2880 8576082SbmahBOOTINODE= 1000000 86101750SbmahMFSINODE= 8000 87101750SbmahFIXITINODE= 2000 88101750SbmahBOOTLABEL= fd1440 89103657SbmahBOOTMFSLABEL= minimum2 9076082SbmahFIXITLABEL= minimum2 9176082Sbmah.endif 92103657Sbmah 9376082SbmahZIPNSPLIT= gzip --no-name -9 -c | split -b 240640 - 9476082Sbmah 9576082Sbmah 9676082SbmahVNDEVICE?= vn0 9776082Sbmah 9895526Sbmah# Things which may get you into trouble if you change them 9995526SbmahMTREEFILES= ${.CURDIR}/../etc/mtree 10095526SbmahRD= /R/stage 101103657SbmahFD= /R/ftp 102103657SbmahCD= /R/cdrom 103103657SbmahCD_DISC1= ${CD}/disc1 10487357SbmahCD_DISC2= ${CD}/disc2 10587357Sbmah 10687357Sbmah# Where the bootstrap ports (see DOCPORTS) get installed. 10796742SbmahLOCALDIR= /usr/local/bin 10887357Sbmah 10987357Sbmah# ${BOOTSTRAPDIR} is for those utilities that refer to the hosting 110103657Sbmah# environment, rather than the target environment. This is specifically 11176082Sbmah# intended for kernel-dependent utilities that are used during the build. 11276082Sbmah# 11386055Sbmah# ${BOOTSTRAPDIR} is actually being used by prepending it to the normal 11476082Sbmah# ${PATH}. Thus, it's also available to outside utilities like doFS.sh. 115103657SbmahBOOTSTRAPDIR= /bootstrap 116103657Sbmah# 117103657Sbmah# The mount subsystem has been changed between 2.2 and 3.0 by the 11876082Sbmah# Lite2 import. 11976082SbmahBOOTSTRAPUTILS= /sbin/mount /sbin/umount 12097677Snyan# 12176082Sbmah# 3.0 cpio tries to reference lchown(2) which is not available in 2.2 12297677SnyanBOOTSTRAPUTILS+= /usr/bin/cpio 12397677Snyan 12497677Snyan.if !defined(CRUNCH_TARGETS) 12597677SnyanCRUNCH_TARGETS= boot fixit 12697677Snyan.endif 12797677Snyan 12897677SnyanEXTRAS= cdrom.1 ftp.1 12987993Sbmah 13076082Sbmah.if !defined(NODOC) 13176082SbmahDOCREL= doc.1 13287993Sbmah.endif 13376560Sbmah 13476560SbmahREDO?= sysinstall 13576082SbmahREDOSED= sed -e 's/dirs/release.1/' -e 's/trees/release.2/' \ 13676082Sbmah -e 's/kerns/release.3/' -e 's/sysinstall/release.4/' \ 13776560Sbmah -e 's/fixup/release.5/' -e 's/tarbin/release.6/' \ 13876560Sbmah -e 's/tarsrc/release.7/' -e 's/boot\.flp/release.8/' \ 13976082Sbmah -e 's/fixit\.flp/release.9/' -e 's/ftp/ftp.1/' \ 14076082Sbmah -e 's/cdrom/cdrom.1/' -e 's/doc/doc.1/' 14176082Sbmah 14286139SbmahREDOREDO!= echo ${REDO} | ${REDOSED} 14376082Sbmah 14486896Sbmahrerelease release: 14586896Sbmah.if !defined(CHROOTDIR) || !defined(BUILDNAME) || !defined(CVSROOT) 14686896Sbmah @echo "To make a release you must set CHROOTDIR, BUILDNAME and CVSROOT" && false 14786896Sbmah.endif 14886896Sbmah.if make(release) 14986896Sbmah.if exists(${CHROOTDIR}) 15086896Sbmah# The first command will fail on a handful of files that have their schg 15186896Sbmah# flags set. But it greatly speeds up the next two commands. 15286896Sbmah -rm -rf ${CHROOTDIR} 15386896Sbmah -chflags -R noschg ${CHROOTDIR}/. 15486896Sbmah -rm -rf ${CHROOTDIR} 15586896Sbmah.endif 15686896Sbmah -mkdir -p ${CHROOTDIR} 15776560Sbmah cd ${.CURDIR}/../etc && ${MAKE} distrib-dirs DESTDIR=${CHROOTDIR} 15876560Sbmah cd ${.CURDIR}/../etc && ${MAKE} distribution DESTDIR=${CHROOTDIR} 15976082Sbmah cd ${.CURDIR}/.. && ${MAKE} installworld DESTDIR=${CHROOTDIR} NOMAN=1 16086896Sbmah mkdir ${CHROOTDIR}/${BOOTSTRAPDIR} 16176560Sbmah for i in ${BOOTSTRAPUTILS} ; do \ 16276560Sbmah cp -p ${CHROOTDIR}$$i ${CHROOTDIR}/${BOOTSTRAPDIR} ; \ 16376560Sbmah done 16476082Sbmah.if !defined(RELEASETAG) 16576082Sbmah cd ${CHROOTDIR}/usr && rm -rf src && \ 16676082Sbmah cvs -R -d ${CVSROOT} co -P ${RELEASESRCMODULE} 16776082Sbmah.else 16876082Sbmah cd ${CHROOTDIR}/usr && rm -rf src && \ 16976082Sbmah cvs -R -d ${CVSROOT} co -P -r ${RELEASETAG} ${RELEASESRCMODULE} 17076560Sbmah.endif 17176560Sbmah.if defined(LOCAL_PATCHES) && exists(${LOCAL_PATCHES}) 17276082Sbmah cd ${CHROOTDIR}/usr/src && patch --silent < ${LOCAL_PATCHES} 17376082Sbmah.endif 17476082Sbmah.if defined(LOCAL_SCRIPT) && exists(${LOCAL_SCRIPT}) 17576560Sbmah cd ${CHROOTDIR} && env CHROOTDIR=${CHROOTDIR} BUILDNAME=${BUILDNAME} RELEASETAG=${RELEASETAG} ${LOCAL_SCRIPT} 17676560Sbmah.endif 17776082Sbmah.if !defined(NOPORTS) 17897677Snyan cd ${CHROOTDIR}/usr && rm -rf ports && cvs -R -d ${CVSROOT} co -P ${RELEASEPORTSMODULE} && cd ports && make readmes PORTSDIR=${CHROOTDIR}/usr/ports 17997677Snyan.endif 18097677Snyan.if !defined(NODOC) 18197677Snyan cd ${CHROOTDIR}/usr && rm -rf doc && cvs -R -d ${CVSROOT} co -P ${RELEASEDOCMODULE} 18297677Snyan cd ${CHROOTDIR}/usr/ports && for i in ${DOCPORTS}; do \ 18397677Snyan (cd $$i; make fetch MASTER_SITE_OVERRIDE=file:/usr/ports/distfiles/ \ 18497677Snyan DISTDIR=${CHROOTDIR}/usr/ports/distfiles ); \ 18597677Snyan done 18697677Snyan.endif 18776082Sbmah.endif 18876082Sbmah.if make(rerelease) 18976082Sbmah.if !defined(RELEASENOUPDATE) 190102813Sbmah.if !defined(RELEASETAG) 191102813Sbmah cd ${CHROOTDIR}/usr/src && cvs -R -q update -P -d 192102444Sbmah.else 193102444Sbmah cd ${CHROOTDIR}/usr/src && cvs -R -q update -P -d -r ${RELEASETAG} 194102813Sbmah.endif 195102444Sbmah.if !defined(NOPORTS) 196102444Sbmah cd ${CHROOTDIR}/usr/ports && cvs -R -q update -P -d 197102444Sbmah.endif 198102444Sbmah.if !defined(NODOC) 199102444Sbmah cd ${CHROOTDIR}/usr/doc && cvs -R -q update -P -d 200102444Sbmah.endif 201102444Sbmah.endif 20282597Sscottl.endif 20376082Sbmah # Add version information to those things that need it. 20476082Sbmah ( cd ${CHROOTDIR}/usr/src/sys/conf && \ 20582597Sscottl mv newvers.sh foo && \ 20682597Sscottl sed "s/^RELEASE=.*/RELEASE=${BUILDNAME}/" foo > newvers.sh&& rm foo ) 20782597Sscottl ( cd ${CHROOTDIR}/usr/src/release/sysinstall && \ 20876396Sscottl sed "s/__RELEASE/${BUILDNAME}/" version.h > version.h.new && \ 20976396Sscottl mv version.h.new version.h && \ 21076396Sscottl echo XXXX ) 21176082Sbmah echo OBJFORMAT=${OBJFORMAT} > ${CHROOTDIR}/etc/objformat 21276082Sbmah -test -f install.cfg && cp install.cfg ${CHROOTDIR}/usr/src/release 21376082Sbmah echo "#!/bin/sh" > ${CHROOTDIR}/mk 21476082Sbmah echo "set -ex" >> ${CHROOTDIR}/mk 21576082Sbmah echo "_RELTARGET=\$${1:-doRELEASE}" >> ${CHROOTDIR}/mk 21676082Sbmah echo "export CFLAGS='-O -pipe'" >> ${CHROOTDIR}/mk 21776082Sbmah echo "export DISTRIBUTIONS=\"${DISTRIBUTIONS}\"" >> ${CHROOTDIR}/mk 21876082Sbmah echo "export BUILDNAME=${BUILDNAME}" >> ${CHROOTDIR}/mk 21976082Sbmah echo "export VNDEVICE=${VNDEVICE}" >> ${CHROOTDIR}/mk 22082597Sscottl echo "export OBJFORMAT=${OBJFORMAT}" >> ${CHROOTDIR}/mk 22176082Sbmah.if defined(RELEASETAG) 22276082Sbmah echo "export RELEASETAG=${RELEASETAG}" >> ${CHROOTDIR}/mk 22376082Sbmah.endif 22476082Sbmah.if defined(NOPORTS) 22576082Sbmah echo "export NOPORTS=${NOPORTS}" >> ${CHROOTDIR}/mk 22676082Sbmah.endif 22776082Sbmah.if defined(NODOC) 22876082Sbmah echo "export NODOC=${NODOC}" >> ${CHROOTDIR}/mk 22976082Sbmah.endif 23076082Sbmah.if defined(ALLLANG) 23176082Sbmah echo "export ALLLANG=${ALLLANG}" >> ${CHROOTDIR}/mk 23276082Sbmah.endif 23376082Sbmah.if defined(NOSRC) 23476082Sbmah echo "export NOSRC=${NOSRC}" >> ${CHROOTDIR}/mk 23576082Sbmah.endif 23676082Sbmah.if defined(NOSHARED) 23776082Sbmah echo "export NOSHARED=${NOSHARED}" >> ${CHROOTDIR}/mk 23876082Sbmah.endif 23976082Sbmah.if defined(BOOT_CONFIG) 24076082Sbmah echo "export BOOT_CONFIG=\"${BOOT_CONFIG}\"">> ${CHROOTDIR}/mk 24176082Sbmah.endif 24276082Sbmah # Don't remove this, or the build will fall over! 24397677Snyan echo "export RELEASEDIR=/R" >> ${CHROOTDIR}/mk 24497677Snyan echo "export PATH=${BOOTSTRAPDIR}:$${PATH}:${LOCALDIR}" >> ${CHROOTDIR}/mk 24597677Snyan echo "cd /usr/src" >> ${CHROOTDIR}/mk 24697677Snyan.if make(release) 24797677Snyan echo "(cd etc; make distrib-dirs distribution)" >> ${CHROOTDIR}/mk 24897677Snyan echo "make world" >> ${CHROOTDIR}/mk 24997677Snyan.endif 25097677Snyan.if make(rerelease) 25197677Snyan echo "make all install" >> ${CHROOTDIR}/mk 25297677Snyan.endif 25397677Snyan echo "cd /usr/src/release/sysinstall" >> ${CHROOTDIR}/mk 25497677Snyan echo "make obj" >> ${CHROOTDIR}/mk 25597677Snyan echo "cd /usr/src/release" >> ${CHROOTDIR}/mk 25697677Snyan echo "make objlink" >> ${CHROOTDIR}/mk 25797677Snyan echo "(cd obj; rm -f ${REDOREDO})" >> ${CHROOTDIR}/mk 25897677Snyan echo "make \$${_RELTARGET}" >> ${CHROOTDIR}/mk 25997677Snyan echo "echo make ${.TARGET} Finished" >> ${CHROOTDIR}/mk 26097677Snyan chmod 755 ${CHROOTDIR}/mk 26197677Snyan chroot ${CHROOTDIR} /mk 26297677Snyan 26397677Snyanclean: 26497677Snyan rm -rf boot_crunch release.[0-9] 26597677Snyan 26697677Snyan# Clean out /R and make the directory structure. 26797677Snyanrelease.1: 26897677Snyan -mkdir /R 26997677Snyan chflags -R noschg /R/. 27097677Snyan rm -rf /R/* 27197677Snyan mkdir ${RD} 27297677Snyan mkdir ${RD}/floppies 27397677Snyan mkdir ${RD}/trees 27497677Snyan mkdir ${RD}/dists 27597677Snyan mkdir ${RD}/kernels 27697677Snyan for i in ${DISTRIBUTIONS} ; do \ 27797677Snyan mkdir ${RD}/trees/$$i && \ 27897677Snyan mkdir ${RD}/dists/$$i && \ 27997677Snyan mtree -deU -f ${MTREEFILES}/BSD.root.dist \ 28097677Snyan -p ${RD}/trees/$$i > /dev/null && \ 28197677Snyan mtree -deU -f ${MTREEFILES}/BSD.usr.dist \ 28297677Snyan -p ${RD}/trees/$$i/usr > /dev/null && \ 28397677Snyan mtree -deU -f ${MTREEFILES}/BSD.include.dist \ 28497677Snyan -p ${RD}/trees/$$i/usr/include > /dev/null && \ 28597677Snyan mtree -deU -f ${MTREEFILES}/BSD.var.dist \ 28697677Snyan -p ${RD}/trees/$$i/var > /dev/null ; \ 28797677Snyan done 28897677Snyan touch release.1 28997677Snyan 29097677Snyan# Install the system into the various distributions. 29197677Snyanrelease.2: 29297677Snyan cd ${.CURDIR}/../etc && make distrib-dirs DESTDIR=${RD}/trees/bin 29397677Snyan cd ${.CURDIR}/.. && make distribute DISTDIR=${RD}/trees 29497677Snyan.if exists(${.CURDIR}/../kerberosIV) && !defined(NOKERBEROS) 29597677Snyan cd ${.CURDIR}/../kerberosIV && ( \ 29697677Snyan make bootstrap &&\ 29797677Snyan make obj all help-distribute DISTDIR=${RD}/trees &&\ 29897677Snyan make kprog \ 29997677Snyan ) 30097677Snyan.endif 30197677Snyan # XXX until lkm and mdec gets populated again by some other means 30297677Snyan.if ${MACHINE_ARCH} == "i386" 30376082Sbmah cd ${.CURDIR}/.. && OBJFORMAT=aout MAKEOBJDIRPREFIX=/usr/obj/aout \ 30487993Sbmah NOTOOLS=1 NOSECURE=1 NOCRYPT=1 \ 30576082Sbmah make -f Makefile.inc1 legacy-install DESTDIR=${RD}/trees/bin 30676082Sbmah.endif 30776082Sbmah chflags -R noschg ${RD}/trees 30876082Sbmah touch release.2 30976082Sbmah 31076082Sbmah# Make and install the generic kernel(s). 31176082Sbmahrelease.3: 31276082Sbmah.for kernel in ${KERNELS} 31376082Sbmah rm -f ${RD}/kernels/${kernel} 31476082Sbmah rm -rf ${.CURDIR}/../sys/compile/${kernel} 31576082Sbmah cd ${.CURDIR} && ${MAKE} doKERNEL KERNEL=${kernel} 31676082Sbmah rm -rf ${.CURDIR}/../sys/compile/${kernel} 31776082Sbmah ln -f ${RD}/kernels/${kernel} ${RD}/trees/bin/kernel.${kernel} 31876082Sbmah.endfor 31987993Sbmah touch release.3 32076082Sbmah 32176082Sbmah# Make and install the three crunched binaries which live on the floppies. 32276082Sbmah# You are not supposed to like this :-) 32376082Sbmah# 32476082Sbmah# NB: the "RELEASE_BUILD_FIXIT" magic prevents vi from including the 32576082Sbmah# Tcl and Perl APIs. See also /usr/src/usr.bin/vi/Makefile. 32676082Sbmahrelease.4: 32776082Sbmah @mkdir -p /stand 32876082Sbmah cd ${.CURDIR}/sysinstall && make obj depend all install 32976082Sbmah rm -rf ${RD}/crunch 33076082Sbmah mkdir -p ${RD}/crunch 33176082Sbmah export RELEASE_BUILD_FIXIT=noway ; \ 33276082Sbmah for j in ${CRUNCH_TARGETS} ; do \ 33376082Sbmah rm -rf $${j}_crunch && \ 33476082Sbmah mkdir $${j}_crunch && \ 33576082Sbmah ( cd $${j}_crunch && \ 33676082Sbmah crunchgen ${.CURDIR}/$${j}_crunch.conf && \ 33776082Sbmah ${MAKE} -DRELEASE_CRUNCH -f $${j}_crunch.mk subclean all \ 33876082Sbmah NOCRYPT=yes "CFLAGS=${CFLAGS} -DCRUNCHED_BINARY") && \ 33976082Sbmah mv $${j}_crunch/$${j}_crunch ${RD}/crunch/$${j} && \ 34076082Sbmah true || { rm -rf $${j}_crunch ; false ; } ; \ 34176082Sbmah done 34276082Sbmah touch release.4 34376082Sbmah 34476082Sbmah# 34576082Sbmah# --==## Fix up the distributions. ##==-- 34676082Sbmah# 34776082Sbmahrelease.5: 34876082Sbmah # Handle some grief caused by the munition braindeadness. 34976082Sbmah for i in sbin/init bin/ed usr.sbin/ppp ; do \ 35076082Sbmah ( cd ${.CURDIR}/../$$i; \ 35176082Sbmah make -DNOCRYPT clean all distribute DISTDIR=${RD}/trees ) ; \ 35287993Sbmah done 35376082Sbmah 35476082Sbmah # Create any "synthetic dists" now. 35576082Sbmah @for i in ${DISTRIBUTIONS}; do \ 35676082Sbmah if [ -f ${.CURDIR}/scripts/$${i}-make.sh ]; then \ 35776082Sbmah echo -n "Running $$i dist creation script... "; \ 35876082Sbmah env OBJFORMAT=${OBJFORMAT} RD=${RD} sh ${.CURDIR}/scripts/$${i}-make.sh || echo "$$i distribution script returned bad status."; \ 35976082Sbmah echo "Done."; \ 36076082Sbmah fi \ 36176082Sbmah done \ 36276082Sbmah 36376082Sbmah # Create symlinks for the MD5-based crypt lib, too. The 36476082Sbmah # automatically created links still point to the DES stuff, 36576082Sbmah # which went into its own distribution. 36676082Sbmah for i in ${RD}/trees/bin/usr/lib/libscrypt* ; do \ 36776082Sbmah c=`echo $$i | sed -e 's/libscrypt/libcrypt/'` ; \ 36876082Sbmah rm -f $$c ; \ 36976082Sbmah ln -s `basename $$i` $$c ; \ 37076082Sbmah done 37176082Sbmah 37276082Sbmah # Remove all the directories we don't need. 37376082Sbmah -cd ${RD}/trees && \ 37476082Sbmah find ${OTHER_DISTS} ${COMPAT_DISTS} ${CRYPTO_DISTS} -depth -type d -print | xargs rmdir 37576082Sbmah touch release.5 37676082Sbmah 37776082Sbmah# 37876082Sbmah# --==## Package up the tarballs from assembled trees ##==-- 37976082Sbmah# 38076082Sbmahrelease.6: 38176082Sbmah rm -rf ${RD}/dists 38276082Sbmah mkdir -p ${RD}/dists 38376082Sbmah @for i in ${DISTRIBUTIONS} ; \ 38476082Sbmah do \ 38587993Sbmah if [ -d ${RD}/trees/$${i} ] ; then \ 38676082Sbmah cd ${.CURDIR} && $(MAKE) doTARBALL \ 38776082Sbmah SD=${RD}/trees/$${i} \ 38876082Sbmah TN=$$i TD=$$i ARG="." && \ 38976082Sbmah echo "$${i} distribution is finished."; \ 39076082Sbmah fi ; \ 39176082Sbmah done 39276082Sbmah # More munition braindeadness. 39376082Sbmah ( cd ${RD}/dists && \ 39476082Sbmah if [ -f krb/krb.aa ] ; then mv krb/* des && rmdir krb ; fi ) 39576082Sbmah touch release.6 39676082Sbmah 39787993Sbmah 39876082Sbmah# 39976082Sbmah# --==## Make source dists ##==-- 40076082Sbmah# 40187993Sbmahrelease.7: 40276082Sbmah.if !defined(NOSRC) 40376082Sbmah @cd ${.CURDIR} && $(MAKE) doTARBALL SD=/usr/src \ 40476082Sbmah TD=src TN=sbase ARG="[A-Z]*" 40576082Sbmah @for i in `cd /usr/src && echo [a-z]*` ; do \ 40676082Sbmah if [ -d /usr/src/$$i ] ; then \ 40776082Sbmah cd ${.CURDIR} && $(MAKE) doTARBALL \ 40876082Sbmah TN=`echo s$$i | tr -d '.' | sed 's/usr/u/'` \ 40976082Sbmah SD=/usr/src TD=src ARG="$$i" ; \ 41076082Sbmah fi ; \ 41176082Sbmah done 41287993Sbmah.if defined(EXTRA_SRC) 41376082Sbmah @set ${EXTRA_SRC} && \ 41476082Sbmah while [ $$# -ge 2 ] ; do \ 41576082Sbmah if [ -d /usr/src/$$1 ] ; then \ 41676560Sbmah cd ${.CURDIR} && $(MAKE) doTARBALL \ 41776082Sbmah SD=/usr/src TN="s$$2" TD=src ARG="$$1" ; \ 41876082Sbmah fi && shift && shift ; \ 41976082Sbmah done 42076082Sbmah.endif 42176082Sbmah ( cd ${RD}/dists/src && \ 42276082Sbmah if [ -f ssecure.aa ] ; then mv ssecure.* ../des ; fi && \ 42376082Sbmah if [ -f scrypto.aa ] ; then mv scrypto.* ../des ; fi && \ 42476082Sbmah if [ -f skerbero.aa ] ; then mv skerbero.* ../des ; fi ; ) 42576082Sbmah @echo "src distribution is finished." 42676082Sbmah.endif 42776082Sbmah touch release.7 42876082Sbmah 42976082Sbmah# Complete the bootfd 43076082Sbmah# 43176082Sbmah# Now, just to get this picture down once and for all: 43276082Sbmah# 43376082Sbmah# +------------------------------------------------------------------------+ 43476082Sbmah# |boot.flp | 43576082Sbmah# +-----+-----+------------------------------------------------------------+ 43676082Sbmah# |boot1|boot2|floppy filesystem "bootfd" | 43776082Sbmah# +-----+-----+-+--------------------------------------------------------+-+ 43876082Sbmah# |kernel | 43976082Sbmah# +------------+-----------------------------------------+-+ 44076082Sbmah# |mfs filesystem "mfsfd" | 44176082Sbmah# +-----------------------------------------+ 44286896Sbmah# 44376082Sbmah 44476082Sbmahrelease.8: write_mfs_in_kernel dumpnlist 44576082Sbmah rm -rf ${RD}/mfsfd 44676082Sbmah mkdir ${RD}/mfsfd 44776082Sbmah cd ${RD}/mfsfd && \ 44876082Sbmah mkdir -p etc dev mnt stand/help 44976082Sbmah @cp ${.CURDIR}/../sys/i386/boot/biosboot/boot.help ${RD}/mfsfd/stand 45076082Sbmah @cd ${.CURDIR} && $(MAKE) installCRUNCH CRUNCH=boot \ 45176082Sbmah DIR=${RD}/mfsfd/stand ZIP=false 45276082Sbmah ( cd ${RD}/trees/bin/dev && \ 45376082Sbmah ls console tty ttyv0 ttyv1 ttyv2 ttyv3 null zero | \ 45476082Sbmah cpio -dump ${RD}/mfsfd/dev ) 45576082Sbmah ( cd ${RD}/mfsfd/dev && rm -f *[swo]d*[bdefgh] ) 45676082Sbmah cd ${RD}/trees/bin && ls ${BOOT1} | cpio -dump ${RD}/mfsfd/stand 45776082Sbmah echo "nameserver 42/tcp name" > ${RD}/mfsfd/stand/etc/services 45876082Sbmah echo "ftp 21/tcp" >> ${RD}/mfsfd/stand/etc/services 45976082Sbmah echo "domain 53/tcp nameserver" >> ${RD}/mfsfd/stand/etc/services 46076082Sbmah echo "domain 53/udp nameserver" >> ${RD}/mfsfd/stand/etc/services 46176082Sbmah echo "cmd 514/tcp shell" >> ${RD}/mfsfd/stand/etc/services 46276082Sbmah gzip -c ${.CURDIR}/../COPYRIGHT > ${RD}/mfsfd/stand/help/COPYRIGHT.hlp.gz 46376082Sbmah -test -f ${.CURDIR}/install.cfg && cp ${.CURDIR}/install.cfg ${RD}/mfsfd 46476082Sbmah @echo "Making the regular boot floppy." 46576082Sbmah tar --exclude CVS -cf - -C ${.CURDIR}/sysinstall help | \ 46676082Sbmah tar xvf - -C ${RD}/mfsfd/stand 46776082Sbmah @echo "Compressing doc files..." 46876082Sbmah @gzip -9 ${RD}/mfsfd/stand/help/*.hlp 46976082Sbmah sh -e ${.CURDIR}/doFS.sh ${RD} ${MNT} ${BOOTMFSSIZE} \ 47076082Sbmah ${RD}/mfsfd ${MFSINODE} ${BOOTMFSLABEL} 47176082Sbmah mv fs-image fs-image.std 47276082Sbmah mv fs-image.size fs-image.std.size 47376082Sbmah gzip -c fs-image.std > ${RD}/floppies/mfsroot.gz 47476082Sbmah cd ${.CURDIR} && ${MAKE} doMFSKERN FSIMAGE=std 47576082Sbmah mv ${RD}/floppies/bootstd.flp ${RD}/floppies/kern.flp 47676082Sbmah cd ${.CURDIR} && ${MAKE} doMFSKERN FSIMAGE=std _MFSKERN=YES 47776082Sbmah mv ${RD}/floppies/bootstd.flp ${RD}/floppies/boot.flp 47876082Sbmah @echo "Regular and MFS boot floppies made." 47976082Sbmah touch release.8 48076082Sbmah 48176082Sbmah# 48276082Sbmah# --==## Create a fixit floppy ##==-- 48376082Sbmah# 48476082Sbmahrelease.9: 48576082Sbmah rm -rf ${RD}/fixitfd 48676082Sbmah mkdir ${RD}/fixitfd 48776082Sbmah cd ${RD}/fixitfd && \ 48876082Sbmah mkdir -p dev stand bin sbin etc mnt mnt1 mnt2 mnt3 mnt4 tmp \ 48976082Sbmah usr/share/misc usr/mdec 49076082Sbmah @cd ${.CURDIR} && $(MAKE) installCRUNCH CRUNCH=fixit \ 49176082Sbmah DIR=${RD}/fixitfd/stand ZIP=false 49276082Sbmah ( cd ${RD}/fixitfd/dev && \ 49376082Sbmah sed -e '/^PATH/s/^/#/' ${RD}/trees/bin/dev/MAKEDEV > MAKEDEV && \ 49476082Sbmah chmod 755 MAKEDEV && \ 49576082Sbmah sh MAKEDEV all ) 49676082Sbmah cp ${RD}/trees/bin/etc/spwd.db ${RD}/trees/bin/etc/group \ 49776082Sbmah ${RD}/trees/bin/etc/protocols ${RD}/fixitfd/etc 49876082Sbmah cp ${RD}/trees/bin/usr/share/misc/scsi_modes \ 49976082Sbmah ${RD}/fixitfd/usr/share/misc 50076082Sbmah cp ${RD}/trees/bin/usr/mdec/boot[12] ${RD}/fixitfd/usr/mdec 50176082Sbmah for type in fd od sd wd ; do \ 50276082Sbmah ( cd ${RD}/fixitfd/usr/mdec && ln -s boot1 $${type}boot && \ 50376082Sbmah ln -s boot2 boot$${type} ) ; \ 50487767Sbmah done 50587767Sbmah cp ${.CURDIR}/fixit.profile ${RD}/fixitfd/.profile 50687842Sbmah cp ${.CURDIR}/fixit.services ${RD}/fixitfd/etc/services 50776082Sbmah cp ${.CURDIR}/tar.sh ${RD}/fixitfd/stand/tar 50887767Sbmah chmod 555 ${RD}/fixitfd/stand/tar 50987767Sbmah sh -e ${.CURDIR}/doFS.sh ${RD} ${MNT} ${FIXITSIZE} \ 51087767Sbmah ${RD}/fixitfd ${FIXITINODE} ${FIXITLABEL} 51187767Sbmah mv fs-image ${RD}/floppies/fixit.flp 51276082Sbmah# Do our last minute floppies directory setup in a convenient place. 51386896Sbmah cp ${.CURDIR}/README.TXT ${RD}/floppies/README.TXT 51476082Sbmah @(cd ${RD}/floppies; md5 * > CHECKSUM.MD5) 51576082Sbmah touch release.9 51676082Sbmah 51776082Sbmah# 51876082Sbmah# --==## Setup a suitable ftp-area ##==-- 51976082Sbmah# 52076082Sbmahftp.1: 52176082Sbmah mkdir -p ${FD} 52276082Sbmah cd ${RD} && find floppies -print | cpio -dumpl ${FD} 52376082Sbmah cd ${RD}/dists && find . -print | cpio -dumpl ${FD} 52476082Sbmah cp ${.CURDIR}/ABOUT.TXT ${FD}/ABOUT.TXT 52576082Sbmah cp ${.CURDIR}/ERRATA.TXT ${FD}/ERRATA.TXT 52676082Sbmah cp ${.CURDIR}/LAYOUT.TXT ${FD}/LAYOUT.TXT 52776082Sbmah cp ${.CURDIR}/sysinstall/help/readme.hlp ${FD}/README.TXT 52876082Sbmah cp ${.CURDIR}/sysinstall/help/hardware.hlp ${FD}/HARDWARE.TXT 52976082Sbmah cp ${.CURDIR}/sysinstall/help/install.hlp ${FD}/INSTALL.TXT 53076082Sbmah cp ${.CURDIR}/sysinstall/help/relnotes.hlp ${FD}/RELNOTES.TXT 53176082Sbmah cp ${.CURDIR}/sysinstall/help/trouble.hlp ${FD}/TROUBLE.TXT 53276082Sbmah cp ${.CURDIR}/sysinstall/help/upgrade.hlp ${FD}/UPGRADE.TXT 53376082Sbmah 53476082Sbmah echo "CD_VERSION = ${BUILDNAME}" > ${FD}/cdrom.inf 53576082Sbmah.if !defined(NOPORTS) 53676082Sbmah tar -cBf - -C ${CD_DISC1} ports | tar -xBf - -C ${FD} 53776082Sbmah.endif 53876082Sbmah 53976082Sbmah# 54076082Sbmah# --==## Setup a suitable cdrom-area ##==-- 54176082Sbmah# 54276082Sbmahcdrom.1: 54376082Sbmah mkdir -p ${CD_DISC1} ${CD_DISC2} 54487767Sbmah cd ${RD} && find floppies -print | cpio -dumpl ${CD_DISC1} 54587767Sbmah cd ${RD}/dists && find . -print | cpio -dumpl ${CD_DISC1} 54687767Sbmah ln -f ${RD}/kernels/MFSKERNEL.std ${CD_DISC1}/kernel 54787767Sbmah.if ${MACHINE_ARCH} != "alpha" 54887767Sbmah ln -f ${RD}/trees/bin/usr/mdec/fbsdboot.exe ${CD_DISC1} 54987767Sbmah.endif 55087767Sbmah for i in ${DISTRIBUTIONS} ; \ 55187767Sbmah do \ 55287767Sbmah if [ -d ${RD}/trees/$${i} ] ; then \ 55387767Sbmah chflags -R noschg ${RD}/trees/$${i} ; \ 55476082Sbmah ( cd ${RD}/trees/$${i} && \ 55576082Sbmah find . -depth -print | cpio -dumpl ${CD_DISC2} ) ; \ 55676082Sbmah fi \ 55776082Sbmah done 55876082Sbmah rm -f ${CD_DISC2}/.profile 55976082Sbmah cp ${.CURDIR}/fixit.profile ${CD_DISC2}/.profile 56076082Sbmah echo "CD_VERSION = ${BUILDNAME}" > ${CD_DISC1}/cdrom.inf 56176082Sbmah echo "CD_VERSION = ${BUILDNAME}" > ${CD_DISC2}/cdrom.inf 56276082Sbmah cp ${.CURDIR}/ABOUT.TXT ${CD_DISC1}/ABOUT.TXT 56376082Sbmah cp ${.CURDIR}/ERRATA.TXT ${CD_DISC1}/ERRATA.TXT 56476082Sbmah cp ${.CURDIR}/LAYOUT.TXT ${CD_DISC1}/LAYOUT.TXT 56576082Sbmah cp ${.CURDIR}/sysinstall/help/readme.hlp ${CD_DISC1}/README.TXT 56676082Sbmah cp ${.CURDIR}/sysinstall/help/hardware.hlp ${CD_DISC1}/HARDWARE.TXT 56776082Sbmah cp ${.CURDIR}/sysinstall/help/install.hlp ${CD_DISC1}/INSTALL.TXT 56876082Sbmah cp ${.CURDIR}/sysinstall/help/relnotes.hlp ${CD_DISC1}/RELNOTES.TXT 56976082Sbmah cp ${.CURDIR}/sysinstall/help/trouble.hlp ${CD_DISC1}/TROUBLE.TXT 57076082Sbmah cp ${.CURDIR}/sysinstall/help/upgrade.hlp ${CD_DISC1}/UPGRADE.TXT 57176082Sbmah 57276082Sbmah.if !defined(NOPORTS) 57376082Sbmah -rm -rf /usr/ports/distfiles/* 57476082Sbmah tar -cBf - -C /usr ports | tar xBpf - -C ${CD_DISC2} && \ 57587767Sbmah mkdir -p ${CD_DISC1}/ports && \ 57687767Sbmah tar -czf ${CD_DISC1}/ports/ports.tgz -C /usr ports && \ 57787767Sbmah cp ${.CURDIR}/scripts/ports-install.sh ${CD_DISC1}/ports/install.sh && \ 57887767Sbmah (cd ${CD_DISC1}/ports; md5 * > CHECKSUM.MD5) 57987767Sbmah ln -s ../ports ${CD_DISC2}/usr/ports 58076082Sbmah.endif 58176082Sbmah 58287993Sbmahdoc.1: 58376082Sbmah for i in ${DOCPORTS}; do \ 58487993Sbmah cd /usr/ports/$$i && make all install clean FORCE_PKG_REGISTER=yes; \ 58576082Sbmah done 58676082Sbmah cd /usr/doc && make all distribute DISTDIR=${RD}/trees 58776082Sbmah touch doc.1 58876082Sbmah 58976082Sbmah# Various "subroutine" and other supporting targets. 59076082Sbmah 59176082SbmahdoTARBALL: 59276082Sbmah.if !defined(SD) 59376082Sbmah @echo "SD undefined in doTARBALL" && exit 1 59476082Sbmah.endif 59576082Sbmah.if !defined(TD) 59676082Sbmah @echo "TB undefined in doTARBALL" && exit 1 59776082Sbmah.endif 59897677Snyan.if !defined(ARG) 59976082Sbmah @echo "ARG undefined in doTARBALL" && exit 1 60076082Sbmah.endif 60176082Sbmah rm -rf ${RD}/dists/${TD}/${TN}* 60276560Sbmah mkdir -p ${RD}/dists/${TD} 60376082Sbmah ( cd ${SD} && \ 60497677Snyan tn=`echo ${TN} | tr '[A-Z]' '[a-z]' | cut -c1-8` && \ 60576082Sbmah echo rolling ${TD}/$$tn tarball &&\ 60676082Sbmah tar --exclude CVS --exclude obj --exclude BOOTMFS -cf - ${ARG} | \ 60797677Snyan ${ZIPNSPLIT} ${RD}/dists/${TD}/$$tn. && \ 60876082Sbmah sh ${.CURDIR}/info.sh ${RD}/dists/${TD}/$$tn > \ 60976082Sbmah ${RD}/dists/${TD}/$$tn.inf && \ 61097677Snyan if [ -f ${.CURDIR}/scripts/$${TD}-install.sh ]; then \ 61176082Sbmah cp -p ${.CURDIR}/scripts/$${TD}-install.sh ${RD}/dists/${TD}/install.sh; \ 61276082Sbmah fi && \ 61397677Snyan if [ "${SD}" != "/usr/src" ]; then \ 61476082Sbmah mtree -c -i -p ${SD}/${ARG} \ 61576082Sbmah -k gname,md5digest,mode,nlink,uname,size,link,type \ 61697677Snyan > ${RD}/dists/${TD}/$$tn.mtree ; \ 61776082Sbmah else \ 61876082Sbmah true; \ 61997677Snyan fi; \ 62076082Sbmah (cd ${RD}/dists/${TD}; \ 62176082Sbmah rm -f CHECKSUM.MD5; \ 62297677Snyan md5 * > CHECKSUM.MD5) \ 62376082Sbmah ) 62476082Sbmah 62576082SbmahdoRELEASE: release.1 release.2 ${DOCREL} release.3 release.4 release.5 \ 62697677Snyan release.6 release.7 release.8 release.9 62776082Sbmah cd ${.CURDIR} && ${MAKE} ${EXTRAS} 62876082Sbmah @echo "Release done" 62997677Snyan 63097677Snyanfloppies: 63197677Snyan cd ${.CURDIR} && ${MAKE} boot.flp 63297677Snyan cd ${.CURDIR} && ${MAKE} fixit.flp 63397677Snyan cd ${RD} && find floppies -print | cpio -dumpl ${FD} 63497677Snyan 63576082Sbmahboot.flp: 63676082Sbmah rm -f release.4 release.8 63776082Sbmah cd ${.CURDIR} && ${MAKE} release.4 release.8 CRUNCH_TARGETS=boot 63897677Snyan 63976560Sbmahfixit.flp: 64076082Sbmah rm -f release.4 release.9 64176082Sbmah cd ${.CURDIR} && ${MAKE} release.4 release.9 CRUNCH_TARGETS=fixit 64276082Sbmah 64376082Sbmahwrite_mfs_in_kernel: ${.CURDIR}/write_mfs_in_kernel.c 64476082Sbmah ${CC} ${CFLAGS} -o write_mfs_in_kernel ${.CURDIR}/write_mfs_in_kernel.c 64576560Sbmah 64676082Sbmah# Add -DDO_SCSI to CFLAGS to enable scsi frobbing support. 64776082Sbmahdumpnlist: ${.CURDIR}/dumpnlist.c 64876082Sbmah ${CC} ${CFLAGS} -o dumpnlist ${.CURDIR}/dumpnlist.c 64976082Sbmah 65076082SbmahinstallCRUNCH: 65176082Sbmah.if !defined(CRUNCH) 65276082Sbmah @echo "CRUNCH undefined in installCRUNCH" && exit 1 65376082Sbmah.endif 65476082Sbmah.if !defined(DIR) 65576082Sbmah @echo "DIR undefined in installCRUNCH" && exit 1 65676082Sbmah.endif 65776082Sbmah.if !defined(ZIP) 65876082Sbmah @echo "ZIP undefined in installCRUNCH" && exit 1 65976082Sbmah.endif 66087842Sbmah if ${ZIP} ; then \ 66176082Sbmah gzip -9 < ${RD}/crunch/${CRUNCH} > ${DIR}/${CRUNCH}_crunch ; \ 66276082Sbmah else \ 66376082Sbmah ln -f ${RD}/crunch/${CRUNCH} ${DIR}/${CRUNCH}_crunch ; \ 66476082Sbmah fi 66576082Sbmah chmod 555 ${DIR}/${CRUNCH}_crunch 66676082Sbmah for i in `crunchgen -l ${.CURDIR}/${CRUNCH}_crunch.conf` ; do \ 66776082Sbmah ln -f ${DIR}/${CRUNCH}_crunch ${DIR}/$$i ; \ 66897677Snyan done 66976560Sbmah 67076082Sbmah# 67176082Sbmah# --==## Compile a kernel by name ${KERNEL} ##==-- 67276082Sbmah# 67376082Sbmah# We don't erase the sys/compile/${KERNEL} directory, since somebody 67476082Sbmah# may want to reuse it (release.8 presently) 67576082Sbmah# 67676082SbmahdoKERNEL: 67776082Sbmah rm -f ${RD}/kernels/${KERNEL} 67876082Sbmah cd ${.CURDIR}/../sys/${MACHINE_ARCH}/conf && config ${KERNEL} 67976082Sbmah cd ${.CURDIR}/../sys/compile/${KERNEL} && \ 68076082Sbmah make depend && \ 68176082Sbmah make kernel && \ 68276082Sbmah cp kernel ${RD}/kernels/${KERNEL} 68376082Sbmah 68476082Sbmah# 68576082Sbmah# --==## Put a filesystem into a BOOTMFS kernel ##==-- 68676082Sbmah# 68776082SbmahdoMFSKERN: 68876082Sbmah @rm -f ${RD}/kernels/BOOTMFS.${FSIMAGE} 68976082Sbmah @rm -f /sys/compile/BOOTMFS/mfs_vfsops.o 69097677Snyan @cd ${.CURDIR}/../sys/i386/conf && \ 69176082Sbmah sed -e '/pty/d' \ 69297677Snyan -e '/pass0/d' \ 69387842Sbmah -e '/apm0/d' \ 69476082Sbmah -e '/ft0/d' \ 69576082Sbmah -e '/ppp/d' \ 69697677Snyan -e '/gzip/d' \ 69787842Sbmah -e '/PROCFS/d' \ 69876082Sbmah -e '/SYSVSHM/d' \ 69997677Snyan -e '/KTRACE/d' \ 70087842Sbmah -e '/MATH_EMULATE/d' \ 70176082Sbmah -e 's/GENERIC/BOOTMFS/g' \ 70276082Sbmah -e '/maxusers/s/32/4/' < GENERIC > BOOTMFS && \ 70397677Snyan echo "options NFS_NOSERVER" >> BOOTMFS && \ 70487842Sbmah echo 'options "MAXCONS=4"' >> BOOTMFS && \ 70576082Sbmah echo "options SCSI_NO_OP_STRINGS" >> BOOTMFS && \ 70697677Snyan echo "options SCSI_NO_SENSE_STRINGS" >> BOOTMFS && \ 70787842Sbmah echo "options USERCONFIG_BOOT" >> BOOTMFS 70876082Sbmah.if defined(_MFSKERN) 70976082Sbmah @echo "options \"MFS_ROOT_SIZE=`cat fs-image.${FSIMAGE}.size`\"" >> \ 71097677Snyan ${.CURDIR}/../sys/i386/conf/BOOTMFS 71187842Sbmah.endif 71282695Smjacob cd ${.CURDIR} && ${MAKE} doKERNEL KERNEL=BOOTMFS 71382695Smjacob @rm -rf ${RD}/boot.${FSIMAGE} 71497677Snyan @mkdir ${RD}/boot.${FSIMAGE} 71576082Sbmah @mv ${RD}/kernels/BOOTMFS ${RD}/kernels/BOOTMFS.${FSIMAGE} 71676082Sbmah @cp ${RD}/kernels/BOOTMFS.${FSIMAGE} ${RD}/boot.${FSIMAGE}/kernel 71797677Snyan.if exists(/boot/loader) && !defined(_MFSKERN) 71876082Sbmah @mkdir -p ${RD}/boot.${FSIMAGE}/boot 71976082Sbmah @cp /boot/* ${RD}/boot.${FSIMAGE}/boot 72097677Snyan @echo "@load /kernel" > ${RD}/boot.${FSIMAGE}/boot/boot.conf 72176082Sbmah @echo "@echo Please insert MFS root floppy and press enter:" >> ${RD}/boot.${FSIMAGE}/boot/boot.conf 72276082Sbmah @echo "@read" >> ${RD}/boot.${FSIMAGE}/boot/boot.conf 72397677Snyan @echo "@load -t mfs_root /mfsroot" >> ${RD}/boot.${FSIMAGE}/boot/boot.conf 72476082Sbmah @echo "@boot" >> ${RD}/boot.${FSIMAGE}/boot/boot.conf 72576082Sbmah.if ${MACHINE_ARCH} != "alpha" 72697677Snyan @echo "/boot/loader" >${RD}/boot.${FSIMAGE}/boot.config 72797677Snyan @touch ${RD}/boot.${FSIMAGE}/boot/loader.config 72897677Snyan.endif 72976082Sbmah.elif defined(BOOT_CONFIG) 73076082Sbmah @echo "${BOOT_CONFIG}" >${RD}/boot.${FSIMAGE}/boot.config 73176082Sbmah.endif 73276082Sbmah @vnconfig /dev/${VNDEVICE} fs-image.${FSIMAGE} 73376082Sbmah @mkdir -p /tmp/mnt_xx 73497677Snyan @mount /dev/${VNDEVICE} /tmp/mnt_xx 73597677Snyan ./dumpnlist ${RD}/boot.${FSIMAGE}/kernel > /tmp/mnt_xx/stand/symbols 73697677Snyan @umount /tmp/mnt_xx 73797677Snyan @vnconfig -u /dev/${VNDEVICE} 73897677Snyan @rmdir /tmp/mnt_xx 73997677Snyan.if defined(_MFSKERN) 74097677Snyan ./write_mfs_in_kernel ${RD}/boot.${FSIMAGE}/kernel \ 74197677Snyan fs-image.${FSIMAGE} 74276082Sbmah.endif 74397677Snyan kzip -v ${RD}/boot.${FSIMAGE}/kernel 74476560Sbmah @mv ${RD}/boot.${FSIMAGE}/kernel ${RD}/kernels/MFSKERNEL.${FSIMAGE} 74576082Sbmah @mv ${RD}/boot.${FSIMAGE}/kernel.kz ${RD}/boot.${FSIMAGE}/kernel 74676082Sbmah @cp ${.CURDIR}/../sys/i386/boot/biosboot/boot.help ${RD}/boot.${FSIMAGE} 74776082Sbmah @printf \\a\\a\\a >> ${RD}/boot.${FSIMAGE}/boot.help 74876082Sbmah @touch ${RD}/boot.${FSIMAGE}/boot.config 74976082Sbmah @touch ${RD}/boot.${FSIMAGE}/kernel.config 75076082Sbmah @rm -f ${RD}/floppies/boot${FSIMAGE}.flp 75176082Sbmah sh -e ${.CURDIR}/doFS.sh ${RD} ${MNT} ${BOOTSIZE} \ 75276082Sbmah ${RD}/boot.${FSIMAGE} ${BOOTINODE} ${BOOTLABEL} 75376082Sbmah mv fs-image ${RD}/floppies/boot${FSIMAGE}.flp 75476082Sbmah 75576560Sbmah.include <bsd.prog.mk> 75676560Sbmah