# https://ocaml.org/learn/tutorials/modules.html

all: 
	make clean_all
	make projet
	make clean

projet:
	ocamlopt -c projet.ml
	ocamlopt -c tests.ml
	ocamlopt -o tests projet.cmx tests.cmx

clean:
	echo "Nettoyage"
	find -name "*.cmx" -delete
	find -name "*.cmi" -delete
	find -name "*.cmo" -delete
	find -name "*.o" -delete
	
clean_all: clean
	echo "Nettoyage tout"
	if [ -f "tests" ]; then rm "tests"; fi