[Nagiosplug-help] Compiling in cygwin

Vanderveken, Jan JVanderveken at ICTautomotive.nl
Mon Jan 31 08:04:16 CET 2005


> Vanderveken, Jan wrote:
> > Hello,
> > 
> > I'm trying to get a nagios setup running on a Windows 
> system using the
> > cygwin tools. I cannot use Linux on this project for the 
> simple reason that
> > Windows is the only allowed platform (not my choice, but I 
> can't change it
> > so don't ask)
> > 
> 
> Funny place. Usually it's the other way around in mission-critical 
> networks. I know the swedish military are forbidden by law to use 
> anything but NetBSD in most of their networks. Windows' 
> IP-stack is just 
> too shoddy to be used in really critical places, even if they made a 
> near-complete ripoff from OpenBSD when they released Win2K (it seems 
> they screwed up enough of it to make it malfunction anyway).

I don't want to turn this into a discussion about the merits of Unix vs
Windows, if you don't mind, so let's please stick to the technical issue at
hand :)
 
> The nagios plugins lean heavily on certain system 
> applications usually 
> only found on unix systems. I don't think a cygwin port is currently 
> planned and I seriously doubt if you will have any luck in 
> making many 
> of them run.

Cygwin provides just those system applications you speak about (or should
anyway). Anyway, I'm a bit surprised that it's so much trouble getting these
relatively simple plugins to compile, when big applications like Apache and
MySQL went smoothly.

> check_icmp (as included in the dist) won't compile under 
> CYGWIN unless 
> you have BSD-compatible headers installed

I don't really need the check_icmp plugin. So that is ok.
 
> The best option you have is probably to run make -i (continue 
> on errors) 
> and take whatever plugins happen to build.

make -i does indeed build a lot of the plugins, but it does not build the
most critical I need, namely check_nt. 

It gave me these errors:
In file included from check_nt.c:38:
common.h:35:20: config.h: No such file or directory
In file included from check_nt.c:38:
common.h:146: error: parse error before "va_list"
common.h:187:21: gettext.h: No such file or directory
In file included from check_nt.c:39:
netutils.h:35:20: config.h: No such file or directory
In file included from check_nt.c:39:
netutils.h:39: error: parse error before "socket_timeout_alarm_handler"
netutils.h:39: warning: data definition has no type or storage class
In file included from check_nt.c:40:
utils.h:30: error: parse error before "timeout_alarm_handler"
utils.h:30: warning: data definition has no type or storage class
utils.h:60: warning: `struct timezone' declared inside parameter list
utils.h:60: warning: its scope is only this definition or declaration, which
is
probably not what you want
check_nt.c: In function `main':
check_nt.c:115: error: `LC_ALL' undeclared (first use in this function)
check_nt.c:115: error: (Each undeclared identifier is reported only once
check_nt.c:115: error: for each function it appears in.)
check_nt.c:116: error: `PACKAGE' undeclared (first use in this function)
check_nt.c:116: error: `LOCALEDIR' undeclared (first use in this function)
check_nt.c:120: warning: passing arg 1 of `usage4' makes pointer from
integer 
without a cast

I do have gettext installed in cygwin ... so it seems a little odd.




More information about the Help mailing list