From 70e786627144e5c62a3efe3a0f95dbcd9946dc48 Mon Sep 17 00:00:00 2001 From: Con Kolivas Date: Tue, 22 Mar 2011 21:47:24 +1100 Subject: [PATCH] Include arpa/inet.h for those OSs that have endian details elsewhere. --- configure.ac | 2 +- lrzip.c | 3 +++ main.c | 3 +++ runzip.c | 3 +++ rzip.c | 3 +++ stream.c | 4 ++++ 6 files changed, 17 insertions(+), 1 deletion(-) diff --git a/configure.ac b/configure.ac index ca8c34e..f5548f8 100644 --- a/configure.ac +++ b/configure.ac @@ -68,7 +68,7 @@ fi AC_CHECK_HEADERS(fcntl.h sys/time.h unistd.h sys/mman.h) AC_CHECK_HEADERS(ctype.h errno.h sys/resource.h) -AC_CHECK_HEADERS(endian.h sys/endian.h) +AC_CHECK_HEADERS(endian.h sys/endian.h arpa/inet.h) AC_TYPE_OFF_T AC_TYPE_SIZE_T diff --git a/lrzip.c b/lrzip.c index bfe25ad..b7283ce 100644 --- a/lrzip.c +++ b/lrzip.c @@ -42,6 +42,9 @@ #elif HAVE_SYS_ENDIAN_H # include #endif +#ifdef HAVE_ARPA_INET_H +# include +#endif #include "md5.h" #include "rzip.h" diff --git a/main.c b/main.c index 4214bd2..c9d3ba6 100644 --- a/main.c +++ b/main.c @@ -42,6 +42,9 @@ #elif HAVE_SYS_ENDIAN_H # include #endif +#ifdef HAVE_ARPA_INET_H +# include +#endif #include "rzip.h" #include "lrzip.h" diff --git a/runzip.c b/runzip.c index 1f9b64a..cfb5b5d 100644 --- a/runzip.c +++ b/runzip.c @@ -36,6 +36,9 @@ #elif HAVE_SYS_ENDIAN_H # include #endif +#ifdef HAVE_ARPA_INET_H +# include +#endif #include "md5.h" #include "runzip.h" diff --git a/rzip.c b/rzip.c index 12c8460..abbc8fe 100644 --- a/rzip.c +++ b/rzip.c @@ -47,6 +47,9 @@ #elif HAVE_SYS_ENDIAN_H # include #endif +#ifdef HAVE_ARPA_INET_H +# include +#endif #include "md5.h" #include "stream.h" diff --git a/stream.c b/stream.c index 6709d03..548eb00 100644 --- a/stream.c +++ b/stream.c @@ -44,6 +44,10 @@ #elif HAVE_SYS_ENDIAN_H # include #endif +#ifdef HAVE_ARPA_INET_H +# include +#endif + /* LZMA C Wrapper */ #include "lzma/C/LzmaLib.h"