1 include ../../../Makefile.defs
5 REQUIRES = helm-library
11 LIBRARIES = $(shell $(OCAMLFIND) query -recursive -predicates "byte $(PREDICATES)" -format "%d/%a" $(REQUIRES))
12 LIBRARIES_OPT = $(shell $(OCAMLFIND) query -recursive -predicates "native $(PREDICATES)" -format "%d/%a" $(REQUIRES))
14 CMOS = $(MLS:%.ml=%.cmo)
15 CMXS = $(MLS:%.ml=%.cmx)
16 CMIS = $(MLIS:%.mli=%.cmi)
19 OCAMLC = $(OCAMLFIND) ocamlc -thread -package "$(REQUIRES)" -linkpkg -rectypes
20 OCAMLOPT = $(OCAMLFIND) ocamlopt -thread -package "$(REQUIRES)" -linkpkg -rectypes
21 OCAMLDEP = $(OCAMLFIND) ocamldep
28 opt: heights.opt $(EXTRAS) .depend.opt
31 heights: $(CMIS) $(CMOS) $(EXTRAS)
32 @echo " OCAMLC $(CMOS)"
33 $(H)$(OCAMLC) -o $@ $(CMOS)
35 heights.opt: $(CMIS) $(CMXS) $(EXTRAS)
36 @echo " OCAMLOPT $(CMXS)"
37 $(H)$(OCAMLOPT) -o $@ $(CMXS)
40 $(H)rm -f *.cm[iox] *.a *.o *.output
41 $(H)rm -f heights heights.opt $(CLEAN)
43 .depend: $(MLIS) $(MLS) $(EXTRAS)
44 @echo " OCAMLDEP $(MLIS) $(MLS)"
45 $(H)$(OCAMLDEP) $(MLIS) $(MLS) > .depend
47 .depend.opt: $(MLIS) $(MLS) $(EXTRAS)
48 @echo " OCAMLDEP -native $(MLIS) $(MLS)"
49 $(H)$(OCAMLDEP) -native $(MLIS) $(MLS) > .depend.opt
51 test: heights heights.conf.xml
53 $(H)$< 1> heights.txt 2> errors.txt
55 test.opt: heights.opt heights.conf.xml $(PACKAGES:%=%.conf.xml)
57 $(H)$< 1> heights.txt 2> errors.txt
62 $(H)cd .. && tar --exclude=heights/.svn -czf heights.tgz heights
66 depend.opt: .depend.opt
68 %.cmi: %.mli $(EXTRAS)
71 %.cmo %.cmi: %.ml $(EXTRAS) $(LIBRARIES)
74 %.cmx: %.ml $(EXTRAS) $(LIBRARIES_OPT)
77 %.ml %.mli: %.mly $(EXTRAS)
79 $(H)$(OCAMLYACC) -v $<
84 include ../../../Makefile.defs
86 ifeq ($(MAKECMDGOALS),)
90 ifeq ($(MAKECMDGOALS), all)
94 ifeq ($(MAKECMDGOALS), opt)
98 ifeq ($(MAKECMDGOALS), test)
102 ifeq ($(MAKECMDGOALS), test.opt)