1 # Public macros for the TeX Live (TL) tree.
2 # Copyright (C) 1997 Karl Berry <karl@cs.umb.edu>
3 # Copyright (C) 2009 Peter Breitenlohner <tex-live@tug.org>
4 # with help from Taco Hoekwater <taco@luatex.org>
6 # This file is free software; the copyright holders
7 # give unlimited permission to copy and/or distribute it,
8 # with or without modifications, as long as this notice is preserved.
12 # KPSE_CHECK_SOCKET_LIBS
13 # ----------------------
14 # Set ac_cv_search_connect as AC_SEARCH_LIBS([connect], [LIB...])
16 # -lsocket is needed on Solaris, at least. Maybe -lnsl on SCO, too?
18 # For WIN32 systems we need -lwsock32 but AC_SEARCH_LIBS would fail.
19 AC_DEFUN([KPSE_CHECK_SOCKET_LIBS],
20 [AC_REQUIRE([KPSE_CHECK_WIN32])
21 AS_IF([test "x$kpse_cv_have_win32" = xno],
23 AC_SEARCH_LIBS([connect], [socket nsl])
24 LIBS=$kpse_save_LIBS],
25 [AC_CHECK_LIB([wsock32], [main],
26 [ac_cv_search_connect=-lwsock32],
27 [ac_cv_search_connect=no])])
28 ]) # KPSE_CHECK_SOCKET_LIBS