Mac-mini multi-boot guide
  • Priest of the Order of the Butterfly
    Priest of the Order of the Butterfly
    boot_wb
    Posts: 874 from 2007/4/9
    From: Kingston upon ...
    The following instructions are intended as a step-by-step guide to configuring Ubuntu/OSX/MorphOS triple-boot using yaboot on the mac-mini.
    It should be applicable to triple-booting on any NewWorld Mac, but has only been tested on Mac-mini so far.

    Apologies if this seems a bit disorganised, I was writing in response to a PM and thought it would probably be more useful here.

    The timbre and flow of the prose could use some work - it's not quite iambic pentameter. Who knows, eventually I may tidy it up and post it to the library.

    START

    For the installation of MorphOS & MacOSX, follow Jacadcap's guide, but with the following modifications:

    When setting up MorphOS, create an additional small HFS partition at the beginning of the disk (This will be used for the Ubuntu bootloader) - around 32MB will do.
    You cannot use the same partition for both the MorphOS bootloader and the Ubuntu bootloader.
    You will also need to leave space on the disk (anywhere on the disk) for 1) your ext2 (Ubuntu) partition and 2) a swap area for Ubuntu.

    Whilst Ext3/4 can be used for the Ubuntu partition, I used ext2 purely because it could be accessed by MorphOS and used for exchanging files between the OSes.

    You don't need to create your Ubuntu/Swap/Boot partitions at this stage, just leave enough space for later - the Ubuntu installer will allow you to create these partitions correctly.
    (For guidance, the ext2 Ubuntu partition took up around 10GB space on my drive after a clean installation, I left around 5GB for swap.)

    /End of modifications to Jacadcap's guide

    Download and burn-to-disk Ubuntu for PPC.
    Begin booting the 'live' installation from the disk (this can be selected from the boot menu by holding 'ATL' when booting).
    When booted, double-click the 'install' icon on the desktop, and follow the instructions until you are prompted to choose the installation destination.

    I recommend using the 'manual' partitioning method as I was not sure if the 'boot side-by-side' option would pick-up on the MorphOS installation. The following instructions assume you have done the same. (NB, I have not tried the 'boot side-by-side' option - it may work, it may not)

    Mount your ext2 area as '/' (not '/etc' or '/usr'). Designate your Newworldboot partition and swap partitions (create partitions now if required).

    Follow the instructions to install Ubuntu, and reboot into Ubuntu when prompted (you may have to hold 'alt' upon reboot and select it from the list).

    At this point, check the partition numbers using the disk utility (available in Ubuntu's menu): on my installation, 32kb of free space at the start of the disk was 'recognised' as a partition, and my first 'real' partition became hda2. You have been warned.

    To configure yaboot, open a terminal window and type 'sudo gedit /etc/yaboot.conf'. This will bring up a text editor which allows you to modify the bootloader config file.

    Most of the script can be ignored (although type 'yaboot.conf man' into a terminal if you want to know the details)

    Add/modify the following lines:
    delay=# (where # is the delay time (in seconds) from the menu appearing to autobooting).
    enableofboot (enables booting to openfirmware prompt from yaboot menu)
    enablecdboot (enables CD booting option in yaboot menu)
    macos=/dev/hda# (where # is the number of the partition containing the MorphOS boot.img)
    macosx=/dev/hda# (where # is the number of the partition containing MacOSX)

    Don't worry, we'll hack something later so that it displays MorphOS (not MacOS) in the menu ;-)

    Save the file and close gedit.

    At a terminal type 'sudo ybin --nonvram -v'

    (The '--nonvram' option prevents ybin from messing with openfirmware's variables (I prefer to do this manually), the -v switch puts the output into verbose mode (just for confirmation everything went ok)).

    Once this has run, reboot holding down 'Command + Option + O + F' to get to the openfirmware prompt.

    Type 'printenv' at the prompt. This will display your current environment variables.

    Type 'setenv boot-command boot hd#,//:tbxi' (where # is the NewWorld boot partition) - you can ignore the 'boot-device' line, it is overridden by the 'boot-command' line. (The tbxi tells openfirmware to look for a 'blessed' file. As there can only be one 'blessed' file per partition, the filename does not need to be specified. This is also the reason why MorphOS and Ubuntu bootloaders require separate partitions.)

    Reboot into MorphOS (either from yaboot, or by holding 'alt' whilst rebooting).

    Mount your NewWorld boot partition (using tools/mounter, if it has not been automatically mounted).
    Using your favourite text editor, edit the following lines of <drive>/ofboot.b (where <drive> is the name of your mounted NewWorld boot partition)

    (Around line 10)
    : boot macos "Booting MacOS..." etc...
    change to
    : boot macos "Booting MorphOS..." etc...

    (Around line 34)
    " m for MacOS," etc
    change to
    " m for MorphOS," etc

    Save and exit.

    Open a CLI

    Type 'hfssetmacboot <drive>:ofboot.b' (where <drive> is the name of your mounted NewWorld boot partition). This 'blesses' the file to allow openfirmware to identify that it is bootable.

    All done.
    Upon reboot, the menu should load automatically, and should offer you MorphOS, Mac OSX, Ubuntu, CD boot and Openfirmware boot.

    Now, that wasn't so hard was it? :-)

    [ Edited by boot_wb on 2010/8/26 14:11 ]
    www.hullchimneyservices.co.uk

    UI: Powerbook 5,6 (1.67GHz, 128MB VRam): OS3.1, OSX 10.5.8
    HTPC: Mac Mini G4 (1,5GHz, 64MB VRam): OS3.1 (ZVNC)
    Audiophile: Efika 5200b (SB Audigy): OS3.1 (VNC + Virtual Monitor)

    Windows free since 2011!
  • »16.08.10 - 11:56
    Profile Visit Website
  • Order of the Butterfly
    Order of the Butterfly
    Divinity
    Posts: 498 from 2009/9/8
    @boot_wb
    very very very very very good :-)
    Any differences using Debian ppc ?

    thanks
    regards
  • »16.08.10 - 15:13
    Profile
  • Priest of the Order of the Butterfly
    Priest of the Order of the Butterfly
    boot_wb
    Posts: 874 from 2007/4/9
    From: Kingston upon ...
    Quote:


    Divinity wrote:
    @boot_wb
    very very very very very good :-)
    Any differences using Debian ppc ?

    thanks
    regards


    Thanks, I hope it proves useful.

    I honestly have not tried to install Debian, but aside from any slight differences in the installation process, I'd expect it to be pretty much the same as Ubuntu (assuming it uses Yaboot for multi-boot).

    It's mainly just about generating, then altering, yaboot and associated files to ensure that all OSes are bootable.

    I went round in circles a few times because I wanted my MorphOS boot partition to show up as "apple_bootstrap" rather than "HFS" (took a bit of jiggling, almost ended up with no bootable OS at one point), but that's not in any way necessary (I just wanted it that way :-) ).
    www.hullchimneyservices.co.uk

    UI: Powerbook 5,6 (1.67GHz, 128MB VRam): OS3.1, OSX 10.5.8
    HTPC: Mac Mini G4 (1,5GHz, 64MB VRam): OS3.1 (ZVNC)
    Audiophile: Efika 5200b (SB Audigy): OS3.1 (VNC + Virtual Monitor)

    Windows free since 2011!
  • »17.08.10 - 09:58
    Profile Visit Website
  • Order of the Butterfly
    Order of the Butterfly
    Divinity
    Posts: 498 from 2009/9/8
    @boot_wb
    all OK also with debian :-)

    I have only one "big" problem ... I need to select in YABOOT more OSX system (four different OSX O.S.), but I can use only one "macosx=" path.
    How to solve this problem ?
    (for exemple I need to bootstrap OSX 10.4 or OSX 10.5 or OSX 10.4 server or OSX 10.5 server)
    Well, if there is no way, I can use ALT key to select manually the other three OSX O.S.
    Thanks

    [ Edited by Divinity on 2010/8/17 23:38 ]
  • »17.08.10 - 20:53
    Profile
  • Priest of the Order of the Butterfly
    Priest of the Order of the Butterfly
    boot_wb
    Posts: 874 from 2007/4/9
    From: Kingston upon ...
    I think this will require adding some lines into the both ofboot.b and yaboot.conf to create additional boot options - it shouldn't be too difficult.

    I'll have a go at fudging something together later today if I can find the time.

    Fortunately it's possible to play around with ofboot.b from within MorphOS, so there's virtually no risk of ending up with an unbootable system ;-)

    Regards



    Rich
    www.hullchimneyservices.co.uk

    UI: Powerbook 5,6 (1.67GHz, 128MB VRam): OS3.1, OSX 10.5.8
    HTPC: Mac Mini G4 (1,5GHz, 64MB VRam): OS3.1 (ZVNC)
    Audiophile: Efika 5200b (SB Audigy): OS3.1 (VNC + Virtual Monitor)

    Windows free since 2011!
  • »18.08.10 - 09:35
    Profile Visit Website
  • Order of the Butterfly
    Order of the Butterfly
    Divinity
    Posts: 498 from 2009/9/8
    @boot_wb
    thanks, when you have time give a look if you find a way :-)
    I have not installed MorphOS at the moment (I have used a PowerMac FW800), but I think also It's very useful editing ofboot.b in MorphOS (Is It also possible to edit ofboot.b in Linux in a simple way ?)
    thanks

    [ Edited by Divinity on 2010/8/18 14:03 ]
  • »18.08.10 - 11:55
    Profile
  • Priest of the Order of the Butterfly
    Priest of the Order of the Butterfly
    boot_wb
    Posts: 874 from 2007/4/9
    From: Kingston upon ...
    @Divinity

    Problem solved. :-)

    Plese find below an updated ofboot.b script, which includes MorphOS (no longer disguised as MacOS), and 4 possible MacOSX installations.
    Note that you will need to manually change the script to point to the correct partitions for your OSX installations.

    A quick comparison between this and the default ofboot.b should be enough to deduce how to make further alterations.

    Amendment to yaboot.conf is not necessary (only necessary if you are re-generating yaboot from within Linux).
    It just seems easier to edit ofboot.b manually from the MorphOS side and re-bless.

    Also, you can change the 'l', 'm', '1', '2', '3' and '4' buttons (to select which OS to boot to) to whatever you desire, just make sure you change it in both places (within ofboot.b).

    You can also change the descriptions to whatever you want.
    For consistency you should also change the descriptor in in two places within ofboot.b: the menu, and the confirmation message (however it will still boot if you fail to do this).

    Don't forget to re-bless the file after editing.

    [Start of ofboot.b]

    <CHRP-BOOT>
    <COMPATIBLE>
    MacRISC MacRISC3 MacRISC4
    </COMPATIBLE>
    <DESCRIPTION>
    PowerPC GNU/Linux First Stage Bootstrap
    </DESCRIPTION>
    <BOOT-SCRIPT>
    : .printf fb8-write drop ;
    : bootyaboot " Loading second stage bootstrap..." .printf 100 ms load-base release-load-area " hd:2,\\yaboot" $boot ;
    : bootmorphos " Booting MorphOS..." .printf 100 ms load-base release-load-area " /pci@f4000000/ata-6@d/disk@0:3,\\:tbxi" $boot ;
    : bootmacosx1 " Booting MacOSX1..." .printf 100 ms load-base release-load-area " /pci@f4000000/ata-6@d/disk@0:9,\\:tbxi" $boot ;
    : bootmacosx2 " Booting MacOSX2..." .printf 100 ms load-base release-load-area " /pci@f4000000/ata-6@d/disk@0:9,\\:tbxi" $boot ;
    : bootmacosx3 " Booting MacOSX3..." .printf 100 ms load-base release-load-area " /pci@f4000000/ata-6@d/disk@0:9,\\:tbxi" $boot ;
    : bootmacosx4 " Booting MacOSX4..." .printf 100 ms load-base release-load-area " /pci@f4000000/ata-6@d/disk@0:9,\\:tbxi" $boot ;
    : bootcd " Booting CDROM..." .printf 100 ms load-base release-load-area " cd:,\\:tbxi" $boot ;
    : bootof " Booting OpenFirmware..." .printf 100 ms quit ;
    " screen" output
    variable interactive
    1 interactive !

    0 interactive @ = if
    bootyaboot
    then

    dev screen
    " "(0000000000aa00aa0000aaaaaa0000aa00aaaa5500aaaaaa)" drop 0 7 set-colors
    " "(5555555555ff55ff5555ffffff5555ff55ffffff55ffffff)" drop 8 15 set-colors
    device-end
    f to foreground-color
    0 to background-color
    " "(0C)" .printf

    " First Stage Ubuntu Bootstrap"(0d 0a)" .printf
    " "(0d 0a)" .printf
    " Press l for GNU/Linux,"(0d 0a)" .printf
    " m for MorphOS,"(0d 0a)" .printf
    " 1 for MacOSX1,"(0d 0a)" .printf
    " 2 for MacOSX2,"(0d 0a)" .printf
    " 3 for MacOSX3,"(0d 0a)" .printf
    " 4 for MacOSX4,"(0d 0a)" .printf
    " c for CDROM,"(0d 0a)" .printf
    " o for OpenFirmware."(0d 0a)" .printf
    " "(0d 0a)" .printf
    " Stage 1 Boot: " .printf
    get-msecs d# 20 3E8 * +
    begin
    key? if
    key case
    ascii l of " l "(0d 0a)" .printf bootyaboot endof
    ascii m of " m "(0d 0a)" .printf bootmorphos endof
    ascii 1 of " 1 "(0d 0a)" .printf bootmacosx1 endof
    ascii 2 of " 2 "(0d 0a)" .printf bootmacosx2 endof
    ascii 3 of " 3 "(0d 0a)" .printf bootmacosx3 endof
    ascii 4 of " 4 "(0d 0a)" .printf bootmacosx4 endof
    ascii c of " c "(0d 0a)" .printf bootcd endof
    ascii o of " o "(0d 0a)" .printf bootof endof
    endcase
    then
    dup get-msecs <
    until
    drop
    " "(0d 0a)" .printf bootmorphos
    </BOOT-SCRIPT>
    <OS-BADGE-ICONS>
    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
    </OS-BADGE-ICONS>
    </CHRP-BOOT>


    [End of ofboot.b]

    ********************************************************************

    Hope this is useful to you.

    If Morphzone changes any of the characters above (it doesn't like GB Pound symbols for instance) I can attach the ofboot.b file as an attachment, just let me know if you need it.

    Regards



    Rich
    www.hullchimneyservices.co.uk

    UI: Powerbook 5,6 (1.67GHz, 128MB VRam): OS3.1, OSX 10.5.8
    HTPC: Mac Mini G4 (1,5GHz, 64MB VRam): OS3.1 (ZVNC)
    Audiophile: Efika 5200b (SB Audigy): OS3.1 (VNC + Virtual Monitor)

    Windows free since 2011!
  • »18.08.10 - 12:03
    Profile Visit Website
  • Order of the Butterfly
    Order of the Butterfly
    Divinity
    Posts: 498 from 2009/9/8
    @boot_wb
    thanks a lot ! Is there aslo a way to edit the "ofboot.b" file in "NewWorld partition" and re-bless it in Linux (or OSX) ? because at the moment I have a PowerMac FW800 without MorphOS

    thanks


    [ Edited by Divinity on 2010/8/18 14:10 ]
  • »18.08.10 - 12:07
    Profile
  • Priest of the Order of the Butterfly
    Priest of the Order of the Butterfly
    boot_wb
    Posts: 874 from 2007/4/9
    From: Kingston upon ...
    Quote:


    Divinity wrote:
    @boot_wb
    I have not installed MorphOS at the moment (I have used a PowerMac FW800), but I think also It's very useful editing ofboot.b in MorphOS (Is It also possible to edit ofboot.b in Linux in a simple way ?)
    thanks

    [ Edited by Divinity on 2010/8/18 14:03 ]


    You can mount the bootloader partition within Linux and edit the file (may require sudo though), but I do not know how to re-bless the file afterwards except by using ybin (which would overwrite your changes anyway, as it does more than just bless).

    I believe ofboot.b it is generated from a combination of a 'template' script within the filesystem (mkofboot or some such) and the changes made to yaboot.conf. What we are doing is bypassing this completely, and just manually altering the final script.
    It may be possible to edit this 'template' script, along with yaboot.conf, then run ybin to generate the results shown above and bless, but it would be a lot easier just to boot from the MorphOS2.5 CD, open a cli, and bless from there (wouldn't even require installing MorphOS onto the hard disk).

    Regards



    Rich

    [ Edited by boot_wb on 2010/8/18 14:15 ]
    www.hullchimneyservices.co.uk

    UI: Powerbook 5,6 (1.67GHz, 128MB VRam): OS3.1, OSX 10.5.8
    HTPC: Mac Mini G4 (1,5GHz, 64MB VRam): OS3.1 (ZVNC)
    Audiophile: Efika 5200b (SB Audigy): OS3.1 (VNC + Virtual Monitor)

    Windows free since 2011!
  • »18.08.10 - 12:14
    Profile Visit Website
  • Order of the Butterfly
    Order of the Butterfly
    Divinity
    Posts: 498 from 2009/9/8
    @boot_wb
    other questions:
    - What do you have in yaboot.config about "macosx=" variable using the four paths OSX in "ofboot.b" file ?
    - Is there a way to "promote" the screen size of Yaboot boot loader at lower resolution (so bigger to see for my eyes :-) )
  • »18.08.10 - 12:19
    Profile
  • Priest of the Order of the Butterfly
    Priest of the Order of the Butterfly
    boot_wb
    Posts: 874 from 2007/4/9
    From: Kingston upon ...
    Ahh, I see you have the Powermac - not surprised you don't have MorphOS installed yet ;-)

    There is a 'Bless' command under OSX, but I'm afraid I can't help you with the correct syntax - This Page should help though ;-)
    www.hullchimneyservices.co.uk

    UI: Powerbook 5,6 (1.67GHz, 128MB VRam): OS3.1, OSX 10.5.8
    HTPC: Mac Mini G4 (1,5GHz, 64MB VRam): OS3.1 (ZVNC)
    Audiophile: Efika 5200b (SB Audigy): OS3.1 (VNC + Virtual Monitor)

    Windows free since 2011!
  • »18.08.10 - 12:22
    Profile Visit Website
  • Order of the Butterfly
    Order of the Butterfly
    Divinity
    Posts: 498 from 2009/9/8
    - So Is It useless the "yaboot.config" in this way ? and I don't need to worry about the "macosx=" variable ? (for using four OSX O.S.) or I need also to config the yaboot.config ?

    Yes I can't use at the moment MorphOS with PowerMac FW800
    :-) or I can bootstrap with 2.5 cd-rom ?

    I'll try to edit form Linux and then re-bless, ok, thanks
  • »18.08.10 - 12:29
    Profile
  • Priest of the Order of the Butterfly
    Priest of the Order of the Butterfly
    boot_wb
    Posts: 874 from 2007/4/9
    From: Kingston upon ...
    Quote:


    Divinity wrote:
    @boot_wb
    other questions:
    - What do you have in yaboot.config about "macosx=" variable using the four paths OSX in "ofboot.b" file ?


    As far as I can determine, yaboot.conf is only used in generating ofboot.b.
    When booting, yaboot.conf is totally ignored (I've even removed it from my bootloader partition with no problems).

    Quote:

    - Is there a way to "promote" the screen size of Yaboot boot loader at lower resolution (so bigger to see for my eyes :-) )


    This, I do not know. If you do find out, please let me know as I'd like to do the same. :-)
    www.hullchimneyservices.co.uk

    UI: Powerbook 5,6 (1.67GHz, 128MB VRam): OS3.1, OSX 10.5.8
    HTPC: Mac Mini G4 (1,5GHz, 64MB VRam): OS3.1 (ZVNC)
    Audiophile: Efika 5200b (SB Audigy): OS3.1 (VNC + Virtual Monitor)

    Windows free since 2011!
  • »18.08.10 - 12:34
    Profile Visit Website
  • Order of the Butterfly
    Order of the Butterfly
    Divinity
    Posts: 498 from 2009/9/8
    Quote:


    boot_wb wrote:
    As far as I can determine, yaboot.conf is only used in generating ofboot.b.
    When booting, yaboot.conf is totally ignored (I've even removed it from my bootloader partition with no problems).

    This, I do not know. If you do find out, please let me know as I'd like to do the same. :-)


    Ok :-)
    Ok :-)
    Now I'll try to find a simple way to edit and re-bless "ofboot.b" in Linux and/or OSX
    thanks
  • »18.08.10 - 12:56
    Profile
  • Order of the Butterfly
    Order of the Butterfly
    Divinity
    Posts: 498 from 2009/9/8
    @boot_wb
    solved, now I have the four OSX O.S. in Yaboot :-)

    mount the HFS "mount -t hfs /dev/hda2 /mnt/newworld"
    then edited the file inside "ofboot.b" and saved

    Only difference is I have no re-blessed the file again
  • »18.08.10 - 17:20
    Profile
  • Just looking around
    marx
    Posts: 2 from 2009/11/24
    From: Poland
    Thank you very much for your great tutorial. But I would like to add something from myself. We can install Ubuntu without making any additional partitions. We should only left a free space on a hard disk. Then (while the Ubuntu installation procedure) we should select the option responsible for using the larges free space for Ubuntu. Instaler will cut this free space for a three partitions, and sets Ubuntu as a default OS. Then we have to modify yaboot.conf (as boot_os wrote before) to have an access to MorphOS and MacOSX from yaboot.

    To set default OS we have to change the last line before </BOOT-SCRIPT>. For example to set MacOSX as a default OS, change it to:

    Code:
    " "(0d 0a)" .printf bootmacosx
    </BOOT-SCRIPT>


    And don`t forget to type “hfssetmacboot <drive>:ofboot.b” in CLI on MorphOS
  • »11.01.11 - 07:22
    Profile Visit Website
  • Just looking around
    Fixi
    Posts: 2 from 2008/7/26
    Hello,

    first I say sorry for my english.
    I have a problem with yaboot.

    I installed mac OS 10.4, morphOS 2.7 and ubuntu 10.10 on my mac mini. In ubuntu I pressed <ALT> and <F2> and typed gksu gedit. I edit the ofboot.b file and saved it. Now the file looks:

    <CHRP-BOOT>
    <COMPATIBLE>
    MacRISC MacRISC3 MacRISC4
    </COMPATIBLE>
    <DESCRIPTION>
    PowerPC GNU/Linux First Stage Bootstrap
    </DESCRIPTION>
    <BOOT-SCRIPT>
    : .printf fb8-write drop ;
    : bootyaboot " Loading second stage bootstrap..." .printf 100 ms load-base release-load-area " /pci@f4000000/ata-6@d/disk@0:13,\\yaboot" $boot ;
    : bootmorphos " Booting MorphOS..." .printf 100 ms load-base release-load-area " /pci@f4000000/ata-6@d/disk@0:4,\\:tbxi" $boot ;
    : bootmacosx " Booting MacOSX..." .printf 100 ms load-base release-load-area " /pci@f4000000/ata-6@d/disk@0:6,\\:tbxi" $boot ;
    : bootcd " Booting CDROM..." .printf 100 ms load-base release-load-area " cd:,\\:tbxi" $boot ;
    " screen" output
    variable interactive
    1 interactive !

    0 interactive @ = if
    bootyaboot
    then

    dev screen
    " "(0000000000aa00aa0000aaaaaa0000aa00aaaa5500aaaaaa)" drop 0 7 set-colors
    " "(5555555555ff55ff5555ffffff5555ff55ffffff55ffffff)" drop 8 15 set-colors
    device-end
    f to foreground-color
    0 to background-color
    " "(0C)" .printf

    " First Stage Ubuntu Bootstrap"(0d 0a)" .printf
    " "(0d 0a)" .printf
    " Press l for GNU/Linux,"(0d 0a)" .printf
    " m for MorphOS,"(0d 0a)" .printf
    " x for MacOSX,"(0d 0a)" .printf
    " c for CDROM."(0d 0a)" .printf
    " "(0d 0a)" .printf
    " Stage 1 Boot: " .printf
    get-msecs d# 10 3E8 * +
    begin
    key? if
    key case
    ascii l of " l "(0d 0a)" .printf bootyaboot endof
    ascii m of " m "(0d 0a)" .printf bootmorphos endof
    ascii x of " x "(0d 0a)" .printf bootmacosx endof
    ascii c of " c "(0d 0a)" .printf bootcd endof
    endcase
    then
    dup get-msecs <
    until
    drop
    " "(0d 0a)" .printf bootyaboot
    </BOOT-SCRIPT>
    <OS-BADGE-ICONS>
    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
    </OS-BADGE-ICONS>
    </CHRP-BOOT>

    After that I reboot the mac mini. Now the mac mini boot directly in morphOS without the bootscript?!

    Maybe somebody can say in simple english (or better in german) where is my fault or what can I do that yaboot will work correctly?! PLEASE!


    [ Edited by Fixi on 2011/3/8 11:45 ]
  • »08.03.11 - 10:44
    Profile
  • Yokemate of Keyboards
    Yokemate of Keyboards
    Andreas_Wolf
    Posts: 12150 from 2003/5/22
    From: Germany
    > the mac mini boot directly in morphOS without the bootscript?!
    > [...] what can I do that yaboot will work correctly?!

    Did you properly follow boot_wb's guide step by step? Especially this:

    Quote:

    Open a CLI

    Type 'hfssetmacboot <drive>:ofboot.b' (where <drive> is the name of your mounted NewWorld boot partition). This 'blesses' the file to allow openfirmware to identify that it is bootable.


    This would be the part I pointed out to you there:
    http://www.pegasosforum.de/viewtopic.php?p=47183#p47183
  • »08.03.11 - 11:03
    Profile
  • Caterpillar
    Caterpillar
    mike-
    Posts: 21 from 2007/11/14
    From: Alpha Centauri
    Hi,

    I finally got Morphos 3.1 set up on a Powerbook g4, following this guide, mostly i got it set up tri-booting Mac os10.4 Debian squeeze and Morphos. However for the powerbook atleast i had to do the following:

    instead of :tbxi" $boot ; i used boot.img" $boot ; in ofboot.b and then blessed the file. simply copying the first yaboot line and replacing \\yaboot with boot.img did the trick.
  • »24.11.12 - 13:26
    Profile Visit Website
  • Priest of the Order of the Butterfly
    Priest of the Order of the Butterfly
    ausPPC
    Posts: 543 from 2007/8/6
    From: Pending...
    Thank you boot_wb and others - the information in this thread deserves to go into the library section along with this open firmware info -

    http://elinux.org/Flameman/openfirmware-apple#The_Apple_BIOS.2C_hardware-independent_firmware

    http://www.firmworks.com/QuickRef.html

    (provided in a response to my post in this thread - https://morph.zone/modules/newbb_plus/viewtopic.php?topic_id=8542&forum=3 )

    I now have OS X, Ubuntu 10.04 (a bit old but I already had it on a cd) and MorphOS 3.1 installed on my powerbook. Those three really didn't seem to want to co-exist but my will proved stronger. ;)
    PPC assembly ain't so bad... ;)
  • »30.01.13 - 10:45
    Profile Visit Website
  • Just looking around
    aurora72
    Posts: 20 from 2013/1/26
    From: Turkey
    What about adding FreeBSD to it? FreeBSD 's got a version for PowerPC and if you prepare 7 partitions it runs perfectly but you should best use gpart for it. In case of mystery, the 7 partitions are:

    1- Bootcode for FreeBSD
    2- / (root directory)
    3- SWAP
    4- /tmp
    5- /var
    6- /usr
    7- /home

    Actually you don't have to add /home but it's better for completeness.

    I have prepared a multi-boot MorphOS and FreeBSD harddisk on my Mac mini G4 but MorphOS install (it's called IWizard, lWizard?) didn't like this scheme of partitioning. MorphOS install gives this error:
    No HFS (Mac OS standard) partition has been found

    though I already prepared and specified a HFS partition using this guide: http://library.morph.zone/Dual-boot_MorphOS_and_MacOS_X_on_a_Mac_Mini_G4

    When I did the partitioning in Mac OS X Disk Utility, the MorphOS install didn't get stuck at this point (it was a Ubuntu - MorphOS dual boot) but partitioning for FreeBSD is a bit awkward to precisely make 10+ partitions.

    Help and advice is needed.
  • »31.01.13 - 16:05
    Profile
  • Priest of the Order of the Butterfly
    Priest of the Order of the Butterfly
    ausPPC
    Posts: 543 from 2007/8/6
    From: Pending...
    I ended up creating nine partitions to support three OSes, three of which weren't strictly necessary. But, with mac style partitioning allowing up to 16 partitions, I would still be able to fit in those seven partitions described for FreeBSD.

    After three failed attempts (one each for those three OSes) with each OS's partitioning tool, I decided to start over with OS X as it seemed unable to install if the drive had been partitioned by any other OS. Installing OS X first was no problem, Ubuntu seemed to have a mild issue allowing me to mark a partition as Newworld bootstrap and as /boot, but when I continued with the install, it seemed to figure out what to do.

    Then MorphOS... From previous attempts I'd noticed that if iWizard was going to have a problem there'd be some weird installer window resizing behaviour at the beginning of the install process. It's difficult to be sure but partitioning with OS X seems to cause the MorphOS installer partitioning tool to show double entries for each partition - even those nutty 128MB padding spaces. Clicking on any partitions results a 'bubble' message:

    Invalid partition layout!
    Valid sector range is between
    Sector x and Sector x-1.
    Maximum size is 0.
    Be aware that the Apple Partition Map
    at the start of the drive requires
    64 cylinder(s).

    Not knowing how to resolve that error, I quit the installer and went about trying to do a manual install. HDConfig displayed the partitions as expected so I chose the one I wanted to use for MorphOS, changed it to SFS and set it as bootable. I also edited the partition I wanted to use as MorphOS Boot. Then I simply copied the contents of the MorphOS install cd to the SFS partition and copied boot.img to Boot.

    I followed the instructions from the beginning of this thread to be able to boot MorphOS.

    Q Does having a bootloader like yaboot remove the need for other OSes to have individual boot partitions with their single, blessed boot files?

    I know this would prevent the Apple alt-boot menu from displaying the available OSes but, as long as yaboot can provide a menu...

    After installing MorphOS, OS X shows a requester advising that Boot should be repaired. I get the impression that OS X still thinks Boot is a HFS Extended partition even though I reformatted it in MorphOS as a plain HFS. I also created a FAT partition thinking each of the OSes would be able to mount it and that I could use it for sharing large files between them. But OS X won't mount it. I guess what might help is a decent replacement for Disk Utility...
    PPC assembly ain't so bad... ;)
  • »31.01.13 - 21:19
    Profile Visit Website
  • Just looking around
    aurora72
    Posts: 20 from 2013/1/26
    From: Turkey
    ausPPC,
    Quote:

    After installing MorphOS, OS X shows a requester advising that Boot should be repaired.


    I got the same sort of message but I fixed it after its first appearance and it no longer appears. I forgot how I've done the fix, though.
  • »31.01.13 - 21:56
    Profile
  • Priest of the Order of the Butterfly
    Priest of the Order of the Butterfly
    ausPPC
    Posts: 543 from 2007/8/6
    From: Pending...
    So far, I'm just ignoring the message because I don't trust OS X / Disk Utility et al to do anything but make one or both other OSes unbootable.
    PPC assembly ain't so bad... ;)
  • »31.01.13 - 22:47
    Profile Visit Website
  • Priest of the Order of the Butterfly
    Priest of the Order of the Butterfly
    boot_wb
    Posts: 874 from 2007/4/9
    From: Kingston upon ...
    @Ausppc

    You could get rid of the morphos boot partition by merging the boot command from bootinfo.txt into ofboot.b and copying boot.img onto the same drive as yaboot.
    OSX has no seperate boot partition.

    Jacadcaps' guide says to (in brief):
    - boot OSX install CD and partition the disk (for MorphOS & OSX) using OSX installer. (My contribution is to leave enough free space for linux unpartitioned)
    - Install OSX.
    - Boot morphOS install CD and format the MorphOS parititons using HDConfig (via iWizard 'manual' method).
    - Install MorphOS.
    - (my contrib) Boot Ubuntu/whichever-linux CD, partition empty space & install.
    This way, each OS is preparing its own partitions at least, so it should work. ;-)

    Re: the double-entries in iWizard - I've come across that bug myself. Think I just rebooted to be on the safe side before going any further, and ahven't come across it again.

    Possible fix for the 'broken partition' message in OSX:
    https://morph.zone/modules/newbb_plus/viewtopic.php?topic_id=7265&forum=3&start=9

    @Aurora72

    Rather than trying to create all partitions at once, why not just leave enough free space to allow the FreeBSD installer to create its own partitions as required? (I'm assuming it does that, I've never even tried FreeBSD).
    PS - Can't you just use mount points on root (/) for /tmp /var /usr /home thus having them on the same partition? Seven seems a bit messy!
    www.hullchimneyservices.co.uk

    UI: Powerbook 5,6 (1.67GHz, 128MB VRam): OS3.1, OSX 10.5.8
    HTPC: Mac Mini G4 (1,5GHz, 64MB VRam): OS3.1 (ZVNC)
    Audiophile: Efika 5200b (SB Audigy): OS3.1 (VNC + Virtual Monitor)

    Windows free since 2011!
  • »31.01.13 - 23:46
    Profile Visit Website