2017-01-29 21:29:39 +00:00
|
|
|
nvidia_x11: sha256:
|
|
|
|
|
2018-07-21 01:44:44 +01:00
|
|
|
{ stdenv, fetchurl, m4 }:
|
2017-01-29 21:29:39 +00:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
name = "nvidia-persistenced-${nvidia_x11.version}";
|
|
|
|
inherit (nvidia_x11) version;
|
|
|
|
|
|
|
|
src = fetchurl {
|
2017-04-29 22:19:04 +01:00
|
|
|
url = "https://download.nvidia.com/XFree86/nvidia-persistenced/${name}.tar.bz2";
|
2017-01-29 21:29:39 +00:00
|
|
|
inherit sha256;
|
|
|
|
};
|
|
|
|
|
|
|
|
nativeBuildInputs = [ m4 ];
|
|
|
|
|
|
|
|
installFlags = [ "PREFIX=$(out)" ];
|
|
|
|
|
|
|
|
postFixup = ''
|
2019-02-27 08:44:05 +00: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 21:29:39 +00:00
|
|
|
patchelf --set-rpath "$(patchelf --print-rpath $out/bin/nvidia-persistenced):${nvidia_x11}/lib" \
|
|
|
|
$out/bin/nvidia-persistenced
|
|
|
|
'';
|
|
|
|
|
|
|
|
meta = with stdenv.lib; {
|
2019-04-15 00:25:45 +01:00
|
|
|
homepage = https://www.nvidia.com/object/unix.html;
|
2017-01-29 21:29:39 +00:00
|
|
|
description = "Settings application for NVIDIA graphics cards";
|
|
|
|
license = licenses.unfreeRedistributable;
|
2018-03-27 14:40:15 +01:00
|
|
|
platforms = nvidia_x11.meta.platforms;
|
2017-01-29 21:29:39 +00:00
|
|
|
maintainers = with maintainers; [ abbradar ];
|
|
|
|
};
|
|
|
|
}
|