diff options
author | Simo Sorce <idra@samba.org> | 2008-09-19 15:49:39 -0400 |
---|---|---|
committer | Simo Sorce <idra@samba.org> | 2008-09-19 18:08:28 -0400 |
commit | e42caab6f91369a981619d0b711071cd1c724d5d (patch) | |
tree | aab6f128e7112e8438f288de4f49fd099e417f6e /source4/lib/ldb/external | |
parent | 474de0f2172ebe55e6cafb4ad7e81fe662eacadc (diff) | |
download | samba-e42caab6f91369a981619d0b711071cd1c724d5d.tar.gz samba-e42caab6f91369a981619d0b711071cd1c724d5d.tar.bz2 samba-e42caab6f91369a981619d0b711071cd1c724d5d.zip |
Fix ldb standalone build.
Add shared-build target to the ldb library, and make it possible to build
it against libtalloc, libevents, libtdb as shared libraries.
Diffstat (limited to 'source4/lib/ldb/external')
-rw-r--r-- | source4/lib/ldb/external/libevents.m4 | 9 | ||||
-rw-r--r-- | source4/lib/ldb/external/libtalloc.m4 | 9 | ||||
-rw-r--r-- | source4/lib/ldb/external/libtdb.m4 | 9 |
3 files changed, 18 insertions, 9 deletions
diff --git a/source4/lib/ldb/external/libevents.m4 b/source4/lib/ldb/external/libevents.m4 index f0f80e9d8e..4fd2e71ec2 100644 --- a/source4/lib/ldb/external/libevents.m4 +++ b/source4/lib/ldb/external/libevents.m4 @@ -1,4 +1,7 @@ -m4_include(pkg.m4) -EVENTS_OBJ="" AC_SUBST(EVENTS_OBJ) -PKG_CHECK_MODULES(EVENTS, events) +AC_SUBST(EVENTS_CFLAGS) +AC_SUBST(EVENTS_LIBS) + +AC_CHECK_HEADER(events.h, + [AC_CHECK_LIB(events, event_context_init, [EVENTS_LIBS="-levents"]) ], + [PKG_CHECK_MODULES(EVENTS, events)]) diff --git a/source4/lib/ldb/external/libtalloc.m4 b/source4/lib/ldb/external/libtalloc.m4 index d08bd42065..a4c5b8a9d9 100644 --- a/source4/lib/ldb/external/libtalloc.m4 +++ b/source4/lib/ldb/external/libtalloc.m4 @@ -1,4 +1,7 @@ -m4_include(pkg.m4) -TALLOC_OBJ="" AC_SUBST(TALLOC_OBJ) -PKG_CHECK_MODULES(TALLOC, talloc) +AC_SUBST(TALLOC_CFLAGS) +AC_SUBST(TALLOC_LIBS) + +AC_CHECK_HEADER(talloc.h, + [AC_CHECK_LIB(talloc, talloc_init, [TALLOC_LIBS="-ltalloc"]) ], + [PKG_CHECK_MODULES(TALLOC, talloc)]) diff --git a/source4/lib/ldb/external/libtdb.m4 b/source4/lib/ldb/external/libtdb.m4 index 4c1f4b530e..8c2cab702f 100644 --- a/source4/lib/ldb/external/libtdb.m4 +++ b/source4/lib/ldb/external/libtdb.m4 @@ -1,4 +1,7 @@ -m4_include(pkg.m4) -TDB_OBJ="" AC_SUBST(TDB_OBJ) -PKG_CHECK_MODULES(TDB, tdb >= 1.1.0) +AC_SUBST(TDB_CFLAGS) +AC_SUBST(TDB_LIBS) + +AC_CHECK_HEADER(tdb.h, + [AC_CHECK_LIB(tdb, tdb_open, [TDB_LIBS="-ltdb"]) ], + [PKG_CHECK_MODULES(TDB, tdb >= 1.1.0)]) |