From 55cfbf2bbf4bff7ad77c514ba30c7c0a3a90bab3 Mon Sep 17 00:00:00 2001 From: Joel Rosdahl Date: Wed, 28 Jan 2015 23:15:07 +0100 Subject: [PATCH] Link with -lws2_32 on Windows --- configure.ac | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/configure.ac b/configure.ac index 2cf293926..9e6558894 100644 --- a/configure.ac +++ b/configure.ac @@ -11,6 +11,7 @@ AC_CANONICAL_HOST case $host in *mingw32* | *cygwin* | *wince* | *mingwce*) + windows_os=yes AC_DEFINE(_WIN32_WINNT,0x0600, Windows Vista or newer is required) ;; esac @@ -122,6 +123,11 @@ else extra_ldflags="-lz" fi +dnl Linking on Windows needs ws2_32 +if test x${windows_os} = xyes; then + extra_ldflags="$extra_ldflags -lws2_32" +fi + AC_C_BIGENDIAN AC_C_INLINE -- 2.47.2