summaryrefslogtreecommitdiff
path: root/debian/patches/0001-Fix-camlp4of.opt-detection-in-configure.patch
diff options
context:
space:
mode:
Diffstat (limited to 'debian/patches/0001-Fix-camlp4of.opt-detection-in-configure.patch')
-rw-r--r--debian/patches/0001-Fix-camlp4of.opt-detection-in-configure.patch111
1 files changed, 111 insertions, 0 deletions
diff --git a/debian/patches/0001-Fix-camlp4of.opt-detection-in-configure.patch b/debian/patches/0001-Fix-camlp4of.opt-detection-in-configure.patch
new file mode 100644
index 0000000..d4afd4a
--- /dev/null
+++ b/debian/patches/0001-Fix-camlp4of.opt-detection-in-configure.patch
@@ -0,0 +1,111 @@
+From: Sylvain Le Gall <gildor@debian.org>
+Date: Sat, 4 Jul 2009 21:05:17 +0000
+Subject: Fix camlp4of.opt detection in configure
+
+Signed-off-by: Sylvain Le Gall <gildor@debian.org>
+---
+ configure | 50 ++++++++++++++++++++++++++++++++++++++++++++++----
+ configure.ac | 6 +++++-
+ 2 files changed, 51 insertions(+), 5 deletions(-)
+
+diff --git a/configure b/configure
+index 7f5fa37..9587336 100755
+--- a/configure
++++ b/configure
+@@ -643,6 +643,7 @@ DIFF
+ TIME
+ OCAML_PKG_cil
+ OCAML_PKG_extlib
++CAMLP4OFOPT
+ CAMLP4OF
+ OCAMLFIND
+ OCAMLBUILD
+@@ -5295,8 +5296,8 @@ $as_echo "$as_me: error: You must have ocaml and findlib installed" >&2;}
+ { (exit 1); exit 1; }; }
+ fi
+
+-# Extract the first word of "camlp4of.opt", so it can be a program name with args.
+-set dummy camlp4of.opt; ac_word=$2
++# Extract the first word of "camlp4of", so it can be a program name with args.
++set dummy camlp4of; ac_word=$2
+ { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
+ $as_echo_n "checking for $ac_word... " >&6; }
+ if test "${ac_cv_prog_CAMLP4OF+set}" = set; then
+@@ -5312,7 +5313,7 @@ do
+ test -z "$as_dir" && as_dir=.
+ for ac_exec_ext in '' $ac_executable_extensions; do
+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+- ac_cv_prog_CAMLP4OF="camlp4of.opt"
++ ac_cv_prog_CAMLP4OF="camlp4of"
+ $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+ break 2
+ fi
+@@ -5333,8 +5334,49 @@ $as_echo "no" >&6; }
+ fi
+
+
++# Extract the first word of "camlp4of.opt", so it can be a program name with args.
++set dummy camlp4of.opt; ac_word=$2
++{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
++$as_echo_n "checking for $ac_word... " >&6; }
++if test "${ac_cv_prog_CAMLP4OFOPT+set}" = set; then
++ $as_echo_n "(cached) " >&6
++else
++ if test -n "$CAMLP4OFOPT"; then
++ ac_cv_prog_CAMLP4OFOPT="$CAMLP4OFOPT" # Let the user override the test.
++else
++as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
++for as_dir in $PATH
++do
++ IFS=$as_save_IFS
++ test -z "$as_dir" && as_dir=.
++ for ac_exec_ext in '' $ac_executable_extensions; do
++ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
++ ac_cv_prog_CAMLP4OFOPT="camlp4of.opt"
++ $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
++ break 2
++ fi
++done
++done
++IFS=$as_save_IFS
++
++ test -z "$ac_cv_prog_CAMLP4OFOPT" && ac_cv_prog_CAMLP4OFOPT="no"
++fi
++fi
++CAMLP4OFOPT=$ac_cv_prog_CAMLP4OFOPT
++if test -n "$CAMLP4OFOPT"; then
++ { $as_echo "$as_me:$LINENO: result: $CAMLP4OFOPT" >&5
++$as_echo "$CAMLP4OFOPT" >&6; }
++else
++ { $as_echo "$as_me:$LINENO: result: no" >&5
++$as_echo "no" >&6; }
++fi
++
++
++if ! test "x$CAMLP4OFOPT" = "xno"; then
++ CAMLP4OF=$CAMLP4OFOPT
++fi
+ if test "x$CAMLP4OF" = "xno"; then
+- { { $as_echo "$as_me:$LINENO: error: You must have camlp4 installed" >&5
++ { { $as_echo "$as_me:$LINENO: error: You must have camlp4 installed" >&5
+ $as_echo "$as_me: error: You must have camlp4 installed" >&2;}
+ { (exit 1); exit 1; }; }
+ fi
+diff --git a/configure.ac b/configure.ac
+index 174ed8c..c72bdb5 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -59,7 +59,11 @@ if test "x$OCAMLFIND" = "x"; then
+ fi
+
+ dnl Check for camlp4
+-AC_CHECK_PROG(CAMLP4OF,camlp4of.opt,camlp4of.opt,no)
++AC_CHECK_PROG(CAMLP4OF,camlp4of,camlp4of,no)
++AC_CHECK_PROG(CAMLP4OFOPT,camlp4of.opt,camlp4of.opt,no)
++if ! test "x$CAMLP4OFOPT" = "xno"; then
++ CAMLP4OF=$CAMLP4OFOPT
++fi
+ if test "x$CAMLP4OF" = "xno"; then
+ AC_MSG_ERROR([You must have camlp4 installed])
+ fi
+--