Home | History | Annotate | Line # | Download | only in bootimage
Makefile.liveimage revision 1.2.4.3
      1  1.2.4.3  yamt #	$NetBSD: Makefile.liveimage,v 1.2.4.3 2013/01/16 05:26:01 yamt Exp $
      2  1.2.4.2  yamt #
      3  1.2.4.2  yamt # Common Makefile to create a bootable FS image for USB flash or emulators
      4  1.2.4.2  yamt #
      5  1.2.4.2  yamt 
      6  1.2.4.2  yamt #
      7  1.2.4.2  yamt # Required variables:
      8  1.2.4.2  yamt #	LIVEIMGBASE
      9  1.2.4.2  yamt #		Basename of the liveimage
     10  1.2.4.2  yamt #
     11  1.2.4.3  yamt # Optional variables:
     12  1.2.4.3  yamt #	LIVEIMAGEMB
     13  1.2.4.3  yamt #		target image size in MB
     14  1.2.4.3  yamt #		(if empty default IMAGEMB in Makefile.bootimage is used)
     15  1.2.4.3  yamt #
     16  1.2.4.2  yamt # See Makefile.bootimage for other variables.
     17  1.2.4.2  yamt #
     18  1.2.4.2  yamt 
     19  1.2.4.2  yamt .if !target(check_LIVEIMGBASE)
     20  1.2.4.2  yamt check_LIVEIMGBASE: .PHONY .NOTMAIN
     21  1.2.4.2  yamt .if !defined(LIVEIMGBASE)
     22  1.2.4.2  yamt 	@echo "Error: LIVEIMGBASE is not set"
     23  1.2.4.2  yamt 	@false
     24  1.2.4.2  yamt .else
     25  1.2.4.2  yamt 	@true
     26  1.2.4.2  yamt .endif
     27  1.2.4.2  yamt .endif
     28  1.2.4.2  yamt 
     29  1.2.4.3  yamt .if defined(LIVEIMAGEMB)
     30  1.2.4.3  yamt IMAGEMB=	${LIVEIMAGEMB}
     31  1.2.4.3  yamt .endif
     32  1.2.4.3  yamt 
     33  1.2.4.2  yamt IMGBASE=	${LIVEIMGBASE}
     34  1.2.4.2  yamt 
     35  1.2.4.2  yamt .include "${NETBSDSRCDIR}/distrib/common/bootimage/Makefile.bootimage"
     36  1.2.4.2  yamt 
     37  1.2.4.2  yamt # LIVEIMG_RELEASEDIR specifies where to install ${LIVEIMGBASE}.img.gz.
     38  1.2.4.2  yamt # This should be passed from etc/Makefile or etc/etc.${MACHINE}/Makefile.inc
     39  1.2.4.2  yamt # but also set default here for manual builds.
     40  1.2.4.2  yamt LIVEIMG_RELEASEDIR?=	${RELEASEMACHINEDIR}/installation/liveimage
     41  1.2.4.2  yamt 
     42  1.2.4.2  yamt # should be defined elsewhere? 
     43  1.2.4.2  yamt MKDIR?=		mkdir -p
     44  1.2.4.2  yamt 
     45  1.2.4.2  yamt live_image: check_LIVEIMGBASE check_RELEASEDIR ${IMGBASE}.img.gz
     46  1.2.4.2  yamt 	${MKDIR} ${LIVEIMG_RELEASEDIR}
     47  1.2.4.2  yamt 	${RELEASE_INSTALL} ${IMGBASE}.img.gz ${LIVEIMG_RELEASEDIR}
     48  1.2.4.2  yamt 	# note ${MAKESUM} will be calculated in src/etc/Makefile
     49  1.2.4.2  yamt 
     50  1.2.4.2  yamt release:
     51  1.2.4.2  yamt 
     52