diff --git a/console/retroarch_console.h b/console/retroarch_console.h index 4de103b1af..9174f5d010 100644 --- a/console/retroarch_console.h +++ b/console/retroarch_console.h @@ -139,6 +139,9 @@ typedef struct char menu_border_file[PATH_MAX]; char border_file[PATH_MAX]; char border_dir[PATH_MAX]; +#ifdef HAVE_HDD_CACHE_PARTITION + char cache_dir[PATH_MAX]; +#endif char cgp_dir[PATH_MAX]; char config_file[PATH_MAX]; char core_dir[PATH_MAX]; diff --git a/console/retroarch_rzlib.c b/console/retroarch_rzlib.c index 97b9facb26..5576f0f97d 100644 --- a/console/retroarch_rzlib.c +++ b/console/retroarch_rzlib.c @@ -49,13 +49,7 @@ static int rarch_extract_currentfile_in_zip(unzFile uf) char write_filename[PATH_MAX]; #ifdef HAVE_HDD_CACHE_PARTITION - -#if defined(__CELLOS_LV2__) - snprintf(write_filename, sizeof(write_filename), "/dev_hdd1/%s", filename_inzip); -#elif defined(_XBOX) - snprintf(write_filename, sizeof(write_filename), "cache:\\%s", filename_inzip); -#endif - + snprintf(write_filename, sizeof(write_filename), "%s%s", default_paths.cache_dir, filename_inzip); #endif err = unzOpenCurrentFile(uf); diff --git a/ps3/frontend/main.c b/ps3/frontend/main.c index 082c82fb95..800aae82f9 100644 --- a/ps3/frontend/main.c +++ b/ps3/frontend/main.c @@ -187,6 +187,9 @@ static void get_environment_settings(int argc, char *argv[]) RARCH_LOG("usrDirPath : [%s].\n", default_paths.port_dir); } +#ifdef HAVE_HDD_CACHE_PARTITION + snprintf(default_paths.cache_dir, sizeof(default_paths.cache_dir), "/dev_hdd1/"); +#endif snprintf(default_paths.core_dir, sizeof(default_paths.core_dir), "%s/cores", default_paths.port_dir); snprintf(default_paths.executable_extension, sizeof(default_paths.executable_extension), ".SELF"); snprintf(default_paths.savestate_dir, sizeof(default_paths.savestate_dir), "%s/savestates", default_paths.core_dir); diff --git a/xdk/frontend/main.c b/xdk/frontend/main.c index 59c33fcf75..4d3c5ee3ba 100644 --- a/xdk/frontend/main.c +++ b/xdk/frontend/main.c @@ -99,13 +99,16 @@ static void get_environment_settings (void) } #endif -#ifdef _XBOX1 +#if defined(_XBOX1) /* FIXME: Hardcoded */ strlcpy(default_paths.config_file, "D:\\retroarch.cfg", sizeof(default_paths.config_file)); strlcpy(g_settings.system_directory, "D:\\system\\", sizeof(g_settings.system_directory)); strlcpy(default_paths.filesystem_root_dir, "D:\\", sizeof(default_paths.filesystem_root_dir)); strlcpy(default_paths.executable_extension, ".xbe", sizeof(default_paths.executable_extension)); -#else +#elif defined(_XBOX360) +#ifdef HAVE_HDD_CACHE_PARTITION + strlcpy(default_paths.cache_dir, "cache:\\", sizeof(default_paths.cache_dir)); +#endif strlcpy(default_paths.filesystem_root_dir, "game:\\", sizeof(default_paths.filesystem_root_dir)); strlcpy(default_paths.shader_file, "game:\\media\\shaders\\stock.cg", sizeof(default_paths.shader_file)); strlcpy(default_paths.config_file, "game:\\retroarch.cfg", sizeof(default_paths.config_file));