X-Git-Url: http://matita.cs.unibo.it/gitweb/?a=blobdiff_plain;f=helm%2FgTopLevel%2Fconfigure.ac;h=2cddc9dbed4004cdcb28b09eba877e14c09bcdd2;hb=5325734bc2e4927ed7ec146e35a6f0f2b49f50c1;hp=aaa661e0aee38df671c19e399e75d99913c198b3;hpb=43791584692853e980f96b58f36fdfb9c316728f;p=helm.git diff --git a/helm/gTopLevel/configure.ac b/helm/gTopLevel/configure.ac index aaa661e0a..2cddc9dbe 100644 --- a/helm/gTopLevel/configure.ac +++ b/helm/gTopLevel/configure.ac @@ -1,5 +1,33 @@ AC_INIT(gTopLevel.ml) +AC_CHECK_PROG(HAVE_OCAMLFIND, ocamlfind, yes, no) +if test $HAVE_OCAMLFIND = "yes"; then + OCAMLFIND="ocamlfind" +else + AC_MSG_ERROR(could not find ocamlfind) +fi +OCAMLFIND_COMMANDS="" +AC_CHECK_PROG(HAVE_OCAMLC_OPT, ocamlc.opt, yes, no) +if test $HAVE_OCAMLC_OPT = "yes"; then + if test "$OCAMLFIND_COMMANDS" = ""; then + OCAMLFIND_COMMANDS="ocamlc=ocamlc.opt" + else + OCAMLFIND_COMMANDS="$OCAMLFIND_COMMANDS ocamlc=ocamlc.opt" + fi +fi +AC_CHECK_PROG(HAVE_OCAMLOPT_OPT, ocamlopt.opt, yes, no) +if test $HAVE_OCAMLOPT_OPT = "yes"; then + if test "$OCAMLFIND_COMMANDS" = ""; then + OCAMLFIND_COMMANDS="ocamlopt=ocamlopt.opt" + else + OCAMLFIND_COMMANDS="$OCAMLFIND_COMMANDS ocamlopt=ocamlopt.opt" + fi +fi +if test "$OCAMLFIND_COMMANDS" != ""; then + OCAMLFIND="OCAMLFIND_COMMANDS='$OCAMLFIND_COMMANDS' $OCAMLFIND" +fi + + AC_ARG_WITH(term-editor, AS_HELP_STRING([--with-term-editor=(tex|textual)], [choose term editor (default is tex)]), @@ -46,6 +74,17 @@ else fi fi +if test $TERM_EDITOR = "tex"; then + CHOSEN_TERM_EDITOR="include TexTermEditor" +else + if test $TERM_EDITOR = "textual"; then + CHOSEN_TERM_EDITOR="include TermEditor" + else + AC_MSG_ERROR(unknwon term editor $TERM_EDITOR) + fi +fi + +AC_SUBST(OCAMLFIND) AC_SUBST(CHOSEN_TERM_EDITOR) AC_SUBST(CHOSEN_TERM_PARSER) AC_SUBST(CHOSEN_TRANSFORMER) @@ -54,5 +93,6 @@ AC_OUTPUT([ chosenTransformer.ml chosenTermEditor.ml disambiguatingParser.ml + Makefile ])