From 4b70dd97e99c7091e718f66b0f20668422c97de6 Mon Sep 17 00:00:00 2001 From: "A. Wilcox" Date: Sat, 23 Sep 2017 18:45:24 -0500 Subject: PowerPC: fixes, thanks @Elizafox --- iso-params-ppc | 2 +- mapping-ppc | 5 +++++ ofboot.b | 64 ---------------------------------------------------------- post-ppc.sh | 13 ++++++++++-- ppc/early.cfg | 2 ++ ppc/grub.cfg | 25 +++++++++++++++++++++++ ppc/ofboot.b | 64 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 7 files changed, 108 insertions(+), 67 deletions(-) delete mode 100644 ofboot.b create mode 100644 ppc/early.cfg create mode 100644 ppc/grub.cfg create mode 100644 ppc/ofboot.b diff --git a/iso-params-ppc b/iso-params-ppc index fa096f8..1f08e9e 100644 --- a/iso-params-ppc +++ b/iso-params-ppc @@ -1 +1 @@ --hfs -hfs-volid Adelie_1.0a3 -part -no-desktop -map mapping-ppc -chrp-boot -prep-boot -hfs-bless cdroot-ppc/boot +-hfs -hfs-volid Adelie_1.0a3 -part -no-desktop -map mapping-ppc -hfs-bless cdroot-ppc/boot -chrp-boot -prep-boot boot/grubcore.img diff --git a/mapping-ppc b/mapping-ppc index 4c945c4..861975c 100644 --- a/mapping-ppc +++ b/mapping-ppc @@ -1,4 +1,9 @@ # EXTN XLate CREATOR TYPE Comment .b Raw 'chrp' 'tbxi' "Macintosh Toolbox ROM file" .squashfs Raw 'UNIX' 'UNIX' "Linux Root File System" +.cfg Raw 'AAPL' 'TEXT' "Configuration file" +.txt Raw 'AAPL' 'TEXT' "Plain text file" +.img Raw 'UNIX' 'UNIX' "GRUB bootable image file" +bzImage Raw 'UNIX' 'UNIX' "Linux kernel" +initrd Raw 'UNIX' 'UNIX' "Linux boot disk" * Raw '????' '????' "Unknown" diff --git a/ofboot.b b/ofboot.b deleted file mode 100644 index 0598597..0000000 --- a/ofboot.b +++ /dev/null @@ -1,64 +0,0 @@ - - -MacRISC MacRISC3 MacRISC4 - - -Adelie - - -" screen" output -load-base release-load-area -boot &device;:\grub - - -1010 -000000000000F8FEACF6000000000000 -0000000000F5FFFFFEFEF50000000000 -00000000002BFAFEFAFCF70000000000 -0000000000F65D5857812B0000000000 -0000000000F5350B2F88560000000000 -0000000000F6335708F8FE0000000000 -00000000005600F600F5FD8100000000 -00000000F9F8000000F5FAFFF8000000 -000000008100F5F50000F6FEFE000000 -000000F8F700F500F50000FCFFF70000 -00000088F70000F50000F5FCFF2B0000 -0000002F582A00F5000008ADE02C0000 -00090B0A35A62B0000002D3B350A0000 -000A0A0B0B3BF60000505E0B0A0B0A00 -002E350B0B2F87FAFCF45F0B2E090000 -00000007335FF82BF72B575907000000 -000000000000ACFFFF81000000000000 -000000000081FFFFFFFF810000000000 -0000000000FBFFFFFFFFAC0000000000 -000000000081DFDFDFFFFB0000000000 -000000000081DD5F83FFFD0000000000 -000000000081DDDF5EACFF0000000000 -0000000000FDF981F981FFFF00000000 -00000000FFACF9F9F981FFFFAC000000 -00000000FFF98181F9F981FFFF000000 -000000ACACF981F981F9F9FFFFAC0000 -000000FFACF9F981F9F981FFFFFB0000 -00000083DFFBF981F9F95EFFFFFC0000 -005F5F5FDDFFFBF9F9F983DDDD5F0000 -005F5F5F5FDD81F9F9E7DF5F5F5F5F00 -0083DD5F5F83FFFFFFFFDF5F835F0000 -000000FBDDDFACFBACFBDFDFFB000000 -000000000000FFFFFFFF000000000000 -0000000000FFFFFFFFFFFF0000000000 -0000000000FFFFFFFFFFFF0000000000 -0000000000FFFFFFFFFFFF0000000000 -0000000000FFFFFFFFFFFF0000000000 -0000000000FFFFFFFFFFFF0000000000 -0000000000FFFFFFFFFFFFFF00000000 -00000000FFFFFFFFFFFFFFFFFF000000 -00000000FFFFFFFFFFFFFFFFFF000000 -000000FFFFFFFFFFFFFFFFFFFFFF0000 -000000FFFFFFFFFFFFFFFFFFFFFF0000 -000000FFFFFFFFFFFFFFFFFFFFFF0000 -00FFFFFFFFFFFFFFFFFFFFFFFFFF0000 -00FFFFFFFFFFFFFFFFFFFFFFFFFFFF00 -00FFFFFFFFFFFFFFFFFFFFFFFFFF0000 -000000FFFFFFFFFFFFFFFFFFFF000000 - - diff --git a/post-ppc.sh b/post-ppc.sh index 33e7cbe..2b6480a 100644 --- a/post-ppc.sh +++ b/post-ppc.sh @@ -1,4 +1,13 @@ mkdir -p cdroot-ppc/boot -curl "https://distfiles.adelielinux.org/adelie/1.0-alpha/ppc/grubcore.img" > cdroot-ppc/boot/grubcore.img -curl "https://distfiles.adelielinux.org/adelie/1.0-alpha/ppc/ofboot.b" > cdroot-ppc/boot/ofboot.b + +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 diff --git a/ppc/early.cfg b/ppc/early.cfg new file mode 100644 index 0000000..1fa86fa --- /dev/null +++ b/ppc/early.cfg @@ -0,0 +1,2 @@ +search.fs_label Adelie_1.0a3 root +set prefix=($root)/boot diff --git a/ppc/grub.cfg b/ppc/grub.cfg new file mode 100644 index 0000000..4288662 --- /dev/null +++ b/ppc/grub.cfg @@ -0,0 +1,25 @@ +menuentry "Adelie Linux 1.0-alpha3 Live (PowerPC 32-bit)" --class linux --id adelie-live-cd { + insmod part_apple + insmod iso9660 + insmod linux + search --label "Adelie_1.0a3" --hint cd,apple2 + linux /bzImage + initrd /initrd +} + +#menuentry "Adelie Linux 1.0-alpha3 Live (PowerPC 64-bit)" --class linux --id adelie-live-64 { +# insmod part_apple +# insmod iso9660 +# insmod linux +# search --label "Adelie_1.0a3" --hint cd,apple2 +# linux /bzImage64 +# initrd /initrd64 +#} + +menuentry "Reboot and Try Again" --class reboot --id reboot { + reboot +} + +GRUB_DEFAULT=adelie-live-cd +GRUB_TIMEOUT=10 +GRUB_DISTRIBUTOR="Adelie" diff --git a/ppc/ofboot.b b/ppc/ofboot.b new file mode 100644 index 0000000..0598597 --- /dev/null +++ b/ppc/ofboot.b @@ -0,0 +1,64 @@ + + +MacRISC MacRISC3 MacRISC4 + + +Adelie + + +" screen" output +load-base release-load-area +boot &device;:\grub + + +1010 +000000000000F8FEACF6000000000000 +0000000000F5FFFFFEFEF50000000000 +00000000002BFAFEFAFCF70000000000 +0000000000F65D5857812B0000000000 +0000000000F5350B2F88560000000000 +0000000000F6335708F8FE0000000000 +00000000005600F600F5FD8100000000 +00000000F9F8000000F5FAFFF8000000 +000000008100F5F50000F6FEFE000000 +000000F8F700F500F50000FCFFF70000 +00000088F70000F50000F5FCFF2B0000 +0000002F582A00F5000008ADE02C0000 +00090B0A35A62B0000002D3B350A0000 +000A0A0B0B3BF60000505E0B0A0B0A00 +002E350B0B2F87FAFCF45F0B2E090000 +00000007335FF82BF72B575907000000 +000000000000ACFFFF81000000000000 +000000000081FFFFFFFF810000000000 +0000000000FBFFFFFFFFAC0000000000 +000000000081DFDFDFFFFB0000000000 +000000000081DD5F83FFFD0000000000 +000000000081DDDF5EACFF0000000000 +0000000000FDF981F981FFFF00000000 +00000000FFACF9F9F981FFFFAC000000 +00000000FFF98181F9F981FFFF000000 +000000ACACF981F981F9F9FFFFAC0000 +000000FFACF9F981F9F981FFFFFB0000 +00000083DFFBF981F9F95EFFFFFC0000 +005F5F5FDDFFFBF9F9F983DDDD5F0000 +005F5F5F5FDD81F9F9E7DF5F5F5F5F00 +0083DD5F5F83FFFFFFFFDF5F835F0000 +000000FBDDDFACFBACFBDFDFFB000000 +000000000000FFFFFFFF000000000000 +0000000000FFFFFFFFFFFF0000000000 +0000000000FFFFFFFFFFFF0000000000 +0000000000FFFFFFFFFFFF0000000000 +0000000000FFFFFFFFFFFF0000000000 +0000000000FFFFFFFFFFFF0000000000 +0000000000FFFFFFFFFFFFFF00000000 +00000000FFFFFFFFFFFFFFFFFF000000 +00000000FFFFFFFFFFFFFFFFFF000000 +000000FFFFFFFFFFFFFFFFFFFFFF0000 +000000FFFFFFFFFFFFFFFFFFFFFF0000 +000000FFFFFFFFFFFFFFFFFFFFFF0000 +00FFFFFFFFFFFFFFFFFFFFFFFFFF0000 +00FFFFFFFFFFFFFFFFFFFFFFFFFFFF00 +00FFFFFFFFFFFFFFFFFFFFFFFFFF0000 +000000FFFFFFFFFFFFFFFFFFFF000000 + + -- cgit v1.2.3-70-g09d2