Source

ocaml-lib / makefile

Full commit
OCAMLLEX=ocamllex
OCAMLC=ocamlc -g
OCAMLOPT=ocamlopt
INCLUDES=            # all relevant -I options here
OCAMLFLAGS= -pp "camlp4o pa_op.cmo" -thread $(INCLUDES)    # add other options for ocamlc here

.SUFFIXES: .mll .ml .mli .cmo .cmi

# Make all
all: common.cmo threads_common.cmo token.cmo lexer.cmo syntax.cmo lSet.cmo cis.cmo setset.cmo ext.cmo term.cmo cache.cmi cache.cmo logdag.cmi logdag.cmo
	echo

# archiving
lib.tgz:
	tar cfz lib.tgz make* *,v *.mll *.ml *.mli */config* */make* */Make* */*.c */*.h */*.ml */*.mli  

# Common rules

%.ml: %.mll
	$(OCAMLLEX) $<

%.cmo: %.ml
	$(OCAMLC) $(OCAMLFLAGS) -c $<
	$(OCAMLOPT) $(OCAMLFLAGS) -c $<

%.cmi: %.mli
	$(OCAMLC) $(OCAMLFLAGS) -c $<


# Clean up
clean:
	rm -f *.cm[ioax]