[xymon] 4.3.0 beta3 compile problem on solaris 10 sparc
Ralph Mitchell
ralphmitchell at gmail.com
Wed Nov 17 03:11:40 CET 2010
On Tue, Nov 16, 2010 at 8:32 PM, Roland Soderstrom <
rolands at logicaltech.com.au> wrote:
> Hi,
>
> Can't compile on Solaris 10 sparc with LDAP disabled.
> I disable LDAP test, SSL tests as I have no ldap server or SSL services.
>
> If I enable SSL and LDAP test I get another problem with ld, see further
> down.
> It uses /usr/ccs/bin/ld, I changed to "LD = /usr/local/bin/ld" in
> xymonnet/c-ares/Makefile.
> Same same...
>
> I get this ldap compile error
>
> LDAP, SSL enabled:
> -bash-3.00$ ./configure
> <snip>
> Checking for OpenSSL ...
> Found OpenSSL include files in /usr/local/ssl/include
> Found OpenSSL libraries in /opt/csw/lib
>
> Xymon can use the OpenSSL library to test SSL-enabled services
> like POP3S, IMAPS, NNTPS and TELNETS. If you have the OpenSSL
> library installed, I recommend that you enable this.
>
> Do you want to be able to test SSL-enabled services (y) ?
> n
>
>
>
> Checking for LDAP ...
> test-ldap.c: In function `main':
> test-ldap.c:25: warning: implicit declaration of function `ldap_init'
> test-ldap.c:25: warning: assignment makes pointer from integer without a
> cast
> Found LDAP include files in /usr/include
> Found LDAP libraries in /usr/lib
>
> Xymon can use your OpenLDAP LDAP client library to test LDAP servers.
>
> Do you want to be able to test LDAP servers (y) ?
> n
> <snip>
> -bash-3.00$ make
> <snip>
> gcc -g -O2 -Wall -Wno-unused -D_REENTRANT -DSunOS -I.
> -I/var/tmp/xymon-4.3.0.beta3/include -I/usr/local/include -c -o ldaptest.o
> ldaptest.c
> ldaptest.c: In function `add_ldap_test':
> ldaptest.c:99: error: `badurl' undeclared (first use in this function)
> ldaptest.c:99: error: (Each undeclared identifier is reported only once
> ldaptest.c:99: error: for each function it appears in.)
> ldaptest.c:101: error: `req' undeclared (first use in this function)
> ldaptest.c:112: error: `basecheck' undeclared (first use in this function)
> make[1]: *** [ldaptest.o] Error 1
> make[1]: Leaving directory `/var/tmp/xymon-4.3.0.beta3/xymonnet'
> make: *** [xymonnet-build] Error 2
> -bash-3.00$
>
I get the same thing in Gentoo Linux on x86_64 laptop. Those undeclared
variables are declared *inside* the #ifdef at line 62:
#ifdef XYMON_LDAP
testitem_t *basecheck;
ldap_data_t *req;
LDAPURLDesc *ludp;
char *urltotest;
int badurl;
Line 99 is outside the closing #ifdef. Moving the #endif down to line 118
effectively comments out the entire function body. I don't know if that's
the correct fix., but at least it compiles...
Ralph Mitchell
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.xymon.com/pipermail/xymon/attachments/20101116/7c65a55b/attachment.html>
More information about the Xymon
mailing list