From 0ca0c0e5a294d3f3f07ef179793c918bcb128356 Mon Sep 17 00:00:00 2001 From: Jelmer Vernooij Date: Tue, 11 Sep 2007 18:24:09 +0000 Subject: r25100: Include LDAP libs in .pc file so linking statically against libldb works again. (This used to be commit bcf5c9447435a826027626ac89a00eaa6739b12a) --- source4/lib/ldb/Makefile.in | 5 ++++- source4/lib/ldb/configure.ac | 3 ++- source4/lib/ldb/ldb.pc.in | 1 + source4/lib/ldb/tools/config.mk | 2 +- 4 files changed, 8 insertions(+), 3 deletions(-) (limited to 'source4') diff --git a/source4/lib/ldb/Makefile.in b/source4/lib/ldb/Makefile.in index 4a4585d861..75f1767550 100644 --- a/source4/lib/ldb/Makefile.in +++ b/source4/lib/ldb/Makefile.in @@ -30,11 +30,14 @@ POPT_LIBS = @POPT_LIBS@ POPT_CFLAGS = @POPT_CFLAGS@ POPT_OBJ = @POPT_OBJ@ +LDAP_LIBS = @LDAP_LIBS@ + CFLAGS=-g -I$(srcdir)/include -Iinclude -I$(srcdir) -I$(srcdir)/.. \ $(POPT_CFLAGS) $(TALLOC_CFLAGS) $(TDB_CFLAGS) \ -DLIBDIR=\"$(libdir)\" -DSHLIBEXT=\"@SHLIBEXT@\" -DUSE_MMAP=1 @CFLAGS@ -LIB_FLAGS=@LDFLAGS@ -Llib -lldb @LIBS@ $(POPT_LIBS) $(TALLOC_LIBS) $(TDB_LIBS) +LIB_FLAGS=@LDFLAGS@ -Llib -lldb @LIBS@ $(POPT_LIBS) $(TALLOC_LIBS) $(TDB_LIBS) \ + $(LDAP_LIBS) LDB_TDB_DIR=ldb_tdb LDB_TDB_OBJ=$(LDB_TDB_DIR)/ldb_tdb.o \ diff --git a/source4/lib/ldb/configure.ac b/source4/lib/ldb/configure.ac index 776877111b..6f19d88290 100644 --- a/source4/lib/ldb/configure.ac +++ b/source4/lib/ldb/configure.ac @@ -53,9 +53,10 @@ m4_include(libtdb.m4) m4_include(ldap.m4) if test x"$with_ldap_support" = x"yes"; then - LIBS="$LIBS -llber -lldap" CFLAGS="$CFLAGS -DHAVE_LDB_LDAP=1" EXTRA_OBJ="$EXTRA_OBJ ldb_ldap/ldb_ldap.o" + LDAP_LIBS="-llber -lldap" + AC_SUBST(LDAP_LIBS) TESTS="$TESTS test-ldap.sh" fi diff --git a/source4/lib/ldb/ldb.pc.in b/source4/lib/ldb/ldb.pc.in index 4a9714ca54..248fb05c4f 100644 --- a/source4/lib/ldb/ldb.pc.in +++ b/source4/lib/ldb/ldb.pc.in @@ -10,6 +10,7 @@ Version: @PACKAGE_VERSION@ Requires.private: tdb Requires: talloc Libs: -L${libdir} -lldb +Libs.private: @LDAP_LIBS@ Cflags: -I${includedir} Modulesdir: ${modulesdir} URL: http://ldb.samba.org/ diff --git a/source4/lib/ldb/tools/config.mk b/source4/lib/ldb/tools/config.mk index 19ff943677..bf6c5f963c 100644 --- a/source4/lib/ldb/tools/config.mk +++ b/source4/lib/ldb/tools/config.mk @@ -1,7 +1,7 @@ ################################################ # Start SUBSYSTEM LIBLDB_CMDLINE [SUBSYSTEM::LIBLDB_CMDLINE] -CFLAGS = -Ilib/ldb +CFLAGS = -Ilib/ldb -Ilib/ldb/include OBJ_FILES= \ cmdline.o PUBLIC_DEPENDENCIES = LIBLDB LIBPOPT -- cgit