2020-03-31 04:34:20 +02:00
|
|
|
{ stdenv
|
|
|
|
, fetchurl
|
|
|
|
, python
|
|
|
|
, pkg-config
|
|
|
|
, readline
|
|
|
|
, tdb
|
|
|
|
, talloc
|
|
|
|
, tevent
|
|
|
|
, popt
|
|
|
|
, libxslt
|
|
|
|
, docbook-xsl-nons
|
|
|
|
, docbook_xml_dtd_42
|
|
|
|
, cmocka
|
|
|
|
, wafHook
|
2014-04-30 09:42:02 +02:00
|
|
|
}:
|
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
2020-03-31 04:34:20 +02:00
|
|
|
pname = "ldb";
|
|
|
|
version = "1.3.3";
|
2014-04-30 09:42:02 +02:00
|
|
|
|
|
|
|
src = fetchurl {
|
2020-03-31 04:34:20 +02:00
|
|
|
url = "mirror://samba/ldb/${pname}-${version}.tar.gz";
|
|
|
|
sha256 = "14gsrm7dvyjpbpnc60z75j6fz2p187abm2h353lq95kx2bv70c1b";
|
2014-04-30 09:42:02 +02:00
|
|
|
};
|
|
|
|
|
2016-09-19 15:33:35 +02:00
|
|
|
outputs = [ "out" "dev" ];
|
|
|
|
|
2020-03-31 04:34:20 +02:00
|
|
|
nativeBuildInputs = [
|
|
|
|
pkg-config
|
|
|
|
wafHook
|
|
|
|
];
|
|
|
|
|
2014-04-30 09:42:02 +02:00
|
|
|
buildInputs = [
|
2020-03-31 04:34:20 +02:00
|
|
|
python
|
|
|
|
readline
|
|
|
|
tdb
|
|
|
|
talloc
|
|
|
|
tevent
|
|
|
|
popt
|
|
|
|
libxslt
|
|
|
|
docbook-xsl-nons
|
|
|
|
docbook_xml_dtd_42
|
2018-04-29 04:13:12 +02:00
|
|
|
cmocka
|
2014-04-30 09:42:02 +02:00
|
|
|
];
|
|
|
|
|
2019-03-20 14:04:12 +01:00
|
|
|
patches = [
|
|
|
|
# CVE-2019-3824
|
|
|
|
# downloading the patch from debian as they have ported the patch from samba to ldb but otherwise is identical to
|
|
|
|
# https://bugzilla.samba.org/attachment.cgi?id=14857
|
|
|
|
(fetchurl {
|
|
|
|
name = "CVE-2019-3824.patch";
|
|
|
|
url = "https://sources.debian.org/data/main/l/ldb/2:1.1.27-1+deb9u1/debian/patches/CVE-2019-3824-master-v4-5-02.patch";
|
|
|
|
sha256 = "1idnqckvjh18rh9sbq90rr4sxfviha9nd1ca9pd6lai0y6r6q4yd";
|
|
|
|
})
|
|
|
|
];
|
|
|
|
|
2020-03-31 04:34:20 +02:00
|
|
|
wafPath = "buildtools/bin/waf";
|
2014-04-30 09:42:02 +02:00
|
|
|
|
2020-03-31 04:34:20 +02:00
|
|
|
wafConfigureFlags = [
|
2014-04-30 09:42:02 +02:00
|
|
|
"--bundled-libraries=NONE"
|
|
|
|
"--builtin-libraries=replace"
|
|
|
|
];
|
|
|
|
|
2016-09-19 15:33:35 +02:00
|
|
|
stripDebugList = "bin lib modules";
|
|
|
|
|
2014-04-30 09:42:02 +02:00
|
|
|
meta = with stdenv.lib; {
|
2016-06-20 12:53:46 +02:00
|
|
|
description = "A LDAP-like embedded database";
|
2020-03-31 04:34:20 +02:00
|
|
|
homepage = "https://ldb.samba.org/";
|
2014-04-30 09:42:02 +02:00
|
|
|
license = licenses.lgpl3Plus;
|
|
|
|
platforms = platforms.all;
|
|
|
|
};
|
|
|
|
}
|