2011-08-20 13:55:05 +04:00
# step 4: build a stage2 subprofile (custom livecd)
# NB: stage2 is not standalone but rather a common base
# for all livecd images (installer, live, rescue)
2011-08-18 23:56:12 +04:00
i f n d e f G L O B A L _ B U I L D D I R
$( error GLOBAL_BUILDDIR not defined )
e n d i f
default : all
i n c l u d e $( GLOBAL_BUILDDIR ) / d i s t c f g . m k
i n c l u d e $( GLOBAL_BUILDDIR ) / f u n c t i o n s . m k
i n c l u d e $( MKIMAGE_PREFIX ) / c o n f i g . m k
# this might have been prepared by ../stage1/scripts.d/03-test-kernel
- i n c l u d e $( GLOBAL_BUILDDIR ) / s q u a s h c f g . m k
2011-08-20 13:55:05 +04:00
# this should be brought in by corresponding specific stage2 feature
i n c l u d e s t a g e 2 c f g . m k
2011-09-03 13:34:53 +04:00
# requisite stuff
IMAGE_PACKAGES += $( SYSTEM_PACKAGES)
2011-08-18 23:56:12 +04:00
# here we also try and come up with the stage1 kernel/modules, if any;
# no kernel flavour specified will result in no modules for stage1 vmlinuz
STAGE1_KFLAVOUR ?= $( lastword $( KFLAVOURS) )
2011-10-06 12:46:31 +04:00
i f e q ( , $( STAGE 1_KFLAVOUR ) )
2011-08-18 23:56:12 +04:00
$( error STAGE 1_KFLAVOUR is utterly empty ; cannot guess either )
e n d i f
# need kernel modules only (which require corresponding kernel-image);
2012-04-06 23:26:54 +04:00
# these go into work chroot; NB: no vmlinuz there (unless live-install)
2012-04-10 19:14:01 +04:00
IMAGE_PACKAGES_REGEXP += $( call kpackages, \
$( STAGE1_KMODULES) $( STAGE2_KMODULES) , \
$( STAGE1_KFLAVOUR) )
2011-08-18 23:56:12 +04:00
2012-04-25 15:08:36 +04:00
- i n c l u d e l i b / * . m k
2012-04-06 23:26:54 +04:00
# see also scripts.d/99-elf-stats
i f d e f G L O B A L _ S Q U A S H F S _ S O R T
i f e q ( t i g h t , $( SQUASHFS ) )
CHROOT_PACKAGES += file
pack-image : PACK_SQUASHFS_OPTS += -sort /.our /elf .lst
pack-image : CLEANUP_OUTDIR =
e n d i f
e n d i f
GLOBAL_SQUASHFS := $( SQUASHFS)
2011-08-18 23:56:12 +04:00
i n c l u d e $( MKIMAGE_PREFIX ) / t a r g e t s . m k
2011-09-13 20:39:31 +04:00
# NB: it's a collector variable, add()ing to a GLOBAL_ results in lost hair
GLOBAL_CLEANUP_PACKAGES := $( CLEANUP_PACKAGES)
2012-04-06 23:26:54 +04:00
all : | $( GLOBAL_DEBUG ) \
build-image run-image-scripts run-scripts pack-image \
2011-08-18 23:56:12 +04:00
$( GLOBAL_CLEAN_WORKDIR)
2011-09-13 20:39:31 +04:00
# dummy
2011-10-23 00:02:22 +04:00
debug :: ;