1 ##### DP_MAKE_TARGET autodetection and arch specific variables #####
17 CMD_MKDIR=$(CMD_UNIXMKDIR)
20 TARGETS_DEBUG=sv-debug cl-debug sdl-debug
21 TARGETS_PROFILE=sv-profile cl-profile sdl-profile
22 TARGETS_RELEASE=sv-release cl-release sdl-release
23 TARGETS_RELEASE_PROFILE=sv-release-profile cl-release-profile sdl-release-profile
24 TARGETS_NEXUIZ=sv-nexuiz cl-nexuiz sdl-nexuiz
27 UNIX_X11LIBPATH=/usr/X11R6/lib
30 .if $(DP_MAKE_TARGET) == "bsd"
33 .if $(DP_ARCH) == "FreeBSD"
44 LDFLAGS_CL=$(LDFLAGS_BSDCL)
45 LDFLAGS_SV=$(LDFLAGS_BSDSV)
46 LDFLAGS_SDL=$(LDFLAGS_BSDSDL)
48 SDLCONFIG_CFLAGS=$(SDLCONFIG_UNIXCFLAGS) $(SDLCONFIG_UNIXCFLAGS_X11)
49 SDLCONFIG_LIBS=$(SDLCONFIG_UNIXLIBS) $(SDLCONFIG_UNIXLIBS_X11)
50 SDLCONFIG_STATICLIBS=$(SDLCONFIG_UNIXSTATICLIBS) $(SDLCONFIG_UNIXSTATICLIBS_X11)
54 EXE_SDL=$(EXE_UNIXSDL)
55 EXE_CLNEXUIZ=$(EXE_UNIXCLNEXUIZ)
56 EXE_SVNEXUIZ=$(EXE_UNIXSVNEXUIZ)
57 EXE_SDLNEXUIZ=$(EXE_UNIXSDLNEXUIZ)
59 # set these to "" if you want to use dynamic loading instead
61 CFLAGS_LIBZ=-DLINK_TO_ZLIB
65 CFLAGS_LIBJPEG=-DLINK_TO_LIBJPEG
69 ODE_CONFIG?=ode-config
70 LIB_ODE=`$(ODE_CONFIG) --libs`
71 CFLAGS_ODE=`$(ODE_CONFIG) --cflags` -DUSEODE -DLINK_TO_LIBODE
74 # most distros do not have d0_blind_id package, dlopen will used by default
75 # LIB_CRYPTO=-ld0_blind_id
76 # CFLAGS_CRYPTO=-DLINK_TO_CRYPTO
77 # LIB_CRYPTO_RIJNDAEL=-ld0_rijndael
78 # CFLAGS_CRYPTO_RIJNDAEL=-DLINK_TO_CRYPTO_RIJNDAEL
82 CFLAGS_CRYPTO_RIJNDAEL=
85 # now ogg is mostly used, modplug is required rarely, keep it dlopen by default
86 # LIB_SND_MODPLUG=-lmodplug
87 # CFLAGS_SND_MODPLUG=-DLINK_TO_LIBMODPLUG
94 ##### Sound configuration #####
97 DP_SOUND_API=$(DEFAULT_SNDAPI)
101 .if $(DP_SOUND_API) == "NULL"
102 OBJ_SOUND=$(OBJ_SND_NULL)
103 LIB_SOUND=$(LIB_SND_NULL)
106 # OSS: Open Sound System
107 .if $(DP_SOUND_API) == "OSS"
108 OBJ_SOUND=$(OBJ_SND_OSS)
109 LIB_SOUND=$(LIB_SND_OSS)
112 # BSD: BSD / Sun audio API
113 .if $(DP_SOUND_API) == "BSD"
114 OBJ_SOUND=$(OBJ_SND_BSD)
115 LIB_SOUND=$(LIB_SND_BSD)
119 ##### Extra CFLAGS #####
123 CFLAGS_FS=-DDP_FS_BASEDIR='\"$(DP_FS_BASEDIR)\"'
129 .ifdef DP_PRELOAD_DEPENDENCIES
130 LDFLAGS_CL+=$(LDFLAGS_UNIXCL_PRELOAD)
131 LDFLAGS_SV+=$(LDFLAGS_UNIXSV_PRELOAD)
132 LDFLAGS_SDL+=$(LDFLAGS_UNIXSDL_PRELOAD)
133 CFLAGS_PRELOAD=$(CFLAGS_UNIX_PRELOAD)
137 ##### BSD Make specific definitions #####
139 MAKE:=$(MAKE) -f BSDmakefile
141 DO_LD=$(CC) -o ../../../$@ $> $(LDFLAGS)
144 ##### Definitions shared by all makefiles #####
145 .include "makefile.inc"