Revision f4f47e595980e39f9780b4538dbfe82d93c77cbe authored by Roberto Di Cosmo on 26 October 2011, 14:49:33 UTC, committed by Roberto Di Cosmo on 26 October 2011, 14:49:33 UTC
1 parent ee19a65
Makefile
NAME = parmap
OBJS = $(NAME)
INTF = $(foreach obj, $(OBJS),$(obj).cmi)
C_OBJS = ba_marshal_stubs
OBJECTS = $(foreach obj, $(OBJS),$(obj).cmo)
XOBJECTS = $(foreach obj, $(OBJS),$(obj).cmx)
LIBS = $(NAME).cma $(NAME).cmxa
OCAMLC = ocamlfind ocamlc -annot
OCAMLOPT = ocamlfind ocamlopt -annot
OCAMLDEP = ocamldep
ARCHIVE = $(NAME).cma
XARCHIVE = $(NAME).cmxa
REQUIRES = extlib unix bigarray
all: $(ARCHIVE) $(XARCHIVE)
.PHONY: install
install: $(LIBS) META
ocamlfind remove $(NAME)
ocamlfind install $(NAME) META $(INTF) $(LIBS) *.a *.mli
.PHONY: uninstall
uninstall:
ocamlfind remove $(NAME)
$(ARCHIVE): $(OBJECTS)
$(OCAMLC) -a -o $(ARCHIVE) -package "$(REQUIRES)" $(OBJECTS)
$(XARCHIVE): $(XOBJECTS)
$(OCAMLOPT) -a -o $(XARCHIVE) -package "$(REQUIRES)" $(XOBJECTS)
.SUFFIXES: .cmo .cmi .cmx .ml .mli
.ml.cmo:
$(OCAMLC) -package "$(REQUIRES)" -c $<
.mli.cmi:
$(OCAMLC) -package "$(REQUIRES)" -c $<
.ml.cmx:
$(OCAMLOPT) -package "$(REQUIRES)" -c $<
depend: *.ml *.mli
$(OCAMLDEP) *.ml *.mli >.depend
include .depend
.PHONY: clean
clean:
rm -f *.cmi *.cmo *.cmx *.cma *.cmxa *.a *.o
![swh spinner](/static/img/swh-spinner.gif)
Computing file changes ...