Merge pull request #249600 from anthonyroussel/nvtop_3_0_2
nvtop: 3.0.1 -> 3.0.2
This commit is contained in:
commit
c0967315ff
|
@ -11,14 +11,15 @@
|
||||||
, udev
|
, udev
|
||||||
, addOpenGLRunpath
|
, addOpenGLRunpath
|
||||||
, amd ? true
|
, amd ? true
|
||||||
|
, intel ? true
|
||||||
|
, msm ? true
|
||||||
, nvidia ? true
|
, nvidia ? true
|
||||||
}:
|
}:
|
||||||
|
|
||||||
let
|
let
|
||||||
pname-suffix = if amd && nvidia then "" else if amd then "-amd" else "-nvidia";
|
|
||||||
nvidia-postFixup = "addOpenGLRunpath $out/bin/nvtop";
|
nvidia-postFixup = "addOpenGLRunpath $out/bin/nvtop";
|
||||||
libPath = lib.makeLibraryPath [ libdrm ncurses udev ];
|
libPath = lib.makeLibraryPath [ libdrm ncurses udev ];
|
||||||
amd-postFixup = ''
|
drm-postFixup = ''
|
||||||
patchelf \
|
patchelf \
|
||||||
--set-interpreter "$(cat $NIX_CC/nix-support/dynamic-linker)" \
|
--set-interpreter "$(cat $NIX_CC/nix-support/dynamic-linker)" \
|
||||||
--set-rpath "${libPath}" \
|
--set-rpath "${libPath}" \
|
||||||
|
@ -26,14 +27,14 @@ let
|
||||||
'';
|
'';
|
||||||
in
|
in
|
||||||
stdenv.mkDerivation rec {
|
stdenv.mkDerivation rec {
|
||||||
pname = "nvtop" + pname-suffix;
|
pname = "nvtop";
|
||||||
version = "3.0.1";
|
version = "3.0.2";
|
||||||
|
|
||||||
src = fetchFromGitHub {
|
src = fetchFromGitHub {
|
||||||
owner = "Syllo";
|
owner = "Syllo";
|
||||||
repo = "nvtop";
|
repo = "nvtop";
|
||||||
rev = version;
|
rev = version;
|
||||||
hash = "sha256-vLvt2sankpQWAVZBPo3OePs4LDy7YfVnMkZLfN6ERAc=";
|
hash = "sha256-SHKdjzbc3ZZfOW2p8RLFRKKBfLnO+Z8/bKVxcdLLqxw=";
|
||||||
};
|
};
|
||||||
|
|
||||||
cmakeFlags = with lib; [
|
cmakeFlags = with lib; [
|
||||||
|
@ -43,17 +44,19 @@ stdenv.mkDerivation rec {
|
||||||
] ++ optional nvidia "-DNVML_INCLUDE_DIRS=${cudatoolkit}/include"
|
] ++ optional nvidia "-DNVML_INCLUDE_DIRS=${cudatoolkit}/include"
|
||||||
++ optional nvidia "-DNVML_LIBRARIES=${cudatoolkit}/targets/x86_64-linux/lib/stubs/libnvidia-ml.so"
|
++ optional nvidia "-DNVML_LIBRARIES=${cudatoolkit}/targets/x86_64-linux/lib/stubs/libnvidia-ml.so"
|
||||||
++ optional (!amd) "-DAMDGPU_SUPPORT=OFF"
|
++ optional (!amd) "-DAMDGPU_SUPPORT=OFF"
|
||||||
|
++ optional (!intel) "-DINTEL_SUPPORT=OFF"
|
||||||
|
++ optional (!msm) "-DMSM_SUPPORT=OFF"
|
||||||
++ optional (!nvidia) "-DNVIDIA_SUPPORT=OFF"
|
++ optional (!nvidia) "-DNVIDIA_SUPPORT=OFF"
|
||||||
++ optional amd "-DLibdrm_INCLUDE_DIRS=${libdrm}/lib/stubs/libdrm.so.2"
|
++ optional (amd || msm) "-DLibdrm_INCLUDE_DIRS=${libdrm}/lib/stubs/libdrm.so.2"
|
||||||
;
|
;
|
||||||
nativeBuildInputs = [ cmake gtest ] ++ lib.optional nvidia addOpenGLRunpath;
|
nativeBuildInputs = [ cmake gtest ] ++ lib.optional nvidia addOpenGLRunpath;
|
||||||
buildInputs = with lib; [ ncurses udev ]
|
buildInputs = with lib; [ ncurses udev ]
|
||||||
++ optional nvidia cudatoolkit
|
++ optional nvidia cudatoolkit
|
||||||
++ optional amd libdrm
|
++ optional (amd || msm) libdrm
|
||||||
;
|
;
|
||||||
|
|
||||||
# ordering of fixups is important
|
# ordering of fixups is important
|
||||||
postFixup = (lib.optionalString amd amd-postFixup) + (lib.optionalString nvidia nvidia-postFixup);
|
postFixup = (lib.optionalString (amd || msm) drm-postFixup) + (lib.optionalString nvidia nvidia-postFixup);
|
||||||
|
|
||||||
doCheck = true;
|
doCheck = true;
|
||||||
|
|
||||||
|
@ -66,9 +69,10 @@ stdenv.mkDerivation rec {
|
||||||
};
|
};
|
||||||
|
|
||||||
meta = with lib; {
|
meta = with lib; {
|
||||||
description = "A (h)top like task monitor for AMD, Intel and NVIDIA GPUs";
|
description = "A (h)top like task monitor for AMD, Adreno, Intel and NVIDIA GPUs";
|
||||||
longDescription = ''
|
longDescription = ''
|
||||||
Nvtop stands for Neat Videocard TOP, a (h)top like task monitor for AMD, Intel and NVIDIA GPUs. It can handle multiple GPUs and print information about them in a htop familiar way.
|
Nvtop stands for Neat Videocard TOP, a (h)top like task monitor for AMD, Adreno, Intel and NVIDIA GPUs.
|
||||||
|
It can handle multiple GPUs and print information about them in a htop familiar way.
|
||||||
'';
|
'';
|
||||||
homepage = "https://github.com/Syllo/nvtop";
|
homepage = "https://github.com/Syllo/nvtop";
|
||||||
changelog = "https://github.com/Syllo/nvtop/releases/tag/${version}";
|
changelog = "https://github.com/Syllo/nvtop/releases/tag/${version}";
|
||||||
|
|
|
@ -24268,8 +24268,30 @@ with pkgs;
|
||||||
nvitop = callPackage ../tools/system/nvitop { };
|
nvitop = callPackage ../tools/system/nvitop { };
|
||||||
|
|
||||||
nvtop = callPackage ../tools/system/nvtop { };
|
nvtop = callPackage ../tools/system/nvtop { };
|
||||||
nvtop-nvidia = callPackage ../tools/system/nvtop { amd = false; };
|
nvtop-amd = (callPackage ../tools/system/nvtop {
|
||||||
nvtop-amd = callPackage ../tools/system/nvtop { nvidia = false; };
|
amd = true;
|
||||||
|
intel = false;
|
||||||
|
msm = false;
|
||||||
|
nvidia = false;
|
||||||
|
}).overrideAttrs { pname = "nvtop-amd"; };
|
||||||
|
nvtop-intel = (callPackage ../tools/system/nvtop {
|
||||||
|
amd = false;
|
||||||
|
intel = true;
|
||||||
|
msm = false;
|
||||||
|
nvidia = false;
|
||||||
|
}).overrideAttrs { pname = "nvtop-intel"; };
|
||||||
|
nvtop-msm = (callPackage ../tools/system/nvtop {
|
||||||
|
amd = false;
|
||||||
|
intel = false;
|
||||||
|
msm = true;
|
||||||
|
nvidia = false;
|
||||||
|
}).overrideAttrs { pname = "nvtop-msm"; };
|
||||||
|
nvtop-nvidia = (callPackage ../tools/system/nvtop {
|
||||||
|
amd = false;
|
||||||
|
intel = false;
|
||||||
|
msm = false;
|
||||||
|
nvidia = true;
|
||||||
|
}).overrideAttrs { pname = "nvtop-nvidia"; };
|
||||||
|
|
||||||
ocl-icd = callPackage ../development/libraries/ocl-icd { };
|
ocl-icd = callPackage ../development/libraries/ocl-icd { };
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue