[Date Prev][Date Next] [Chronological] [Thread] [Top]

I want to turn off support for debug output

I thought ./configure --disable-debug was supposed to turn off support
for debug output by causing LDAP_DEBUG to be un#defined, but:

1) libldap/ldap-int.h #defines a non-empty Debug() unconditionally.

2) If NEW_LOGGING is #defined (I expect that will be the default
   eventually?), include/ldap_log.h unconditionally #defines LDAP_LOG()
   to be non-empty.

3) libldap/os-ip.c and libldap/os-local.c #define their own osip_debug()
   and oslocal_debug() unconditionally.

4) portable.h always #defines LDAP_DEBUG if LDAP_VENDOR_VERSION == 0, so
   CVS version can't be tested without debugging.

I'd like to make (1)-(3) conditional on LDAP_DEBUG, and to remove (4).
--enable-debug is on by default, so CVS versions will normally be tested
with debugging anyway.  OK?

Or maybe some of this should be conditional on LDAP_DEBUG || LDAP_SYSLOG.
I need to see what the debugging code does to find out.

BTW, Debug() in include/ldap_log.h is defined to do nothing if
!LDAP_DEBUG, even if LDAP_SYSLOG is defined.  Is that intentional, or
should it be fixed?