diff options
Diffstat (limited to 'util')
-rw-r--r-- | util/configure.ac | 14 | ||||
-rw-r--r-- | util/src/Makefile.am | 5 | ||||
-rw-r--r-- | util/src/minizip/Makefile.am | 2 |
3 files changed, 18 insertions, 3 deletions
diff --git a/util/configure.ac b/util/configure.ac index 65555da..ccb808b 100644 --- a/util/configure.ac +++ b/util/configure.ac @@ -196,6 +196,20 @@ AC_SUBST([PLATFORM]) AC_DEFINE([HOST_OS_MINGW], 1, [define if we are on mingw]) +dnl Check for cygwin and mingw builds to allow building DLLs +WIN32_EXTRA_LIBADD= +WIN32_EXTRA_LDFLAGS= +case "$host" in + *-*-cygwin*) + WIN32_EXTRA_LDFLAGS="-no-undefined -avoid-version" + ;; + *-*-mingw*) + WIN32_EXTRA_LDFLAGS="-no-undefined -avoid-version" + ;; +esac +AC_SUBST(WIN32_EXTRA_LIBADD) +AC_SUBST(WIN32_EXTRA_LDFLAGS) + AC_MSG_CHECKING(whether to build guththila xml parser library) AC_ARG_ENABLE(guththila, [ --enable-guththila build guththila xml parser library wrapper. default=no], [ case "${enableval}" in diff --git a/util/src/Makefile.am b/util/src/Makefile.am index fb40027..0cc7fbf 100644 --- a/util/src/Makefile.am +++ b/util/src/Makefile.am @@ -56,9 +56,10 @@ libaxutil_la_SOURCES = hash.c \ libaxutil_la_LIBADD = $(top_builddir)/src/platforms/$(PLATFORM)/libaxis2_$(PLATFORM).la \ -lpthread \ - @ZLIBLIBS@ + @ZLIBLIBS@ \ + $(WIN32_EXTRA_LIBADD) -libaxutil_la_LDFLAGS = -version-info $(VERSION_NO) +libaxutil_la_LDFLAGS = -version-info $(VERSION_NO) $(WIN32_EXTRA_LDFLAGS) INCLUDES = -I$(top_builddir)/include diff --git a/util/src/minizip/Makefile.am b/util/src/minizip/Makefile.am index f9e239e..9cf9fe1 100644 --- a/util/src/minizip/Makefile.am +++ b/util/src/minizip/Makefile.am @@ -19,7 +19,7 @@ libaxis2_minizip_la_SOURCES = ioapi.c \ archive_extract.c \ crypt.c -libaxis2_minizip_la_LDFLAGS = -version-info $(VERSION_NO) +libaxis2_minizip_la_LDFLAGS = -version-info $(VERSION_NO) $(WIN32_EXTRA_LDFLAGS) INCLUDES = -I$(top_builddir)/include \ -I$(top_builddir)/platforms |