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

Linking of slapd/tools (ITS#602)

Full_Name: Christian Lorenz
Version: 2.0-devel
OS: linux-2.2.14
URL: ftp://ftp.openldap.org/incoming/
Submission from: (NULL) (

I suggest to only link those slapd/tools with the MODULE_LIBS which also
link against the libbackend.a.
I had problems with a backend that uses librecode: I confiured -lrecode
into the MODULE_LIBS. The slapd itself builds fine, but ldif failed, because
the global variable 'program_name' (which librecode depends on) was only
defined in my backend!

Here's the patch:
--- ldap/servers/slapd/tools/Makefile.in.orig   Tue Jun 13 15:05:48 2000
+++ ldap/servers/slapd/tools/Makefile.in        Wed Jun 21 11:32:16 2000
@@ -30,7 +30,7 @@
        $(LDIF_LIBS) $(LUTIL_LIBS)
 PROGRAMS=ldif slappasswd slapadd slapcat slapindex
 LDBMPROGRAMS=centipede sizecount
@@ -84,13 +84,13 @@
 # SLAP Tools
 slapadd:       slapadd.o ../libbackends.a $(SLAPOBJS) $(SLAPD_LIBDEPEND) 
-       $(LTLINK) -o $@ slapadd.o $(SLAPOBJS) ../libbackends.a $(LIBS)
+       $(LTLINK) -o $@ slapadd.o $(SLAPOBJS) ../libbackends.a $(LIBS)
 slapcat:       slapcat.o ../libbackends.a $(SLAPOBJS) $(SLAPD_LIBDEPEND) 
-       $(LTLINK) -o $@ slapcat.o $(SLAPOBJS) ../libbackends.a $(LIBS)
+       $(LTLINK) -o $@ slapcat.o $(SLAPOBJS) ../libbackends.a $(LIBS)
 slapindex:     slapindex.o ../libbackends.a $(SLAPOBJS) $(SLAPD_LIBDEPEND) 
-       $(LTLINK) -o $@ slapindex.o $(SLAPOBJS) ../libbackends.a $(LIBS)
+       $(LTLINK) -o $@ slapindex.o $(SLAPOBJS) ../libbackends.a $(LIBS)
 ldif:          ldif.o $(SLAPD_LIBDEPEND) 
        $(LTLINK) -o $@ ldif.o $(LIBS)

Have fun!