2010-12-03 17:53:02 +03:00
# steps to build a distribution image:
2010-09-27 23:02:57 +04:00
# --- here
2010-12-03 17:53:02 +03:00
# 1. initialize new profile (BUILDDIR) as a copy of image.in/
# 2. configure distro
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
# 3. copy subprofiles, script hooks, and package lists/groups
2010-12-03 17:53:02 +03:00
# from metaprofile to new profile (as needed)
2010-09-27 23:02:57 +04:00
# --- in BUILDDIR
2010-12-03 17:53:02 +03:00
# 4. build subprofiles and subsequently image
2010-09-27 23:02:57 +04:00
all help :
@echo '** available distribution targets:'
2011-05-11 23:40:47 +04:00
@echo $( DISTROS) | fmt -sw" $$ ((COLUMNS>>1)) " | column -t
2010-08-28 20:28:42 +04:00
2011-05-11 23:40:47 +04:00
# most of the actual work done elsewhere
i n c l u d e c l e a n . m k
i n c l u d e p r o f i l e . m k
2011-06-12 19:06:36 +04:00
i n c l u d e d i s t r o . m k
2011-05-11 23:40:47 +04:00
i n c l u d e l o g . m k
i n c l u d e i s o . m k
2010-09-13 18:22:05 +04:00
2010-08-28 20:28:42 +04:00
# we can't use implicit rules for top-level targets, only for prereqs
2010-09-27 23:02:57 +04:00
CONFIGS := $( shell sed -n 's,^distro/\([^:.]\+\):.*$$,\1,p' distro.mk)
2010-09-13 18:22:05 +04:00
DISTROS := $( addsuffix .iso,$( CONFIGS) )
2010-09-27 23:02:57 +04:00
ARCH ?= $( shell arch | sed 's/i686/i586/' )
2011-05-11 23:40:47 +04:00
DATE = $( shell date +%Y%m%d)
2011-06-12 19:06:36 +04:00
export ARCH DATE
2010-08-28 20:28:42 +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
# to be passed into distcfg.mk
2011-05-11 23:40:47 +04:00
IMAGEDIR ?= $( shell [ -d " $$ HOME/out " -a -w " $$ HOME/out " ] \
&& echo " $$ HOME/out " \
|| echo " $( BUILDDIR) /out " )
IMAGENAME ?= mkimage-profiles-$( ARCH) .iso
2010-08-28 20:28:42 +04:00
2010-09-14 14:18:53 +04:00
$(DISTROS) : %.iso : | profile /init distro /% boot /isolinux profile /populate iso
2011-05-11 23:40:47 +04:00
@# TODO: run automated tests ( e.g. iso size)
@OUTNAME= " $( @:.iso= ) - $( DATE) - $( ARCH) .iso " ; \
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
OUTPATH = " $( IMAGEDIR) / $$ OUTNAME " ; \
2011-05-11 23:40:47 +04:00
test -s " $( IMAGEDIR) / $( IMAGENAME) " && \
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
mv " $( IMAGEDIR) / $( IMAGENAME) " " $$ OUTPATH " && \
echo " ** image: $$ OUTPATH " && \
2011-05-11 23:40:47 +04:00
ln -sf " $$ OUTNAME " " $( IMAGEDIR) / $@ " && \
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
ln -sf " $@ " " $( IMAGEDIR) /mkimage-profiles.iso " ; \
if [ -n " $( DEBUG) " ] ; then \
cp -a " $( BUILDLOG) " " $$ OUTPATH.log " ; \
cp -a " $( CONFIG) " " $$ OUTPATH.cfg " ; \
fi