TIPE2021/Makefile
2021-06-09 20:31:47 +02:00

35 lines
827 B
Makefile

.PHONY: ascii tipe ocshell runall clean
%.ascii.txt: %.txt
iconv -f utf-8 -t ascii//TRANSLIT $< -o $@
ascii: $(shell find textes/ -type f -iname "*.txt" ! -iname "*.ascii.txt" | sed "s/\.txt/\.ascii\.txt/")
%.cmx: %.ml
ocamlopt -c $<
images.cmo: images.ml images.mli
ocamlc -c images.mli
ocamlc -c images.ml
Code.cmo: Code.ml Code.mli Math.cmo
ocamlc -c "Code.mli"
ocamlc -c "Code.ml"
Math.cmo: Math.ml Math.mli
ocamlc -c Math.mli
ocamlc -c Math.ml
tipe: tipe.cmx
ocamlopt -o tipe str.cmxa tipe.cmx
%.txt.test: %.ascii.txt tipe
./tipe $<
ocshell: images.cmo Math.cmo Code.cmo
rlwrap ocaml graphics.cma images.cmo Math.cmo Code.cmo
runall: $(shell find textes/ -type f -iname "*.txt" ! -iname "*.ascii.txt" | sed "s/\.txt/\.txt\.test/")
clean:
rm -rf tipe *.cmx *.cmi *.cmo *.o textes/*.ascii.txt *.ntl.ml