Commit 98c6f80e authored by Pietro Abate's avatar Pietro Abate
Browse files

[r2004-04-23 12:48:29 by afrisch] Add cdo2cmo/Makefile to build oCaml_all.cma/cmxa

Original author: afrisch
Date: 2004-04-23 12:48:29+00:00
parent 0052e54e
PREFIX=/home/frisch/tmp/ocaml-3.07
MODEL=tree
OBJECTS=$(patsubst %,$(PREFIX)/%, $(UNITS))
XOBJECTS=$(OBJECTS:.cmo=.cmx)
ifeq ($(MODEL),flat)
UNITS= $(subst utils/,,$(UTILS)) \
$(subst parsing/,,$(PARSING)) \
$(subst typing/,,$(TYPING))
else
ifeq ($(MODEL),tree)
UNITS= $(UTILS) $(PARSING) $(TYPING)
else
$(error Set MODEL=flat or MODEL=tree)
endif
endif
oCaml_all.cma:
ocamlc -pack -o oCaml_all.cmo $(OBJECTS)
ocamlc -a -o oCaml_all.cma oCaml_all.cmo
cp oCaml_all.cma oCaml_all.cmi ..
rm -f oCaml_all.*
oCaml_all.cmxa:
ocamlopt -pack -o oCaml_all.cmx $(XOBJECTS)
ocamlopt -a -o oCaml_all.cmxa oCaml_all.cmx
cp oCaml_all.cmxa oCaml_all.cmi ..
rm -f oCaml_all.*
clean:
rm -f oCaml_all.* *~
UTILS=utils/misc.cmo utils/tbl.cmo utils/config.cmo \
utils/clflags.cmo utils/terminfo.cmo utils/ccomp.cmo utils/warnings.cmo \
utils/consistbl.cmo
PARSING=parsing/linenum.cmo parsing/location.cmo parsing/longident.cmo \
parsing/syntaxerr.cmo parsing/parser.cmo \
parsing/lexer.cmo parsing/parse.cmo parsing/printast.cmo
TYPING=typing/ident.cmo typing/path.cmo \
typing/primitive.cmo typing/types.cmo \
typing/btype.cmo typing/oprint.cmo \
typing/subst.cmo typing/predef.cmo \
typing/datarepr.cmo typing/env.cmo \
typing/typedtree.cmo typing/ctype.cmo \
typing/printtyp.cmo typing/includeclass.cmo \
typing/mtype.cmo typing/includecore.cmo \
typing/includemod.cmo typing/parmatch.cmo \
typing/typetexp.cmo typing/stypes.cmo typing/typecore.cmo \
typing/typedecl.cmo typing/typeclass.cmo \
typing/typemod.cmo
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment