diff --git a/neo/sys/linux/main.cpp b/neo/sys/linux/main.cpp index d4b52b08..01cb25fb 100644 --- a/neo/sys/linux/main.cpp +++ b/neo/sys/linux/main.cpp @@ -65,7 +65,9 @@ bool Sys_GetPath(sysPath_t type, idStr &path) { // try next to the executable.. if (Sys_GetPath(PATH_EXE, path)) { path = path.StripFilename(); - if (stat(path.c_str(), &st) != -1 && S_ISDIR(st.st_mode)) { + // the path should have a base dir in it, otherwise it probably just contains the executable + idStr testPath = path + "/" BASE_GAMEDIR; + if (stat(testPath.c_str(), &st) != -1 && S_ISDIR(st.st_mode)) { common->Warning("using path of executable: %s", path.c_str()); return true; } else { @@ -75,7 +77,7 @@ bool Sys_GetPath(sysPath_t type, idStr &path) { // fallback to vanilla doom3 install if (stat(LINUX_DEFAULT_PATH, &st) != -1 && S_ISDIR(st.st_mode)) { - common->Warning("using hardcoded default base path"); + common->Warning("using hardcoded default base path: " LINUX_DEFAULT_PATH); path = LINUX_DEFAULT_PATH; return true;