diff --git a/README.md b/README.md index aee44fd..623c639 100644 --- a/README.md +++ b/README.md @@ -1,10 +1,10 @@ -# iplboot +# gekkoboot A utilitarian bootloader for the GameCube ## Usage -iplboot will attempt to load DOLs from the following locations in order: +gekkoboot will attempt to load DOLs from the following locations in order: - USB Gecko in Card Slot B - SD Gecko in Card Slot B - USB Gecko in Card Slot A @@ -12,7 +12,7 @@ iplboot will attempt to load DOLs from the following locations in order: - SD2SP2 You can use button shortcuts to keep alternate software on quick access. -When loading from an SD card, iplboot will look for and load different filenames +When loading from an SD card, gekkoboot will look for and load different filenames depending on what buttons are being held: Button Held | File Loaded @@ -27,12 +27,12 @@ depending on what buttons are being held: CLI files are also supported. -If the selected shortcut file cannot be loaded, iplboot will fall back to +If the selected shortcut file cannot be loaded, gekkoboot will fall back to `/ipl.dol`. If that cannot be loaded either, the next device will be searched. -If all fails, iplboot will reboot to the onboard IPL (original GameCube intro +If all fails, gekkoboot will reboot to the onboard IPL (original GameCube intro and menu). -Holding D-Pad Left or the reset button will skip iplboot functionality and +Holding D-Pad Left or the reset button will skip gekkoboot functionality and reboot straight into the onboard IPL. For example, this configuration would boot straight into Swiss by default, @@ -52,7 +52,7 @@ If you hold multiple buttons, the highest in the table takes priority. Be careful not to touch any of the analog controls (sticks and triggers) when powering on as this is when they are calibrated. -iplboot also acts as a server for @emukidid's [usb-load](https://github.com/emukidid/gc-usb-load), +gekkoboot also acts as a server for @emukidid's [usb-load](https://github.com/emukidid/gc-usb-load), should you want to use it for development purposes. **Something not working?** See the [troubleshooting section](#troubleshooting). @@ -67,11 +67,11 @@ according the table above. ### PicoBoot -iplboot is bundled with the [PicoBoot] firmware. +gekkoboot is bundled with the [PicoBoot] firmware. Just follow the [installation guide][pb-install]. -You can also update iplboot separately from the PicoBoot firmware, -using the supplied `iplboot_pico.uf2` (depends on [PicoBoot PR 107][pb-pr-107]). +You can also update gekkoboot separately from the PicoBoot firmware, +using the supplied `gekkoboot_pico.uf2` (depends on [PicoBoot PR 107][pb-pr-107]). [PicoBoot]: https://github.com/webhdx/PicoBoot [pb-install]: https://github.com/webhdx/PicoBoot/wiki/Installation-guide @@ -79,15 +79,15 @@ using the supplied `iplboot_pico.uf2` (depends on [PicoBoot PR 107][pb-pr-107]). ### Qoob -Qoob Pro only: use the Qoob USB flash utility to install `iplboot_qoob_pro.gcb` +Qoob Pro only: use the Qoob USB flash utility to install `gekkoboot_qoob_pro.gcb` as a BIOS like you normally would. A modified copy of the updater is also provided for both versions of the Qoob. It can be run via Swiss, or the original Qoob BIOS, from an ISO9660 DVD or over the nework using a Broadband Adapter[^qoob-bba]. -The updater files are `qoob_pro_iplboot_upgrade.elf` and -`qoob_sx_iplboot_upgrade.elf` respectively. +The updater files are `qoob_pro_gekkoboot_upgrade.elf` and +`qoob_sx_gekkoboot_upgrade.elf` respectively. When burning them to a disc, you may need to pad the image with a large (~1GiB) file, to ensure the drive can read it properly. @@ -100,7 +100,7 @@ This means that a DVD drive or a BBA is required to flash anyting to a Qoob SX.\ If this is inconvenient, consider upgrading to PicoBoot. > [!TIP] -> Alternatively, if iplboot is already installed, or you have access to another +> Alternatively, if gekkoboot is already installed, or you have access to another > boot method, you can disconnect the modchip from its cable and reconnect it > while the system is running. > This will disable write protection, and you can run the updater from there. @@ -109,15 +109,15 @@ If this is inconvenient, consider upgrading to PicoBoot. ### ViperGC -Flash `iplboot_viper.vgc` as a BIOS like you normally would. +Flash `gekkoboot_viper.vgc` as a BIOS like you normally would. The hardware flasher is recommended, as it will be impossible to reflash the -Viper without it once iplboot is installed. +Viper without it once gekkoboot is installed. If you've lost it, consider upgrading to PicoBoot. ### GameCube Memory Card -Copy `iplboot_memcard.gci` to a memory card using [GCMM] or Swiss. +Copy `gekkoboot_memcard.gci` to a memory card using [GCMM] or Swiss. It will be saved as `boot.dol` and can be used in conjunction with the various [game save exploits](https://www.gc-forever.com/wiki/index.php?title=Booting_homebrew#Game_Save_Exploits). @@ -126,24 +126,24 @@ It will be saved as `boot.dol` and can be used in conjunction with the various ## Troubleshooting -iplboot displays useful diagnostic messages as it attempts to load the selected DOL. +gekkoboot displays useful diagnostic messages as it attempts to load the selected DOL. But it's so fast you may not have time to read or even see them. If you hold the down direction on the D-Pad, the messages will remain on screen until you let go. When choosing a shortcut button, beware that some software checks for buttons held at boot to alter certain behaviors. -If your software behaves differently when booted through iplboot, ensure the +If your software behaves differently when booted through gekkoboot, ensure the assigned shortcut button is not used in this way. For example, it is not recommended to assign Swiss to the B button as holding B causes Swiss to disable the DVD drive. -Also on Qoob SX, the "backup" BIOS will run before iplboot, so it may interfere +Also on Qoob SX, the "backup" BIOS will run before gekkoboot, so it may interfere with some shortcuts. ## Compiling -You should only need to compile iplboot if you want to modify to the source +You should only need to compile gekkoboot if you want to modify to the source code. Otherwise, you can just download prebuilt binaries from the releases tab. @@ -165,7 +165,7 @@ Note: on Windows, you'll want to install all the dependencies inside of MSYS2. ```console # Clone this repo -$ git clone https://github.com/redolution/iplboot.git +$ git clone https://github.com/redolution/gekkoboot.git # Ensure devkitPPC is in PATH $ export PATH="$DEVKITPPC/bin:$PATH" @@ -179,12 +179,12 @@ $ meson compile -C build # The binaries will be in the build directory $ ls build ... -iplboot_memcard.gci -iplboot_pico.uf2 -iplboot_qoob_pro.gcb -iplboot_viper.vgc -qoob_pro_iplboot_upgrade.elf -qoob_sx_iplboot_upgrade.elf +gekkoboot_memcard.gci +gekkoboot_pico.uf2 +gekkoboot_qoob_pro.gcb +gekkoboot_viper.vgc +qoob_pro_gekkoboot_upgrade.elf +qoob_sx_gekkoboot_upgrade.elf ... ``` @@ -194,7 +194,7 @@ Qoob Pro requires BS1 (early initialization code) from the original bootrom. This can be obtained from an existing Qoob Pro BIOS or any IPL dump. To use an existing Qoob Pro BIOS (easiest method), -grab `iplboot_qoob_pro.gcb` from the [latest release]. +grab `gekkoboot_qoob_pro.gcb` from the [latest release]. Alternatively, you can dump the IPL ROM from your own GameCube using Swiss: 1. Ensure file management is enabled in Swiss settings: press B, select the gear @@ -212,4 +212,4 @@ You should now have a suitable IPL ROM. 1. The output should now say `Qoob Pro support: YES`. 1. Continue building normally. -[latest release]: https://github.com/redolution/iplboot/releases/latest +[latest release]: https://github.com/redolution/gekkoboot/releases/latest diff --git a/buildtools/dol2ipl.py b/buildtools/dol2ipl.py index a253de6..ef07f41 100755 --- a/buildtools/dol2ipl.py +++ b/buildtools/dol2ipl.py @@ -139,7 +139,7 @@ def main(): print("Unknown input format") return -1 - qoob_header = bytearray(b"(C) iplboot".ljust(256, b"\x00")) + qoob_header = bytearray(b"(C) gekkoboot".ljust(256, b"\x00")) if output.endswith(".gcb"): if len(sys.argv) < 4: @@ -174,7 +174,7 @@ def main(): print("Invalid entry point and base address (must be 0x81300000)") return -1 - header = b"VIPR\x00\x02".ljust(16, b"\x00") + b"iplboot".ljust(16, b"\x00") + header = b"VIPR\x00\x02".ljust(16, b"\x00") + b"gekkoboot".ljust(16, b"\x00") out = header + scramble(bytearray(0x720) + img)[0x720:] elif output.endswith(".uf2"): diff --git a/buildtools/qoob_injector.py b/buildtools/qoob_injector.py index 1374e67..394be55 100755 --- a/buildtools/qoob_injector.py +++ b/buildtools/qoob_injector.py @@ -18,7 +18,7 @@ if len(img) > 128 * 1024: raise "Qoob Pro BIOS image too big to fit in flasher" - msg = b"QOOB Pro iplboot install\0" + msg = b"gekkoboot for QOOB Pro\0" msg_offset = 0x1A68 img_offset = 0x1AE0 @@ -26,7 +26,7 @@ if len(img) > 62800: raise "Qoob SX BIOS image too big to fit in flasher" - msg = b"QOOB SX iplboot install\0" + msg = b"gekkoboot for QOOB SX\0" msg_offset = 7240 img_offset = 7404 diff --git a/flake.nix b/flake.nix index e9c6b0f..866f5f7 100644 --- a/flake.nix +++ b/flake.nix @@ -41,7 +41,7 @@ , p7zip , python3 }: mkShell { - name = "iplboot"; + name = "gekkoboot"; nativeBuildInputs = [ # The cross toolchain devkitPPC diff --git a/meson.build b/meson.build index 4457a70..d9c4a3a 100644 --- a/meson.build +++ b/meson.build @@ -1,5 +1,5 @@ project( - 'iplboot', + 'gekkoboot', ['c', 'cpp'], meson_version: '>=1.2', default_options: { @@ -48,8 +48,8 @@ font = custom_target( command: [psf2c, '@INPUT@', '@OUTPUT@', 'console_font_8x16'], ) -iplboot = executable( - 'iplboot', +gekkoboot = executable( + 'gekkoboot', 'source/main.c', 'source/utils.c', 'source/fatfs/ff.c', @@ -67,15 +67,15 @@ iplboot = executable( name_suffix: 'elf', ) compressed_exes += { - 'iplboot': { - 'exe': iplboot, + 'gekkoboot': { + 'exe': gekkoboot, 'link_args': [ '-Wl,--section-start,.init=0x01300000' ], 'dol': true, }, - 'iplboot_sx': { - 'exe': iplboot, + 'gekkoboot_sx': { + 'exe': gekkoboot, 'link_args': [ # This is the same entry point as the original BIOS, # but the recovery slot hangs on "starting flashed app..." @@ -86,8 +86,8 @@ compressed_exes += { '-Wl,--nmagic', ], }, - 'iplboot_lowmem': { - 'exe': iplboot, + 'gekkoboot_lowmem': { + 'exe': gekkoboot, 'dol': true, }, } @@ -108,8 +108,8 @@ endforeach if full_rom_opt.allowed() qoob_pro = custom_target( 'qoob_pro', - input: [iplboot_dol, ipl_rom], - output: 'iplboot_qoob_pro.gcb', + input: [gekkoboot_dol, ipl_rom], + output: 'gekkoboot_qoob_pro.gcb', command: [dol2ipl, '@OUTPUT@', '@INPUT@'], build_by_default: true, install: true, @@ -118,7 +118,7 @@ if full_rom_opt.allowed() qoob_pro_updater_tgt = custom_target( 'qoob_pro_updater', input: [qoob_pro, qoob_pro_updater], - output: 'qoob_pro_iplboot_upgrade.elf', + output: 'qoob_pro_gekkoboot_upgrade.elf', command: [qoob_injector, '@INPUT@', '@OUTPUT@'], build_by_default: true, install: true, @@ -126,22 +126,22 @@ if full_rom_opt.allowed() ) endif -iplboot_sx_stripped = custom_target( - iplboot_sx_compressed.name() + '_stripped', - input: iplboot_sx_compressed, - output: iplboot_sx_compressed.name() + '_stripped.elf', +gekkoboot_sx_stripped = custom_target( + gekkoboot_sx_compressed.name() + '_stripped', + input: gekkoboot_sx_compressed, + output: gekkoboot_sx_compressed.name() + '_stripped.elf', command: [objcopy, '-S', '@INPUT@', '@OUTPUT@'], ) qoob_sx = custom_target( 'qoob_sx', - input: iplboot_sx_stripped, - output: 'iplboot_qoob_sx.qbsx', + input: gekkoboot_sx_stripped, + output: 'gekkoboot_qoob_sx.qbsx', command: [dol2ipl, '@OUTPUT@', '@INPUT@'], ) qoob_sx_updater_tgt = custom_target( 'qoob_sx_updater', input: [qoob_sx, qoob_sx_updater], - output: 'qoob_sx_iplboot_upgrade.elf', + output: 'qoob_sx_gekkoboot_upgrade.elf', command: [qoob_injector, '@INPUT@', '@OUTPUT@'], build_by_default: true, install: true, @@ -150,8 +150,8 @@ qoob_sx_updater_tgt = custom_target( viper = custom_target( 'viper', - input: iplboot_dol, - output: 'iplboot_viper.vgc', + input: gekkoboot_dol, + output: 'gekkoboot_viper.vgc', command: [dol2ipl, '@OUTPUT@', '@INPUT@'], build_by_default: true, install: true, @@ -160,8 +160,8 @@ viper = custom_target( pico = custom_target( 'pico', - input: iplboot_dol, - output: 'iplboot_pico.uf2', + input: gekkoboot_dol, + output: 'gekkoboot_pico.uf2', command: [dol2ipl, '@OUTPUT@', '@INPUT@'], build_by_default: true, install: true, @@ -170,8 +170,8 @@ pico = custom_target( gci = custom_target( 'gci', - input: iplboot_lowmem_dol, - output: 'iplboot_memcard.gci', + input: gekkoboot_lowmem_dol, + output: 'gekkoboot_memcard.gci', command: [dol2gci, '@INPUT@', '@OUTPUT@', 'boot.dol'], build_by_default: true, install: true, diff --git a/release.sh b/release.sh index 7839ad6..c327d17 100755 --- a/release.sh +++ b/release.sh @@ -4,10 +4,10 @@ set -e distdir=$PWD/dist builddir=$distdir/build -destdir=$distdir/iplboot +destdir=$distdir/gekkoboot version=$(git describe --always --tags --dirty) -distfile=iplboot-$version.zip +distfile=gekkoboot-$version.zip rm -rf "$distdir" "$distfile" diff --git a/source/main.c b/source/main.c index 50e7071..c31808b 100644 --- a/source/main.c +++ b/source/main.c @@ -361,7 +361,7 @@ int main() VIDEO_WaitVSync(); CON_Init(__xfb, 0, 0, rmode->fbWidth, rmode->xfbHeight, rmode->fbWidth * VI_DISPLAY_PIX_SZ); - kprintf("\n\niplboot %s\n", version); + kprintf("\n\ngekkoboot %s\n", version); // Disable Qoob u32 val = 6 << 24;