Skip to content

Commit

Permalink
[fix] fedora,configure: work with non fresh install
Browse files Browse the repository at this point in the history
  • Loading branch information
OpaOnWindowsNow committed Jan 13, 2012
1 parent 489c62b commit 62e3dc8
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions configure
Expand Up @@ -194,9 +194,11 @@ else
echo "Ocaml 3.12 or newer is required. It's usually found in package 'ocaml'."
false
fi
OCAMLOPT_DIR=$(dirname $(which $OCAMLOPT))


echo-check ocamlbuild
: ${OCAMLBUILD:=$(dirname $OCAMLOPT)/ocamlbuild}
: ${OCAMLBUILD:=$OCAMLOPT_DIR/ocamlbuild}
if [ -n "$IS_RELEASE" ]; then
OCAMLBUILD_FLAGS="${OCAMLBUILD_FLAGS:-} -tag release -tag noassert"
else
Expand Down Expand Up @@ -279,8 +281,8 @@ EOF
check-ocaml

echo-check for camlp4
: ${CAMLP4O:=$(dirname $OCAMLOPT)/camlp4o}
: ${CAMLP4ORF:=$(dirname $OCAMLOPT)/camlp4orf}
: ${CAMLP4O:=$OCAMLOPT_DIR/camlp4o}
: ${CAMLP4ORF:=$OCAMLOPT_DIR/camlp4orf}
if [ -x "$CAMLP4O" ] && [ -x "$CAMLP4ORF" ]
then echo-ok $CAMLP4O
else
Expand Down Expand Up @@ -319,7 +321,7 @@ if [ "X$NO_CAMLIDL" = "X1" ]; then
echo-ok Disabled
elif
[ -e $OCAMLLIB/libcamlidl.a ] &&
CAMLIDL=${CAMLIDL:-$(dirname "$OCAMLOPT")/camlidl} && [ -x "$CAMLIDL" ] ||
CAMLIDL=${CAMLIDL:-$OCAMLOPT_DIR)/camlidl} && [ -x "$CAMLIDL" ] ||
CAMLIDL=$(which camlidl)
then
HAS_CAMLIDL=1
Expand Down Expand Up @@ -423,7 +425,7 @@ if [ -n "${NO_OCAMLFIND:-}" ]; then
OCAMLFIND=
echo-skip Disabled
elif [ -z "${OCAMLFIND:-}" ]; then
OCAMLFIND=$(dirname $OCAMLOPT)/ocamlfind
OCAMLFIND=$OCAMLOPT_DIR/ocamlfind
if [ ! -x "$OCAMLFIND" ]; then
OCAMLFIND=$OCAMLLIB/../../bin/ocamlfind
fi
Expand Down

0 comments on commit 62e3dc8

Please sign in to comment.