When building zabbix agent there are problems with ldap functions, example:
**************
myserver:/usr/local/src/zabbix-1.6.1/src/zabbix_agent# make
gcc -g -O2 -I/usr/include/postgresql -I. -I/usr/include -I/usr/include -I/usr/include -static -L/usr/lib -lldap -llber -lgnutls -lpthread -lsasl2 -L/usr/lib -lOpenIPMI -lOpenIPMIposix -o zabbix_agent zabbix_agent.o stats.o cpustat.o diskdevices.o interfaces.o perfstat.o zbxconf.o ../../src/libs/zbxsysinfo/libzbxagentsysinfo.a ../../src/libs/zbxsysinfo/linux/libspecsysinfo.a ../../src/libs/zbxsysinfo/common/libcommonsysinfo.a ../../src/libs/zbxsysinfo/simple/libsimplesysinfo.a ../../src/libs/zbxlog/libzbxlog.a ../../src/libs/zbxsys/libzbxsys.a ../../src/libs/zbxnix/libzbxnix.a ../../src/libs/zbxcomms/libzbxcomms.a ../../src/libs/zbxconf/libzbxconf.a ../../src/libs/zbxcommon/libzbxcommon.a ../../src/libs/zbxcrypto/libzbxcrypto.a ../../src/libs/zbxjson/libzbxjson.a -lsasl2 -lpthread -lgnutls -llber -lm -lresolv
/usr/lib/liblber.a(sockbuf.o): In function `sb_debug_write':
(.text+0x140): aviso: `sys_errlist' is deprecated; use `strerror' or `strerror_r' instead
/usr/lib/liblber.a(sockbuf.o): In function `sb_debug_write':
(.text+0x137): aviso: `sys_nerr' is deprecated; use `strerror' or `strerror_r' instead
../../src/libs/zbxsysinfo/linux/libspecsysinfo.a(libspecsysinfo_a-proc.o): In function `PROC_NUM':
/usr/local/src/zabbix-1.6.1/src/libs/zbxsysinfo/linux/proc.c:353: aviso: Using 'getpwnam' in statically linked applications requires at runtime the shared libraries from the glibc version used for linking
../../src/libs/zbxcomms/libzbxcomms.a(comms.o): In function `zbx_tcp_check_security':
/usr/local/src/zabbix-1.6.1/src/libs/zbxcomms/comms.c:1065: aviso: Using 'getaddrinfo' in statically linked applications requires at runtime the shared libraries from the glibc version used for linking
../../src/libs/zbxcomms/libzbxcomms.a(comms.o): In function `zbx_gethost':
/usr/local/src/zabbix-1.6.1/src/libs/zbxcomms/comms.c:198: aviso: Using 'gethostbyaddr' in statically linked applications requires at runtime the shared libraries from the glibc version used for linking
/usr/local/src/zabbix-1.6.1/src/libs/zbxcomms/comms.c:193: aviso: Using 'gethostbyname' in statically linked applications requires at runtime the shared libraries from the glibc version used for linking
../../src/libs/zbxsysinfo/simple/libsimplesysinfo.a(simple.o): In function `check_ldap':
/usr/local/src/zabbix-1.6.1/src/libs/zbxsysinfo/simple/simple.c:60: referencia a `ldap_init' sin definir
/usr/local/src/zabbix-1.6.1/src/libs/zbxsysinfo/simple/simple.c:66: referencia a `ldap_search_s' sin definir
/usr/local/src/zabbix-1.6.1/src/libs/zbxsysinfo/simple/simple.c:75: referencia a `ldap_err2string' sin definir
/usr/local/src/zabbix-1.6.1/src/libs/zbxsysinfo/simple/simple.c:95: referencia a `ldap_msgfree' sin definir
/usr/local/src/zabbix-1.6.1/src/libs/zbxsysinfo/simple/simple.c:96: referencia a `ldap_unbind' sin definir
/usr/local/src/zabbix-1.6.1/src/libs/zbxsysinfo/simple/simple.c:79: referencia a `ldap_first_entry' sin definir
/usr/local/src/zabbix-1.6.1/src/libs/zbxsysinfo/simple/simple.c:85: referencia a `ldap_first_attribute' sin definir
/usr/local/src/zabbix-1.6.1/src/libs/zbxsysinfo/simple/simple.c:87: referencia a `ldap_get_values' sin definir
/usr/local/src/zabbix-1.6.1/src/libs/zbxsysinfo/simple/simple.c:92: referencia a `ldap_value_free' sin definir
/usr/local/src/zabbix-1.6.1/src/libs/zbxsysinfo/simple/simple.c:93: referencia a `ldap_memfree' sin definir
/usr/local/src/zabbix-1.6.1/src/libs/zbxsysinfo/simple/simple.c:81: referencia a `ldap_err2string' sin definir
collect2: ld returned 1 exit status
make: *** [zabbix_agent] Error 1
**************
It seems to reference some ldap functions not defined yet.
The same way for zabbix server and proxy I have problems with ldap, PostgreSQL and IPIMI functions.
My library versions on Debian Etch with backports:
libldap 2.1.3
libopenipmi 2.0.7
postgresql 8.3.3
**************
myserver:/usr/local/src/zabbix-1.6.1/src/zabbix_agent# make
gcc -g -O2 -I/usr/include/postgresql -I. -I/usr/include -I/usr/include -I/usr/include -static -L/usr/lib -lldap -llber -lgnutls -lpthread -lsasl2 -L/usr/lib -lOpenIPMI -lOpenIPMIposix -o zabbix_agent zabbix_agent.o stats.o cpustat.o diskdevices.o interfaces.o perfstat.o zbxconf.o ../../src/libs/zbxsysinfo/libzbxagentsysinfo.a ../../src/libs/zbxsysinfo/linux/libspecsysinfo.a ../../src/libs/zbxsysinfo/common/libcommonsysinfo.a ../../src/libs/zbxsysinfo/simple/libsimplesysinfo.a ../../src/libs/zbxlog/libzbxlog.a ../../src/libs/zbxsys/libzbxsys.a ../../src/libs/zbxnix/libzbxnix.a ../../src/libs/zbxcomms/libzbxcomms.a ../../src/libs/zbxconf/libzbxconf.a ../../src/libs/zbxcommon/libzbxcommon.a ../../src/libs/zbxcrypto/libzbxcrypto.a ../../src/libs/zbxjson/libzbxjson.a -lsasl2 -lpthread -lgnutls -llber -lm -lresolv
/usr/lib/liblber.a(sockbuf.o): In function `sb_debug_write':
(.text+0x140): aviso: `sys_errlist' is deprecated; use `strerror' or `strerror_r' instead
/usr/lib/liblber.a(sockbuf.o): In function `sb_debug_write':
(.text+0x137): aviso: `sys_nerr' is deprecated; use `strerror' or `strerror_r' instead
../../src/libs/zbxsysinfo/linux/libspecsysinfo.a(libspecsysinfo_a-proc.o): In function `PROC_NUM':
/usr/local/src/zabbix-1.6.1/src/libs/zbxsysinfo/linux/proc.c:353: aviso: Using 'getpwnam' in statically linked applications requires at runtime the shared libraries from the glibc version used for linking
../../src/libs/zbxcomms/libzbxcomms.a(comms.o): In function `zbx_tcp_check_security':
/usr/local/src/zabbix-1.6.1/src/libs/zbxcomms/comms.c:1065: aviso: Using 'getaddrinfo' in statically linked applications requires at runtime the shared libraries from the glibc version used for linking
../../src/libs/zbxcomms/libzbxcomms.a(comms.o): In function `zbx_gethost':
/usr/local/src/zabbix-1.6.1/src/libs/zbxcomms/comms.c:198: aviso: Using 'gethostbyaddr' in statically linked applications requires at runtime the shared libraries from the glibc version used for linking
/usr/local/src/zabbix-1.6.1/src/libs/zbxcomms/comms.c:193: aviso: Using 'gethostbyname' in statically linked applications requires at runtime the shared libraries from the glibc version used for linking
../../src/libs/zbxsysinfo/simple/libsimplesysinfo.a(simple.o): In function `check_ldap':
/usr/local/src/zabbix-1.6.1/src/libs/zbxsysinfo/simple/simple.c:60: referencia a `ldap_init' sin definir
/usr/local/src/zabbix-1.6.1/src/libs/zbxsysinfo/simple/simple.c:66: referencia a `ldap_search_s' sin definir
/usr/local/src/zabbix-1.6.1/src/libs/zbxsysinfo/simple/simple.c:75: referencia a `ldap_err2string' sin definir
/usr/local/src/zabbix-1.6.1/src/libs/zbxsysinfo/simple/simple.c:95: referencia a `ldap_msgfree' sin definir
/usr/local/src/zabbix-1.6.1/src/libs/zbxsysinfo/simple/simple.c:96: referencia a `ldap_unbind' sin definir
/usr/local/src/zabbix-1.6.1/src/libs/zbxsysinfo/simple/simple.c:79: referencia a `ldap_first_entry' sin definir
/usr/local/src/zabbix-1.6.1/src/libs/zbxsysinfo/simple/simple.c:85: referencia a `ldap_first_attribute' sin definir
/usr/local/src/zabbix-1.6.1/src/libs/zbxsysinfo/simple/simple.c:87: referencia a `ldap_get_values' sin definir
/usr/local/src/zabbix-1.6.1/src/libs/zbxsysinfo/simple/simple.c:92: referencia a `ldap_value_free' sin definir
/usr/local/src/zabbix-1.6.1/src/libs/zbxsysinfo/simple/simple.c:93: referencia a `ldap_memfree' sin definir
/usr/local/src/zabbix-1.6.1/src/libs/zbxsysinfo/simple/simple.c:81: referencia a `ldap_err2string' sin definir
collect2: ld returned 1 exit status
make: *** [zabbix_agent] Error 1
**************
It seems to reference some ldap functions not defined yet.
The same way for zabbix server and proxy I have problems with ldap, PostgreSQL and IPIMI functions.
My library versions on Debian Etch with backports:
libldap 2.1.3
libopenipmi 2.0.7
postgresql 8.3.3
Comment