From: David Schweikert Date: Thu, 12 Jan 2017 14:38:09 +0000 (+0100) Subject: AIX compatibility, fixes #69 X-Git-Tag: 3.16~15 X-Git-Url: https://git.gsnw.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=099d873253912e4807ed36f4f16c22edeca8f9ca;p=fping.git AIX compatibility, fixes #69 --- diff --git a/ChangeLog b/ChangeLog index f69bcb8..15dad0f 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,6 @@ +Unreleased + * (bugfix) Fix compatibility issue with AIX (#69, @blentzgh) + 2017-01-11 David Schweikert * Version 3.15 * (bugfix) Fix compiler errors on platforms other than Linux (related diff --git a/src/fping.c b/src/fping.c index b02493c..269598d 100644 --- a/src/fping.c +++ b/src/fping.c @@ -54,7 +54,6 @@ extern "C" #include #include #include -#include #include #include "config.h" @@ -91,6 +90,11 @@ extern "C" #include #include +/* RS6000 hasn't getopt.h */ +#ifdef HAVE_GETOPT_H +#include +#endif /* HAVE_GETOPT_H */ + /* RS6000 has sys/select.h */ #ifdef HAVE_SYS_SELECT_H #include @@ -102,7 +106,9 @@ extern "C" extern char *optarg; extern int optind,opterr; +#ifndef h_errno extern int h_errno; +#endif #ifdef __cplusplus }