91775c0c6a5c455213a85936acd86a67e9f19e72
[reactos.git] / reactos / tools / wpp / wpp.mak
1 WPP_BASE = tools$(SEP)wpp
2
3 $(INTERMEDIATE)$(WPP_BASE): $(INTERMEDIATE_NO_SLASH) $(RMKDIR_TARGET)
4 ${mkdir} $(INTERMEDIATE)$(WPP_BASE)
5
6 WPP_TARGET = \
7 $(INTERMEDIATE)$(WPP_BASE)$(SEP)libwpp.a
8
9 WPP_SOURCES = \
10 $(WPP_BASE)$(SEP)lex.yy.c \
11 $(WPP_BASE)$(SEP)preproc.c \
12 $(WPP_BASE)$(SEP)wpp.c \
13 $(WPP_BASE)$(SEP)wpp.tab.c
14
15 WPP_OBJECTS = \
16 $(addprefix $(INTERMEDIATE), $(WPP_SOURCES:.c=.o))
17
18 WPP_HOST_CFLAGS = -D__USE_W32API -I$(WPP_BASE) -Iinclude -Iinclude/wine -g
19
20 $(WPP_TARGET): $(INTERMEDIATE)$(WPP_BASE) $(WPP_OBJECTS)
21 $(ECHO_AR)
22 ${host_ar} -rc $(WPP_TARGET) $(WPP_OBJECTS)
23
24 $(INTERMEDIATE)$(WPP_BASE)$(SEP)lex.yy.o: $(INTERMEDIATE)$(WPP_BASE) $(WPP_BASE)$(SEP)lex.yy.c
25 $(ECHO_CC)
26 ${host_gcc} $(WPP_HOST_CFLAGS) -c $(WPP_BASE)$(SEP)lex.yy.c -o $(INTERMEDIATE)$(WPP_BASE)$(SEP)lex.yy.o
27
28 $(INTERMEDIATE)$(WPP_BASE)$(SEP)preproc.o: $(INTERMEDIATE)$(WPP_BASE) $(WPP_BASE)$(SEP)preproc.c
29 $(ECHO_CC)
30 ${host_gcc} $(WPP_HOST_CFLAGS) -c $(WPP_BASE)$(SEP)preproc.c -o $(INTERMEDIATE)$(WPP_BASE)$(SEP)preproc.o
31
32 $(INTERMEDIATE)$(WPP_BASE)$(SEP)wpp.o: $(INTERMEDIATE)$(WPP_BASE) $(WPP_BASE)$(SEP)wpp.c
33 $(ECHO_CC)
34 ${host_gcc} $(WPP_HOST_CFLAGS) -c $(WPP_BASE)$(SEP)wpp.c -o $(INTERMEDIATE)$(WPP_BASE)$(SEP)wpp.o
35
36 $(INTERMEDIATE)$(WPP_BASE)$(SEP)wpp.tab.o: $(INTERMEDIATE)$(WPP_BASE) $(WPP_BASE)$(SEP)wpp.tab.c
37 $(ECHO_CC)
38 ${host_gcc} $(WPP_HOST_CFLAGS) -c $(WPP_BASE)$(SEP)wpp.tab.c -o $(INTERMEDIATE)$(WPP_BASE)$(SEP)wpp.tab.o
39
40 .PHONY: wpp_clean
41 wpp_clean:
42 -@$(rm) $(WPP_TARGET) $(WPP_OBJECTS) 2>$(NUL)
43 clean: wpp_clean