]> matita.cs.unibo.it Git - helm.git/blob - helm/ocaml/grafite_parser/Makefile
test branch
[helm.git] / helm / ocaml / grafite_parser / Makefile
1 PACKAGE = grafite_parser
2 PREDICATES =
3
4 INTERFACE_FILES = \
5         dependenciesParser.mli  \
6         grafiteParser.mli       \
7         cicNotation2.mli        \
8         grafiteDisambiguator.mli \
9         grafiteDisambiguate.mli \
10         $(NULL)
11 IMPLEMENTATION_FILES = $(INTERFACE_FILES:%.mli=%.ml)
12
13 all: test_parser print_grammar test_dep
14 clean: clean_tests
15
16 # <cross> cross compatibility among ocaml 3.09 and ocaml 3.08, to be removed as
17 # soon as we have ocaml 3.09 everywhere and "loc" occurrences are replaced by
18 # "_loc" occurrences
19 UTF8DIR = $(shell $(OCAMLFIND) query helm-utf8_macros)
20 ULEXDIR = $(shell $(OCAMLFIND) query ulex)
21 MY_SYNTAXOPTIONS = -pp "camlp4o -I $(UTF8DIR) -I $(ULEXDIR) pa_extend.cmo pa_ulex.cma pa_unicode_macro.cma -loc loc"
22 grafiteParser.cmo: SYNTAXOPTIONS = $(MY_SYNTAXOPTIONS)
23 grafiteParser.cmx: SYNTAXOPTIONS = $(MY_SYNTAXOPTIONS)
24 depend: SYNTAXOPTIONS = $(MY_SYNTAXOPTIONS)
25 # </cross>
26 #
27 grafiteParser.cmo: OCAMLC = $(OCAMLC_P4)
28 grafiteParser.cmx: OCAMLOPT = $(OCAMLOPT_P4)
29
30 clean_tests:
31         rm -f test_parser{,.opt} test_dep{,.opt} print_grammar{,.opt}
32
33 LOCAL_LINKOPTS = -package helm-$(PACKAGE) -linkpkg
34 test: test_parser print_grammar test_dep
35 test_parser: test_parser.ml $(PACKAGE).cma
36         $(OCAMLC) $(LOCAL_LINKOPTS) -o $@ $<
37 print_grammar: print_grammar.ml $(PACKAGE).cma
38         $(OCAMLC) $(LOCAL_LINKOPTS) -o $@ $<
39 test_dep: test_dep.ml $(PACKAGE).cma
40         $(OCAMLC) $(LOCAL_LINKOPTS) -o $@ $<
41
42 include ../Makefile.common