Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/mono.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorlateralusX <lateralusx.github@gmail.com>2019-10-03 13:25:30 +0300
committerlateralusX <lateralusx.github@gmail.com>2019-10-03 13:25:30 +0300
commitaaa383b3e113b2416f9787d4eec6acabf7967d4f (patch)
tree4c2939512d23bab0f82afc2c1615a7d51fe6355b /autogen.sh
parent55be8289ff1601824707bb2ef9d554b01123f713 (diff)
Default --host in autogen.sh on cygwin when missing.
Diffstat (limited to 'autogen.sh')
-rwxr-xr-xautogen.sh14
1 files changed, 13 insertions, 1 deletions
diff --git a/autogen.sh b/autogen.sh
index 583e616b13f..ab7f0215d8a 100755
--- a/autogen.sh
+++ b/autogen.sh
@@ -160,7 +160,19 @@ if test x$MONO_EXTRA_CONFIGURE_FLAGS != x; then
echo "MONO_EXTRA_CONFIGURE_FLAGS is $MONO_EXTRA_CONFIGURE_FLAGS"
fi
-conf_flags="$MONO_EXTRA_CONFIGURE_FLAGS --enable-maintainer-mode --enable-compile-warnings" #--enable-iso-c
+host_conf_flag=
+build_uname_all=`(uname -a) 2>/dev/null`
+case "$build_uname_all" in
+CYGWIN*)
+ if [[ "$@" != *"--host="* ]]; then
+ echo "Missing --host parameter, configure using ./configure --host=i686-w64-mingw32 or --host=x86_64-w64-mingw32"
+ echo "Falling back using --host=x86_64-w64-mingw32 as default."
+ host_conf_flag="--host=x86_64-w64-mingw32"
+ fi
+ ;;
+esac
+
+conf_flags="$MONO_EXTRA_CONFIGURE_FLAGS --enable-maintainer-mode --enable-compile-warnings $host_conf_flag" #--enable-iso-c
if test x$NOCONFIGURE = x; then
echo Running $srcdir/configure $conf_flags "$@" ...