summaryrefslogtreecommitdiff
path: root/xtrans.m4
diff options
context:
space:
mode:
authorYaakov Selkowitz <yselkowitz@users.sourceforge.net>2009-10-15 15:25:57 -0500
committerAlan Coopersmith <alan.coopersmith@sun.com>2009-10-15 17:09:58 -0700
commitd009d995d85dc499dc3f1add34da551fdf703b60 (patch)
treea539ed271ced6f9a82cc4f3005e9564294a11afb /xtrans.m4
parent773478581913bafa5e98a7bff3260efb0c4f2ab6 (diff)
Don't use -lws2_32 on Cygwin
On Cygwin, both the (builtin) *NIX socket API and WinSock (via w32api) are available, but they cannot be mixed. We use *NIX APIs for everything else, so we do not want to mix in WinSock here. Signed-off-by: Yaakov Selkowitz <yselkowitz@users.sourceforge.net>
Diffstat (limited to 'xtrans.m4')
-rw-r--r--xtrans.m44
1 files changed, 3 insertions, 1 deletions
diff --git a/xtrans.m4 b/xtrans.m4
index f6bc2ea..b58081c 100644
--- a/xtrans.m4
+++ b/xtrans.m4
@@ -32,7 +32,9 @@ AC_DEFUN([XTRANS_TCP_FLAGS],[
# SVR4 hides these in libraries other than libc
AC_SEARCH_LIBS(socket, [socket])
AC_SEARCH_LIBS(gethostbyname, [nsl])
- AC_HAVE_LIBRARY([ws2_32])
+ if test "$ac_cv_search_socket$ac_cv_search_gethostbyname" = "nono"; then
+ AC_HAVE_LIBRARY([ws2_32])
+ fi
# Needs to come after above checks for libsocket & libnsl for SVR4 systems
AC_ARG_ENABLE(ipv6,