diff --git a/docs/retroarch.1 b/docs/retroarch.1 index 47a466f89a..9716ad8846 100644 --- a/docs/retroarch.1 +++ b/docs/retroarch.1 @@ -8,7 +8,7 @@ retroarch \- The reference frontend for the libretro API. .SH SYNOPSIS -\fBretroarch\fR [rom file] [OPTIONS]... +\fBretroarch\fR [rom file(s)] [OPTIONS]... .SH "DESCRIPTION" @@ -117,28 +117,11 @@ Multiple config files are delimited by ','. Every config file will be appended in order where the key-value pairs of the next config file takes priority over the old ones. .TP -\fB--gameboy PATH, -g PATH\fR -Path to a Nintendo Game Boy ROM. If this flag is set, the Super Game Boy subsystem will be activated. The Super Game Boy BIOS needs to be loaded as the normal rom. - -.TP -\fB--bsx PATH, -b PATH\fR -Path to BS-X rom. Load BS-X BIOS as the regular rom. -When using BS-X, save ram paths will be inferred from the BS-X BIOS path, not BS-X rom path. - -.TP -\fB--bsxslot PATH, -B PATH\fR -Path to BS-X slotted rom. Load BS-X BIOS as the regular rom. -When using BS-X, save ram paths will be inferred from the BS-X BIOS path, not BS-X rom path. - -.TP -\fB--sufamiA PATH\fR -Path to A slot in Sufami Turbo. Load Sufami Turbo BIOS as regular rom. -When using Sufami, save ram paths will be inferred from the Sufami BIOS path, not slot paths. - -.TP -\fB--sufamiB PATH\fR -Path to B slot in Sufami Turbo. Load Sufami Turbo BIOS as regular rom. -When using Sufami, save ram paths will be inferred from the Sufami BIOS path, not slot paths. +\fB--subsystem SUBSYSTEM\fR +Use a subsystem of the loaded libretro core. Multiple ROMs are loaded as multiple arguments. +If a ROM is skipped, use a blank ("") command line argument. +ROMs must be loaded in an order which depends on the particular subsystem used. +See verbose log output to learn how a particular subsystem wants ROMs to be loaded. .TP \fB--mouse PORT, -m PORT\fR diff --git a/file.c b/file.c index a118142f6a..2a2f6e9131 100644 --- a/file.c +++ b/file.c @@ -484,7 +484,7 @@ bool init_rom_file(void) string_list_free(roms); return false; } - + string_list_set(roms, i, temporary_rom); string_list_append(g_extern.temporary_roms, temporary_rom, attr); } } diff --git a/file_path.c b/file_path.c index d2d304557c..017f2d013a 100644 --- a/file_path.c +++ b/file_path.c @@ -211,6 +211,12 @@ bool string_list_append(struct string_list *list, const char *elem, union string return true; } +void string_list_set(struct string_list *list, unsigned index, const char *str) +{ + free(list->elems[index].data); + rarch_assert(list->elems[index].data = strdup(str)); +} + void string_list_join_concat(char *buffer, size_t size, const struct string_list *list, const char *sep) { size_t len = strlen(buffer); diff --git a/file_path.h b/file_path.h index eceadf2dae..4354696cc1 100644 --- a/file_path.h +++ b/file_path.h @@ -61,6 +61,7 @@ struct string_list *string_list_new(void); bool string_list_append(struct string_list *list, const char *elem, union string_list_elem_attr attr); void string_list_free(struct string_list *list); void string_list_join_concat(char *buffer, size_t size, const struct string_list *list, const char *sep); +void string_list_set(struct string_list *list, unsigned index, const char *str); bool path_is_directory(const char *path); bool path_file_exists(const char *path); diff --git a/retroarch.c b/retroarch.c index ccf5b90947..0d0c519818 100644 --- a/retroarch.c +++ b/retroarch.c @@ -776,11 +776,10 @@ static void print_help(void) #ifdef HAVE_DYNAMIC puts("\t-L/--libretro: Path to libretro implementation. Overrides any config setting."); #endif - puts("\t-g/--gameboy: Path to Gameboy ROM. Load SuperGameBoy as the regular rom."); - puts("\t-b/--bsx: Path to BSX rom. Load BSX BIOS as the regular rom."); - puts("\t-B/--bsxslot: Path to BSX slotted rom. Load BSX BIOS as the regular rom."); - puts("\t--sufamiA: Path to A slot of Sufami Turbo. Load Sufami base cart as regular rom."); - puts("\t--sufamiB: Path to B slot of Sufami Turbo."); + puts("\t--subsystem: Use a subsystem of the libretro core. Multiple ROMs are loaded as multiple arguments."); + puts("\t\tIf a ROM is skipped, use a blank (\"\") command line argument"); + puts("\t\tROMs must be loaded in an order which depends on the particular subsystem used."); + puts("\t\tSee verbose log output to learn how a particular subsystem wants ROMs to be loaded."); printf("\t-N/--nodevice: Disconnects controller device connected to port (1 to %d).\n", MAX_PLAYERS); printf("\t-A/--dualanalog: Connect a DualAnalog controller to port (1 to %d).\n", MAX_PLAYERS);