Solaris compile woes: undefined getopt_long

Mike McClure mmcclure at pneservices.com
Sat Dec 28 06:08:38 CET 2002


Hi Steve,

Which version are you trying to compile?  1.0-stable?  CVS?  1.0b6?

Post your ./configure output, please.  Do a "make clean" first, though.

- Mike

> Hi all,
>
> I'm trying to compile Nagios under Solaris 8, and it keeps failing with the
> following message:
>
> ***
> make all
> ....
> gcc -g -O2 -DHAVE_CONFIG_H -DNSCORE  nagios.c checks.o config.o commands.o
> flapping.o logging.o notifications.o sehandlers.o utils.o sretention.o
> ../xdata/xrddefault.c ../common/comments.c ../xdata/xcddefault.c
> ../common/objects.c ../xdata/xodtemplate.c ../common/statusdata.c
> ../xdata/xsddefault.c perfdata.o ../xdata/xpddefault.c ../common/downtime.c
> ../xdata/xdddefault.c    -lm -o nagios
> Undefined                       first referenced
>   symbol                             in file
> getopt_long                         /var/tmp//ccz3C8yU.o
> ld: fatal: Symbol referencing errors. No output written to nagios
> collect2: ld returned 1 exit status
> make[1]: *** [nagios] Error 1
> make[1]: Leaving directory
> `/export/home/steve/files/nagios/tmp/nagios-1.0/base'
> make: *** [all] Error 2
>
> ***
>
> Yes, I do have a getopt header file on my system, and getopt *is* defined
> in common/config.h!  I have commented it out, but I prefer to actually find
> the source of the original error rather than run without.
>
> FYI, here are my configure options:
>
> ./configure --prefix=/usr/local/nagios --with-cgiurl=/nagios/cgi-bin
> --with-htmurl=/nagios
>
> .. and I run "make all" as instructed.
>
> If you have any thoughts, I'd appreciate them.
>
> -- Steve



-- 
Mike McClure, CCIE # 5125, CISSP # 30232
PNE Services, Inc. -  http://www.pneservices.com
mmcclure at pneservices.com
mobile: 913-636-5590



-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf




More information about the Users mailing list