NRPE compile error

Andreas Ericsson ae at op5.se
Fri Oct 27 10:52:26 CEST 2006


Eric Smith wrote:
> I've seen this mentioned in the mailing list archive; someone mentioned
> I might need the SSL development libraries (zlib and others possibly).
> Installing OpenSSL alleviated the configure "config: error: could not
> find ssl libraries" error but apparently it didn't install all the ones
> I needed for compilation.  Can someone tell me which libraries I need
> and where to get them?
> 
> Any help is much appreciated.

When asking for help, you need to supply the system you're encountering 
the problem on, because the fix is very different depending on if you're 
running Solaris, IRIX, AIX, BSD or Linux (or Windows, for that matter, 
although I'm fairly certain you'd run into unsurmountable problems on 
such an un-posixy platform).


> gcc -g -O2 -I/usr/local/ssl/include/openssl -I/usr/local/ssl/include
> -DHAVE_CONFIG_H -o nrpe nrpe.c utils.c -L/usr/local/ssl/lib  -lssl
> -lcrypto -lnsl
> /usr/local/ssl/lib/libcrypto.a(dso_dlfcn.o): In function
> `dlfcn_bind_func':
> dso_dlfcn.c:(.text+0x27d): undefined reference to `dlsym'
> dso_dlfcn.c:(.text+0x2f9): undefined reference to `dlerror'
> /usr/local/ssl/lib/libcrypto.a(dso_dlfcn.o): In function
> `dlfcn_bind_var':
> dso_dlfcn.c:(.text+0x36d): undefined reference to `dlsym'
> dso_dlfcn.c:(.text+0x3e1): undefined reference to `dlerror'
> /usr/local/ssl/lib/libcrypto.a(dso_dlfcn.o): In function `dlfcn_unload':
> dso_dlfcn.c:(.text+0x44c): undefined reference to `dlclose'
> /usr/local/ssl/lib/libcrypto.a(dso_dlfcn.o): In function `dlfcn_load':
> dso_dlfcn.c:(.text+0x4f5): undefined reference to `dlopen'
> dso_dlfcn.c:(.text+0x546): undefined reference to `dlclose'
> dso_dlfcn.c:(.text+0x56f): undefined reference to `dlerror'
> collect2: ld returned 1 exit status
> make[1]: *** [nrpe] Error 1
> 

This happens because gcc doesn't link in the dynamic link loader in the 
program itself. Since this is a compiling issue you'll also need to 
supply the compiler and linker version (gcc --version and ld --version 
should work with GNU tools).

The problem seems to stem from the fact that you've installed the 
statically linked version of openssl but still managed to get it linked 
to the dynamic link loader, which may or may not be present as a static 
library on your system. You may have to supply the libld as an extra 
argument to your LDFLAGS. Do this by trying

	$ LDFLAGS=-ldl make nrpe

Note that this is just a wild guess. The solution should be somewhere 
along that line though.

-- 
Andreas Ericsson                   andreas.ericsson at op5.se
OP5 AB                             www.op5.se
Tel: +46 8-230225                  Fax: +46 8-230231

-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
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