]> icculus.org git repositories - divverent/darkplaces.git/blob - makefile.bsd
use sdl-config --static-libs on Mac
[divverent/darkplaces.git] / makefile.bsd
1 #####  DP_MAKE_TARGET autodetection and arch specific variables ##### 
2
3 .ifndef DP_MAKE_TARGET
4
5 DP_MAKE_TARGET=bsd
6
7 .endif
8 DP_ARCH != uname
9
10
11 # Command used to delete files
12 CMD_RM=$(CMD_UNIXRM)
13
14 UNIX_X11LIBPATH=-L/usr/X11R6/lib
15
16 # BSD configuration
17 .if $(DP_MAKE_TARGET) == "bsd"
18
19 # FreeBSD uses OSS
20 .if $(DP_ARCH) == "FreeBSD"
21 DEFAULT_SNDAPI=OSS
22 .else
23 DEFAULT_SNDAPI=BSD
24 .endif
25 OBJ_CD=$(OBJ_BSDCD)
26
27 OBJ_CL=$(OBJ_GLX)
28
29 LDFLAGS_CL=$(LDFLAGS_BSDCL)
30 LDFLAGS_SV=$(LDFLAGS_BSDSV)
31
32 EXE_CL=$(EXE_UNIXCL)
33 EXE_SV=$(EXE_UNIXSV)
34 EXE_SDL=$(EXE_UNIXSDL)
35
36 .endif
37
38
39 ##### Sound configuration #####
40
41 .ifndef DP_SOUND_API
42 DP_SOUND_API=$(DEFAULT_SNDAPI)
43 .endif
44
45 # NULL: no sound
46 .if $(DP_SOUND_API) == "NULL"
47 OBJ_SOUND=$(OBJ_SND_NULL)
48 LIB_SOUND=$(LIB_SND_NULL)
49 .endif
50
51 # OSS: Open Sound System
52 .if $(DP_SOUND_API) == "OSS"
53 OBJ_SOUND=$(OBJ_SND_OSS)
54 LIB_SOUND=$(LIB_SND_OSS)
55 .endif
56
57 # BSD: BSD / Sun audio API
58 .if $(DP_SOUND_API) == "BSD"
59 OBJ_SOUND=$(OBJ_SND_BSD)
60 LIB_SOUND=$(LIB_SND_BSD)
61 .endif
62
63
64 ##### BSD Make specific definitions #####
65
66 MAKE:=$(MAKE) -f makefile.bsd
67
68 DO_LD=$(CC) -o $@ $> $(LDFLAGS)
69
70
71 ##### Definitions shared by all makefiles #####
72 .include "makefile.inc"
73
74
75 ##### Dependency files #####
76
77 DEPEND_FILES != ls *.d
78 .for i in $(DEPEND_FILES)
79 .       include "$i"
80 .endfor