socket.m4 393 B

12345678910111213
  1. AC_DEFUN([AC_REQUIRE_SOCKET],
  2. [
  3. AC_SEARCH_LIBS(socket, [xnet bsd socket inet], [have_socket=yes])
  4. if test x"$have_socket" = x"yes"; then
  5. AC_SEARCH_LIBS(gethostbyname, [bsd socket inet netinet nsl])
  6. AC_CHECK_MEMBERS([struct linger.l_linger], , , [
  7. #include <sys/types.h>
  8. #include <sys/socket.h>
  9. ])
  10. else
  11. AC_MSG_ERROR([Couldn't find socket functions])
  12. fi
  13. ])