Home | History | Annotate | Line # | Download | only in etc.sgimips
Makefile.inc revision 1.16.10.1
      1 #	$NetBSD: Makefile.inc,v 1.16.10.1 2008/03/24 07:14:41 keiichi 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 
      9 KERNEL_SETS=		GENERIC32_IP12 GENERIC32_IP2x GENERIC32_IP3x
     10 KERNEL_SUFFIXES=	ecoff
     11 
     12 #EXTRA_KERNELS=		NETBOOT
     13 
     14 BUILD_KERNELS=		INSTALL32_IP2x INSTALL32_IP3x
     15 
     16 INSTALLATION_DIRS+=	installation/netboot \
     17 			installation/diskimage
     18 
     19 iso-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 
     25 SGI.image= ${RELEASEDIR}/${RELEASEMACHINEDIR}/installation/cdrom/netbsd-sgimips.img
     26 
     27 iso-image-md-post:
     28 	@SEEK=`awk '/SGI_BOOT_BLOCK_SIZE_VOLHDR/{print $$3}' \
     29 		${DESTDIR}/usr/include/sys/bootblock.h` ; \
     30 	EST=`ls -l ${CDROM.image} \
     31 		| awk '{ s += $$5} END { print int(('$${SEEK}'*512+s)/1024/1024/32+1)*32 }'` ; \
     32 	echo "Estimated image size: $${EST} MB"; \
     33 	dd if=/dev/zero of=${SGI.image} bs=1024k count=$${EST}; \
     34 	${TOOLDIR}/bin/nbsgivol -f -i ${SGI.image}; \
     35 	${TOOLDIR}/bin/nbsgivol -f -w aoutboot ${DESTDIR}/usr/mdec/aoutboot \
     36 		${SGI.image}; \
     37 	${TOOLDIR}/bin/nbsgivol -f -w ip2xboot ${DESTDIR}/usr/mdec/ip2xboot \
     38 		${SGI.image}; \
     39 	${TOOLDIR}/bin/nbsgivol -f -w ip3xboot ${DESTDIR}/usr/mdec/ip3xboot \
     40 		${SGI.image}; \
     41 	dd if=${CDROM.image} of=${SGI.image} bs=512 seek=$${SEEK}
     42 	mv ${SGI.image} ${CDROM.image}
     43 	rm -f ${RELEASEDIR}/ip2x ${RELEASEDIR}/ip3x
     44