On my PowerBook I have OpenBSD and Mac OS X installed. As a FreeBSD user I also play with FreeBSD on the PowerPC.
One very disturbing issue is booting. In the Open Firmware you can configure a default boot device (usually your OS X partition) or specify one at the Open Firmware prompt like this:
# boot OpenBSD on the hard disk
boot hd:,ofwboot bsd
# boot FreeBSD on a USB disk
boot hd:,\fbsd_loader usb0/disk@1:3
If you are like me, you use OS X as your default desktop environment and Open/FreeBSD for testing and development. So every time I want to boot Open/FreeBSD I have to drop to Open Firmware and type one of the lines above.
Dario Freri shared his way of booting on the ppc@freebsd.org mailing list (inspired by OS X.
<CHRP-BOOT>
<COMPATIBLE>
MacRISC MacRISC3 MacRISC4
</COMPATIBLE>
<DESCRIPTION>
Multi-boot loader
</DESCRIPTION>
<BOOT-SCRIPT>
” screen” output
” get-key-map” ” keyboard” open-dev $call-method
dup 20 dump
5 + c@ 08 = if
” Booting FreeBSD …” cr ” boot hd:,\fbsd_loader usb0/disk@1:3” eval
else
” Booting Mac OS X…” cr ” boot hd:,\\:tbxi” eval
then
</BOOT-SCRIPT>
</CHRP-BOOT>
Create this file as /boot.tbxi on the OS X partition, set the boot-device to hd:,\boot.tbxi and re-enable the auto-boot? variable in Open Firmware:
setenv auto-boot? true
setenv boot-file hd:,\boot.tbxi
setenv boot-device hd:,\boot.tbxi
Adapting this file to OpenBSD is very easy, just change the boot hd:,\fbsd_loader line to a boot hd:,ofwboot line in /boot.tbxi.
