diff options
author | A. Wilcox <AWilcox@Wilcox-Tech.com> | 2017-01-22 16:11:20 -0600 |
---|---|---|
committer | A. Wilcox <AWilcox@Wilcox-Tech.com> | 2017-01-22 16:11:20 -0600 |
commit | 0aff91dc699e9688ac0b0947d6e65e35f6b30f50 (patch) | |
tree | 479e437bcf92c3793518a342a841e92c1c972797 /build-cd | |
parent | bc60e4be19b1390e02aa7acd54b1b5ac2daeb5dc (diff) | |
download | image-0aff91dc699e9688ac0b0947d6e65e35f6b30f50.tar.gz image-0aff91dc699e9688ac0b0947d6e65e35f6b30f50.tar.bz2 image-0aff91dc699e9688ac0b0947d6e65e35f6b30f50.tar.xz image-0aff91dc699e9688ac0b0947d6e65e35f6b30f50.zip |
Make build-cd fully architecture independent
Diffstat (limited to 'build-cd')
-rwxr-xr-x | build-cd | 35 |
1 files changed, 14 insertions, 21 deletions
@@ -86,8 +86,10 @@ while [ -n "$1" ]; do shift done +set -a declare -r ARCH=${MY_ARCH:-$def_arch} declare -r LDARCH=${LDARCH:-$ARCH} +set +a ensure_commands @@ -122,19 +124,19 @@ declare -r PACKAGES=" pciutils libusb1 usbutils \ strace \ hdparm \ - dmidecode \ less \ bzip2 \ netifrc netifrc-doc netifrc-openrc \ - diskdev_cmds exfat-utils hfsutils mtools \ - efibootmgr elilo mactel-boot syslinux + diskdev_cmds exfat-utils hfsutils mtools " +declare -r ARCH_PKGS=$(cat packages-$ARCH 2>/dev/null || echo '') + printf '\033[01;32m * \033[37mInstalling base system to squash root...\033[00;39m\n' mkdir -p squashroot-$ARCH/etc/apk/keys cp 'packages@adelielinux.org.pub' squashroot-$ARCH/etc/apk/keys/ -apk --arch $ARCH -X "https://distfiles.adelielinux.org/adelie/1.0-alpha/$EXTRA_MIRROR" -U --root squashroot-$ARCH --initdb add $PACKAGES +apk --arch $ARCH -X "https://distfiles.adelielinux.org/adelie/1.0-alpha/$EXTRA_MIRROR" -U --root squashroot-$ARCH --initdb add $PACKAGES $ARCH_PKGS mkdir -p squashroot-$ARCH/home/live mkdir squashroot-$ARCH/target mkdir -p squashroot-$ARCH/media/live @@ -214,7 +216,8 @@ cat >squashroot-$ARCH/etc/shells <<- SHELLS SHELLS cat >squashroot-$ARCH/etc/resolv.conf <<- RESOLVE - nameserver 8.8.8.8 + nameserver 84.200.69.80 + nameserver 2001:1608:10:25::1c04:b12f RESOLVE cat >squashroot-$ARCH/etc/apk/repositories <<-REPOS @@ -302,22 +305,12 @@ printf '\033[01;32m * \033[37mAdding kernel...\033[00;39m\n' cp squashroot-$ARCH/boot/vmlinuz* cdroot-$ARCH/bzImage -printf '\033[01;32m * \033[37mInstalling ISOLINUX...\033[00;39m\n' - -mkdir cdroot-$ARCH/isolinux - -cat >cdroot-$ARCH/isolinux/isolinux.cfg <<BOOTCFG -prompt 1 -default adelie - -label adelie - kernel /bzImage - append initrd=/initrd -BOOTCFG - -cp /usr/share/syslinux/isolinux-debug.bin cdroot-$ARCH/isolinux/isolinux.bin -cp /usr/share/syslinux/ldlinux.c32 cdroot-$ARCH/isolinux/ +if test -f post-$ARCH.sh; then + printf '\033]01;32m * \033]37mRunning architecture-specific scripts...\033[00;39m\n' + sh post-$ARCH.sh +fi printf '\033[01;32m * \033[37mCreating the CD...\033[00;39m\n' -mkisofs -o adelie-${DO_FULL:-live}-$ARCH-1.0-ALPHA2-$(date +%Y%m%d).iso -b isolinux/isolinux.bin -c isolinux/boot.cat -no-emul-boot -boot-load-size 4 -boot-info-table -joliet -rational-rock -V "Adélie 1.0a2 $ARCH" cdroot-$ARCH +declare -r CD_PARAMS=$(cat iso-params-$ARCH) +mkisofs -o adelie-${DO_FULL:-live}-$ARCH-1.0-ALPHA2-$(date +%Y%m%d).iso ${CD_PARAMS} -joliet -rational-rock -V "Adélie 1.0a2 $ARCH" cdroot-$ARCH |