1{ lib, fetchFromGitHub, stdenv, cmake, libssh, openssl }:
2
3stdenv.mkDerivation rec {
4 pname = "rtrlib";
5 version = "0.8.0";
6
7 src = fetchFromGitHub {
8 repo = pname;
9 owner = "rtrlib";
10 rev = "v${version}";
11 sha256 = "sha256-ISb4ojcDvXY/88GbFMrA5V5+SGE6CmE5D+pokDTwotQ=";
12 };
13
14 nativeBuildInputs = [ cmake ];
15 buildInputs = [ libssh openssl ];
16
17 postFixup = ''
18 substituteInPlace "$out"/lib/pkgconfig/rtrlib.pc \
19 --replace '=''${prefix}//' '=/'
20 '';
21
22 meta = with lib; {
23 description = "An open-source C implementation of the RPKI/Router Protocol client";
24 homepage = "https://github.com/rtrlib/rtrlib";
25 license = licenses.mit;
26 maintainers = with maintainers; [ Anillc ];
27 platforms = platforms.all;
28 };
29}