2010-12-03 16:53:02 +02:00
# step 4: build image (final stage)
#
2011-06-14 18:25:55 +04:00
# NB: this directory forms the initial BUILDDIR/
2010-12-03 16:53:02 +02:00
2011-06-12 18:06:36 +03: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
2010-08-28 19:28:42 +03:00
i n c l u d e f u n c t i o n s . m k
2010-10-29 12:11:03 +03:00
i n c l u d e $( GLOBAL_BUILDDIR ) / f u n c t i o n s . m k
server-ovz; KDEFAULT; syslinux features reworked
Renamed server-light.iso into server-ovz.iso to avoid brand dilution
and confusion (rider@'s server-light rather favours kvm, anyways).
Introduced KDEFAULT: a reliable default kernel chooser knob
since apt's regex ordering proved pretty unreliable.
Spelling things explicitly is better anyways.
SYSLINUX related features undergone pretty major rewrite
(that includes syslinux, hdt and memtest).
The problem to tackle was features.in/syslinux/generate.mk
assuming syslinux and pciids available in build *host* system;
this well might not be the case (or worse yet, those can be
just different). So now we're a bit less elegant and a bit
more enterprise, stuffing things into chroot and working there.
Bunch of other fixes along the road, including ; to name a few:
- fixed memtest entry (overlooked while renaming SYSLINUX_ITEMS)
- new and shiny doc/CodingStyle
- gfxboot, stage1 target chain, hdt tweaks
- distro.mk rehashed
- README++
- TODO: dropped (integer overflow anyways)
+ actually moved off-tree to reduce commit spam
- s,\.config\.mk,distcfg.mk,g
- doc/profiles.mk.sample: sample ~/.mkimage/profiles.mk
- ...and assorted fixups/additions
Sorry for convoluted commit, this would have been pretty hard to
rework into some really readable shape (and you might be interested
in the original repo's history horrors then, anyways).
2011-05-31 02:05:33 +04:00
i n c l u d e $( GLOBAL_BUILDDIR ) / d i s t c f g . m k
2010-09-27 22:02:57 +03:00
i n c l u d e $( MKIMAGE_PREFIX ) / c o n f i g . m k
2010-08-28 19:28:42 +03:00
2011-08-20 12:55:05 +03:00
# for complex-specified subprofiles like stage2/live,
# take the latter part
SUBDIRS = $( notdir $( SUBPROFILES) )
2010-08-28 19:28:42 +03:00
2010-09-09 12:50:29 +03:00
# "main" subprofile needs genbasedir
CHROOT_PACKAGES = apt-utils
2011-05-11 23:40:47 +04:00
MKI_PACK_RESULTS = isoboot:$( IMAGENAME)
2010-09-09 12:50:29 +03:00
COPY_TREE = ./files
2010-08-28 19:28:42 +03:00
BOOT_TYPE = isolinux
2011-05-11 23:40:47 +04:00
# outdir shouldn't be wiped clean before use
2011-06-14 18:25:55 +04:00
CLEANUP_OUTDIR ?=
2011-05-11 23:40:47 +04:00
server-ovz; KDEFAULT; syslinux features reworked
Renamed server-light.iso into server-ovz.iso to avoid brand dilution
and confusion (rider@'s server-light rather favours kvm, anyways).
Introduced KDEFAULT: a reliable default kernel chooser knob
since apt's regex ordering proved pretty unreliable.
Spelling things explicitly is better anyways.
SYSLINUX related features undergone pretty major rewrite
(that includes syslinux, hdt and memtest).
The problem to tackle was features.in/syslinux/generate.mk
assuming syslinux and pciids available in build *host* system;
this well might not be the case (or worse yet, those can be
just different). So now we're a bit less elegant and a bit
more enterprise, stuffing things into chroot and working there.
Bunch of other fixes along the road, including ; to name a few:
- fixed memtest entry (overlooked while renaming SYSLINUX_ITEMS)
- new and shiny doc/CodingStyle
- gfxboot, stage1 target chain, hdt tweaks
- distro.mk rehashed
- README++
- TODO: dropped (integer overflow anyways)
+ actually moved off-tree to reduce commit spam
- s,\.config\.mk,distcfg.mk,g
- doc/profiles.mk.sample: sample ~/.mkimage/profiles.mk
- ...and assorted fixups/additions
Sorry for convoluted commit, this would have been pretty hard to
rework into some really readable shape (and you might be interested
in the original repo's history horrors then, anyways).
2011-05-31 02:05:33 +04:00
APTCONF := $( wildcard $( APTCONF) )
i f e q "$(APTCONF)" ""
2010-09-27 22:02:57 +03:00
GLOBAL_HSH_APT_CONFIG = /etc/apt/apt.conf
e l s e
GLOBAL_HSH_APT_CONFIG = $( APTCONF)
e n d i f
2011-08-22 18:31:45 +03:00
# Metadata/ needed only for installers (and not for e.g. syslinux.iso)
2011-09-19 10:55:45 +03:00
### what about installable live?
i f n e q ( , $( findstring install 2,$ ( FEATURES ) ) )
2011-08-22 18:31:45 +03:00
METADATA = metadata
e n d i f
2010-09-08 15:47:06 +03:00
i n c l u d e $( MKIMAGE_PREFIX ) / t a r g e t s . m k
2010-08-28 19:28:42 +03:00
2011-08-15 23:30:20 +03:00
all : $( GLOBAL_DEBUG ) prep copy -subdirs copy -tree run -scripts pack -image \
$( GLOBAL_CLEAN_WORKDIR)
2010-08-28 19:28:42 +03:00
2011-08-22 18:31:45 +03:00
prep : $( GLOBAL_DEBUG ) dot -disk $( METADATA ) $( IMAGEDIR )
2011-07-15 00:00:46 +03:00
metadata : dot -base
server-ovz; KDEFAULT; syslinux features reworked
Renamed server-light.iso into server-ovz.iso to avoid brand dilution
and confusion (rider@'s server-light rather favours kvm, anyways).
Introduced KDEFAULT: a reliable default kernel chooser knob
since apt's regex ordering proved pretty unreliable.
Spelling things explicitly is better anyways.
SYSLINUX related features undergone pretty major rewrite
(that includes syslinux, hdt and memtest).
The problem to tackle was features.in/syslinux/generate.mk
assuming syslinux and pciids available in build *host* system;
this well might not be the case (or worse yet, those can be
just different). So now we're a bit less elegant and a bit
more enterprise, stuffing things into chroot and working there.
Bunch of other fixes along the road, including ; to name a few:
- fixed memtest entry (overlooked while renaming SYSLINUX_ITEMS)
- new and shiny doc/CodingStyle
- gfxboot, stage1 target chain, hdt tweaks
- distro.mk rehashed
- README++
- TODO: dropped (integer overflow anyways)
+ actually moved off-tree to reduce commit spam
- s,\.config\.mk,distcfg.mk,g
- doc/profiles.mk.sample: sample ~/.mkimage/profiles.mk
- ...and assorted fixups/additions
Sorry for convoluted commit, this would have been pretty hard to
rework into some really readable shape (and you might be interested
in the original repo's history horrors then, anyways).
2011-05-31 02:05:33 +04:00
@mkdir -p files/Metadata
@rm -f files/Metadata/pkg-groups.tar
2011-06-14 18:25:55 +04:00
# see also alterator-pkg (backend3/pkg-install); we only tar up what's up to it
@tar -cvf files/Metadata/pkg-groups.tar -C $( PKGDIR) \
2011-09-01 12:04:04 +03:00
$$ ( echo $( call list,$( MAIN_GROUPS) .base) \
$( call group,$( MAIN_GROUPS) ) \
server-ovz; KDEFAULT; syslinux features reworked
Renamed server-light.iso into server-ovz.iso to avoid brand dilution
and confusion (rider@'s server-light rather favours kvm, anyways).
Introduced KDEFAULT: a reliable default kernel chooser knob
since apt's regex ordering proved pretty unreliable.
Spelling things explicitly is better anyways.
SYSLINUX related features undergone pretty major rewrite
(that includes syslinux, hdt and memtest).
The problem to tackle was features.in/syslinux/generate.mk
assuming syslinux and pciids available in build *host* system;
this well might not be the case (or worse yet, those can be
just different). So now we're a bit less elegant and a bit
more enterprise, stuffing things into chroot and working there.
Bunch of other fixes along the road, including ; to name a few:
- fixed memtest entry (overlooked while renaming SYSLINUX_ITEMS)
- new and shiny doc/CodingStyle
- gfxboot, stage1 target chain, hdt tweaks
- distro.mk rehashed
- README++
- TODO: dropped (integer overflow anyways)
+ actually moved off-tree to reduce commit spam
- s,\.config\.mk,distcfg.mk,g
- doc/profiles.mk.sample: sample ~/.mkimage/profiles.mk
- ...and assorted fixups/additions
Sorry for convoluted commit, this would have been pretty hard to
rework into some really readable shape (and you might be interested
in the original repo's history horrors then, anyways).
2011-05-31 02:05:33 +04:00
| sed 's,$(PKGDIR)/*,,g' )
2011-07-15 00:00:46 +03:00
dot-base :
2011-09-03 12:34:53 +03:00
@{ \
echo -e "\n## added by image.in/Makefile" ; \
echo " $( call kpackages,$( KMODULES) ,$( KFLAVOURS) ) " ; \
} >> $( call list,.base)
2011-07-15 00:00:46 +03:00
2011-05-11 23:40:47 +04:00
$(IMAGEDIR) :
2011-09-03 12:34:53 +03:00
@mkdir -p " $( IMAGEDIR) "
2011-05-11 23:40:47 +04:00
# specified only for the final image, not for the subparts
pack-image : OUTDIR = $( IMAGEDIR )
2010-09-27 22:02:57 +03:00
debug :
2011-06-14 18:25:55 +04:00
@echo " TOPDIR= $( TOPDIR) "
@echo " ARCH= $( ARCH) "
@echo " GLOBAL_HSH_APT_CONFIG= $( GLOBAL_HSH_APT_CONFIG) "
2010-08-28 19:28:42 +03:00
2010-12-03 16:53:02 +02:00
dot-disk :
2010-09-14 13:18:53 +03:00
@mkdir -p files/.disk
2010-12-03 16:53:02 +02:00
@echo "ALT Linux based" >files/.disk/info
@echo " $( ARCH) " >files/.disk/arch
2011-05-11 23:40:47 +04:00
@echo " $( DATE) " >files/.disk/date
2011-09-03 12:34:53 +03:00
@if type -t git >& /dev/null; then \
( cd $( TOPDIR) && \
git show-ref --head -ds -- HEAD ) \
>files/.disk/commit 2>/dev/null; \
fi