summaryrefslogtreecommitdiff
path: root/post/arch
diff options
context:
space:
mode:
authorA. Wilcox <AWilcox@Wilcox-Tech.com>2020-02-02 14:27:01 -0600
committerA. Wilcox <AWilcox@Wilcox-Tech.com>2020-02-02 14:27:01 -0600
commit44905a2bdc4ce312c406f67428157ea43456db19 (patch)
tree3248431bfe368528e3291f45d31138a971889a5d /post/arch
parent0f4eabe1911f45a7f8f756049d1fedc5c0ffdaf5 (diff)
downloadimage-44905a2bdc4ce312c406f67428157ea43456db19.tar.gz
image-44905a2bdc4ce312c406f67428157ea43456db19.tar.bz2
image-44905a2bdc4ce312c406f67428157ea43456db19.tar.xz
image-44905a2bdc4ce312c406f67428157ea43456db19.zip
Better organisation of package lists and post scripts
Diffstat (limited to 'post/arch')
-rwxr-xr-xpost/arch/pmmx.sh48
-rw-r--r--post/arch/ppc.sh17
-rwxr-xr-xpost/arch/ppc64.sh23
-rwxr-xr-xpost/arch/x86_64.sh46
4 files changed, 134 insertions, 0 deletions
diff --git a/post/arch/pmmx.sh b/post/arch/pmmx.sh
new file mode 100755
index 0000000..e68e387
--- /dev/null
+++ b/post/arch/pmmx.sh
@@ -0,0 +1,48 @@
+mkdir -p cdroot-pmmx/boot
+
+if ! type grub-mkimage>/dev/null; then
+ printf "GRUB image cannot be created. Using stale copy.\n"
+ printf "If you don't have one, this will fail!\n"
+else
+ printf '\033[01;32m * \033[37mInstalling GRUB...\033[00;39m\n'
+ grub-mkimage -c x86/early.cfg -v -p boot -o grubcore-stage1.img -O i386-pc biosdisk boot btrfs datetime disk ext2 gfxmenu help iso9660 jfs linux ls luks lvm memdisk nilfs2 normal part_gpt part_msdos png scsi search xfs reboot gfxterm gfxterm_background gfxterm_menu
+ cat /usr/lib/grub/i386-pc/cdboot.img grubcore-stage1.img > cdroot-pmmx/boot/grubcore.img
+
+ grub-mkimage -c x86/early.cfg -v -p boot -o x86/efi32.exe -O i386-efi boot btrfs datetime disk ext2 gfxmenu help iso9660 jfs ls luks lvm memdisk nilfs2 normal part_gpt part_msdos png scsi search xfs linux reboot gfxterm gfxterm_background gfxterm_menu
+fi
+
+cp x86/grub.cfg cdroot-pmmx/boot/grub.cfg
+
+mkdir -p cdroot-pmmx/System/Library/CoreServices
+touch cdroot-pmmx/System/Library/CoreServices/mach_kernel
+cat >cdroot-pmmx/System/Library/CoreServices/SystemVersion.plist <<PLIST
+<plist version="1.0">
+<dict>
+ <key>ProductBuildVersion</key>
+ <string>1B4</string>
+ <key>ProductName</key>
+ <string>Adélie Linux</string>
+ <key>ProductVersion</key>
+ <string>1.0-BETA4</string>
+</dict>
+PLIST
+cp disk-label cdroot-pmmx/System/Library/CoreServices/.disk_label
+echo 'Adélie 1.0-BETA4' >cdroot-pmmx/System/Library/CoreServices/.disk_label.contentDetails
+cp x86/efi32.exe cdroot-pmmx/System/Library/CoreServices/boot.efi
+
+if ! type mkfs.fat>/dev/null; then
+ printf "EFI image cannot be created.\n"
+ printf "If one does not already exist, this CD will boot BIOS systems only.\n"
+else
+ mkdir -p x86/efitemp
+ dd if=/dev/zero of=x86/efi32.img bs=1024 count=2880
+ mkfs.fat x86/efi32.img
+ mount -t vfat -o loop,rw x86/efi32.img x86/efitemp
+ mkdir -p x86/efitemp/EFI/BOOT
+ mv x86/efi32.exe x86/efitemp/EFI/BOOT/bootia32.efi
+ cp x86/efitemp/EFI/BOOT/bootia32.efi x86/efitemp/EFI/BOOT/boot.efi
+ umount x86/efitemp
+ rmdir x86/efitemp
+fi
+cp x86/efi32.img cdroot-pmmx/efi.img
+
diff --git a/post/arch/ppc.sh b/post/arch/ppc.sh
new file mode 100644
index 0000000..2c4fe64
--- /dev/null
+++ b/post/arch/ppc.sh
@@ -0,0 +1,17 @@
+mkdir -p cdroot-ppc/boot
+
+if ! type grub-mkimage>/dev/null; then
+ echo "GRUB image cannot be created. Using stale copy."
+ curl "https://distfiles.adelielinux.org/adelie/1.0-alpha/ppc/grubcore.img" > cdroot-ppc/boot/grubcore.img
+else
+ grub-mkimage -c ppc/early.cfg -v -p boot -o cdroot-ppc/boot/grubcore.img -O powerpc-ieee1275 boot btrfs datetime disk ext2 gfxmenu help hfs hfsplus ieee1275_fb iso9660 jfs ls luks lvm macbless macho nilfs2 ofnet part_apple part_gpt part_msdos png scsi search xfs linux reboot gfxterm gfxterm_background gfxterm_menu
+fi
+
+cp AdelieTux.icns 'cdroot-ppc/Icon '
+cp ppc/grub.cfg cdroot-ppc/boot/grub.cfg
+cp ppc/ofboot.b cdroot-ppc/boot/ofboot.b
+cp cdroot-ppc/boot/ofboot.b cdroot-ppc/boot/bootinfo.txt
+
+# CHRP
+mkdir -p cdroot-ppc/ppc
+cp cdroot-ppc/boot/bootinfo.txt cdroot-ppc/ppc/bootinfo.txt
diff --git a/post/arch/ppc64.sh b/post/arch/ppc64.sh
new file mode 100755
index 0000000..dd4a5b9
--- /dev/null
+++ b/post/arch/ppc64.sh
@@ -0,0 +1,23 @@
+mkdir -p cdroot-ppc64/boot
+
+if ! type grub-mkimage>/dev/null; then
+ printf "GRUB image cannot be created. Using stale copy.\n"
+ printf "If you don't have one, this will fail!\n"
+else
+ grub-mkimage -c ppc/early.cfg64 -v -p boot -o cdroot-ppc64/boot/grubcore.img -O powerpc-ieee1275 boot btrfs datetime disk ext2 gfxmenu help hfs hfsplus ieee1275_fb iso9660 jfs ls luks lvm macbless macho nilfs2 ofnet part_apple part_gpt part_msdos png scsi search xfs linux reboot gfxterm gfxterm_background gfxterm_menu
+fi
+
+cp AdelieTux.icns 'cdroot-ppc64/Icon '
+cp ppc/grub.cfg64 cdroot-ppc64/boot/grub.cfg
+cp ppc/ofboot.b cdroot-ppc64/boot/ofboot.b
+cp cdroot-ppc64/boot/ofboot.b cdroot-ppc64/boot/bootinfo.txt
+
+# Fix petitboot
+mkdir cdroot-ppc64/boot/grub
+cp ppc/grub.cfg64 cdroot-ppc64/boot/grub/grub.cfg
+
+# Fix CHRP
+mkdir cdroot-ppc64/ppc
+cp cdroot-ppc64/boot/bootinfo.txt cdroot-ppc64/ppc/bootinfo.txt
+
+mv squashroot-ppc64/boot/vmlinux-4.14.138-mc15-easy-power8 cdroot-ppc64/bzImage-p8
diff --git a/post/arch/x86_64.sh b/post/arch/x86_64.sh
new file mode 100755
index 0000000..3117f86
--- /dev/null
+++ b/post/arch/x86_64.sh
@@ -0,0 +1,46 @@
+mkdir -p cdroot-x86_64/boot
+
+if ! type grub-mkimage>/dev/null; then
+ printf "GRUB image cannot be created. Using stale copy.\n"
+ printf "If you don't have one, this will fail!\n"
+else
+ printf '\033[01;32m * \033[37mInstalling GRUB...\033[00;39m\n'
+ grub-mkimage -c x86/early.cfg64 -v -p boot -o grubcore-stage1.img -O i386-pc biosdisk boot btrfs datetime disk ext2 gfxmenu help iso9660 jfs linux ls luks lvm memdisk nilfs2 normal part_gpt part_msdos png scsi search xfs reboot gfxterm gfxterm_background gfxterm_menu
+ cat /usr/lib/grub/i386-pc/cdboot.img grubcore-stage1.img > cdroot-x86_64/boot/grubcore.img
+
+ grub-mkimage -c x86/early.cfg64 -v -p boot -o x86/efi64.exe -O x86_64-efi boot btrfs datetime disk ext2 gfxmenu help iso9660 jfs ls luks lvm memdisk nilfs2 normal part_gpt part_msdos png scsi search xfs linux reboot gfxterm gfxterm_background gfxterm_menu
+fi
+
+cp x86/grub.cfg64 cdroot-x86_64/boot/grub.cfg
+
+mkdir -p cdroot-x86_64/System/Library/CoreServices
+touch cdroot-x86_64/System/Library/CoreServices/mach_kernel
+cat >cdroot-x86_64/System/Library/CoreServices/SystemVersion.plist <<PLIST
+<plist version="1.0">
+<dict>
+ <key>ProductBuildVersion</key>
+ <string>1B4</string>
+ <key>ProductName</key>
+ <string>Adélie Linux</string>
+ <key>ProductVersion</key>
+ <string>1.0-BETA4</string>
+</dict>
+PLIST
+cp disk-label cdroot-x86_64/System/Library/CoreServices/.disk_label
+echo 'Adélie 1.0-BETA4' >cdroot-x86_64/System/Library/CoreServices/.disk_label.contentDetails
+cp x86/efi64.exe cdroot-x86_64/System/Library/CoreServices/boot.efi
+
+if ! type mkfs.fat>/dev/null; then
+ printf "EFI image cannot be created.\n"
+ printf "If one does not already exist, this CD will boot BIOS systems only.\n"
+else
+ mkdir -p x86/efitemp
+ dd if=/dev/zero of=x86/efi64.img bs=1024 count=1440
+ mkfs.fat x86/efi64.img
+ mount -t vfat -o loop,rw x86/efi64.img x86/efitemp
+ mkdir -p x86/efitemp/EFI/BOOT
+ mv x86/efi64.exe x86/efitemp/EFI/BOOT/bootx64.efi
+ umount x86/efitemp
+ rmdir x86/efitemp
+fi
+cp x86/efi64.img cdroot-x86_64/efi.img