NetBSD/distrib/macppc/floppies/ramdisk/Makefile

58 lines
1.3 KiB
Makefile
Raw Normal View History

1999-11-09 02:51:29 +03:00
# $NetBSD: Makefile,v 1.9 1999/11/08 23:51:30 mycroft Exp $
1998-07-03 15:20:08 +04:00
TOP= ${.CURDIR}/..
.include "${TOP}/Makefile.inc"
IMAGE= ramdisk.fs
CBIN= ramdiskbin
MOUNT_POINT?= /mnt
VND?= vnd1
VND_DEV= /dev/${VND}a
VND_RDEV= /dev/r${VND}a
MDEC= ${DESTDIR}/usr/mdec
LISTS= list
CRUNCHCONF= ${CBIN}.conf
MTREE= mtree.conf
SIZE= 2048k
1998-07-03 15:20:08 +04:00
DISKTYPE= floppyinstfs
all: ${CBIN}
dd if=/dev/zero of=${IMAGE} bs=${SIZE} count=1
vnconfig -t ${DISKTYPE} -v -c ${VND} ${IMAGE}
1999-11-09 02:51:29 +03:00
disklabel -f ${.CURDIR}/disktab -rw ${VND} ${DISKTYPE}
newfs -B be -m 0 -o space -i 6144 -c 128 ${VND_RDEV}
1998-07-03 15:20:08 +04:00
mount ${VND_DEV} ${MOUNT_POINT}
mtree -def ${.CURDIR}/${MTREE} -p ${MOUNT_POINT}/ -u
TOPDIR=${TOP} CURDIR=${.CURDIR} OBJDIR=${.OBJDIR} \
TARGDIR=${MOUNT_POINT} sh ${TOP}/runlist.sh ${.CURDIR}/${LISTS}
@echo ""
@df -i ${MOUNT_POINT}
@echo ""
umount ${MOUNT_POINT}
vnconfig -u ${VND}
1998-07-03 15:20:08 +04:00
unconfig:
-umount -f ${MOUNT_POINT}
-vnconfig -u ${VND}
-rm -f ${IMAGE}
1998-07-03 15:20:08 +04:00
${CBIN}.mk ${CBIN}.cache ${CBIN}.c: ${CRUNCHCONF}
crunchgen -D ${TOP}/../../.. -L ${DESTDIR}/usr/lib ${.ALLSRC}
${CBIN}: ${CBIN}.mk ${CBIN}.cache ${CBIN}.c #libhack.o
1998-07-03 15:20:08 +04:00
make -f ${CBIN}.mk all
#HACKSRC=${TOP}/../../utils/libhack
#.include "${HACKSRC}/Makefile.inc"
1998-07-03 15:20:08 +04:00
1998-09-05 18:46:13 +04:00
clean cleandir distclean:
rm -f ${IMAGE} ${CBIN} ${CBIN}.mk ${CBIN}.cache
rm -f *.core *.o *.cro *.c
1998-07-03 15:20:08 +04:00
.include <bsd.obj.mk>
.include <bsd.subdir.mk>