include Makefile.defs MODULES = common misc types request daemon response DESTDIR = $(shell $(OCAMLFIND) printconf stdlib) all: http.cmo opt: http.cmx world: all opt examples: $(MAKE) -C examples/ examples.opt: $(MAKE) -C examples/ opt include .depend depend: $(OCAMLDEP) *.ml *.mli > .depend %.cmi: %.mli $(OCAMLC) -c $< %.cmo: %.ml %.cmi $(OCAMLC) -c $< %.cmx: %.ml %.cmi $(OCAMLOPT) -c $< http.cmo: $(patsubst %,%.cmo,$(MODULES)) ocamlc -pack -o $@ $^ http.cmx: $(patsubst %,%.cmx,$(MODULES)) ocamlopt -pack -o $@ $^ meta: META META: META.in cat META.in | sed -e 's/@DISTVERSION@/$(DISTVERSION)/' > META clean: $(MAKE) -C examples/ clean -rm -f *.cm[ioax] *.o test{,.opt} distclean: clean $(MAKE) -C examples/ distclean -rm -f META dist: distclean depend mkdir $(DISTDIR) cp -r \ $(patsubst %,%.ml,$(MODULES)) $(patsubst %,%.mli,$(MODULES)) \ $(EXTRA_DIST) examples/ debian/ \ $(DISTDIR)/ -find $(DISTDIR)/ -type d -name CVS -exec rm -rf {} \; -find $(DISTDIR)/ -type f -name ".cvs*" -exec rm -f {} \; tar cvzf $(DISTDIR).tar.gz $(DISTDIR)/ rm -rf $(DISTDIR)/ install: META $(OCAMLFIND) install -destdir $(DESTDIR) $(PKGNAME) META *.mli http.* .PHONY: \ all opt world examples examples.opt depend clean distclean dist \ install meta