nixpkgs/pkgs/by-name/re/remctl/package.nix
2024-10-21 09:58:24 -04:00

63 lines
1.2 KiB
Nix

{
lib,
stdenv,
fetchFromGitHub,
autoreconfHook,
libevent,
krb5,
openssl,
perl,
pkg-config,
}:
stdenv.mkDerivation (finalAttrs: {
pname = "remctl";
version = "3.18";
src = fetchFromGitHub {
owner = "rra";
repo = "remctl";
rev = "release/${finalAttrs.version}";
hash = "sha256-4KzNhFswNTwcXrDBAfRyr502zwRQ3FACV8gDfBm7M0A=";
};
# Fix references to /usr/bin/perl in tests and
# disable acl/localgroup test that does not work in sandbox.
postPatch = ''
patchShebangs tests
sed -i '\,server/acl/localgroup,d' tests/TESTS
'';
nativeBuildInputs = [
autoreconfHook
perl
pkg-config
];
buildInputs = [
krb5
libevent
openssl
];
# Invokes pod2man to create man pages required by Makefile.
preConfigure = ''
./bootstrap
'';
makeFlags = [
"LD=$(CC)"
"REMCTL_PERL_FLAGS='--prefix=$(out)'"
"REMCTL_PYTHON_INSTALL='--prefix=$(out)'"
];
checkTarget = "check-local";
meta = with lib; {
description = "Remote execution tool";
homepage = "https://www.eyrie.org/~eagle/software/remctl";
mainProgram = "remctl";
license = licenses.mit;
maintainers = teams.deshaw.members;
};
})