1 SCM := $(shell if [ -d .svn ]; then echo svn; elif [ -d ../.git ]; then echo git; fi)
3 QCCFLAGS_WATERMARK ?= -DWATERMARK='"$(shell git describe)"'
6 QCCVERSIONFILE := qccversion.$(shell $(QCC) --version > qccversion.txt && git hash-object qccversion.txt)
8 # We eventually need to get rid of these.
10 -Wno-field-redeclared \
11 -Wno-double-declaration \
16 -Werror -fno-bail-on-werror -Wall \
17 -fftepp -fftepp-predefs -Wcpp -futf8 \
19 $(QCCFLAGS_EXTRA) $(QCCFLAGS_WATERMARK)
21 # xonotic build system overrides this by command line argument to turn off the update-cvarcount step
28 qc: ../menu.dat ../progs.dat ../csprogs.dat
32 rm -f ../progs.dat ../menu.dat ../csprogs.dat server/precache-for-csqc.inc
36 echo This file intentionally left blank. > $@
38 FILES_CSPROGS = $(shell find client common warpzonelib csqcmodellib -type f -not -name fteqcc.log -not -name qc.asm) $(wildcard server/w_*.qc)
39 ../csprogs.dat: $(FILES_CSPROGS) $(QCCVERSIONFILE)
40 @echo make[1]: Entering directory \`$(PWD)/client\'
41 cd client && $(QCC) $(QCCFLAGS)
43 server/precache-for-csqc.inc: $(FILES_CSPROGS)
44 sh collect-precache.sh
46 FILES_PROGS = $(shell find server common warpzonelib csqcmodellib -type f -not -name fteqcc.log -not -name qc.asm) $(wildcard server/w_*.qc)
47 ../progs.dat: $(FILES_PROGS) $(QCCVERSIONFILE) server/precache-for-csqc.inc
48 @echo make[1]: Entering directory \`$(PWD)/server\'
49 cd server && $(QCC) $(QCCFLAGS)
51 FILES_MENU = $(shell find menu common warpzonelib -type f -not -name fteqcc.log -not -name qc.asm) $(wildcard server/w_*.qc)
52 ../menu.dat: $(FILES_MENU) $(QCCVERSIONFILE)
53 @echo make[1]: Entering directory \`$(PWD)/menu\'
54 cd menu && $(QCC) $(QCCFLAGS)
58 cd testcase && $(QCC) $(QCCFLAGS) -DTESTCASE="$$TESTCASE"