added check for some networking headers

This commit is contained in:
2023-11-18 22:30:35 +09:00
parent 52829974ec
commit 6b774bb235
5 changed files with 24 additions and 7 deletions

View File

@ -208,6 +208,9 @@
/* Define to 1 if you have the <ndir.h> header file, and it defines `DIR'. */
#undef HAVE_NDIR_H
/* Define to 1 if you have the <netinet/if_ether.h> header file. */
#undef HAVE_NETINET_IF_ETHER_H
/* Define to 1 if you have the <netinet/in.h> header file. */
#undef HAVE_NETINET_IN_H

View File

@ -32,10 +32,15 @@
#include <errno.h>
#include <string.h> /* strerror */
#include <netinet/in.h>
#include <arpa/inet.h>
#include <net/if.h>
#include <netinet/if_ether.h>
#if defined(HAVE_NETINET_IN_H)
# include <netinet/in.h>
#endif
#if defined(HAVE_NET_IF_H)
# include <net/if.h>
#endif
#if defined(HAVE_NETINET_IF_ETHER_H)
# include <netinet/if_ether.h>
#endif
#if defined(HAVE_NETINET_SCTP_H)
# include <netinet/sctp.h>