Michael Ströder writes:
Might that be caused by the missing "make depend" step?
If so make distclean (which he did use) would be broken. There are hosts which don't provide a way to do "make depend".
Any hint? Maybe something related to libtool?
Remove your CPPFLAGS and LDFLAGS. It's the -Wl,-R/usr/lib. That worked in OpenLDAP 2.2 but has been broken since 2.3.4 (the first 2.3 release). Links the libraries in /usr/lib instead of the ones you just built. Don't know if it's the Makefile or libtool.
I seem to remeber warnings in the gcc doc that you should not do -I/usr/include either, it overrides gcc's special version of some files. Or did, maybe they've worked around it since I saw that.