]> matita.cs.unibo.it Git - helm.git/blobdiff - helm/hbugs/common/Makefile
fixed a typo (inside a comment)
[helm.git] / helm / hbugs / common / Makefile
index 4055f88c985df77c1e6f8116e2d611e0bb35c3f1..ca95aae243384c12e66c724c1cd5385fcc43f60e 100644 (file)
@@ -1,19 +1,34 @@
-REQUIRES = pcre pxp
+REQUIRES = helm-xml helm-pxp pcre pxp http
 COMMONOPTS = -package "$(REQUIRES)" -pp camlp4o
-OCAMLC = ocamlfind ocamlc $(COMMONOPTS)
-OCAMLOPT = ocamlfind ocamlopt $(COMMONOPTS)
-OCAMLDEP = ocamlfind ocamldep $(COMMONOPTS)
+OCAMLFIND = ocamlfind
+OCAMLC = $(OCAMLFIND) ocamlc -thread $(COMMONOPTS)
+OCAMLOPT = $(OCAMLFIND) ocamlopt -thread $(COMMONOPTS)
+OCAMLDEP = $(OCAMLFIND) ocamldep $(COMMONOPTS)
+OCAMLDOC =     \
+       ocamldoc        \
+               $(shell $(OCAMLFIND) query -i-format helm-xml)  \
+               $(shell $(OCAMLFIND) query -i-format helm-pxp)  \
+               $(shell $(OCAMLFIND) query -i-format pcre)      \
+               $(shell $(OCAMLFIND) query -i-format pxp-engine)        \
+               $(shell $(OCAMLFIND) query -i-format threads)   \
+               $(shell $(OCAMLFIND) query -i-format http)
 MODULES =      \
-       hbugs_types threadSafe hbugs_misc hbugs_id_generator hbugs_messages
+       hbugs_types threadSafe hbugs_misc       \
+       hbugs_common hbugs_id_generator hbugs_messages
 
 OBJS = $(patsubst %,%.cmo,$(MODULES))
 OBJSOPT = $(patsubst %,%.cmx,$(MODULES))
+DEPS = $(shell $(OCAMLFIND) query -recursive -predicates byte -format "%d/%a" $(REQUIRES))
+DEPSOPT = $(shell $(OCAMLFIND) query -recursive -predicates native -format "%d/%a" $(REQUIRES))
 
 all: byte
 byte: $(OBJS)
 opt: $(OBJSOPT)
 world: byte opt
 
+hbugs_common.dot: *.ml *.mli
+       $(OCAMLDOC) -dot -o $@ $^
+
 include .depend
 depend:
        $(OCAMLDEP) *.ml *.mli > .depend
@@ -25,6 +40,8 @@ depend:
 %.cmx: %.ml %.cmi
        $(OCAMLOPT) -c $<
 include Makefile.overrides
+$(OBJS): $(DEPS)
+$(OBJSOPT): $(DEPSOPT)
 
 distclean: clean
 clean: