This is a fork of Zandronum used on servers hosted by The Sentinels Playground (TSPG), Euroboros (EB), and Down Under Doomers (DUD).
修订版 | dd287b2ffc2d0823fe91b40d8e0f47a3592b9fdf (tree) |
---|---|
时间 | 2008-02-10 10:21:45 |
作者 | Randy Heit <rheit@zdoo...> |
Commiter | Randy Heit |
- Modified FLAC/share/alloc.h to define SIZE_T_MAX if it isn't defined
- Changed the way that the makefiles detect MSYS to a method that should
SVN r737 (trunk)
@@ -11,7 +11,7 @@ | ||
11 | 11 | WIN=1 |
12 | 12 | WINCMD=1 |
13 | 13 | endif |
14 | -ifeq (msys,$(OSTYPE)) | |
14 | +ifeq ($(findstring msys,$(shell sh --version 2>nul)),msys) | |
15 | 15 | WIN=1 |
16 | 16 | WINCMD=0 |
17 | 17 | endif |
@@ -33,14 +33,16 @@ | ||
33 | 33 | #endif |
34 | 34 | #include <stdlib.h> /* for size_t, malloc(), etc */ |
35 | 35 | |
36 | +#ifndef SIZE_T_MAX | |
37 | +# ifdef _WIN64 | |
38 | +# define SIZE_T_MAX ULLONG_MAX | |
39 | +# elif defined(_WIN32) | |
40 | +# define SIZE_T_MAX UINT_MAX /* Why doesn't the standard MinGW distribution define this? */ | |
41 | +# else | |
42 | +# error | |
43 | +# endif | |
44 | +#endif | |
36 | 45 | #ifndef SIZE_MAX |
37 | -# ifndef SIZE_T_MAX | |
38 | -# ifdef _MSC_VER | |
39 | -# define SIZE_T_MAX UINT_MAX | |
40 | -# else | |
41 | -# error | |
42 | -# endif | |
43 | -# endif | |
44 | 46 | # define SIZE_MAX SIZE_T_MAX |
45 | 47 | #endif |
46 | 48 |
@@ -1,7 +1,7 @@ | ||
1 | 1 | ifeq (Windows_NT,$(OS)) |
2 | 2 | WIN=1 |
3 | 3 | endif |
4 | -ifeq (msys,$(OSTYPE)) | |
4 | +ifeq ($(findstring msys,$(shell sh --version 2>nul)),msys) | |
5 | 5 | WIN=1 |
6 | 6 | endif |
7 | 7 |
@@ -45,7 +45,7 @@ | ||
45 | 45 | @$(MAKE) -C zlib -f Makefile.mgw clean |
46 | 46 | @$(MAKE) -C flac -f Makefile.mgw clean |
47 | 47 | @$(MAKE) -C jpeg-6b -f Makefile.mgw clean |
48 | -ifeq (msys,$(OSTYPE)) | |
48 | +ifeq ($(findstring msys,$(shell sh --version 2>nul)),msys) | |
49 | 49 | rm -f ccdv.exe |
50 | 50 | else |
51 | 51 | del /q /f ccdv.exe 2>nul |
@@ -1,10 +1,13 @@ | ||
1 | +# This makefile makes zdoom(d).exe only. | |
2 | +# Makefile.mgw builds this plus everything else. | |
3 | + | |
1 | 4 | # Sub-makefile autogenerated by premake |
2 | 5 | # And then tweaked by hand |
3 | 6 | |
4 | 7 | # Where did you install the FMOD API to? Change this line so that the build process can find it. |
5 | 8 | FMODDIR = "c:/program files/fmodapi375win" |
6 | 9 | |
7 | -ifeq (msys,$(OSTYPE)) | |
10 | +ifeq ($(findstring msys,$(shell sh --version 2>nul)),msys) | |
8 | 11 | WINCMD=0 |
9 | 12 | else |
10 | 13 | WINCMD=1 |
@@ -1,12 +1,23 @@ | ||
1 | +February 9, 2008 | |
2 | +- Modified FLAC/share/alloc.h to define SIZE_T_MAX if it isn't defined | |
3 | + already. For some reason, a stock install of MinGW doesn't define it, but | |
4 | + if you compile your own GCC, it installs headers that do. | |
5 | +- After thoroughly messing up my MinGW/MSYS installation, I deleted the whole | |
6 | + thing and reinstalled everything using the latest zips. Much to my surprise, | |
7 | + the MSYS-detection in the makefiles no longer worked because OSTYPE wasn't | |
8 | + being exported to process launched by the MSYS shell. I've now switched to a | |
9 | + different method I found through the power of Google that asks the shell | |
10 | + what version it is to see if the version string contains "msys". | |
11 | + | |
1 | 12 | February 8, 2008 |
2 | 13 | - Applied Blzut3's sbarinfo update #11: |
3 | 14 | * SBarInfo will also accept a '|' between flags for those who are really |
4 | 15 | bothered by the indefinite "arguments" in the middle of the statement. |
5 | - * Added: completeBorder. When set to true SBarInfo will draw the border where | |
16 | + * Added: completeBorder. When set to true SBarInfo will draw the border where | |
6 | 17 | the status bar normally goes. |
7 | 18 | * Fixed: I forgot to accept TK_None on "base" and "statusbar". |
8 | 19 | * Fixed: "base" was apparently broken when the SBarInfo init code was moved to |
9 | - d_main.cpp. Also, if "base Strife" was used then it would not use the | |
20 | + d_main.cpp. Also, if "base Strife" was used then it would not use the | |
10 | 21 | default log message of "find help". |
11 | 22 | - Fixed: D_ReadUserInfoString() parsed the final element of a compact string |
12 | 23 | as the empty string. Since that was the player class, this meant that any |
@@ -33,7 +33,7 @@ | ||
33 | 33 | .PHONY: clean |
34 | 34 | |
35 | 35 | clean: |
36 | -ifeq (msys,$(OSTYPE)) | |
36 | +ifeq ($(findstring msys,$(shell sh --version 2>nul)),msys) | |
37 | 37 | rm -f $(STATICLIB) |
38 | 38 | rm -f *.o |
39 | 39 | else |
@@ -1,11 +1,11 @@ | ||
1 | -ifeq (Windows_NT,$(OS)) | |
2 | - WIN=1 | |
3 | - WINCMD=1 | |
4 | -endif | |
5 | -ifeq (msys,$(OSTYPE)) | |
6 | - WIN=1 | |
7 | - WINCMD=0 | |
8 | -endif | |
1 | +ifeq (Windows_NT,$(OS)) | |
2 | + WIN=1 | |
3 | + WINCMD=1 | |
4 | +endif | |
5 | +ifeq ($(findstring msys,$(shell sh --version 2>nul)),msys) | |
6 | + WIN=1 | |
7 | + WINCMD=0 | |
8 | +endif | |
9 | 9 | |
10 | 10 | ifeq (1,$(WIN)) |
11 | 11 | EXE = dehsupp.exe |
@@ -2,7 +2,7 @@ | ||
2 | 2 | WIN=1 |
3 | 3 | WINCMD=1 |
4 | 4 | endif |
5 | -ifeq (msys,$(OSTYPE)) | |
5 | +ifeq ($(findstring msys,$(shell sh --version 2>nul)),msys) | |
6 | 6 | WIN=1 |
7 | 7 | WINCMD=0 |
8 | 8 | endif |
@@ -1,11 +1,11 @@ | ||
1 | -ifeq (Windows_NT,$(OS)) | |
2 | - WIN=1 | |
3 | - WINCMD=1 | |
4 | -endif | |
5 | -ifeq (msys,$(OSTYPE)) | |
6 | - WIN=1 | |
7 | - WINCMD=0 | |
8 | -endif | |
1 | +ifeq (Windows_NT,$(OS)) | |
2 | + WIN=1 | |
3 | + WINCMD=1 | |
4 | +endif | |
5 | +ifeq ($(findstring msys,$(shell sh --version 2>nul)),msys) | |
6 | + WIN=1 | |
7 | + WINCMD=0 | |
8 | +endif | |
9 | 9 | |
10 | 10 | ifeq (1,$(WIN)) |
11 | 11 | EXE = lemon.exe |
@@ -1,11 +1,11 @@ | ||
1 | -ifeq (Windows_NT,$(OS)) | |
2 | - WIN=1 | |
3 | - WINCMD=1 | |
4 | -endif | |
5 | -ifeq (msys,$(OSTYPE)) | |
6 | - WIN=1 | |
7 | - WINCMD=0 | |
8 | -endif | |
1 | +ifeq (Windows_NT,$(OS)) | |
2 | + WIN=1 | |
3 | + WINCMD=1 | |
4 | +endif | |
5 | +ifeq ($(findstring msys,$(shell sh --version 2>nul)),msys) | |
6 | + WIN=1 | |
7 | + WINCMD=0 | |
8 | +endif | |
9 | 9 | |
10 | 10 | ifeq (1,$(WIN)) |
11 | 11 | EXE = makewad.exe |
@@ -323,7 +323,7 @@ | ||
323 | 323 | { |
324 | 324 | fprintf (wadfile, " \\\n\t\"%s\"", filename); |
325 | 325 | } |
326 | - // ARGH! Stupid make. Too bad but then these files can't be checked. | |
326 | + // ARGH! Stupid make. Too bad, but then these files can't be checked. | |
327 | 327 | // Still better than something that doesn't work at all though! |
328 | 328 | else if (!strpbrk(filename, "[]^")) |
329 | 329 | { |
@@ -2,7 +2,7 @@ | ||
2 | 2 | WIN=1 |
3 | 3 | WINCMD=1 |
4 | 4 | endif |
5 | -ifeq (msys,$(OSTYPE)) | |
5 | +ifeq ($(findstring msys,$(shell sh --version 2>nul)),msys) | |
6 | 6 | WIN=1 |
7 | 7 | WINCMD=0 |
8 | 8 | endif |
@@ -2,7 +2,7 @@ | ||
2 | 2 | WIN=1 |
3 | 3 | WINCMD=1 |
4 | 4 | endif |
5 | -ifeq (msys,$(OSTYPE)) | |
5 | +ifeq ($(findstring msys,$(shell sh --version 2>nul)),msys) | |
6 | 6 | WIN=1 |
7 | 7 | WINCMD=0 |
8 | 8 | endif |
@@ -27,8 +27,8 @@ | ||
27 | 27 | $(EXE): $(OBJS) |
28 | 28 | $(CCDV) $(CC) -o $(EXE) $(OBJS) $(CFLAGS) $(LDFLAGS) |
29 | 29 | |
30 | -%.o : %.rc | |
31 | - $(CCDV) windres -o $@ -i $< | |
30 | +%.o : %.rc | |
31 | + $(CCDV) windres -o $@ -i $< | |
32 | 32 | |
33 | 33 | .PHONY: clean |
34 | 34 |
@@ -0,0 +1,6 @@ | ||
1 | +// This resource script is for compiling with MinGW only. Visual C++ | |
2 | +// compilations use the manifest tool to insert the manifest instead. | |
3 | + | |
4 | +#include <WinUser.h> | |
5 | + | |
6 | +1 RT_MANIFEST "trustinfo.txt" |
@@ -2,7 +2,7 @@ | ||
2 | 2 | WIN=1 |
3 | 3 | WINCMD=1 |
4 | 4 | endif |
5 | -ifeq (msys,$(OSTYPE)) | |
5 | +ifeq ($(findstring msys,$(shell sh --version 2>nul)),msys) | |
6 | 6 | WIN=1 |
7 | 7 | WINCMD=0 |
8 | 8 | endif |
@@ -1,26 +1,29 @@ | ||
1 | -MAKEWAD=../tools/makewad/makewad | |
2 | -XLATCC=../tools/xlatcc/xlatcc | |
3 | -DEHSUPP=../tools/dehsupp/dehsupp | |
4 | - | |
5 | -ifneq ($(MAKECMDGOALS),clean) | |
6 | -include Makefile2 | |
7 | -endif | |
8 | - | |
9 | -wadmake: zdoom.lst $(MAKEWAD).exe $(XLATCC).exe $(DEHSUPP).exe | |
10 | - $(MAKEWAD) -make wadmake zdoom.lst | |
11 | - | |
12 | -clean: | |
13 | -ifeq (msys,$(OSTYPE)) | |
14 | - rm -f wadmake zdoom.pk3 xlat/*.x dehsupp.lmp | |
15 | -else | |
16 | - del /q /f wadmake zdoom.pk3 xlat\*.x dehsupp.lmp 2>nul | |
17 | -endif | |
18 | - | |
19 | -../tools/makewad/makewad.exe: | |
20 | - $(MAKE) -C ../tools/makewad -f Makefile | |
21 | - | |
22 | -../tools/xlatcc/xlatcc.exe: | |
23 | - $(MAKE) -C ../tools/xlatcc -f Makefile | |
24 | - | |
25 | -../tools/dehsupp/dehsupp.exe: | |
26 | - $(MAKE) -C ../tools/dehsupp -f Makefile | |
1 | +MAKEWAD=../tools/makewad/makewad | |
2 | +XLATCC=../tools/xlatcc/xlatcc | |
3 | +DEHSUPP=../tools/dehsupp/dehsupp | |
4 | + | |
5 | +ifneq ($(MAKECMDGOALS),clean) | |
6 | +include Makefile2 | |
7 | +endif | |
8 | +ifeq ($(findstring msys,$(shell sh --version 2>nul)),msys) | |
9 | +export OSTYPE=msys | |
10 | +endif | |
11 | + | |
12 | +wadmake: zdoom.lst $(MAKEWAD).exe $(XLATCC).exe $(DEHSUPP).exe | |
13 | + $(MAKEWAD) -make wadmake zdoom.lst | |
14 | + | |
15 | +clean: | |
16 | +ifeq ($(OSTYPE),msys) | |
17 | + rm -f wadmake zdoom.pk3 xlat/*.x dehsupp.lmp | |
18 | +else | |
19 | + del /q /f wadmake zdoom.pk3 xlat\*.x dehsupp.lmp 2>nul | |
20 | +endif | |
21 | + | |
22 | +../tools/makewad/makewad.exe: | |
23 | + $(MAKE) -C ../tools/makewad -f Makefile | |
24 | + | |
25 | +../tools/xlatcc/xlatcc.exe: | |
26 | + $(MAKE) -C ../tools/xlatcc -f Makefile | |
27 | + | |
28 | +../tools/dehsupp/dehsupp.exe: | |
29 | + $(MAKE) -C ../tools/dehsupp -f Makefile |
@@ -63,7 +63,7 @@ | ||
63 | 63 | .PHONY: clean |
64 | 64 | |
65 | 65 | clean: |
66 | -ifeq (msys,$(OSTYPE)) | |
66 | +ifeq ($(findstring msys,$(shell sh --version 2>nul)),msys) | |
67 | 67 | rm -f $(STATICLIB) |
68 | 68 | rm -f *.o |
69 | 69 | rm -f *.exe |