forked from aolarchive/ribs2
-
Notifications
You must be signed in to change notification settings - Fork 11
/
Copy pathMakefile
33 lines (26 loc) · 745 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
EXAMPLES=httpd helloworld mydump httpget ribeye
all:
@echo "[ribs2] build"
@$(MAKE) -C src -s
@echo "[ribs2] success"
@$(MAKE) -s $(EXAMPLES:%=example_%)
example_%:
@echo "[examples/$(@:example_%=%)] build"
@$(MAKE) -C examples/$(@:example_%=%)/src -s
@echo "[examples/$(@:example_%=%)] success"
unit_tests:
@echo "[$@] build"
@$(MAKE) -C tests/src -s
@echo "[$@] success"
clean: $(EXAMPLES:%=clean_example_%)
@echo "[ribs2] clean"
@$(MAKE) -C src -s clean
clean_example_%:
@echo "[examples/$(@:clean_example_%=%)] clean"
@$(MAKE) -C examples/$(@:clean_example_%=%)/src -s clean
etags:
@echo "etags"
find . -regex ".*\.[cChH]\(pp\)?" -print | etags -
test: all unit_tests
@echo "Running tests"
@./scripts/run_tests.sh