2017-01-29 22:29:39 +01:00
|
|
|
nvidia_x11: sha256:
|
|
|
|
|
2019-04-23 21:46:45 +02:00
|
|
|
{ stdenv, fetchFromGitHub, m4 }:
|
2017-01-29 22:29:39 +01:00
|
|
|
|
2019-08-13 23:52:01 +02:00
|
|
|
stdenv.mkDerivation {
|
2019-04-23 21:46:45 +02:00
|
|
|
pname = "nvidia-persistenced";
|
2017-01-29 22:29:39 +01:00
|
|
|
inherit (nvidia_x11) version;
|
|
|
|
|
2019-04-23 21:46:45 +02:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "NVIDIA";
|
|
|
|
repo = "nvidia-persistenced";
|
|
|
|
rev = nvidia_x11.version;
|
2017-01-29 22:29:39 +01:00
|
|
|
inherit sha256;
|
|
|
|
};
|
|
|
|
|
|
|
|
nativeBuildInputs = [ m4 ];
|
|
|
|
|
|
|
|
installFlags = [ "PREFIX=$(out)" ];
|
|
|
|
|
|
|
|
postFixup = ''
|
2019-02-27 09:44:05 +01:00
|
|
|
# Save a copy of persistenced for mounting in containers
|
|
|
|
mkdir $out/origBin
|
|
|
|
cp $out/{bin,origBin}/nvidia-persistenced
|
|
|
|
patchelf --set-interpreter /lib64/ld-linux-x86-64.so.2 $out/origBin/nvidia-persistenced
|
|
|
|
|
2017-01-29 22:29:39 +01:00
|
|
|
patchelf --set-rpath "$(patchelf --print-rpath $out/bin/nvidia-persistenced):${nvidia_x11}/lib" \
|
|
|
|
$out/bin/nvidia-persistenced
|
|
|
|
'';
|
|
|
|
|
|
|
|
meta = with stdenv.lib; {
|
2020-04-01 03:11:51 +02:00
|
|
|
homepage = "https://www.nvidia.com/object/unix.html";
|
2017-01-29 22:29:39 +01:00
|
|
|
description = "Settings application for NVIDIA graphics cards";
|
|
|
|
license = licenses.unfreeRedistributable;
|
2018-03-27 15:40:15 +02:00
|
|
|
platforms = nvidia_x11.meta.platforms;
|
2017-01-29 22:29:39 +01:00
|
|
|
maintainers = with maintainers; [ abbradar ];
|
|
|
|
};
|
|
|
|
}
|