i2pd: install systemd service file and man page

The systemd service file could be useful in the future for use in the i2pd NixOS module.
This commit is contained in:
Luflosi 2022-01-25 17:42:56 +01:00
parent 04560b9163
commit 577d4ef239
No known key found for this signature in database
GPG key ID: 4E41E29EDCC345D0

View file

@ -1,4 +1,5 @@
{ lib, stdenv, fetchFromGitHub
, installShellFiles
, boost, zlib, openssl
, upnpSupport ? true, miniupnpc ? null
, aesniSupport ? stdenv.hostPlatform.aesSupport
@ -21,6 +22,10 @@ stdenv.mkDerivation rec {
buildInputs = with lib; [ boost zlib openssl ]
++ optional upnpSupport miniupnpc;
nativeBuildInputs = [
installShellFiles
];
makeFlags =
let ynf = a: b: a + "=" + (if b then "yes" else "no"); in
[ (ynf "USE_AESNI" aesniSupport)
@ -32,6 +37,8 @@ stdenv.mkDerivation rec {
installPhase = ''
install -D i2pd $out/bin/i2pd
install --mode=444 -D 'contrib/i2pd.service' "$out/etc/systemd/system/i2pd.service"
installManPage 'debian/i2pd.1'
'';
meta = with lib; {