nixpkgs mirror (for testing) github.com/NixOS/nixpkgs
nix
at devShellTools-shell 87 lines 2.0 kB view raw
1{ 2 lib, 3 stdenv, 4 fetchurl, 5 fetchpatch, 6 bc, 7 check, 8 curl, 9 10 withEncryption ? true, 11 libgcrypt, 12 libgpg-error, 13 14 withUuid ? true, 15 libuuid, 16 17 withBashBuiltins ? true, 18 bash, 19}: 20 21stdenv.mkDerivation rec { 22 pname = "recutils"; 23 version = "1.9"; 24 25 src = fetchurl { 26 url = "mirror://gnu/recutils/recutils-${version}.tar.gz"; 27 hash = "sha256-YwFZKwAgwUtFZ1fvXUNNSfYCe45fOkmdEzYvIFxIbg4="; 28 }; 29 30 patches = [ 31 (fetchpatch { 32 name = "configure-big_sur.diff"; 33 url = "https://github.com/Homebrew/formula-patches/raw/03cf8088210822aa2c1ab544ed58ea04c897d9c4/libtool/configure-big_sur.diff"; 34 hash = "sha256-NazWrrwZhD8aKzpj6IC6zrD1J4qxrOZh5XpQLZ14yTw="; 35 }) 36 ]; 37 38 hardeningDisable = lib.optional stdenv.cc.isClang "format"; 39 40 configureFlags = lib.optionals withBashBuiltins [ 41 "--with-bash-headers=${bash.dev}/include/bash" 42 ]; 43 44 buildInputs = [ 45 curl 46 ] 47 ++ lib.optionals withEncryption [ 48 libgpg-error.dev 49 libgcrypt.dev 50 ] 51 ++ lib.optionals withUuid [ 52 libuuid 53 ] 54 ++ lib.optionals withBashBuiltins [ 55 bash.dev 56 ]; 57 58 env.NIX_CFLAGS_COMPILE = toString ( 59 lib.optionals stdenv.cc.isClang [ 60 "-Wno-error=implicit-function-declaration" 61 ] 62 ++ lib.optionals stdenv.cc.isGNU [ 63 "-Wno-error=implicit-function-declaration" 64 "-Wno-error=incompatible-pointer-types" 65 ] 66 ); 67 68 nativeCheckInputs = [ 69 bc 70 check 71 ]; 72 73 doCheck = true; 74 75 meta = with lib; { 76 homepage = "https://www.gnu.org/software/recutils/"; 77 description = "Tools and libraries to access human-editable, text-based databases"; 78 longDescription = '' 79 GNU Recutils is a set of tools and libraries to access human-editable, 80 text-based databases called recfiles. The data is stored as a sequence of 81 records, each record containing an arbitrary number of named fields. 82 ''; 83 license = licenses.gpl3Plus; 84 maintainers = with maintainers; [ ]; 85 platforms = platforms.all; 86 }; 87}