1 AC_INIT(matita/matitaTypes.ml)
3 # Distribution settings
4 # (i.e. settings (automatically) manipulated before a release)
6 DEFAULT_DBHOST="mysql://mowgli.cs.unibo.it"
7 RT_BASE_DIR_DEFAULT="`pwd`/matita"
9 DISTRIBUTED="no" # "yes" for distributed tarballs
10 # End of distribution settings
13 AC_CHECK_PROG(HAVE_OCAMLC, ocamlc, yes, no)
14 if test $HAVE_OCAMLC = "no"; then
15 AC_MSG_ERROR(could not find ocamlc)
17 AC_CHECK_PROG(HAVE_OCAMLOPT, ocamlopt, yes, no)
18 if test $HAVE_OCAMLOPT = "no"; then
19 AC_MSG_WARN(could not find ocamlopt: native code compilation disabled)
21 AC_CHECK_PROG(HAVE_OCAMLFIND, ocamlfind, yes, no)
22 if test $HAVE_OCAMLFIND = "yes"; then
25 AC_MSG_ERROR(could not find ocamlfind)
27 AC_CHECK_PROG(HAVE_LABLGLADECC, lablgladecc2, yes, no)
28 if test $HAVE_LABLGLADECC = "yes"; then
29 LABLGLADECC="lablgladecc2"
31 AC_MSG_ERROR(could not find lablgladecc2)
33 AC_CHECK_PROG(HAVE_CAMLP5O, camlp5o, yes, no)
34 if test $HAVE_CAMLP5O = "yes"; then
37 AC_MSG_ERROR(could not find camlp5o)
42 LIBSPATH="`pwd`/components"
43 OCAMLPATH="$LIBSPATH/METAS"
47 echo -n "creating METAs ... "
48 for f in $OCAMLPATH/meta.*.src; do
49 basename=`basename $f`
50 metaname=`echo $basename | sed 's/meta\.\(.*\)\.src/\1/'`
51 dirname=`echo $metaname | sed 's/^helm-//'`
52 metafile="$OCAMLPATH/META.$metaname"
54 echo "directory=\"$LIBSPATH/$dirname\"" >> $metafile
58 # (libs) findlib requisites
60 FINDLIB_LIBSREQUIRES="\
65 lablgtksourceview.gtksourceview \
73 # (Matita) findlib requisites
75 FINDLIB_COMREQUIRES="\
77 helm-cic_disambiguation \
81 helm-ng_disambiguation \
83 helm-acic_procedural \
88 helm-cic_exportation \
91 $FINDLIB_COMREQUIRES \
97 lablgtksourceview.gtksourceview \
100 for r in $FINDLIB_LIBSREQUIRES $FINDLIB_REQUIRES
102 AC_MSG_CHECKING(for $r ocaml library)
103 if OCAMLPATH=$OCAMLPATH $OCAMLFIND query $r &> /dev/null; then
106 AC_MSG_ERROR(could not find $r ocaml library)
110 OCAMLFIND_COMMANDS=""
111 # AC_CHECK_PROG(HAVE_OCAMLC_OPT, ocamlc.opt, yes, no)
112 # if test $HAVE_OCAMLC_OPT = "yes"; then
113 # if test "$OCAMLFIND_COMMANDS" = ""; then
114 # OCAMLFIND_COMMANDS="ocamlc=ocamlc.opt"
116 # OCAMLFIND_COMMANDS="$OCAMLFIND_COMMANDS ocamlc=ocamlc.opt"
119 # AC_CHECK_PROG(HAVE_OCAMLOPT_OPT, ocamlopt.opt, yes, no)
120 # if test $HAVE_OCAMLOPT_OPT = "yes"; then
121 # if test "$OCAMLFIND_COMMANDS" = ""; then
122 # OCAMLFIND_COMMANDS="ocamlopt=ocamlopt.opt"
124 # OCAMLFIND_COMMANDS="$OCAMLFIND_COMMANDS ocamlopt=ocamlopt.opt"
127 if test "$OCAMLFIND_COMMANDS" != ""; then
128 OCAMLFIND="OCAMLFIND_COMMANDS='$OCAMLFIND_COMMANDS' $OCAMLFIND"
131 AC_MSG_CHECKING(--enable-debug argument)
133 [ --enable-debug Turn on debugging],
135 case "${enableval}" in
138 *) AC_MSG_ERROR(bad value ${enableval} for --enable-debug) ;;
140 [GIVEN="no"; DEBUG="$DEBUG_DEFAULT"])
142 if test "$DEBUG" = "true"; then
143 MSG="$MSG, debugging enabled."
145 MSG="$MSG, debugging disabled."
149 AC_MSG_CHECKING(--with-runtime-dir argument)
150 AC_ARG_WITH(runtime-dir,
151 [ --with-runtime-dir Runtime directory (current working directory if not given)],
152 [ RT_BASE_DIR="${withval}" ],
153 [ RT_BASE_DIR="$RT_BASE_DIR_DEFAULT" ])
155 if test "yes" = "$RT_BASE_DIR"; then
158 ** empty --with-runtime-dir argument, please use --with-runtime-dir=value **"
162 AC_MSG_CHECKING(--with-dbhost argument)
164 [ --with-dbhost SQL database hostname],
165 [ DBHOST="${withval}" ],
166 [ DBHOST="$DEFAULT_DBHOST" ])
168 if test "yes" = "$DBHOST"; then
171 ** empty --with-dbhost argument, please use --with-dbhost=value **"
178 AC_SUBST(DISTRIBUTED)
179 AC_SUBST(FINDLIB_CREQUIRES)
180 AC_SUBST(FINDLIB_REQUIRES)
181 AC_SUBST(HAVE_OCAMLOPT)
182 AC_SUBST(LABLGLADECC)
183 AC_SUBST(MATITA_VERSION)
186 AC_SUBST(RT_BASE_DIR)
188 AC_SUBST(TRANSFORMER_MODULE)
191 components/extlib/componentsConf.ml
192 matita/matita.conf.xml
193 matita/buildTimeConf.ml
194 matita/gtkmathview.matita.conf.xml
195 matita/help/C/version.txt