ntdb: clean up expression

* format with nixpkgs-fmt
* quote homepage as per RFC 0045
* split name → pname & version
* do not use aliases
* switch to wafHook
* move build tools to nativeBuildInputs
This commit is contained in:
Jan Tojnar 2020-03-31 05:17:21 +02:00
parent 4cfdc7af53
commit 1be7664496
No known key found for this signature in database
GPG key ID: 7FAB2A15F7A607A4
2 changed files with 29 additions and 15 deletions

View file

@ -1,32 +1,48 @@
{ stdenv, fetchurl, python, pkgconfig, readline, gettext, libxslt { stdenv
, docbook_xsl, docbook_xml_dtd_42 , fetchurl
, python3
, pkg-config
, readline
, gettext
, libxslt
, docbook-xsl-nons
, docbook_xml_dtd_42
, wafHook
}: }:
stdenv.mkDerivation rec { stdenv.mkDerivation rec {
name = "ntdb-1.0"; pname = "ntdb";
version = "1.0";
src = fetchurl { src = fetchurl {
url = "mirror://samba/tdb/${name}.tar.gz"; url = "mirror://samba/tdb/${pname}-${version}.tar.gz";
sha256 = "0jdzgrz5sr25k83yrw7wqb3r0yj1v04z4s3lhsmnr5z6n5ifhyl1"; sha256 = "0jdzgrz5sr25k83yrw7wqb3r0yj1v04z4s3lhsmnr5z6n5ifhyl1";
}; };
nativeBuildInputs = [ pkgconfig ]; nativeBuildInputs = [
buildInputs = [ pkg-config
python readline gettext libxslt docbook_xsl docbook_xml_dtd_42 gettext
libxslt
docbook-xsl-nons
docbook_xml_dtd_42
wafHook
]; ];
preConfigure = '' buildInputs = [
patchShebangs buildtools/bin/waf python3
''; readline # required to build python
];
configureFlags = [ wafPath = "buildtools/bin/waf";
wafConfigureFlags = [
"--bundled-libraries=NONE" "--bundled-libraries=NONE"
"--builtin-libraries=replace,ccan" "--builtin-libraries=replace,ccan"
]; ];
meta = with stdenv.lib; { meta = with stdenv.lib; {
description = "The not-so trivial database"; description = "The not-so trivial database";
homepage = https://tdb.samba.org/; homepage = "https://tdb.samba.org/";
license = licenses.lgpl3Plus; license = licenses.lgpl3Plus;
platforms = platforms.all; platforms = platforms.all;
}; };

View file

@ -14627,9 +14627,7 @@ in
tclx = callPackage ../development/libraries/tclx { }; tclx = callPackage ../development/libraries/tclx { };
ntdb = callPackage ../development/libraries/ntdb { ntdb = callPackage ../development/libraries/ntdb { };
python = python2;
};
tdb = callPackage ../development/libraries/tdb {}; tdb = callPackage ../development/libraries/tdb {};