Home | History | Annotate | Line # | Download | only in bootfloppy-big
Makefile revision 1.10
      1  1.10     fvdl #	$NetBSD: Makefile,v 1.10 2000/10/17 21:08:43 fvdl 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 VND_CDEV=	/dev/${VND}d
     38  1.10     fvdl VND_CRDEV=	/dev/r${VND}d
     39  1.10     fvdl MDEC=		${DESTDIR}/usr/mdec
     40  1.10     fvdl BOOTCODE=	${MDEC}/biosboot.sym
     41  1.10     fvdl STRIP?=		strip
     42  1.10     fvdl 
     43  1.10     fvdl LISTS?=		${COMMONDIR}/list
     44  1.10     fvdl 
     45  1.10     fvdl # Some reasonable values for the -i parameter to newfs are:
     46  1.10     fvdl #
     47  1.10     fvdl #   6144	1147k, 189 inodes free
     48  1.10     fvdl #  16384	1159k,  93 inodes free
     49  1.10     fvdl # on 1.44M:
     50  1.10     fvdl # 204800	1407k,  27 inodes free
     51  1.10     fvdl # (with a 4k blocksize, one cannot get fewer than ~32 inodes allocated)
     52  1.10     fvdl 
     53  1.10     fvdl INO_BYTES?=	204800
     54  1.10     fvdl 
     55  1.10     fvdl CLEANFILES+=	netbsd
     56  1.10     fvdl 
     57  1.10     fvdl realall:	netbsd
     58  1.10     fvdl 	-rm -f ${IMAGE}.tmp
     59  1.10     fvdl 	dd if=/dev/zero of=${IMAGE}.tmp count=${DISKSIZE}
     60  1.10     fvdl 	vnconfig -t ${DISKTYPE} -v -c ${VND_CDEV} ${IMAGE}.tmp
     61  1.10     fvdl 	disklabel -rw ${VND_CDEV} ${DISKTYPE}
     62  1.10     fvdl 	newfs -B le -m 0 -o space -i ${INO_BYTES} -c 80 ${VND_RDEV} ${DISKTYPE}
     63  1.10     fvdl 	${MDEC}/installboot -v -f ${BOOTCODE} ${VND_RDEV}
     64  1.10     fvdl 	mount ${VND_DEV} ${MOUNT_POINT}
     65  1.10     fvdl 	TOPDIR=${TOP} CURDIR=${.CURDIR} OBJDIR=${.OBJDIR} \
     66  1.10     fvdl 	    TARGDIR=${MOUNT_POINT} sh ${TOP}/runlist.sh ${LISTS}
     67  1.10     fvdl 	@echo ""
     68  1.10     fvdl 	@df -i ${MOUNT_POINT}
     69  1.10     fvdl 	umount ${MOUNT_POINT}
     70  1.10     fvdl 	vnconfig -u ${VND_CDEV}
     71  1.10     fvdl 	mv -f ${IMAGE}.tmp ${IMAGE}
     72  1.10     fvdl 
     73  1.10     fvdl unconfig:
     74  1.10     fvdl 	-umount -f ${MOUNT_POINT}
     75  1.10     fvdl 	-vnconfig -u ${VND_DEV}
     76  1.10     fvdl 	-/bin/rm -f ${IMAGE} ${IMAGE}.tmp
     77  1.10     fvdl 
     78  1.10     fvdl netbsd: ${KERN}
     79  1.10     fvdl 	rm -f netbsd
     80  1.10     fvdl 	cp ${KERN} netbsd
     81  1.10     fvdl 
     82  1.10     fvdl release:
     83  1.10     fvdl 	-mkdir -p ${RELEASEDIR}/installation/floppy
     84  1.10     fvdl 	cp -p ${IMAGE} ${RELEASEDIR}/installation/floppy
     85  1.10     fvdl 	gzip <${IMAGE} >${RELEASEDIR}/installation/floppy/${IMAGE}.gz
     86  1.10     fvdl 
     87  1.10     fvdl clean cleandir distclean:
     88  1.10     fvdl 	/bin/rm -f *.core ${CLEANFILES} ${IMAGE} ${IMAGE}.tmp
     89  1.10     fvdl 
     90  1.10     fvdl .include <bsd.own.mk>
     91  1.10     fvdl .include <bsd.obj.mk>
     92  1.10     fvdl .include <bsd.subdir.mk>
     93