1 # $NetBSD: Makefile.inc,v 1.15 2003/10/26 07:25:34 lukem Exp $
3 # TOP is assumed to be defined by Makefile including this one.
6 COMMONDIR= ${TOP}/inst-common
11 VND_RDEV= /dev/r${VND}c
12 IMAGE?= miniroot-${DISTRIBREV}.fs
13 BOOTSYS= bootroot-${DISTRIBREV}.fs
14 MDEC= ${DESTDIR}/usr/mdec
16 LISTS= ${COMMONDIR}/list ${.CURDIR}/list
17 CRUNCHCONF= ${COMMONDIR}/${CBIN}.conf
18 MTREECONF= ${COMMONDIR}/mtree.conf
21 BOOTDISKTYPE= bootroot
24 dd if=/dev/zero of=${IMAGE} bs=64k count=32
25 vnconfig -t ${DISKTYPE} -v -c ${VND_DEV} ${IMAGE}
26 newfs -B le -O -m 0 -o space -i 8192 ${VND_RDEV} ${DISKTYPE}
27 mount ${VND_DEV} ${MOUNT_POINT}
28 ${TOOL_MTREE} -def ${MTREECONF} -p ${MOUNT_POINT}/ -u
29 TOPDIR=${TOP} CURDIR=${.CURDIR} OBJDIR=${.OBJDIR} \
30 KERNOBJDIR=${KERNOBJDIR} TARGDIR=${MOUNT_POINT} ${HOST_SH} \
31 ${NETBSDSRCDIR}/distrib/common/runlist.sh ${LISTS}
35 umount -f ${MOUNT_POINT}
36 vnconfig -u ${VND_DEV}
38 bootroot: edlabel copy xxboot boot
39 dd if=/dev/zero of=${BOOTSYS} bs=64k count=4
40 vnconfig -t ${BOOTDISKTYPE} -v -c ${VND_DEV} ${BOOTSYS}
41 newfs -B le -O -m 0 -o space -i 8192 ${VND_RDEV} ${BOOTDISKTYPE}
42 dd if=xxboot of=/dev/rvnd0a count=16
43 mount ${VND_DEV} ${MOUNT_POINT}
44 cp edlabel copy boot ${MOUNT_POINT}
45 umount -f ${MOUNT_POINT}
46 vnconfig -u ${VND_DEV}
48 edlabel copy xxboot boot:
49 (cd /sys/arch/vax/boot; ${MAKE})
50 cp /sys/arch/vax/boot/edlabel .
51 cp /sys/arch/vax/boot/copy .
52 cp /sys/arch/vax/boot/xxboot .
53 cp /sys/arch/vax/boot/boot .
56 -umount -f ${MOUNT_POINT}
57 -vnconfig -u ${VND_DEV} ${IMAGE}
60 ${CBIN}.mk ${CBIN}.cache ${CBIN}.c: ${CRUNCHCONF}
61 ${TOOL_CRUNCHGEN} ${CRUNCHCONF}
63 ${CBIN}: ${CBIN}.mk ${CBIN}.cache ${CBIN}.c
66 clean cleandir distclean:
67 /bin/rm -f core ${IMAGE} ${CBIN} ${CBIN}.mk ${CBIN}.cache *.o *.cro *.c
70 .include <bsd.subdir.mk>