This commit is contained in:
Dmitry Boulytchev 2020-02-16 02:02:54 +03:00
parent 3b9fac8e9a
commit 83bd6d7ad8
5 changed files with 8 additions and 6 deletions

View file

@ -2,16 +2,17 @@ TOPFILE = lamac
OCAMLC = ocamlfind c
OCAMLOPT = ocamlfind opt
OCAMLDEP = ocamlfind dep
SOURCES = Language.ml SM.ml X86.ml version.ml Driver.ml
SOURCES = version.ml stdpath.ml Language.ml SM.ml X86.ml Driver.ml
CAMLP5 = -syntax camlp5o -package ostap.syntax,GT.syntax.all
PXFLAGS = $(CAMLP5)
BFLAGS = -rectypes -g
OFLAGS = $(BFLAGS)
all: version .depend $(TOPFILE)
all: metagen .depend $(TOPFILE)
version:
metagen:
echo "let version = \"Version `git rev-parse --abbrev-ref HEAD`, `git rev-parse --short HEAD`, `git rev-parse --verify HEAD |git show --no-patch --no-notes --pretty='%cd'`\"" > version.ml
echo "let path = \"`opam var share`/Lama\"" > stdpath.ml
.depend: $(SOURCES)
$(OCAMLDEP) $(PXFLAGS) *.ml > .depend