mkiso 809 Bytes
Newer Older
1 2 3 4 5 6
#!/bin/sh

tmp=$PWD/tmp
aports=$PWD/../aports
target=alpine-test.iso

Natanael Copa's avatar
Natanael Copa committed
7 8 9 10 11 12 13 14 15 16
unapk() {
	local dest="$1"
	shift
	while [ $# -gt 0 ]; do
		tar -C "$dest" -zxf "$1"
		shift
	done
	rm -f "$dest/.PKGINFO"
}

17 18 19 20
rm -r $tmp
mkdir -p $tmp/apks $tmp/isolinux
cp /usr/share/syslinux/isolinux.* $tmp/isolinux
cat >$tmp/isolinux/isolinux.cfg <<EOF
Natanael Copa's avatar
Natanael Copa committed
21
timeout 20
22 23 24 25 26
prompt 1
default test

label test
	kernel /boot/vmlinuz
Natanael Copa's avatar
Natanael Copa committed
27
	append initrd=/boot/test.gz alpine_dev=cdrom quiet
28 29 30
EOF


Natanael Copa's avatar
Natanael Copa committed
31 32 33
#cp $aports/core/*/*.apk $tmp/apks

unapk $tmp $aports/core/linux-grsec/linux-grsec-[0-9]*.apk
34 35

sh mkinitram
Natanael Copa's avatar
Natanael Copa committed
36
sh mkmodloop
37

Natanael Copa's avatar
Natanael Copa committed
38
mkdir -p $tmp/boot/
Natanael Copa's avatar
Natanael Copa committed
39
cp test.gz $tmp/boot/ 
Natanael Copa's avatar
Natanael Copa committed
40
cp modloop.cmg $tmp/boot/
41 42 43 44 45 46 47 48 49 50 51

genisoimage -o $target -l -J -R \
	-b isolinux/isolinux.bin \
	-c isolinux/boot.cat	\
	-no-emul-boot		\
	-boot-load-size 4	\
	-boot-info-table	\
	-quiet			\
	$tmp