diff options
author | Sebastian | 2011-04-26 19:38:11 +0200 |
---|---|---|
committer | Sebastian | 2011-04-26 19:38:11 +0200 |
commit | e8f2057c4ba4e366f132e2a8780324232c725fd3 (patch) | |
tree | 9b411c31c01a20e397b633ae672b27a24858f998 /create-installer | |
parent | update fbgui... (diff) | |
download | usb-boot-stick-e8f2057c4ba4e366f132e2a8780324232c725fd3.tar.gz usb-boot-stick-e8f2057c4ba4e366f132e2a8780324232c725fd3.tar.xz usb-boot-stick-e8f2057c4ba4e366f132e2a8780324232c725fd3.zip |
create installer working ..
Diffstat (limited to 'create-installer')
-rwxr-xr-x | create-installer | 46 |
1 files changed, 46 insertions, 0 deletions
diff --git a/create-installer b/create-installer new file mode 100755 index 0000000..ce7ad58 --- /dev/null +++ b/create-installer @@ -0,0 +1,46 @@ +#!/bin/bash + +ROOT_DIR=$(dirname $(readlink -f $0)) + +if [ $(whoami) != "root" ]; then + echo "you should be root" + exit 1; +fi + +OUT_DEV=$1 +SYSLINUX=$ROOT_DIR/contrib/syslinux/latest + +PBSI=$ROOT_DIR/installer/pbstick-installer + +PATH="$PATH:$ROOT_DIR/bin/" + +[ ! -f $SYSLINUX/Makefile ] && env.setup-syslinux.sh + +rm -rf $ROOT_DIR/installer/tmp +rm -f $ROOT_DIR/installer/stick-payload.tar.bz2 + +mkdir -p $ROOT_DIR/installer/tmp/share \ + $ROOT_DIR/installer/tmp/bin \ + $ROOT_DIR/installer/tmp/boot + +cp -f $SYSLINUX/mbr/mbr.bin $ROOT_DIR/installer/tmp/share +cp -f $SYSLINUX/extlinux/extlinux -i $ROOT_DIR/installer/tmp/bin + +[ ! -f $ROOT_DIR/build/kernel-preboot-latest ] && build.kernel.sh +cp -f $ROOT_DIR/build/kernel-preboot-latest $ROOT_DIR/installer/tmp/boot/kernel + +build.initramfs.sh +cp -f $ROOT_DIR/build/initramfs-default $ROOT_DIR/installer/tmp/boot/initramfs + +cp -f $SYSLINUX/com32/menu/menu.c32 $ROOT_DIR/installer/tmp/boot/ +cp -f $SYSLINUX/com32/menu/vesamenu.c32 $ROOT_DIR/installer/tmp/boot/ +cp -f $ROOT_DIR/config/extlinux/* $ROOT_DIR/installer/tmp/boot/ + +cd $ROOT_DIR/installer/tmp/ +tar cjf ../stick-payload.tar.bz2 * +cd $ROOT_DIR + +cat $ROOT_DIR/installer/tpl/installer.tpl.sh > $PBSI +echo "PAYLOAD:" >> $PBSI +cat $ROOT_DIR/installer/stick-payload.tar.bz2 | uuencode - >> $PBSI +chmod +rx $PBSI |