]> matita.cs.unibo.it Git - helm.git/commitdiff
added ocamlfind library checks to configure.ac
authorStefano Zacchiroli <zack@upsilon.cc>
Tue, 20 Apr 2004 09:41:10 +0000 (09:41 +0000)
committerStefano Zacchiroli <zack@upsilon.cc>
Tue, 20 Apr 2004 09:41:10 +0000 (09:41 +0000)
helm/matita/Makefile.in
helm/matita/configure.ac

index 02686b0fb1d0ff97879a106261539b9a4d9ce834..c784b0be698f86fb9a5472ec2f8a64d3824e2ab2 100644 (file)
@@ -2,8 +2,8 @@
 OCAMLFIND = @OCAMLFIND@
 CAMLP4O = @CAMLP4O@
 LABLGLADECC = @LABLGLADECC@
+REQUIRES = @FINDLIB_REQUIRES@
 
-REQUIRES = lablgtk2.glade helm-registry
 OCAML_FLAGS = -package "$(REQUIRES)" -pp $(CAMLP4O)
 OCAML_THREADS_FLAGS = -thread
 OCAML_DEBUG_FLAGS =
index cc0c50349ed1c8b1556e6f68de9f42cb681a8ba5..cc8d14a1384bc6b953b131fb16576da1a15ebb04 100644 (file)
@@ -6,14 +6,12 @@ if test $HAVE_OCAMLFIND = "yes"; then
 else
   AC_MSG_ERROR(could not find ocamlfind)
 fi
-
 AC_CHECK_PROG(HAVE_LABLGLADECC, lablgladecc2, yes, no)
 if test $HAVE_LABLGLADECC = "yes"; then
   LABLGLADECC="lablgladecc2"
 else
   AC_MSG_ERROR(could not find lablgladecc2)
 fi
-
 AC_CHECK_PROG(HAVE_CAMLP4O, camlp4o, yes, no)
 if test $HAVE_CAMLP4O = "yes"; then
   CAMLP4O="camlp4o"
@@ -21,9 +19,21 @@ else
   AC_MSG_ERROR(could not find camlp4o)
 fi
 
+FINDLIB_REQUIRES="lablgtk2.glade helm-registry"
+for r in $FINDLIB_REQUIRES
+do
+  AC_MSG_CHECKING(for $r ocaml library)
+  if $OCAMLFIND query $r &> /dev/null; then
+    AC_MSG_RESULT(yes)
+  else
+    AC_MSG_ERROR(could not find $r ocaml library)
+  fi
+done
+
 AC_SUBST(OCAMLFIND)
 AC_SUBST(CAMLP4O)
 AC_SUBST(LABLGLADECC)
+AC_SUBST(FINDLIB_REQUIRES)
 
 AC_OUTPUT([
   buildTimeConf.ml