On Sunday 05 June 2005 15:41, Turbo Fredriksson wrote: > Quoting Scott Ryan <[EMAIL PROTECTED]>: > > I am having a problem compiliing with this patch. > > I have core qmail1.03 with qmail-ldap patch 20050401a, then I apply the > > latest qmail-ldap-control patch with no problems. When I try to compile I > > get a lot of undefined reference errors such as: > > > > ./load qmail-lspawn spawn.o prot.o slurpclose.o coe.o control.o \ > > qldap.a sig.a strerr.a constmap.o getln.a wait.a case.a cdb.a \ > > fd.a seek.a open.a dirmaker.o read-ctrl.o localdelivery.o env.a \ > > stralloc.a alloc.a substdio.a str.a error.a fs.a auto_qmail.o \ > > auto_uids.o auto_usera.o auto_spawn.o > > > > control.o(.text+0x875): In function `control_ldap_search': > > : undefined reference to `ldap_count_entries' > > > > I have looked through the source code of both pathes and do not see where > > ldap_count_entries is defined. > > But you haven't read the QmailLDAP documentation. Please do so: > http://www.lifewithqmail.org/ldap/ > > > HINT: You're missing a whole lot of defines and setup at the top of the > Makefile.
Sorry, maybe I am missing something...
The only define that i see in the Makefile is
CONTROLDB=-DUSE_CONTROLDB -DQLDAP_BAILOUT
Which is what I have set in my Makefile.
What do you mean by a 'whole lot of defines and setups' ? There is only one
reference in the documentation to modifying the makefile for the control
patch that I can see:
<quote>
Now it's time to modify the Makefile to reflect your setup. You can change the
following values:
CONTROLDB=-DUSE_CONTROLDB
To enable having the configuration (~control/*) in the
LDAP database to, uncomment this line.
</quote>
So I am not sure what you mean by 'setups'
Anyway, just for you interest, here is where it borks:
./compile -DALTQUEUE -DBIGBROTHER -DBIGTODO -DBIND_8_COMPAT -DDASH_EXT
-DDATA_COMPRESS -DEXTERNAL_TODO -DIGNOREVERISIGN -DQUOTATRASH
-DUSE_CONTROLDB -DQLDAP_BAILOUT localdelivery.c
./compile constmap.c
./load qmail-lspawn spawn.o prot.o slurpclose.o coe.o control.o \
qldap.a sig.a strerr.a constmap.o getln.a wait.a case.a cdb.a \
fd.a seek.a open.a dirmaker.o read-ctrl.o localdelivery.o env.a \
stralloc.a alloc.a substdio.a str.a error.a fs.a auto_qmail.o \
auto_uids.o auto_usera.o auto_spawn.o
control.o(.text+0x875): In function `control_ldap_search':
: undefined reference to `ldap_count_entries'
As you can see, the flags -DUSE_CONTROLDB -DQLDAP_BAILOUT are there, as
defined in the makefile.
Here is the relevant section of my Makefile and the version openldap I am
using:
LDAPFLAGS="-DALTQUEUE -DBIGBROTHER -DBIGTODO -DBIND_8_COMPAT -DDASH_EXT
-DDATA_COMPRESS -DEXTERNAL_TODO -DIGNOREVERISIGN -DQUOTATRASH"
# * These are some options to securly connect to the LDAP server
# -DSECUREBIND_SASL Bind using SASL
# -DSECUREBIND_SSL Encrypt the channel with SSL
# -DSECUREBIND_TLS Encrypt the channel with TLS (SSL v3)
# -DSECUREBIND_ALL All of the above...
#SECUREBIND=-DSECUREBIND_ALL
# * Log authentication success/failures in auth_{pop,imap,smtp}
SYSLOGAUTH=-DSYSLOGAUTH
# -DUSE_RFC2307 -> Follow the RFC2307
# -DUSE_RFC822 -> Follow the RFC822
# See the QLDAPINSTALL file for more about this.
#RFCFLAGS=-DUSE_RFC2307 -DUSE_RFC822
# to enable having the configuration (~control/* in the LDAP database
# to, uncomment the following line and read QLDAPINSTALL.
# -DUSE_CONTROLDB Search LDAP for control files
# -DQLDAP_BAILOUT First search LDAP, then FS
CONTROLDB=-DUSE_CONTROLDB -DQLDAP_BAILOUT
# Perhaps you have different ldap libraries, change them here
#LDAPLIBS=-L/usr/local/lib -lldap -llber
# and change the location of the include files here
#LDAPINCLUDES=-I/usr/local/include
# on Slowaris you need -lresolv and probably a LD_RUN_PATH added like this:
#LDAPLIBS=-L/opt/OpenLDAP/lib -lldap -llber -lresolv -R/opt/OpenLDAP/lib
# for example on my Linux box I use:
#LDAPLIBS=-L/opt/OpenLDAP/lib -lldap -llber
# if you need a special include-directory for ldap headers enable this
#LDAPINCLUDES=-I/opt/OpenLDAP/include
# ZLIB needed for -DDATA_COMPRESS and -DQMQP_COMPRESS
ZLIB=-lz
# or you installed zlib in a different path you can use something like this
#ZLIB=-L/opt/zlib/lib -lz
#ZINCLUDES=-I/opt/zlib/include
# TLS (SMTP encryption) in qmail-smtpd and qmail-remote, see TLS.readme
# You need OpenSSL for this
# use -DTLS_REMOTE to enable tls support in qmail-remote
# use -DTLS_SMTPD to enable tls support in qmail-smtpd
# use -DTLSDEBUG to enable additional tls debug information in qmail-remote
#TLS=-DTLS_REMOTE -DTLS_SMTPD
# Path to OpenSSL includes
#TLSINCLUDES=-I/usr/local/include
# Path to OpenSSL libraries
#TLSLIBS=-L/usr/local/lib -lssl -lcrypto
# Path to OpenSSL binary
#OPENSSLBIN=/usr/local/bin/openssl
#OPENSSLBIN=openssl
# to make the Netscape download progress bar work with qmail-pop3d
# uncomment the next line (allready done)
MNW=-DMAKE_NETSCAPE_WORK
# to enable the auto-maildir-make feature uncomment the next line
MDIRMAKE=-DAUTOMAILDIRMAKE
# to enable the auto-homedir-make feature uncomment the next line
HDIRMAKE=-DAUTOHOMEDIRMAKE
# on most systems we need this to make auth_pop and auth_imap
SHADOWLIBS=-lcrypt
# OpenBSD and other Systems do not have libcrypt, so comment the line out
# if you get linking problems.
# To use shadow passwords under some Linux OS, uncomment the next two lines.
#SHADOWLIBS=-lcrypt -lshadow
#SHADOWOPTS=-DPW_SHADOW
# To use shadow passwords under Solaris, uncomment the SHADOWOPTS line.
# to enable the possibility to log and debug imap and pop uncoment the
# next line
#DEBUG=-DDEBUG
# WARNING: you need a NONE DEBUG auth_* to run with inetd
# for profiling ...
#INCTAI=../libtai-0.60
#LIBTAI=../libtai-0.60
# Just for me, make from time to time a backup
BACKUPPATH=/backup/qmail-backup/qmail-ldap.`date "+%Y%m%d-%H%M"`.tar
# STOP editing HERE !!!
$ rpm -qa | grep openldap-devel
openldap-devel-2.2.13-2
--
slr
pgpyVfmpod9sj.pgp
Description: PGP signature
