]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blob - qcsrc/Makefile
Merge remote-tracking branch 'origin/divVerent/waypointeditor-auto'
[xonotic/xonotic-data.pk3dir.git] / qcsrc / Makefile
1 SCM := $(shell if [ -d .svn ]; then echo svn; elif [ -d ../.git ]; then echo git; fi)
2 FTEQCC ?= fteqcc
3 PERL ?= perl
4
5 FTEQCCFLAGS_WATERMARK ?= -DWATERMARK='"$(shell git describe)"' -DCVAR_POPCON
6 FTEQCCFLAGS ?= -Werror -Wno-Q302 -O3 -Ono-c -Ono-cs -fno-fastarrays $(FTEQCCFLAGS_EXTRA) $(FTEQCCFLAGS_WATERMARK)
7 FTEQCCFLAGS_PROGS ?=
8 FTEQCCFLAGS_MENU ?=
9
10 # NOTE: use -DUSE_FTE instead of -TFTE here!
11 # It will automagically add an engine check with -TID and then change back to -TFTE
12 FTEQCCFLAGS_CSPROGS ?= 
13
14 # xonotic build system overrides this by command line argument to turn off the update-cvarcount step
15 XON_BUILDSYSTEM =
16
17 all: qc
18
19 .PHONY: qc
20 qc:
21         $(MAKE) qc-recursive
22
23 .PHONY: qc-recursive
24 qc-recursive: ../menu.dat ../progs.dat ../csprogs.dat
25
26 .PHONY: clean
27 clean:
28         rm -f ../progs.dat ../menu.dat ../csprogs.dat
29
30 FILES_CSPROGS = $(shell find client common warpzonelib csqcmodellib -type f -not -name fteqcc.log -not -name qc.asm) $(wildcard server/w_*.qc)
31 ../csprogs.dat: $(FILES_CSPROGS)
32         @echo make[1]: Entering directory \`$(PWD)/client\'
33         cd client && $(FTEQCC) $(FTEQCCFLAGS) $(FTEQCCFLAGS_CSPROGS)
34
35 FILES_PROGS = $(shell find server common warpzonelib csqcmodellib -type f -not -name fteqcc.log -not -name qc.asm) $(wildcard server/w_*.qc)
36 ../progs.dat: $(FILES_PROGS)
37         @echo make[1]: Entering directory \`$(PWD)/server\'
38         cd server && $(FTEQCC) $(FTEQCCFLAGS) $(FTEQCCFLAGS_PROGS)
39
40 FILES_MENU = $(shell find menu common warpzonelib -type f -not -name fteqcc.log -not -name qc.asm) $(wildcard server/w_*.qc)
41 ../menu.dat: $(FILES_MENU)
42         @echo make[1]: Entering directory \`$(PWD)/menu\'
43         cd menu && $(FTEQCC) $(FTEQCCFLAGS) $(FTEQCCFLAGS_MENU)
44
45 .PHONY: testcase
46 testcase:
47         cd testcase && $(FTEQCC) $(FTEQCCFLAGS) $(FTEQCCFLAGS_CSPROGS) -DTESTCASE="$$TESTCASE"