blob: cc24863c60ec7dfc3e14060e6ec939a8aa2fba80 [file] [log] [blame]
Brad Bishop1a4b7ee2018-12-16 17:11:34 -08001SUMMARY = "Hierarchical, reference counted memory pool system with destructors"
2HOMEPAGE = "http://ldb.samba.org"
3SECTION = "libs"
4LICENSE = "LGPL-3.0+ & LGPL-2.1+ & GPL-3.0+"
5
6DEPENDS += "libtdb libtalloc libtevent popt"
Brad Bishop26bdd442019-08-16 17:08:17 -04007RDEPENDS_pyldb += "python3"
Brad Bishop1a4b7ee2018-12-16 17:11:34 -08008
9SRC_URI = "http://samba.org/ftp/ldb/ldb-${PV}.tar.gz \
10 file://do-not-import-target-module-while-cross-compile.patch \
Brad Bishop1a4b7ee2018-12-16 17:11:34 -080011 file://libldb-fix-musl-libc-unkown-type-error.patch \
12 file://libldb-fix-musl-libc-conflict-type-error.patch \
Brad Bishop26bdd442019-08-16 17:08:17 -040013 file://0001-waf-add-support-of-cross_compile.patch \
14 file://options-1.5.4.patch \
Brad Bishop1a4b7ee2018-12-16 17:11:34 -080015 "
16
17PACKAGECONFIG ??= "\
18 ${@bb.utils.filter('DISTRO_FEATURES', 'acl', d)} \
19 ${@bb.utils.contains('DISTRO_FEATURES', 'xattr', 'attr', '', d)} \
20"
21PACKAGECONFIG[acl] = "--with-acl,--without-acl,acl"
22PACKAGECONFIG[attr] = "--with-attr,--without-attr,attr"
23PACKAGECONFIG[ldap] = ",,openldap"
24PACKAGECONFIG[libaio] = "--with-libaio,--without-libaio,libaio"
25PACKAGECONFIG[libbsd] = "--with-libbsd,--without-libbsd,libbsd"
26PACKAGECONFIG[libcap] = "--with-libcap,--without-libcap,libcap"
27PACKAGECONFIG[valgrind] = "--with-valgrind,--without-valgrind,valgrind"
Brad Bishop26bdd442019-08-16 17:08:17 -040028PACKAGECONFIG[lmdb] = ",--without-ldb-lmdb,lmdb,"
Brad Bishop1a4b7ee2018-12-16 17:11:34 -080029
30SRC_URI += "${@bb.utils.contains('PACKAGECONFIG', 'ldap', '', 'file://avoid-openldap-unless-wanted.patch', d)}"
31
32LIC_FILES_CHKSUM = "file://pyldb.h;endline=24;md5=dfbd238cecad76957f7f860fbe9adade \
33 file://man/ldb.3.xml;beginline=261;endline=262;md5=137f9fd61040c1505d1aa1019663fd08 \
34 file://tools/ldbdump.c;endline=19;md5=a7d4fc5d1f75676b49df491575a86a42"
35
Brad Bishop2f973922019-11-11 07:58:48 -050036SRC_URI[md5sum] = "fc58ef432c1fcb03fc3bb6cccce08977"
37SRC_URI[sha256sum] = "ff82474d0bf109e415a2d50334bde5715f486a53ff4bb8c7f74459dd229e975b"
Brad Bishop1a4b7ee2018-12-16 17:11:34 -080038
Brad Bishop23eaf032019-11-20 05:15:02 -050039inherit waf-samba
Brad Bishop1a4b7ee2018-12-16 17:11:34 -080040
41S = "${WORKDIR}/ldb-${PV}"
42
Brad Bishop26bdd442019-08-16 17:08:17 -040043#cross_compile cannot use preforked process, since fork process earlier than point subproces.popen
44#to cross Popen
45export WAF_NO_PREFORK="yes"
46
Brad Bishop1a4b7ee2018-12-16 17:11:34 -080047EXTRA_OECONF += "--disable-rpath \
48 --disable-rpath-install \
49 --bundled-libraries=cmocka \
50 --builtin-libraries=replace \
51 --with-modulesdir=${libdir}/ldb/modules \
52 --with-privatelibdir=${libdir}/ldb \
53 --with-libiconv=${STAGING_DIR_HOST}${prefix}\
Brad Bishop1a4b7ee2018-12-16 17:11:34 -080054 "
55
56PACKAGES =+ "pyldb pyldb-dbg pyldb-dev"
57
58NOAUTOPACKAGEDEBUG = "1"
59
60FILES_${PN} += "${libdir}/ldb/*"
61FILES_${PN}-dbg += "${bindir}/.debug/* \
62 ${libdir}/.debug/* \
63 ${libdir}/ldb/.debug/* \
64 ${libdir}/ldb/modules/ldb/.debug/*"
65
66FILES_pyldb = "${libdir}/python${PYTHON_BASEVERSION}/site-packages/* \
Brad Bishop26bdd442019-08-16 17:08:17 -040067 ${libdir}/libpyldb-util.*.so.* \
Brad Bishop1a4b7ee2018-12-16 17:11:34 -080068 "
69FILES_pyldb-dbg = "${libdir}/python${PYTHON_BASEVERSION}/site-packages/.debug \
Brad Bishop26bdd442019-08-16 17:08:17 -040070 ${libdir}/.debug/libpyldb-util.*.so.*"
71FILES_pyldb-dev = "${libdir}/libpyldb-util.*.so"