Makefile.inc revision 1.16.12.2
1#	$NetBSD: Makefile.inc,v 1.16.12.2 2009/01/17 20:43:44 mjf Exp $
2#
3#	etc.sgimips/Makefile.inc -- sgimips-specific etc Makefile targets
4#
5
6# If you change the list of distributed kernels, don't forget
7# to update the release documentation in distrib/notes/common/contents
8
9KERNEL_SETS=		GENERIC32_IP12 GENERIC32_IP2x GENERIC32_IP3x
10KERNEL_SUFFIXES=	ecoff
11
12#EXTRA_KERNELS=		NETBOOT
13
14BUILD_KERNELS=		INSTALL32_IP2x INSTALL32_IP3x
15
16INSTALLATION_DIRS+=	installation/netboot \
17			installation/diskimage
18
19iso-image-md-pre:
20	cp ${RELEASEDIR}/${RELEASEMACHINEDIR}/binary/kernel/netbsd-INSTALL32_IP2x.gz ${RELEASEDIR}/ip2x
21	cp ${RELEASEDIR}/${RELEASEMACHINEDIR}/binary/kernel/netbsd-INSTALL32_IP3x.gz ${RELEASEDIR}/ip3x
22	echo "ip2x/=${RELEASEDIR}/ip2x/" >> ${CDROM.pathlist}
23	echo "ip3x/=${RELEASEDIR}/ip3x/" >> ${CDROM.pathlist}
24
25SGI.image= ${RELEASEDIR}/${RELEASEMACHINEDIR}/installation/cdrom/netbsd-sgimips.img
26
27iso-image-md-post:
28	@SEEK=`${TOOL_AWK} '/SGI_BOOT_BLOCK_SIZE_VOLHDR/{print $$3}' \
29		${DESTDIR}/usr/include/sys/bootblock.h` ; \
30	EST=`ls -l ${CDROM.image} \
31		| ${TOOL_AWK} '{ s += $$5 } \
32			END { print int(('$${SEEK}'*512+s)/1024/1024/32+1)*32 \
33			}'` ; \
34	echo "Estimated image size: $${EST} MB"; \
35	dd if=/dev/zero of=${SGI.image} bs=1024k count=$${EST}; \
36	${TOOLDIR}/bin/nbsgivol -f -i ${SGI.image}; \
37	${TOOLDIR}/bin/nbsgivol -f -w aoutboot ${DESTDIR}/usr/mdec/aoutboot \
38		${SGI.image}; \
39	${TOOLDIR}/bin/nbsgivol -f -w ip2xboot ${DESTDIR}/usr/mdec/ip2xboot \
40		${SGI.image}; \
41	${TOOLDIR}/bin/nbsgivol -f -w ip3xboot ${DESTDIR}/usr/mdec/ip3xboot \
42		${SGI.image}; \
43	dd if=${CDROM.image} of=${SGI.image} bs=512 seek=$${SEEK}
44	mv ${SGI.image} ${CDROM.image}
45	rm -f ${RELEASEDIR}/ip2x ${RELEASEDIR}/ip3x
46