1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37
|
#! /bin/sh
# $Id: configure,v 1.7 2004/07/02 09:58:47 barnier Exp $
# Checking for ocaml >= $ocaml_min_version (i.e. with -where option and
# compilation of or-patterns fixed)
ocaml_min_version=3.02
echo "Checking for OCaml compiler (>= ${ocaml_min_version})..."
if expr `ocamlc -version` \>\= $ocaml_min_version >/dev/null 2>&1; then
version=`ocamlc -version`
echo "OCaml $version found"
else
echo "Aborting... OCaml compiler is either missing or too old"
exit 1
fi
# Default place for facile in OCaml library directory
faciledir=`ocamlc -where`/facile
# Parse command-line arguments
while : ; do
case "$1" in
"") break;;
-faciledir|--faciledir)
faciledir=$2; shift;;
*) echo "Unknown option \"$1\"." 1>&2; exit 2;;
esac
shift
done
# Generates config_Makefile
echo FACILEDIR=$faciledir > config_Makefile
echo FaCiLe directory: $faciledir
|