jenkins: 2.479.3 -> 2.492.1
[NixPkgs.git] / pkgs / by-name / nt / ntirpc / package.nix
blobf88180473f2ffb3e2ccff9f514ad98193ee3fafa
2   lib,
3   stdenv,
4   fetchFromGitHub,
5   cmake,
6   krb5,
7   liburcu,
8   libtirpc,
9   libnsl,
12 stdenv.mkDerivation rec {
13   pname = "ntirpc";
14   version = "6.3";
16   src = fetchFromGitHub {
17     owner = "nfs-ganesha";
18     repo = "ntirpc";
19     rev = "v${version}";
20     sha256 = "sha256-e4eF09xwX2Qf/y9YfOGy7p6yhDFnKGI5cnrQy3o8c98=";
21   };
23   outputs = [
24     "out"
25     "dev"
26   ];
27   postPatch = ''
28     substituteInPlace ntirpc/netconfig.h --replace "/etc/netconfig" "$out/etc/netconfig"
29     sed '1i#include <assert.h>' -i src/work_pool.c
30   '';
32   nativeBuildInputs = [ cmake ];
33   buildInputs = [
34     krb5
35     liburcu
36     libnsl
37   ];
39   postInstall = ''
40     mkdir -p $out/etc
42     # Library needs a netconfig to run.
43     # Steal the file from libtirpc
44     cp ${libtirpc}/etc/netconfig $out/etc/
45   '';
47   meta = with lib; {
48     description = "Transport-independent RPC (TI-RPC)";
49     homepage = "https://github.com/nfs-ganesha/ntirpc";
50     maintainers = [ maintainers.markuskowa ];
51     platforms = platforms.linux;
52     license = licenses.bsd3;
53   };