]> git.pld-linux.org Git - packages/doomlegacy.git/blame - doomlegacy-paths.patch
- build on x32
[packages/doomlegacy.git] / doomlegacy-paths.patch
CommitLineData
746b6f37 1--- doomlegacy_142_src/linux_x/musserv/musserver.c.orig Sat Feb 22 20:51:24 2003
2+++ doomlegacy_142_src/linux_x/musserv/musserver.c Sat Feb 22 20:52:15 2003
24b824db 3@@ -122,9 +122,7 @@
4 ppid = getpid();
5 if (verbose > 1)
6 printf("pid %d %s\n", ppid, pproc);
7- waddir = getenv("DOOMWADDIR");
8- if (waddir == NULL)
9- waddir = ".";
10+ waddir = getenv("DOOMWADDIR") ? getenv("DOOMWADDIR") : "/usr/share/doomlegacy";
11
12 while ((x = getopt(argc, argv, "acd:fhi:lmt:u:Vv")) != -1)
13 switch (x)
746b6f37 14--- doomlegacy_142_src/linux_x/musserv/readwad.c.orig Sat Feb 22 20:52:25 2003
15+++ doomlegacy_142_src/linux_x/musserv/readwad.c Sat Feb 22 20:53:03 2003
24b824db 16@@ -213,7 +213,7 @@
17 FILE *fp;
18
19 if (!(waddir = getenv("DOOMWADDIR")))
20- waddir = ".";
860e57e2 21+ waddir = "/usr/share/doomlegacy";
24b824db 22
23 wadfilename = malloc(2 + strlen(s) + strlen(waddir));
24 if (*s != '/')
746b6f37 25--- doomlegacy_142_src/linux_x/i_video_xshm.c.orig Sat Feb 22 20:45:02 2003
26+++ doomlegacy_142_src/linux_x/i_video_xshm.c Sat Feb 22 20:46:49 2003
24b824db 27@@ -1984,7 +1984,7 @@
28 rendermode = render_opengl;
29
30 // try to open library in CWD
31- dlptr = dlopen("./r_opengl.so",RTLD_NOW | RTLD_GLOBAL);
860e57e2 32+ dlptr = dlopen("/usr/lib/doomlegacy/r_opengl.so",RTLD_NOW | RTLD_GLOBAL);
24b824db 33
34 if(!dlptr) {
35 // try to open in LIBPATH
746b6f37 36--- doomlegacy_142_src/linux_x/i_system.c.orig Sat Feb 22 20:48:37 2003
37+++ doomlegacy_142_src/linux_x/i_system.c Sat Feb 22 20:50:55 2003
24b824db 38@@ -141,9 +141,9 @@
39 extern int eventtail;
40
41 // Locations for searching the legacy.dat
42-#define DEFAULTWADLOCATION1 "/usr/local/games/legacy"
43-#define DEFAULTWADLOCATION2 "/usr/games/legacy"
44-#define DEFAULTSEARCHPATH1 "/usr/local"
45+#define DEFAULTWADLOCATION1 "/usr/share/doomlegacy"
46+#define DEFAULTWADLOCATION2 "/usr/share/games/doomlegacy"
47+#define DEFAULTSEARCHPATH1 "/usr/share/games/"
48 #define DEFAULTSEARCHPATH2 "/usr/games"
49 #define WADKEYWORD "legacy.dat"
50
746b6f37 51--- doomlegacy_142_src/linux_x/searchp.c.orig Sat Feb 22 20:53:41 2003
52+++ doomlegacy_142_src/linux_x/searchp.c Sat Feb 22 20:54:22 2003
24b824db 53@@ -22,6 +22,12 @@
54 static char b[2048];
55 struct stat s;
56 char pb[2048];
57+
860e57e2 58+ strcpy(b,"/usr/lib/doomlegacy/");
24b824db 59+ strcat(b,file);
60+ if (stat(b, &s) == 0) {
61+ return(b);
62+ }
63
64 /* get PATH, if not set just return filename, might be in cwd */
65 /* added "./" for current path 19990416 by Kin */
0a49077e
ER
66--- doomlegacy-1.44/d_main.c~ 2010-09-20 23:00:51.000000000 +0300
67+++ doomlegacy-1.44/d_main.c 2011-01-20 02:38:22.202123940 +0200
68@@ -1264,11 +1264,7 @@
69 char *doomwaddir = getenv("DOOMWADDIR");
70 if (!doomwaddir)
71 {
24b824db 72- // get the current directory (possible problem on NT with "." as current dir)
746b6f37 73- if (getcwd(pathtemp, _MAX_PATH) != NULL)
24b824db 74- doomwaddir = pathtemp;
75- else
76- doomwaddir = ".";
0a49077e
ER
77+ doomwaddir = "/usr/share/doomlegacy";
78 }
79 #if 0
80 //[WDJ] disabled in 143beta_macosx
This page took 0.03563 seconds and 4 git commands to generate.