Solaris compile woes: undefined getopt_long

Steve Fulton sfulton at esoteric.ca
Sat Dec 28 02:33:57 CET 2002


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



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




More information about the Users mailing list