Do use the actual ocaml stdlib (not the install dir) to find the
[oota-llvm.git] / bindings / ocaml / Makefile.ocaml
index 8ad085ecad3e1cf920099e7200bcdcb6dd3c4271..278b31ea3223f7d17eee562b99c15948cc9ad330 100644 (file)
 
 include $(LEVEL)/Makefile.config
 
-# Find the ocaml stdlib root. /usr/local/lib/ocaml is the default when built
-# from source; distros use something like /usr/lib/ocaml/3.10.0.
-ifndef OCAML_LIBDIR
-OCAML_LIBDIR := $(shell $(OCAMLC) -where)
-endif
-
-# CFLAGS needs to be set before Makefile.rules is included. Yes, ocaml puts its
-# includes under its libdir.
-CFLAGS += -I$(OCAML_LIBDIR)
+# CFLAGS needs to be set before Makefile.rules is included.
+CFLAGS += -I$(shell $(OCAMLC) -where)
 
 include $(LEVEL)/Makefile.common
 
 # Intentionally ignore PROJ_prefix here. We want the ocaml stdlib. However, the
-# user can override this with OCAML_LIBDIR.
+# user can override this with OCAML_LIBDIR or configure --with-ocaml-libdir=.
 PROJ_libocamldir := $(DESTDIR)$(OCAML_LIBDIR)
 OcamlDir := $(LibDir)/ocaml