diff --git a/Makefile b/Makefile index 43c249a7..b02343cf 100644 --- a/Makefile +++ b/Makefile @@ -1,5 +1,16 @@ +# Including a Makefile from the visitors package, but making sure +# to give decent errors. + # make src/Ast.processed.ml -include $(shell ocamlfind query visitors)/Makefile.preprocess +_:=$(shell ocamlfind query) +ifneq ($(.SHELLSTATUS),0) +_: $(error "'ocamlfind query' failed, please install OCaml and put it in your PATH) +endif +visitors_root:=$(shell ocamlfind query visitors) +ifneq ($(.SHELLSTATUS),0) +_: $(error "'ocamlfind query visitors' failed, please 'opam install visitors') +endif +include $(visitors_root)/Makefile.preprocess .PHONY: all minimal clean test pre krmllib install