2021-11-19 13:43:28 +01:00
|
|
|
{ stdenv
|
|
|
|
, cmake
|
2022-08-14 13:47:29 +02:00
|
|
|
, curl
|
2021-11-19 13:43:28 +01:00
|
|
|
, fetchFromGitHub
|
|
|
|
, gss
|
|
|
|
, hwloc
|
|
|
|
, lib
|
|
|
|
, libsodium
|
|
|
|
, libuv
|
2022-02-02 11:46:13 +01:00
|
|
|
, nix-update-script
|
2021-11-19 13:43:28 +01:00
|
|
|
, openssl
|
|
|
|
, pkg-config
|
|
|
|
, zeromq
|
|
|
|
}:
|
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "p2pool";
|
2022-08-31 19:15:17 +02:00
|
|
|
version = "2.3";
|
2021-11-19 13:43:28 +01:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "SChernykh";
|
|
|
|
repo = "p2pool";
|
|
|
|
rev = "v${version}";
|
2022-08-31 19:15:17 +02:00
|
|
|
sha256 = "sha256-hf0iU246cmTCDYotPdTACFY135L2+cRV3FpVYnRZtRc=";
|
2021-11-19 13:43:28 +01:00
|
|
|
fetchSubmodules = true;
|
|
|
|
};
|
|
|
|
|
|
|
|
nativeBuildInputs = [ cmake pkg-config ];
|
2022-08-14 13:47:29 +02:00
|
|
|
buildInputs = [ libuv zeromq libsodium gss hwloc openssl curl ];
|
2021-11-19 13:43:28 +01:00
|
|
|
|
|
|
|
installPhase = ''
|
|
|
|
runHook preInstall
|
|
|
|
|
|
|
|
install -vD p2pool $out/bin/p2pool
|
|
|
|
|
|
|
|
runHook postInstall
|
|
|
|
'';
|
|
|
|
|
2022-02-02 11:46:13 +01:00
|
|
|
passthru = {
|
|
|
|
updateScript = nix-update-script {
|
|
|
|
attrPath = pname;
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
2021-11-19 13:43:28 +01:00
|
|
|
meta = with lib; {
|
|
|
|
description = "Decentralized pool for Monero mining";
|
|
|
|
homepage = "https://github.com/SChernykh/p2pool";
|
|
|
|
license = licenses.gpl3Only;
|
|
|
|
maintainers = with maintainers; [ ratsclub ];
|
|
|
|
};
|
|
|
|
}
|