Add a --root= command line argument to override what host0: is mounted to.

Fixes #20191
This commit is contained in:
Henrik Rydgård committed 2026-01-06 20:41:35 +01:00
1 parent 656db38ebc
commit b64d7b217f
4 files changed
+9 -2

No files matched your search

+2
View File
@@ -662,6 +662,8 @@ public:
Path internalDataDirectory;
Path appCacheDirectory;
Path mountRoot; // Actually, mount as host0. keeping consistent with headless args.
void Load(const char *iniFileName = nullptr, const char *controllerIniFilename = nullptr);
bool Save(const char *saveReason);
void Reload();
+1 -1
View File
@@ -451,7 +451,7 @@ static u32 sceMpegRingbufferConstruct(u32 ringbufferAddr, u32 numPackets, u32 da
if (ring->semaID != 0) {
// I'm starting to think this is just padding or something.
// It's not written by this function.
WARN_LOG(Log::Mpeg, "Detected semaID %d", ring->semaID);
WARN_LOG(Log::Mpeg, "Detected 'semaID' (might not be) %d (%08x)", ring->semaID, ring->semaID);
}
ring->mpeg = 0;
// This isn't in ver 0104, but it is in 0105.
+1 -1
View File
@@ -306,7 +306,7 @@ void EmuScreen::ProcessGameBoot(const Path &filename) {
coreParam.enableSound = g_Config.bEnableSound;
coreParam.fileToStart = filename;
coreParam.mountIso.clear();
coreParam.mountRoot.clear();
coreParam.mountRoot = g_Config.mountRoot;
coreParam.startBreak = !g_Config.bAutoRun;
coreParam.headLess = false;
+5
View File
@@ -530,6 +530,8 @@ void NativeInit(int argc, const char *argv[], const char *savegame_dir, const ch
forceLogLevel = true;
};
// TODO: Need a much better command line argument parser.
for (int i = 1; i < argc; i++) {
if (argv[i][0] == '-') {
#if defined(__APPLE__)
@@ -581,6 +583,9 @@ void NativeInit(int argc, const char *argv[], const char *savegame_dir, const ch
g_Config.iForceFullScreen = 1;
System_ToggleFullscreenState("1");
}
if (!strncmp(argv[i], "--root=", strlen("--root=")) && strlen(argv[i]) > strlen("--root=")) {
g_Config.mountRoot = Path(argv[i] + strlen("--root="));
}
if (!strcmp(argv[i], "--windowed")) {
g_Config.iForceFullScreen = 0;
System_ToggleFullscreenState("0");