nixpkgs/pkgs/by-name/po/powerjoular/package.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

46 lines
853 B
Nix
Raw Normal View History

2024-06-16 15:06:56 +00:00
{
stdenv,
lib,
fetchFromGitHub,
gnat,
gprbuild,
}:
stdenv.mkDerivation rec {
pname = "powerjoular";
2024-07-15 01:49:46 +00:00
version = "1.0.4";
2024-06-16 15:06:56 +00:00
src = fetchFromGitHub {
owner = "joular";
repo = pname;
rev = version;
2024-07-15 01:49:46 +00:00
hash = "sha256-zcG/R8isL7WcwsIFovnRKZ5DCtZu4vJWOximFY9ARuE=";
2024-06-16 15:06:56 +00:00
};
nativeBuildInputs = [
gnat
gprbuild
];
buildPhase = ''
runHook preBuild
gprbuild
runHook postBuild
'';
installPhase = ''
runHook preInstall
mkdir -p $out/bin
cp obj/powerjoular $out/bin
runHook postInstall
'';
meta = with lib; {
description = "CLI software to monitor the power consumption of software and hardware components";
homepage = "https://github.com/joular/powerjoular";
maintainers = [ maintainers.julienmalka ];
license = licenses.gpl3Plus;
platforms = platforms.linux;
};
}