aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLasse Collin <lasse.collin@tukaani.org>2015-08-11 13:21:52 +0300
committerLasse Collin <lasse.collin@tukaani.org>2015-09-25 14:03:24 +0300
commit85a6dfed53477906bfe9a7c0123dd412e391cb48 (patch)
tree365c7544f3436ad742674362eaea0268c479e11c
parentWindows: Define DLL_EXPORT when building liblzma.dll with MSVC. (diff)
downloadxz-85a6dfed53477906bfe9a7c0123dd412e391cb48.tar.xz
Build: Support building of MSYS2 binaries.
-rw-r--r--configure.ac16
1 files changed, 11 insertions, 5 deletions
diff --git a/configure.ac b/configure.ac
index 0efaaecc..13d3a8d9 100644
--- a/configure.ac
+++ b/configure.ac
@@ -34,8 +34,8 @@ AC_CANONICAL_HOST
# We do some special things on Windows (32-bit or 64-bit) builds.
case $host_os in
- mingw* | cygwin*) is_w32=yes ;;
- *) is_w32=no ;;
+ mingw* | cygwin* | msys) is_w32=yes ;;
+ *) is_w32=no ;;
esac
AM_CONDITIONAL([COND_W32], [test "$is_w32" = yes])
@@ -43,9 +43,15 @@ AM_CONDITIONAL([COND_W32], [test "$is_w32" = yes])
# executables. Cygwin is an exception to this, since it is recommended
# that symlinks don't have the .exe suffix. To make this work, we
# define LN_EXEEXT.
+#
+# MSYS2 is treated the same way as Cygwin. It uses plain "msys" like
+# the original MSYS when building MSYS/MSYS2-binaries. Hopefully this
+# doesn't break things for the original MSYS developers. Note that this
+# doesn't affect normal MSYS/MSYS2 users building non-MSYS/MSYS2 binaries
+# since in that case the $host_os is usually mingw32.
case $host_os in
- cygwin) LN_EXEEXT= ;;
- *) LN_EXEEXT='$(EXEEXT)' ;;
+ cygwin | msys) LN_EXEEXT= ;;
+ *) LN_EXEEXT='$(EXEEXT)' ;;
esac
AC_SUBST([LN_EXEEXT])
@@ -283,7 +289,7 @@ if test "x$enable_assembler" = xyes; then
case $host_os in
# Darwin should work too but only if not creating universal
# binaries. Solaris x86 could work too but I cannot test.
- linux* | *bsd* | mingw* | cygwin* | *djgpp*)
+ linux* | *bsd* | mingw* | cygwin* | msys | *djgpp*)
case $host_cpu in
i?86) enable_assembler=x86 ;;
x86_64) enable_assembler=x86_64 ;;