Hans Leidekker wrote:
The configure check somehow needs -lpthread on Fedora based systems but Wine's build system links wldap32 to libldap_r without it just fine.
Adding -lphtread to the configure check doesn't seem to cause any trouble on my Debian based Ubuntu either (where it isn't needed). I suspect it's a problem with the (newer) autoconf tools in Fedora.
-Hans
Changelog Link to the reentrant version of libldap.
f891a05d34c03c99b3476dea041cca3f9e06cc09 diff --git a/configure.ac b/configure.ac index a834d40..4b9a0f2 100644 --- a/configure.ac +++ b/configure.ac @@ -542,15 +542,20 @@ then fi
dnl **** Check for OpenLDAP *** +saved_libs="$LIBS" +LIBS="$LIBS $LIBPTHREAD"
AC_SUBST(LDAPLIBS,"") if test "$ac_cv_header_ldap_h" = "yes" -a "$ac_cv_header_lber_h" = "yes" then
- AC_CHECK_LIB(ldap, ldap_initialize,
- AC_CHECK_LIB(ldap_r, ldap_initialize, [AC_CHECK_LIB(lber, ber_init, [AC_DEFINE(HAVE_LDAP, 1, [Define if you have the OpenLDAP development environment])
LDAPLIBS="-lldap -llber"])])
LDAPLIBS="-lldap_r -llber"])])
fi
+LIBS="$saved_libs"
dnl **** Check for FreeType 2 **** AC_SUBST(FREETYPELIBS,"") AC_SUBST(FREETYPEINCL,"")
This patch breaks builds on RH9 and appears to be responsible for the build breakage on http://www.astro.gla.ac.uk/users/paulm/WRT/wrt.php
On Wednesday 14 December 2005 01:56, Robert Reif wrote:
Changelog Link to the reentrant version of libldap.
This patch breaks builds on RH9 and appears to be responsible for the build breakage on http://www.astro.gla.ac.uk/users/paulm/WRT/wrt.php
Can you send me the build errors and a relevant snippet from config.log, say 20 lines after 'checking for ldap_initialize in -lldap_r'?
-Hans
Hans Leidekker wrote:
On Wednesday 14 December 2005 01:56, Robert Reif wrote:
Changelog Link to the reentrant version of libldap.
This patch breaks builds on RH9 and appears to be responsible for the build breakage on http://www.astro.gla.ac.uk/users/paulm/WRT/wrt.php
Can you send me the build errors and a relevant snippet from config.log, say 20 lines after 'checking for ldap_initialize in -lldap_r'?
-Hans
My build error is the same as the link above.
Here is the log info:
configure:9617: checking for ldap_initialize in -lldap_r configure:9647: gcc -o conftest -g -O2 conftest.c -lldap_r -lpthread >&5 configure:9653: $? = 0 configure:9656: test -z || test ! -s conftest.err configure:9659: $? = 0 configure:9662: test -s conftest configure:9665: $? = 0 configure:9678: result: yes configure:9681: checking for ber_init in -llber
nm shows that the symbols are in libldap.so but not libldap_r.so.
On Thursday 15 December 2005 01:52, Robert Reif wrote:
This patch breaks builds on RH9 and appears to be responsible for the build breakage on http://www.astro.gla.ac.uk/users/paulm/WRT/wrt.php
nm shows that the symbols are in libldap.so but not libldap_r.so.
Can you try this patch?
-Hans
Hans Leidekker wrote:
On Thursday 15 December 2005 01:52, Robert Reif wrote:
This patch breaks builds on RH9 and appears to be responsible for the build breakage on http://www.astro.gla.ac.uk/users/paulm/WRT/wrt.php
nm shows that the symbols are in libldap.so but not libldap_r.so.
Can you try this patch?
-Hans
Adding this fixes it for me but you may need to check for ldap_parse_reference also.
Index: parse.c =================================================================== RCS file: /home/wine/wine/dlls/wldap32/parse.c,v retrieving revision 1.2 diff -p -u -r1.2 parse.c --- parse.c 2 Dec 2005 13:15:16 -0000 1.2 +++ parse.c 18 Dec 2005 14:02:35 -0000 @@ -130,7 +130,7 @@ ULONG ldap_parse_referenceW( WLDAP32_LDA PWCHAR **referrals ) { ULONG ret = LDAP_NOT_SUPPORTED; -#ifdef HAVE_LDAP +#if defined(HAVE_LDAP) && defined(HAVE_LDAP_COUNT_REFERENCES) char **referralsU = NULL;
TRACE( "(%p, %p, %p)\n", ld, message, referrals );
On Sunday 18 December 2005 15:13, Robert Reif wrote:
Adding this fixes it for me but you may need to check for ldap_parse_reference also.
Yes, strictly speaking we should check all 4 reference handling functions that are absent from your libldap_r, but I'd rather keep the configure checks to an absolute minimum. Since these functions are related I doubt that there are versions of libldap_r around where less than 4 of them are missing. And when that happens we can deal with it ;-)
-Hans
Hi,
Just a quick email to say Hans' patch on it own fails for me too. His patch with Robert's addition works fine.
On Sunday 18 Dec 2005 14:56, Hans Leidekker wrote:
On Sunday 18 December 2005 15:13, Robert Reif wrote:
Adding this fixes it for me but you may need to check for ldap_parse_reference also.
Yes, strictly speaking we should check all 4 reference handling functions that are absent from your libldap_r, but I'd rather keep the configure checks to an absolute minimum. Since these functions are related I doubt that there are versions of libldap_r around where less than 4 of them are missing. And when that happens we can deal with it ;-)
Agreed.
Cheers,
Paul.
Hans Leidekker hans@it.vu.nl writes:
Yes, strictly speaking we should check all 4 reference handling functions that are absent from your libldap_r, but I'd rather keep the configure checks to an absolute minimum. Since these functions are related I doubt that there are versions of libldap_r around where less than 4 of them are missing. And when that happens we can deal with it ;-)
It's really not much more work to do it right the first time around, and it makes the code much clearer. Otherwise it looks quite strange to have #ifdefs for a function you aren't even calling.