[xymon] 4.3.0 beta3 compile problem on solaris 10 sparc

Henrik Størner henrik at hswn.dk
Wed Nov 17 12:03:15 CET 2010


In <AANLkTimHMG282n=FbZGpDSH9w_u2hm3qaCEp2BPW_6VO at mail.gmail.com> Ralph Mitchell <ralphmitchell at gmail.com> writes:

>On Tue, Nov 16, 2010 at 8:32 PM, Roland Soderstrom <
>rolands at logicaltech.com.au> wrote:

>> 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.
>> <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

>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...

It looks like the right fix.

Index: xymonnet/ldaptest.c
===================================================================
--- xymonnet/ldaptest.c	(revision 6590)
+++ xymonnet/ldaptest.c	(working copy)
@@ -94,7 +94,6 @@
 	req->certinfo = NULL;
 	req->certexpires = 0;
 	req->skiptest = 0;
-#endif
 
 	if (badurl) {
 		errprintf("Invalid LDAP URL %s\n", t->testspec);
@@ -116,6 +115,8 @@
 		req->output = "Cannot connect to server";
 	}
 
+#endif
+
 	return 0;
 }
 

Regards,
Henrik



More information about the Xymon mailing list