diff options
Diffstat (limited to 'tools')
| -rwxr-xr-x | tools/gbdemo | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/tools/gbdemo b/tools/gbdemo index 956c9f3..a45c935 100755 --- a/tools/gbdemo +++ b/tools/gbdemo @@ -130,12 +130,14 @@ def hub_type(payload: bytes): def v_spawn(args): nohub = "--nohub" in args # offline: no link (script smoke-tests) args = [a for a in args if a != "--nohub"] - # bare --bios: resolve the emulator's default boot ROM to an absolute path - # (the tmux pane's cwd is wherever the user happens to be) + # bare --bios: resolve to an absolute path (the tmux pane's cwd is wherever + # the user happens to be). Prefer our forked SL0PBOY boot ROM if present. if "--bios" in args: i = args.index("--bios") if i + 1 >= len(args) or args[i + 1].startswith("-"): - args.insert(i + 1, os.path.join(GBC, "bios/gbc_bios.bin")) + fork = os.path.join(GBC, "bios/sl0pboy_bios.bin") + stock = os.path.join(GBC, "bios/gbc_bios.bin") + args.insert(i + 1, fork if os.path.exists(fork) else stock) if not nohub and not os.path.exists(HUB): die("no hub at %s - start it first: sudo tools/gbhub --daemon" % HUB) rom = "/tmp/gbdemo_%d.gb" % os.getpid() # private copy: no .sav clashes |
