Merge branch 'ocamlbuild-port' of ssh://git.nguyen.vg/tatoo into ocamlbuild-port
[tatoo.git] / Makefile.in
1 CAMLP4FLAGS=@CAMLP4FLAGS@
2 OCAMLBUILDFLAGS=-j 0 -use-ocamlfind @OCAMLBUILDFLAGS@  $(CAMLP4FLAGS:%=-tag %)
3 OCAMLBUILD=@OCAMLBUILD@
4 PACKAGE = @PACKAGE_TARNAME@
5 NATIVE=$(PACKAGE).native
6 BYTE=$(PACKAGE).byte
7 TARGETS=$(NATIVE)
8
9 ifeq ($(BYTE), true)
10         TARGETS += $(BYTE)
11 endif
12
13 INLINE=@INLINE@
14 TAGS= -tag 'inline($(INLINE))'
15
16
17 .PHONY: clean distclean test test_byte test_native do_test all $(TARGETS)
18
19 all:
20         @
21
22 %:
23         @ $(OCAMLBUILD) $(OCAMLBUILDFLAGS)  $@
24
25 clean:
26         @ $(OCAMLBUILD) $(OCAMLBUILDFLAGS) -clean
27
28 distclean: clean
29         @ rm -rf configure config.log config.status autom4te.cache Makefile
30
31
32 test:
33         ${MAKE} test_native
34         ${MAKE} test_byte
35
36 test_native: PROG=$(NATIVE)
37 test_native: $(NATIVE) do_test
38
39 test_byte: PROG=$(BYTE)
40 test_byte: $(BYTE) do_test
41
42
43 do_test:
44                 for test in tests/test_*.sh ; \
45                 do \
46                         $${test} $(PROG) tests ; \
47                 done