-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
executable file
·79 lines (63 loc) · 1.45 KB
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
# Generic NewGRF Makefile
# Necessary defines unique to this NewGRF
-include Makefile.local
include Makefile.config
# Necessary defines common to all NewGRFs
include scripts/Makefile.def
# most important build targets for users
all:
$(_V) $(MAKE) $(MAKE_FLAGS) depend
$(_V) $(MAKE) $(MAKE_FLAGS) $(TARGET_FILES) $(DOC_FILES)
docs: $(DOC_FILES)
grf: $(GRF_FILES)
bundle: $(DIR_NAME)
clean::
$(_E) "[CLEAN]"
remake:
$(_V) $(MAKE) $(MAKE_FLAGS) clean
$(_V) $(MAKE) $(MAKE_FLAGS) all
distclean:: clean
$(_E) "[DISTCLEAN]"
# Include custom rules
-include scripts/Makefile.in
# Do not include the dependencies when we're cleaning
# or going to call make recursively again
ifeq "$(MAKECMDGOALS)" ""
NODEP = 1
endif
ifeq "$(MAKECMDGOALS)" "clean"
NODEP = 1
endif
ifeq "$(MAKECMDGOALS)" "distclean"
NODEP = 1
endif
ifeq "$(MAKECMDGOALS)" "remake"
NODEP = 1
endif
ifeq "$(MAKECMDGOALS)" "mrproper"
NODEP = 1
endif
ifeq "$(MAKECMDGOALS)" "maintainer-clean"
NODEP = 1
endif
ifeq "$(MAKECMDGOALS)" "all"
NODEP = 1
endif
ifeq "$(MAKECMDGOALS)" "depend"
NODEP = 1
endif
ifeq "$(MAKECMDGOALS)" "test"
NODEP = 1
endif
ifndef NODEP
-include Makefile.dep
-include $(patsubst %.grf,%.src.dep,$(GRF_FILES))
-include $(patsubst %.grf,%.gfx.dep,$(GRF_FILES))
endif
# Stuff common to all NewGRFs
include scripts/Makefile.common
# Include the language - specific makefile
-include scripts/Makefile.nml
-include scripts/Makefile.nfo
# Include bundles etc
include scripts/Makefile.bundles