Problem Compiling N.R.P.E. on AIX Unix 4.3
Ewan Leith
ejl at man.fwltech.com
Mon Jun 9 16:01:04 CEST 2003
AIX being awkward, you will need to add the line
#include <sys/socket.h>
to nrpe.c and utils.c near the top where the other #include statements are.
Also, it'll be worth the effort to change the line #include <time.h> to
#include <sys/time.h> whereever it occurs.
Ewan
> -----Original Message-----
> From: giabbo [mailto:gianluca.boccia at bitmedia.it]
> Sent: 09 June 2003 13:47
> To: Nagios-users at lists.sourceforge.net
> Subject: [Nagios-users] Problem Compiling N.R.P.E. on AIX Unix 4.3
>
>
>
> I have a problem when compiling all version of nrpe tools on unix aix.
> I try to compile the nrpe, for example version 1.8, with
> standard options, and gcc compiler;
> when the GCC compiles, it finds an error in nrpe.c and
> utils.c in the some use of variable declared in system.h
> library. This is the output:
>
> >gcc -g -O2 -DHAVE_CONFIG_H -lnsl nrpe.c utils.c -o nrpe
> >In file included from ../common/config.h:110,
> from nrpe.c:22:
> >/usr/lynx/cross_43/lib/gcc-lib/powerpc-cetia-lynxos/2.8.
> 1/natif/usr/include/sys/time.h:21: >warning: #warning Using
> <time.h> instead of <sys/time.h>
> >nrpe.c: In function `wait_for_connections':
> >nrpe.c:352: `AF_INET' undeclared (first use in this function)
> >nrpe.c:352: (Each undeclared identifier is reported only once
> >nrpe.c:352: for each function it appears in.)
> >nrpe.c:352: `SOCK_STREAM' undeclared (first use in this >function)
> >nrpe.c:362: `SOL_SOCKET' undeclared (first use in this >function)
> >nrpe.c:362: `SO_REUSEADDR' undeclared (first use in this >function)
> >In file included from ../common/config.h:110,
> from utils.h:32,
> from utils.c:33:
> >/usr/lynx/cross_43/lib/gcc-lib/powerpc-cetia-lynxos/2.8.
> 1/natif/usr/include/sys/time.h:21: >warning: #warning Using
> <time.h> instead of <sys/time.h>
> >utils.c: In function `my_connect':
> >utils.c:54: `AF_INET' undeclared (first use in this function)
> >utils.c:54: (Each undeclared identifier is reported only once
> >utils.c:54: for each function it appears in.)
> >utils.c:61: warning: passing arg 1 of `gethostbyname'
> discards >`const' from pointer target type
> >utils.c:77: `PF_INET' undeclared (first use in this function)
> >utils.c:77: `SOCK_DGRAM' undeclared (first use in this >function)
> >utils.c:77: `SOCK_STREAM' undeclared (first use in this >function)
> >make[1]: *** [nrpe] Error 1
>
> Someone have idea to resolve this problem ???
>
> Thanks for all
>
> Gianluca
>
>
> -------------------------------------------------------
> This SF.net email is sponsored by: Etnus, makers of
> TotalView, The best
> thread debugger on the planet. Designed with thread debugging features
> you've never dreamed of, try TotalView 6 free at www.etnus.com.
> _______________________________________________
> Nagios-users mailing list
> Nagios-users at lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/nagios-users
> ::: Please include Nagios version, plugin version (-v) and OS
> when reporting any issue.
> ::: Messages without supporting info will risk being sent to /dev/null
>
-------------------------------------------------------
This SF.net email is sponsored by: Etnus, makers of TotalView, The best
thread debugger on the planet. Designed with thread debugging features
you've never dreamed of, try TotalView 6 free at www.etnus.com.
_______________________________________________
Nagios-users mailing list
Nagios-users at lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting any issue.
::: Messages without supporting info will risk being sent to /dev/null
More information about the Users
mailing list