]>
Commit | Line | Data |
---|---|---|
a36b575a ÆAB |
1 | # The default target of this Makefile is... |
2 | all:: | |
3 | ||
8df786d2 ÆAB |
4 | # Import tree-wide shared Makefile behavior and libraries |
5 | include ../../shared.mak | |
6 | ||
a36b575a ÆAB |
7 | include ../../config.mak.uname |
8 | -include ../../config.mak.autogen | |
9 | -include ../../config.mak | |
10 | ||
0a43fb22 JS |
11 | TARGETS = scalar$(X) scalar.o |
12 | GITLIBS = ../../common-main.o ../../libgit.a ../../xdiff/lib.a | |
13 | ||
f2a2876f | 14 | all:: scalar$(X) ../../bin-wrappers/scalar |
0a43fb22 JS |
15 | |
16 | $(GITLIBS): | |
17 | $(QUIET_SUBDIR0)../.. $(QUIET_SUBDIR1) $(subst ../../,,$@) | |
18 | ||
19 | $(TARGETS): $(GITLIBS) scalar.c | |
20 | $(QUIET_SUBDIR0)../.. $(QUIET_SUBDIR1) $(patsubst %,contrib/scalar/%,$@) | |
21 | ||
22 | clean: | |
9187659f | 23 | $(RM) $(TARGETS) ../../bin-wrappers/scalar |
0a43fb22 | 24 | |
9187659f JS |
25 | ../../bin-wrappers/scalar: ../../wrap-for-bin.sh Makefile |
26 | @mkdir -p ../../bin-wrappers | |
27 | $(QUIET_GEN)sed -e '1s|#!.*/sh|#!$(SHELL_PATH_SQ)|' \ | |
28 | -e 's|@@BUILD_DIR@@|$(shell cd ../.. && pwd)|' \ | |
29 | -e 's|@@PROG@@|contrib/scalar/scalar$(X)|' < $< > $@ && \ | |
30 | chmod +x $@ | |
31 | ||
32 | test: all | |
33 | $(MAKE) -C t | |
34 | ||
35 | .PHONY: $(GITLIBS) all clean test FORCE |