summaryrefslogtreecommitdiff
path: root/server
diff options
context:
space:
mode:
authorSumit Bose <sbose@redhat.com>2009-11-24 22:37:10 +0100
committerStephen Gallagher <sgallagh@redhat.com>2009-11-25 11:03:12 -0500
commit04f015616f5e659086dacde2d4c398bab8ccf2ea (patch)
treeb40c6e8ed71e83e93cf29256c82b93e5f4b2da0e /server
parenta466888622798d91cf72d547584194c76e133d15 (diff)
downloadsssd-04f015616f5e659086dacde2d4c398bab8ccf2ea.tar.gz
sssd-04f015616f5e659086dacde2d4c398bab8ccf2ea.tar.bz2
sssd-04f015616f5e659086dacde2d4c398bab8ccf2ea.zip
Make ldb lib dir configurable
Diffstat (limited to 'server')
-rw-r--r--server/Makefile.am2
-rw-r--r--server/external/libldb.m418
2 files changed, 19 insertions, 1 deletions
diff --git a/server/Makefile.am b/server/Makefile.am
index 198d5c41..c0293913 100644
--- a/server/Makefile.am
+++ b/server/Makefile.am
@@ -6,7 +6,7 @@ builddir ?= .
sssdlibexecdir = $(libexecdir)/sssd
sssdlibdir = $(libdir)/sssd
-ldblibdir = $(libdir)/ldb
+ldblibdir = @ldblibdir@
if BUILD_KRB5_LOCATOR_PLUGIN
krb5plugindir = @krb5pluginpath@
endif
diff --git a/server/external/libldb.m4 b/server/external/libldb.m4
index 150c7ee0..d11acb4b 100644
--- a/server/external/libldb.m4
+++ b/server/external/libldb.m4
@@ -8,3 +8,21 @@ AC_CHECK_HEADERS(ldb.h ldb_module.h,
[AC_CHECK_LIB(ldb, ldb_init, [LDB_LIBS="-lldb"], , -ltevent) ],
[AC_MSG_ERROR([LDB header files are not installed])]
)
+
+AC_ARG_WITH([ldb-lib-dir],
+ [AC_HELP_STRING([--with-ldb-lib-dir=PATH],
+ [Path to store ldb modules [${libdir}/ldb]]
+ )
+ ]
+ )
+
+if test x"$with_ldb_lib_dir" != x; then
+ ldblibdir=$with_ldb_lib_dir
+else
+ ldblibdir="`$PKG_CONFIG --variable=modulesdir ldb`"
+ if test x"$ldblibdir" == x; then
+ ldblibdir="${libdir}/ldb"
+ fi
+fi
+AC_MSG_NOTICE([ldb lib directory: $ldblibdir])
+AC_SUBST(ldblibdir)