summaryrefslogtreecommitdiffstats
path: root/util/configure.ac
diff options
context:
space:
mode:
Diffstat (limited to 'util/configure.ac')
-rw-r--r--util/configure.ac14
1 files changed, 14 insertions, 0 deletions
diff --git a/util/configure.ac b/util/configure.ac
index 1e7169e..65555da 100644
--- a/util/configure.ac
+++ b/util/configure.ac
@@ -135,6 +135,7 @@ dnl AC_FUNC_REALLOC
AC_CHECK_FUNCS(getifaddrs)
# System-dependent adjustments.
+mingw=no
cygwin=no
darwin=no
solaris=no
@@ -155,11 +156,18 @@ alpha*)
;;
esac
+PLATFORM=unix
+
case "${host_os}" in
cygwin)
cygwin=yes
no_undefined=yes
;;
+mingw32)
+ mingw=yes
+ no_undefined=yes
+ PLATFORM=windows
+ ;;
darwin*)
darwin=yes
dnl if test x"$GCC" = xyes
@@ -178,10 +186,15 @@ solaris*)
esac
AM_CONDITIONAL(HOST_OS_CYGWIN, test x$cygwin = xyes)
+AM_CONDITIONAL(HOST_OS_MINGW, test x$mingw = xyes)
AM_CONDITIONAL(HOST_OS_DARWIN, test x$darwin = xyes)
AM_CONDITIONAL(HOST_OS_SOLARIS, test x$solaris = xyes)
AM_CONDITIONAL(NO_UNDEFINED, test x$no_undefined = xyes)
+PLATFORM_SUB=platforms/${PLATFORM}
+AC_SUBST([PLATFORM_SUB])
+AC_SUBST([PLATFORM])
+AC_DEFINE([HOST_OS_MINGW], 1, [define if we are on mingw])
AC_MSG_CHECKING(whether to build guththila xml parser library)
AC_ARG_ENABLE(guththila, [ --enable-guththila build guththila xml parser library wrapper. default=no],
@@ -283,6 +296,7 @@ AC_SUBST(TESTDIR)
AC_CONFIG_FILES([Makefile \
src/Makefile \
src/platforms/unix/Makefile \
+ src/platforms/windows/Makefile \
src/minizip/Makefile \
include/Makefile \
test/Makefile \