2021-02-05 17:12:51 +00:00
|
|
|
{ lib, stdenv
|
2020-04-24 23:36:52 +00:00
|
|
|
, fetchurl
|
|
|
|
, python3
|
|
|
|
, pkg-config
|
|
|
|
, readline
|
|
|
|
, tdb
|
|
|
|
, talloc
|
|
|
|
, tevent
|
|
|
|
, popt
|
|
|
|
, libxslt
|
|
|
|
, docbook-xsl-nons
|
|
|
|
, docbook_xml_dtd_42
|
|
|
|
, cmocka
|
|
|
|
, wafHook
|
2023-02-16 17:41:37 +00:00
|
|
|
, libxcrypt
|
2020-04-24 23:36:52 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "ldb";
|
2023-02-16 17:41:37 +00:00
|
|
|
version = "2.6.1";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchurl {
|
|
|
|
url = "mirror://samba/ldb/${pname}-${version}.tar.gz";
|
2023-02-16 17:41:37 +00:00
|
|
|
sha256 = "sha256-RnQD9334Z4LDlluxdUQLqi7XUan+uVYBlL2MBr8XNsk=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
outputs = [ "out" "dev" ];
|
|
|
|
|
|
|
|
nativeBuildInputs = [
|
|
|
|
pkg-config
|
|
|
|
python3
|
|
|
|
wafHook
|
|
|
|
libxslt
|
|
|
|
docbook-xsl-nons
|
|
|
|
docbook_xml_dtd_42
|
2023-02-16 17:41:37 +00:00
|
|
|
tdb
|
|
|
|
tevent
|
2020-04-24 23:36:52 +00:00
|
|
|
];
|
|
|
|
|
|
|
|
buildInputs = [
|
|
|
|
python3
|
|
|
|
readline # required to build python
|
|
|
|
tdb
|
|
|
|
talloc
|
|
|
|
tevent
|
|
|
|
popt
|
|
|
|
cmocka
|
2023-02-16 17:41:37 +00:00
|
|
|
libxcrypt
|
2020-04-24 23:36:52 +00:00
|
|
|
];
|
|
|
|
|
2023-02-16 17:41:37 +00:00
|
|
|
# otherwise the configure script fails with
|
|
|
|
# PYTHONHASHSEED=1 missing! Don't use waf directly, use ./configure and make!
|
|
|
|
preConfigure = ''
|
|
|
|
export PKGCONFIG="$PKG_CONFIG"
|
|
|
|
export PYTHONHASHSEED=1
|
|
|
|
'';
|
|
|
|
|
2020-04-24 23:36:52 +00:00
|
|
|
wafPath = "buildtools/bin/waf";
|
|
|
|
|
|
|
|
wafConfigureFlags = [
|
|
|
|
"--bundled-libraries=NONE"
|
|
|
|
"--builtin-libraries=replace"
|
|
|
|
"--without-ldb-lmdb"
|
|
|
|
];
|
|
|
|
|
|
|
|
stripDebugList = [ "bin" "lib" "modules" ];
|
|
|
|
|
2021-02-05 17:12:51 +00:00
|
|
|
meta = with lib; {
|
2022-06-16 17:23:12 +00:00
|
|
|
broken = stdenv.isDarwin;
|
2020-04-24 23:36:52 +00:00
|
|
|
description = "A LDAP-like embedded database";
|
|
|
|
homepage = "https://ldb.samba.org/";
|
|
|
|
license = licenses.lgpl3Plus;
|
|
|
|
platforms = platforms.all;
|
|
|
|
};
|
|
|
|
}
|