Skip to content

Commit

Permalink
Check sockaddr* struct fields.
Browse files Browse the repository at this point in the history
  • Loading branch information
vstakhov committed Dec 30, 2014
1 parent 99970ea commit fd859d6
Showing 1 changed file with 21 additions and 0 deletions.
21 changes: 21 additions & 0 deletions configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -107,6 +107,9 @@ AC_CHECK_HEADERS_ONCE([stdio.h])
AC_CHECK_HEADERS_ONCE([float.h])
AC_CHECK_HEADERS_ONCE([math.h])
AC_CHECK_HEADERS_ONCE([osreldate.h])
AC_CHECK_HEADERS_ONCE([sys/socket.h])
AC_CHECK_HEADERS_ONCE([netinet/in.h])
AC_CHECK_HEADERS_ONCE([netinet/in6.h])
AC_CHECK_HEADERS_ONCE([dirent.h], [sys/ndir.h], [sys/dir.h], [ndir.h])

AC_CHECK_HEADER([regex.h], [
Expand Down Expand Up @@ -141,6 +144,24 @@ AC_CHECK_FUNCS_ONCE([closefrom])
AC_CHECK_FUNCS_ONCE([dirfd])
AC_CHECK_FUNCS_ONCE([sysconf])

AC_CHECK_MEMBERS([struct in6_addr.s6_addr32,
struct in6_addr.s6_addr16,
struct sockaddr_in.sin_len,
struct sockaddr_in6.sin6_len,
struct sockaddr_storage.ss_family,
struct sockaddr_storage.__ss_family], , ,
[#include <sys/types.h>
#ifdef HAVE_NETINET_IN_H
#include <netinet/in.h>
#endif
#ifdef HAVE_NETINET_IN6_H
#include <netinet/in6.h>
#endif
#ifdef HAVE_SYS_SOCKET_H
#include <sys/socket.h>
#endif
])

PKG_PROG_PKG_CONFIG

AC_DEFUN([AC_PROG_GIT], [AC_CHECK_PROG(GITBIN,git,yes)])
Expand Down

0 comments on commit fd859d6

Please sign in to comment.