apparently M_ToggleMenu_f is not what to call... Call_MR_ToggleMenu_f is
[divverent/darkplaces.git] / makefile
1 #####  DP_MAKE_TARGET autodetection and arch specific variables ##### 
2
3 ifndef DP_MAKE_TARGET
4
5 # Win32
6 ifdef windir
7         DP_MAKE_TARGET=mingw
8 else
9
10 # UNIXes
11 DP_ARCH:=$(shell uname)
12 ifeq ($(DP_ARCH),NetBSD)
13         DP_MAKE_TARGET=bsd
14 else
15         DP_MAKE_TARGET=linux
16 endif
17
18 endif
19
20 endif
21
22
23 # Command used to delete files
24 ifdef windir
25         CMD_RM=del
26 else
27         CMD_RM=$(CMD_UNIXRM)
28 endif
29
30
31 # Linux configuration
32 ifeq ($(DP_MAKE_TARGET), linux)
33         OBJ_SOUND=$(OBJ_LINUXSOUND)
34         LIB_SOUND=$(LIB_LINUXSOUND)
35         OBJ_CD=$(OBJ_LINUXCD)
36
37         OBJ_CL=$(OBJ_GLX)
38
39         LDFLAGS_CL=$(LDFLAGS_LINUXCL)
40         LDFLAGS_SV=$(LDFLAGS_LINUXSV)
41         LDFLAGS_SDL=$(LDFLAGS_LINUXSDL)
42
43         EXE_CL=$(EXE_UNIXCL)
44         EXE_SV=$(EXE_UNIXSV)
45         EXE_SDL=$(EXE_UNIXSDL)
46 endif
47
48 # BSD configuration
49 ifeq ($(DP_MAKE_TARGET), bsd)
50         OBJ_SOUND=$(OBJ_BSDSOUND)
51         LIB_SOUND=$(LIB_BSDSOUND)
52         OBJ_CD=$(OBJ_BSDCD)
53
54         OBJ_CL=$(OBJ_GLX)
55
56         LDFLAGS_CL=$(LDFLAGS_BSDCL)
57         LDFLAGS_SV=$(LDFLAGS_BSDSV)
58         LDFLAGS_SDL=$(LDFLAGS_BSDSDL)
59
60         EXE_CL=$(EXE_UNIXCL)
61         EXE_SV=$(EXE_UNIXSV)
62         EXE_SDL=$(EXE_UNIXSDL)
63 endif
64
65 # Win32 configuration
66 ifeq ($(DP_MAKE_TARGET), mingw)
67         OBJ_SOUND=$(OBJ_WINSOUND)
68         LIB_SOUND=$(LIB_WINSOUND)
69         OBJ_CD=$(OBJ_WINCD)
70
71         OBJ_CL=$(OBJ_WGL)
72
73         LDFLAGS_CL=$(LDFLAGS_WINCL)
74         LDFLAGS_SV=$(LDFLAGS_WINSV)
75         LDFLAGS_SDL=$(LDFLAGS_WINSDL)
76
77         EXE_CL=$(EXE_WINCL)
78         EXE_SV=$(EXE_WINSV)
79         EXE_SDL=$(EXE_WINSDL)
80 endif
81
82
83 ##### GNU Make specific definitions #####
84
85 DO_LD=$(CC) -o $@ $^ $(LDFLAGS)
86
87
88 ##### Definitions shared by all makefiles #####
89 include makefile.inc
90
91
92 ##### Dependency files #####
93
94 -include *.d