From 5ac03256db0fe4ca7e3ad1117d096c3a76368b76 Mon Sep 17 00:00:00 2001 From: Andreas Baumann Date: Fri, 9 Jan 2015 09:46:07 +0100 Subject: backported CyaSSL/OpenSSL support for internal webserver instead of MatrixSSL --- release/src/router/cyassl/m4/lib_socket_nsl.m4 | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 release/src/router/cyassl/m4/lib_socket_nsl.m4 (limited to 'release/src/router/cyassl/m4/lib_socket_nsl.m4') diff --git a/release/src/router/cyassl/m4/lib_socket_nsl.m4 b/release/src/router/cyassl/m4/lib_socket_nsl.m4 new file mode 100644 index 00000000..e786e61c --- /dev/null +++ b/release/src/router/cyassl/m4/lib_socket_nsl.m4 @@ -0,0 +1,25 @@ +dnl @synopsis LIB_SOCKET_NSL +dnl +dnl This macro figures out what libraries are required on this platform +dnl to link sockets programs. +dnl +dnl The common cases are not to need any extra libraries, or to need +dnl -lsocket and -lnsl. We need to avoid linking with libnsl unless we +dnl need it, though, since on some OSes where it isn't necessary it +dnl will totally break networking. Unisys also includes gethostbyname() +dnl in libsocket but needs libnsl for socket(). +dnl +dnl @category Misc +dnl @author Russ Allbery +dnl @author Stepan Kasal +dnl @author Warren Young +dnl @version 2005-09-06 +dnl @license AllPermissive + +AC_DEFUN([LIB_SOCKET_NSL], +[ + AC_SEARCH_LIBS([gethostbyname], [nsl]) + AC_SEARCH_LIBS([socket], [socket], [], [ + AC_CHECK_LIB([socket], [socket], [LIBS="-lsocket -lnsl $LIBS"], + [], [-lnsl])]) +]) -- cgit v1.2.3-54-g00ecf