aboutsummaryrefslogtreecommitdiffstats
path: root/tools/configure
diff options
context:
space:
mode:
authorRoger Pau Monne <roger.pau@citrix.com>2012-10-30 18:11:02 +0000
committerRoger Pau Monne <roger.pau@citrix.com>2012-10-30 18:11:02 +0000
commit26104b09f9269bed2805423ba0f398254c324eee (patch)
tree94251e75270a3202ed3c935321b8cfe4df101684 /tools/configure
parentecf9846a6a200e8c8cfb26d409d18fd9615df9b9 (diff)
downloadxen-26104b09f9269bed2805423ba0f398254c324eee.tar.gz
xen-26104b09f9269bed2805423ba0f398254c324eee.tar.bz2
xen-26104b09f9269bed2805423ba0f398254c324eee.zip
autoconf: check for wget and ftp
Some OSes don't come with wget by default, so ftp should be choosen on those. Add an autoconf check to check for wget and ftp, and replace the usage of hardcoded wget in tools. [ Stubdom builds still use wget unconditionally. -iwj ] Signed-off-by: Christoph Egger <Christoph.Egger@amd.com> Signed-off-by: Roger Pau Monne <roger.pau@citrix.com> Acked-by: Ian Jackson <ian.jackson@eu.citrix.com> Committed-by: Ian Jackson <ian.jackson@eu.citrix.com>
Diffstat (limited to 'tools/configure')
-rwxr-xr-xtools/configure107
1 files changed, 107 insertions, 0 deletions
diff --git a/tools/configure b/tools/configure
index 6292a264c3..edf42f6b0d 100755
--- a/tools/configure
+++ b/tools/configure
@@ -606,6 +606,9 @@ libgcrypt
EXTFS_LIBS
system_aio
zlib
+FETCHER
+FTP
+WGET
glib_LIBS
glib_CFLAGS
PKG_CONFIG_LIBDIR
@@ -2392,6 +2395,8 @@ case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
+
+
# Enable/disable options
# Check whether --enable-githttp was given.
@@ -6095,6 +6100,108 @@ $as_echo "yes" >&6; }
fi
+# Extract the first word of "wget", so it can be a program name with args.
+set dummy wget; ac_word=$2
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+$as_echo_n "checking for $ac_word... " >&6; }
+if test "${ac_cv_path_WGET+set}" = set; then :
+ $as_echo_n "(cached) " >&6
+else
+ case $WGET in
+ [\\/]* | ?:[\\/]*)
+ ac_cv_path_WGET="$WGET" # Let the user override the test with a path.
+ ;;
+ *)
+ 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_path_WGET="$as_dir/$ac_word$ac_exec_ext"
+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ break 2
+ fi
+done
+ done
+IFS=$as_save_IFS
+
+ test -z "$ac_cv_path_WGET" && ac_cv_path_WGET="no"
+ ;;
+esac
+fi
+WGET=$ac_cv_path_WGET
+if test -n "$WGET"; then
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WGET" >&5
+$as_echo "$WGET" >&6; }
+else
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+fi
+
+
+if test x"$WGET" != x"no"; then :
+
+ FETCHER="$WGET -c -O"
+
+else
+
+ # Extract the first word of "ftp", so it can be a program name with args.
+set dummy ftp; ac_word=$2
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+$as_echo_n "checking for $ac_word... " >&6; }
+if test "${ac_cv_path_FTP+set}" = set; then :
+ $as_echo_n "(cached) " >&6
+else
+ case $FTP in
+ [\\/]* | ?:[\\/]*)
+ ac_cv_path_FTP="$FTP" # Let the user override the test with a path.
+ ;;
+ *)
+ 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_path_FTP="$as_dir/$ac_word$ac_exec_ext"
+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ break 2
+ fi
+done
+ done
+IFS=$as_save_IFS
+
+ test -z "$ac_cv_path_FTP" && ac_cv_path_FTP="no"
+ ;;
+esac
+fi
+FTP=$ac_cv_path_FTP
+if test -n "$FTP"; then
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FTP" >&5
+$as_echo "$FTP" >&6; }
+else
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+fi
+
+
+ if test x"$FTP" != x"no"; then :
+
+ FETCHER="$FTP -o"
+
+else
+
+ as_fn_error $? "cannot find wget or ftp" "$LINENO" 5
+
+fi
+
+fi
+
+
+
# Checks for libraries.
ac_fn_c_check_header_mongrel "$LINENO" "bzlib.h" "ac_cv_header_bzlib_h" "$ac_includes_default"
if test "x$ac_cv_header_bzlib_h" = x""yes; then :