It annoyed me that it was now quicker to burn a NetBSD/dreamcast CD on a Windows box than a *ix box, so tonight I decided to address that.
A fair number of years ago Marcus Comstedt write a number of very handy Dreamcast development tools, including a couple of utilities to generate a Dreamcast bootloader and then process a binary suitable for use with that bootloader ('makeip' and 'scramble' from http://mc.pp.se/dc/sw.html)
All I needed to do was wrap them in a little shell script, throw in a call to mkisofs to create an iso9660 CD filesystem and cdrecord to write and and I was done.
Then the creatures started feeping.
- Obviously it would be convenient if the script could download the necessary kernel files from ftp.netbsd.org automatically, but you should also be able to point it at a locally built kernel
- If downloading the version should be selectable
- Selection of a plain GENERIC or GENERIC plus ramdisk be possible
- As a final bonus it should be able to download a complete NetBSD distribution, extract and burn it onto the CD as the root filesystem
... and finally the feeping stopped.
I can now say I've run a Dreamcast with an iso9660 (rockridge) root filesystem. Its not exactly fast, and you would really want to union mount some ramdisks over /var and suchlike to even consider trying to take it multiuser, but it works :)
% dc-burn-netbsd -h
Usage: dc-burn-netbsd [opts]
-C : Clean work directory before starting
-c opts : Set cdrecord opts (driveropts=burnfree gracetime=3)
-d : Take kernel/ & sets/ under datadir - no downloading
-h : This help
-k type : Set kernel type (GENERIC_MD) eg: GENERIC or GENERIC_MD
-n : Generate data but do not write (just display cdrecord commands)
-r : Include full NetBSD release on CD
-t tmpd : Set temporary work directory to tmpd
-v vers : Set NetBSD version (6.0_BETA2) eg: 5.1 6.0_BETA2
dc-burn will create a temporary work directory dc-burn-netbsd-files which will
need to have sufficient space to store the downloaded & generated files.
if -d is used the directory is expected to match the layout on ftp.netbsd.org:
- kernel/netbsd-$type.bin.gz, and
- sets/base.tgz (etc - if -r given)