AC_INIT(gMathView.ml) PACKAGE=lablgtkmathview LABLGTKMATHVIEW_MAJOR_VERSION=0 LABLGTKMATHVIEW_MINOR_VERSION=2 LABLGTKMATHVIEW_MICRO_VERSION=2 LABLGTKMATHVIEW_VERSION=$LABLGTKMATHVIEW_MAJOR_VERSION.$LABLGTKMATHVIEW_MINOR_VERSION.$LABLGTKMATHVIEW_MICRO_VERSION VERSION=$LABLGTKMATHVIEW_VERSION AC_SUBST(PACKAGE) AC_SUBST(VERSION) AC_CHECK_PROG(HAVE_GTKMATHVIEW, gtkmathview-config, yes, no) if test $HAVE_GTKMATHVIEW = "no"; then AC_MSG_ERROR(could not find gtkmathview configuration script, please make sure gtkmathview is installed) fi AC_CHECK_PROG(HAVE_OCAMLC, ocamlc, yes, no) if test $HAVE_OCAMLC = "no"; then AC_MSG_ERROR(could not find ocamlc in PATH, please make sure ocaml is installed) fi AC_MSG_CHECKING(for the ocaml library dir) OCAML_LIB_DIR=`ocamlc -v | grep "^Standard" | sed 's/^.*: *//'` AC_MSG_RESULT($OCAML_LIB_DIR) AC_CHECK_FILE($OCAML_LIB_DIR/lablgtk/gtk.ml, RES="yes" LABLGTK_LIB_DIR=$OCAML_LIB_DIR/lablgtk, RES="no" ) if test $RES = "no"; then RES="" AC_CACHE_VAL(lablgtkmathview_cv_LABLGTK_LIB_DIR, echo "In which directory can I find the lablgtk library? (I haven't found it in the usual location $OCAML_LIB_DIR/lablgtk)" read lablgtkmathview_cv_LABLGTK_LIB_DIR RES="Asked" ) LABLGTK_LIB_DIR=$lablgtkmathview_cv_LABLGTK_LIB_DIR if test "$RES" != "Asked"; then LABLGTK_LIB_DIR=`eval "echo $LABLGTK_LIB_DIR"` fi AC_CACHE_SAVE fi AC_CHECK_FILE($OCAML_LIB_DIR/mlminidom/minidom.mli, RES="yes" MLMINIDOM_LIB_DIR=$OCAML_LIB_DIR/mlminidom, RES="no" ) if test $RES = "no"; then RES="" AC_CACHE_VAL(lablgtkmathview_cv_MLMINIDOM_LIB_DIR, echo "In which directory can I find the mlminidom library? (I haven't found it in the usual location $OCAML_LIB_DIR/mlminidom)" read lablgtkmathview_cv_MLMINIDOM_LIB_DIR RES="Asked" ) MLMINIDOM_LIB_DIR=$lablgtkmathview_cv_MLMINIDOM_LIB_DIR if test "$RES" != "Asked"; then MLMINIDOM_LIB_DIR=`eval "echo $MLMINIDOM_LIB_DIR"` fi AC_CACHE_SAVE fi AC_SUBST(LABLGTKMATHVIEW_VERSION) AC_SUBST(OCAML_LIB_DIR) AC_SUBST(LABLGTK_LIB_DIR) AC_SUBST(MLMINIDOM_LIB_DIR) AC_OUTPUT([ Makefile lablgtkmathview.spec ])