Remove completely obsoleted "XML map" support.

This is from ancient times and no longer relevant.
This commit is contained in:
Themaister 2014-01-02 16:01:43 +01:00
parent b57dd76478
commit a60d49293b
4 changed files with 4 additions and 33 deletions

View File

@ -270,11 +270,6 @@ Note that RetroArch cannot perform any error checking if patching was successful
\fB--no-patch\fR
Disables all kinds of ROM patching.
.TP
\fB--xml MAP, -X MAP\fR
Specifies path to XML memory map for the given ROM.
If this flag is not specified, RetroArch will look for a .xml file with same basename as ROM specified.
.TP
\fB-D, --detach\fR
Detach from the current console. This is currently only relevant for Microsoft Windows.

20
file.c
View File

@ -362,18 +362,6 @@ void save_ram_file(const char *path, int type)
}
}
static char *load_xml_map(const char *path)
{
char *xml_buf = NULL;
if (*path)
{
if (read_file_string(path, &xml_buf))
RARCH_LOG("Found XML memory map in \"%s\"\n", path);
}
return xml_buf;
}
#define MAX_ROMS 4
static bool load_roms(unsigned rom_type, const char **rom_paths, size_t roms)
@ -388,9 +376,8 @@ static bool load_roms(unsigned rom_type, const char **rom_paths, size_t roms)
return false;
void *rom_buf[MAX_ROMS] = {NULL};
ssize_t rom_len[MAX_ROMS] = {0};
long rom_len[MAX_ROMS] = {0};
struct retro_game_info info[MAX_ROMS] = {{NULL}};
char *xml_buf = load_xml_map(g_extern.xml_name);
if (!g_extern.system.info.need_fullpath)
{
@ -410,7 +397,7 @@ static bool load_roms(unsigned rom_type, const char **rom_paths, size_t roms)
info[0].path = rom_paths[0];
info[0].data = rom_buf[0];
info[0].size = rom_len[0];
info[0].meta = xml_buf;
info[0].meta = NULL; // Not relevant at this moment.
for (i = 1; i < roms; i++)
{
@ -426,6 +413,7 @@ static bool load_roms(unsigned rom_type, const char **rom_paths, size_t roms)
info[i].path = rom_paths[i];
info[i].data = rom_buf[i];
info[i].size = rom_len[i];
info[i].meta = NULL;
}
if (rom_type == 0)
@ -439,8 +427,6 @@ static bool load_roms(unsigned rom_type, const char **rom_paths, size_t roms)
end:
for (i = 0; i < MAX_ROMS; i++)
free(rom_buf[i]);
free(xml_buf);
return ret;
}

View File

@ -379,7 +379,6 @@ struct global
char savefile_name_asrm[PATH_MAX];
char savefile_name_bsrm[PATH_MAX];
char savestate_name[PATH_MAX];
char xml_name[PATH_MAX];
// Used on reentrancy to use a savestate dir.
char savefile_dir[PATH_MAX];

View File

@ -750,7 +750,6 @@ static void print_help(void)
puts("\t--bps: Specifies path for BPS patch that will be applied to ROM.");
puts("\t--ips: Specifies path for IPS patch that will be applied to ROM.");
puts("\t--no-patch: Disables all forms of rom patching.");
puts("\t-X/--xml: Specifies path to XML memory map.");
puts("\t-D/--detach: Detach RetroArch from the running console. Not relevant for all platforms.\n");
}
@ -858,7 +857,6 @@ static void parse_input(int argc, char *argv[])
{ "bps", 1, &val, 'B' },
{ "ips", 1, &val, 'I' },
{ "no-patch", 0, &val, 'n' },
{ "xml", 1, NULL, 'X' },
{ "detach", 0, NULL, 'D' },
{ "features", 0, &val, 'f' },
{ NULL, 0, NULL, 0 }
@ -888,7 +886,7 @@ static void parse_input(int argc, char *argv[])
#define BSV_MOVIE_ARG
#endif
const char *optstring = "hs:fvS:m:p4jJA:g:b:c:B:Y:Z:U:DN:X:" BSV_MOVIE_ARG NETPLAY_ARG DYNAMIC_ARG FFMPEG_RECORD_ARG;
const char *optstring = "hs:fvS:m:p4jJA:g:b:c:B:Y:Z:U:DN:" BSV_MOVIE_ARG NETPLAY_ARG DYNAMIC_ARG FFMPEG_RECORD_ARG;
for (;;)
{
@ -1071,10 +1069,6 @@ static void parse_input(int argc, char *argv[])
g_extern.ups_pref = true;
break;
case 'X':
strlcpy(g_extern.xml_name, optarg, sizeof(g_extern.xml_name));
break;
case 'D':
#if defined(_WIN32) && !defined(_XBOX)
FreeConsole();
@ -1879,9 +1873,6 @@ static void fill_pathnames(void)
if (!(*g_extern.ips_name))
fill_pathname_noext(g_extern.ips_name, g_extern.basename, ".ips", sizeof(g_extern.ips_name));
if (!(*g_extern.xml_name))
fill_pathname_noext(g_extern.xml_name, g_extern.basename, ".xml", sizeof(g_extern.xml_name));
}
}