1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
|
From 99e82d0644fee9a21e967b7b8708ff253e7528d5 Mon Sep 17 00:00:00 2001
From: Jan Cholasta <jan@cholasta.net>
Date: Tue, 25 Feb 2020 12:53:07 +0100
Subject: [PATCH] Fix file paths
---
src/common/platform/posix/sdl/i_main.cpp | 14 +-------------
src/gameconfigfile.cpp | 10 ++--------
2 files changed, 3 insertions(+), 21 deletions(-)
diff --git a/src/common/platform/posix/sdl/i_main.cpp b/src/common/platform/posix/sdl/i_main.cpp
index a28b90f01..7299029fd 100644
--- a/src/common/platform/posix/sdl/i_main.cpp
+++ b/src/common/platform/posix/sdl/i_main.cpp
@@ -175,19 +175,7 @@ int main (int argc, char **argv)
Args = new FArgs(argc, argv);
// Should we even be doing anything with progdir on Unix systems?
- char program[PATH_MAX];
- if (realpath (argv[0], program) == NULL)
- strcpy (program, argv[0]);
- char *slash = strrchr (program, '/');
- if (slash != NULL)
- {
- *(slash + 1) = '\0';
- progdir = program;
- }
- else
- {
- progdir = "./";
- }
+ progdir = "/usr/lib/gzdoom/";
I_StartupJoysticks();
diff --git a/src/gameconfigfile.cpp b/src/gameconfigfile.cpp
index 17898f3ae..7bfb63205 100644
--- a/src/gameconfigfile.cpp
+++ b/src/gameconfigfile.cpp
@@ -119,8 +119,6 @@ FGameConfigFile::FGameConfigFile ()
// Arch Linux likes them in /usr/share/doom
// Debian likes them in /usr/share/games/doom
// I assume other distributions don't do anything radically different
- SetValueForKey ("Path", "/usr/local/share/doom", true);
- SetValueForKey ("Path", "/usr/local/share/games/doom", true);
SetValueForKey ("Path", "/usr/share/doom", true);
SetValueForKey ("Path", "/usr/share/games/doom", true);
#endif
@@ -141,8 +139,6 @@ FGameConfigFile::FGameConfigFile ()
SetValueForKey ("Path", "$HOME/" GAME_DIR, true);
SetValueForKey ("Path", "$HOME/.local/share/games/doom", true);
SetValueForKey ("Path", SHARE_DIR, true);
- SetValueForKey ("Path", "/usr/local/share/doom", true);
- SetValueForKey ("Path", "/usr/local/share/games/doom", true);
SetValueForKey ("Path", "/usr/share/doom", true);
SetValueForKey ("Path", "/usr/share/games/doom", true);
#endif
@@ -170,10 +166,8 @@ FGameConfigFile::FGameConfigFile ()
SetValueForKey("Path", "$HOME/" GAME_DIR "/fm_banks", true);
SetValueForKey("Path", "$HOME/.local/share/games/doom/soundfonts", true);
SetValueForKey("Path", "$HOME/.local/share/games/doom/fm_banks", true);
- SetValueForKey("Path", "/usr/local/share/doom/soundfonts", true);
- SetValueForKey("Path", "/usr/local/share/doom/fm_banks", true);
- SetValueForKey("Path", "/usr/local/share/games/doom/soundfonts", true);
- SetValueForKey("Path", "/usr/local/share/games/doom/fm_banks", true);
+ SetValueForKey("Path", "/usr/share/" GAMENAMELOWERCASE "/soundfonts", true);
+ SetValueForKey("Path", "/usr/share/" GAMENAMELOWERCASE "/fm_banks", true);
SetValueForKey("Path", "/usr/share/doom/soundfonts", true);
SetValueForKey("Path", "/usr/share/doom/fm_banks", true);
SetValueForKey("Path", "/usr/share/games/doom/soundfonts", true);
--
2.34.1
|