[Snort-devel] Barnyard Solaris 8 compile issue

Roelof JT Jonkman roel at ...60...
Wed May 1 14:29:12 EDT 2002


> gcc  -g -O2 -Wall  -L/usr/local/mysql/lib/mysql -lmysqlclient -o
> barnyard  barnyard.o configparse.o  mstring.o strlcatu.o strlcpyu.o 
> util.o spool.o sid.o debug.o  classification.o output-plugins/libop.a
> input-plugins/libdp.a -lsocket
> Undefined                       first referenced
>  symbol                             in file
> inet_ntoa                          
> output-plugins/libop.a(op_logdump.o)  (symbol belongs to implicit
> dependency /usr/lib/libnsl.so.1)
> ld: fatal: Symbol referencing errors. No output written to barnyard
> collect2: ld returned 1 exit status
> *** Error code 1
> make: Fatal error: Command failed for target `barnyard'

Solution 1:

make distclean

Solution 2:

Or just simply add '-lnsl' to the link line. (cut and paste, add -lnsl, sorry
I'm lazy that way.)

Solaris (as do most typical system V derrivatives) have most internet specific
routines living outside libc, hence you need to link in additional libraries.

Hope this helps, and good luck.


More information about the Snort-devel mailing list