/
Makefile
62 lines (44 loc) · 1.06 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
CFILES=$(shell find src/ -name '*.c')
HFILES=$(shell find src/ -name '*.h')
INCFILES=$(shell find include/ -name '*.h')
SOURCES=$(CFILES) $(HFILES) $(INCFILES) src/builtins.expando
MAKEFILES=Makefile main.mk config.mk
# Files included in distributed tarballs
TAR_FILES=$(SOURCES) include/README include/eris/builtins_pre \
README $(MAKEFILES)
# Names of executables we generate
EXE_NAMES=rvmi
# Names of source files we generate
GENFILE_NAMES=include/eris/builtins.expando
# Libraries we depend on.
LIBS=gmp Judy
# Make "all" default target.
.PHONY: all
all:
INCLUDE_DIRS+= include/
include config.mk
# verbose flag
V?=0
ifeq (0,$(V))
QUIET:=@
else
QUIET:=
endif
# Cleaning stuff.
CLEAN_RULES=depclean objclean clean pristine
.PHONY: $(CLEAN_RULES)
depclean:
rm -rf build/*/dep
objclean:
rm -rf build/*/bin build/*/obj
clean:
rm -rf build/
rm -f eris.tar.*
pristine: clean
rm -f TAGS
# If we're just cleaning, we can ignore everything else.
ifneq (,$(filter-out $(CLEAN_RULES), $(MAKECMDGOALS)))
include main.mk
else ifeq (,$(MAKECMDGOALS))
include main.mk
endif