Makefile revision 1.1
1#	$NetBSD: Makefile,v 1.1 2003/01/29 04:56:17 perseant Exp $
2
3NOMAN=	# defined
4
5TMPL=/tmp/lfstemplate
6TMPMP=/tmp/lfsregresstest_mount
7TMPIM=/var/tmp/lfsregresstest.im
8SRCDIR?= ${.CURDIR}
9
10VND?= vnd0
11BVND= /dev/${VND}
12CVND= /dev/r${VND}
13MPART?= a
14.if (${MACHINE_ARCH} == "i386")
15RPART?= d
16.else
17RPART?= c
18.endif
19
20#
21# Make a small filesystem, and fsck it.
22# This ensures that newfs_lfs and fsck_lfs play well together.
23#
24# Mount it, copy some data in, unmount, fsck.
25# This ensures that kernel and fsck_lfs play well together.
26#
27# This was based on the FFS endianness regression tests.
28#
29regress:
30	@echo "***  Creating a dummy directory tree at ${TMPMP} monted on" \
31	   "${TMPIM}."
32	dd if=/dev/zero of=${TMPIM} count=5860
33	vnconfig -v ${BVND}${RPART} ${TMPIM}
34	disklabel -f ${SRCDIR}/disktab -rw ${VND} floppy288
35	newfs_lfs -B 131072 -b 4096 -f 512 ${CVND}${MPART}
36	@echo "***  Checking that newfs_lfs could be understood by fsck_lfs"
37	fsck_lfs -n ${CVND}${MPART}
38	mkdir ${TMPMP}
39	mount -t lfs ${BVND}${MPART} ${TMPMP}
40	dd if=/dev/zero of=${TMPMP}/zero bs=16384 count=100
41	umount ${TMPMP}
42	@echo "***  Checking that kernel write could be understood by fsck_lfs"
43	fsck_lfs -n ${CVND}${MPART}
44	vnconfig -u ${BVND}${RPART}
45
46clean:
47	-umount ${TMPMP}
48	vnconfig -u ${BVND}${RPART}
49
50.include <bsd.prog.mk>
51