Home | History | Annotate | Line # | Download | only in bootfloppy-big
Makefile revision 1.11
      1  1.11  christos #	$NetBSD: Makefile,v 1.11 2001/11/08 02:10:26 christos Exp $
      2   1.1        he 
      3   1.6   mycroft TOP=	${.CURDIR}/..
      4   1.1        he 
      5   1.1        he .include "${TOP}/Makefile.inc"
      6   1.1        he 
      7  1.10      fvdl COMMONDIR=	${TOP}/bootfloppy-common
      8   1.6   mycroft IMAGE=	boot-big.fs
      9   1.9      fvdl KERN!=	cd $(.CURDIR)/../kernel-ramdisk/; \
     10   1.6   mycroft         printf "xxx: .MAKE\n\t@echo \$${.OBJDIR}/netbsd.INSTALL.gz\n" | \
     11   1.6   mycroft 	${MAKE} -s -f-
     12   1.1        he 
     13   1.1        he # This Makefile builds a boot image on a 2.88M-sized image.
     14   1.1        he #
     15   1.2        he # Since NetBSD currently can't write 2.88M diskettes, it's only
     16   1.1        he # use is as a boot image for El Torito bootable CD-ROM images.
     17   1.1        he #
     18   1.1        he # To prepare a CD, do the following steps:
     19   1.1        he # 1) create a release(7) tree called NetBSD-1.3I
     20   1.1        he # 2) create NetBSD-1.3I/boot.i386/ and place boot.fs in that directory
     21   1.1        he # 3) do ``mkisofs -A "NetBSD ${version}" -b boot.i386/boot.fs -f \
     22   1.1        he #	-o i386-cd.img -r -T NetBSD-1.3I''
     23   1.1        he #    (you may omit '-f' if you're not using symlinks in the release tree)
     24   1.1        he # This should place the image in i386-cd.img, which can hopefully
     25   1.1        he # be used to burn a CD.
     26   1.1        he 
     27   1.1        he DISKTYPE=	floppy288
     28   1.1        he DISKSIZE=	5760
     29   1.8      fvdl METAFILE!=	printf "USTAR.volsize.%o" ${DISKSIZE}
     30   1.7   mycroft BLOCK8K=	359
     31   1.8      fvdl PAD=yes
     32   1.1        he 
     33  1.10      fvdl MOUNT_POINT?=	/mnt
     34  1.10      fvdl VND?=		vnd0
     35  1.10      fvdl VND_DEV=	/dev/${VND}a
     36  1.10      fvdl VND_RDEV=	/dev/r${VND}a
     37  1.10      fvdl MDEC=		${DESTDIR}/usr/mdec
     38  1.10      fvdl BOOTCODE=	${MDEC}/biosboot.sym
     39  1.10      fvdl STRIP?=		strip
     40  1.10      fvdl 
     41  1.10      fvdl LISTS?=		${COMMONDIR}/list
     42  1.10      fvdl 
     43  1.10      fvdl # Some reasonable values for the -i parameter to newfs are:
     44  1.10      fvdl #
     45  1.10      fvdl #   6144	1147k, 189 inodes free
     46  1.10      fvdl #  16384	1159k,  93 inodes free
     47  1.10      fvdl # on 1.44M:
     48  1.10      fvdl # 204800	1407k,  27 inodes free
     49  1.10      fvdl # (with a 4k blocksize, one cannot get fewer than ~32 inodes allocated)
     50  1.10      fvdl 
     51  1.10      fvdl INO_BYTES?=	204800
     52  1.10      fvdl 
     53  1.10      fvdl CLEANFILES+=	netbsd
     54  1.10      fvdl 
     55  1.10      fvdl realall:	netbsd
     56  1.10      fvdl 	-rm -f ${IMAGE}.tmp
     57  1.10      fvdl 	dd if=/dev/zero of=${IMAGE}.tmp count=${DISKSIZE}
     58  1.11  christos 	vnconfig -t ${DISKTYPE} -v -c ${VND} ${IMAGE}.tmp
     59  1.11  christos 	disklabel -rw ${VND} ${DISKTYPE}
     60  1.11  christos 	newfs -B le -m 0 -o space -i ${INO_BYTES} -c 80 ${VND_RDEV}
     61  1.10      fvdl 	${MDEC}/installboot -v -f ${BOOTCODE} ${VND_RDEV}
     62  1.10      fvdl 	mount ${VND_DEV} ${MOUNT_POINT}
     63  1.10      fvdl 	TOPDIR=${TOP} CURDIR=${.CURDIR} OBJDIR=${.OBJDIR} \
     64  1.10      fvdl 	    TARGDIR=${MOUNT_POINT} sh ${TOP}/runlist.sh ${LISTS}
     65  1.10      fvdl 	@echo ""
     66  1.10      fvdl 	@df -i ${MOUNT_POINT}
     67  1.10      fvdl 	umount ${MOUNT_POINT}
     68  1.11  christos 	vnconfig -u ${VND}
     69  1.10      fvdl 	mv -f ${IMAGE}.tmp ${IMAGE}
     70  1.10      fvdl 
     71  1.10      fvdl unconfig:
     72  1.10      fvdl 	-umount -f ${MOUNT_POINT}
     73  1.11  christos 	-vnconfig -u ${VND}
     74  1.10      fvdl 	-/bin/rm -f ${IMAGE} ${IMAGE}.tmp
     75  1.10      fvdl 
     76  1.10      fvdl netbsd: ${KERN}
     77  1.10      fvdl 	rm -f netbsd
     78  1.10      fvdl 	cp ${KERN} netbsd
     79  1.10      fvdl 
     80  1.10      fvdl release:
     81  1.10      fvdl 	-mkdir -p ${RELEASEDIR}/installation/floppy
     82  1.10      fvdl 	cp -p ${IMAGE} ${RELEASEDIR}/installation/floppy
     83  1.10      fvdl 	gzip <${IMAGE} >${RELEASEDIR}/installation/floppy/${IMAGE}.gz
     84  1.10      fvdl 
     85  1.10      fvdl clean cleandir distclean:
     86  1.10      fvdl 	/bin/rm -f *.core ${CLEANFILES} ${IMAGE} ${IMAGE}.tmp
     87  1.10      fvdl 
     88  1.10      fvdl .include <bsd.own.mk>
     89  1.10      fvdl .include <bsd.obj.mk>
     90  1.10      fvdl .include <bsd.subdir.mk>
     91