-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathMakefile
48 lines (37 loc) · 812 Bytes
/
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
ifeq ($(M),)
METAC_ROOT=../../..
all: test target
target:
$(MAKE) -C $(METAC_ROOT) M=$(PWD) target
clean:
$(MAKE) -C $(METAC_ROOT) M=$(PWD) clean
test:
$(MAKE) -C $(METAC_ROOT) M=$(PWD) test
.PHONY: all clean test
endif
rules+= \
target \
demodb
TPL-target:=phony_target
IN-target:= \
demodb
TPL-demodb:=bin_target
IN-demodb= \
main.o \
demodb.o \
demodb.reflect.o
LDFLAGS-demodb=-Lsrc -lmetac
DEPS-demodb=src/libmetac.a
#added to support demodb.reflect.o
rules+= \
_meta_demodb \
demodb.reflect.c
TPL-_meta_demodb=bin_target
IN-_meta_demodb= \
main.meta.o \
demodb.meta.o
LDFLAGS-_meta_demodb=-Lsrc -lmetac
POST-_meta_demodb=$(METAC_POST_META)
TPL-demodb.reflect.c:=metac_target
IN-demodb.reflect.c=_meta_demodb
METACFLAGS-demodb.reflect.c=run metac-reflect-gen $(METAC_OVERRIDE_IN_TYPE)