From 6b6a46b593dd5beb3384850f54e4338bf8a5d287 Mon Sep 17 00:00:00 2001 From: Andrea Zagli Date: Mon, 14 Nov 2011 16:29:11 +0100 Subject: [PATCH] Added wsock32 library when under win. --- configure.ac | 16 ++++++++++++++++ src/Makefile.am | 9 ++++++++- 2 files changed, 24 insertions(+), 1 deletion(-) diff --git a/configure.ac b/configure.ac index 310c238..980eaab 100644 --- a/configure.ac +++ b/configure.ac @@ -66,6 +66,22 @@ AC_C_CONST # Checks for library functions. # Checks for library functions. + +dnl ****************************** +dnl Check for Operating System +dnl ****************************** + +platform_win32=no + +case "$host" in +*-mingw*) + platform_win32=yes + ;; +esac + +AM_CONDITIONAL(PLATFORM_WIN32, [test $platform_win32 = yes]) + +# Output files AC_CONFIG_FILES([ libsolipa.pc libsolipaooo.pc diff --git a/src/Makefile.am b/src/Makefile.am index dda206a..eb9fa53 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -1,7 +1,14 @@ guidir = $(datadir)/$(PACKAGE)/gui +if PLATFORM_WIN32 +WIN32_LIBS=-lwsock32 +else +WIN32_LIBS= +endif + LIBS = $(SOLIPA_LIBS) \ - $(CAMEL_LIBS) + $(CAMEL_LIBS) \ + $(WIN32_LIBS) if HAVE_CAMEL3 CAMEL3 = -DCAMEL3=\"yes\" -- 2.49.0