Merge pull request #249158 from Kiskae/nvidia-settings/fix-path
linuxPackages.nvidia_x11.settings: fix runpath
This commit is contained in:
commit
467e4c2e93
2 changed files with 25 additions and 6 deletions
|
@ -64,6 +64,7 @@ installPhase() {
|
|||
for i in $lib32 $out; do
|
||||
rm -f $i/lib/lib{glx,nvidia-wfb}.so.* # handled separately
|
||||
rm -f $i/lib/libnvidia-gtk* # built from source
|
||||
rm -f $i/lib/libnvidia-wayland-client* # built from source
|
||||
if [ "$useGLVND" = "1" ]; then
|
||||
# Pre-built libglvnd
|
||||
rm $i/lib/lib{GL,GLX,EGL,GLESv1_CM,GLESv2,OpenGL,GLdispatch}.so.*
|
||||
|
|
|
@ -1,9 +1,25 @@
|
|||
nvidia_x11: sha256:
|
||||
|
||||
{ stdenv, lib, fetchFromGitHub, fetchpatch, pkg-config, m4, jansson, gtk2, dbus, gtk3
|
||||
, libXv, libXrandr, libXext, libXxf86vm, libvdpau
|
||||
, librsvg, wrapGAppsHook
|
||||
, withGtk2 ? false, withGtk3 ? true
|
||||
{ stdenv
|
||||
, lib
|
||||
, fetchFromGitHub
|
||||
, fetchpatch
|
||||
, pkg-config
|
||||
, m4
|
||||
, jansson
|
||||
, gtk2
|
||||
, dbus
|
||||
, gtk3
|
||||
, libXv
|
||||
, libXrandr
|
||||
, libXext
|
||||
, libXxf86vm
|
||||
, libvdpau
|
||||
, librsvg
|
||||
, wrapGAppsHook
|
||||
, addOpenGLRunpath
|
||||
, withGtk2 ? false
|
||||
, withGtk3 ? true
|
||||
}:
|
||||
|
||||
let
|
||||
|
@ -75,10 +91,10 @@ stdenv.mkDerivation {
|
|||
fi
|
||||
'';
|
||||
|
||||
nativeBuildInputs = [ pkg-config m4 ];
|
||||
nativeBuildInputs = [ pkg-config m4 addOpenGLRunpath ];
|
||||
|
||||
buildInputs = [ jansson libXv libXrandr libXext libXxf86vm libvdpau nvidia_x11 gtk2 dbus ]
|
||||
++ lib.optionals withGtk3 [ gtk3 librsvg wrapGAppsHook ];
|
||||
++ lib.optionals withGtk3 [ gtk3 librsvg wrapGAppsHook ];
|
||||
|
||||
installFlags = [ "PREFIX=$(out)" ];
|
||||
|
||||
|
@ -106,6 +122,8 @@ stdenv.mkDerivation {
|
|||
postFixup = ''
|
||||
patchelf --set-rpath "$(patchelf --print-rpath $out/bin/$binaryName):$out/lib:${libXv}/lib" \
|
||||
$out/bin/$binaryName
|
||||
|
||||
addOpenGLRunpath $out/bin/$binaryName
|
||||
'';
|
||||
|
||||
passthru = {
|
||||
|
|
Loading…
Reference in a new issue