mesa: fix the default DRI driver dir to /run/opegl-driver{,-32}

This commit is contained in:
Vladimír Čunát 2013-09-11 11:36:15 +02:00
parent d55fb56690
commit 2dc0f91806

View File

@ -24,6 +24,7 @@ else
let let
version = "9.1.6"; version = "9.1.6";
# this is the default search path for DRI drivers (note: X server introduces an overriding env var)
driverLink = "/run/opengl-driver" + stdenv.lib.optionalString stdenv.isi686 "-32"; driverLink = "/run/opengl-driver" + stdenv.lib.optionalString stdenv.isi686 "-32";
in in
stdenv.mkDerivation { stdenv.mkDerivation {
@ -134,6 +135,8 @@ stdenv.mkDerivation {
patchelf --set-rpath "$(patchelf --print-rpath $lib):$drivers/lib" "$lib" patchelf --set-rpath "$(patchelf --print-rpath $lib):$drivers/lib" "$lib"
fi fi
done done
'' + /* set the default search path for DRI drivers; used e.g. by X server */ ''
substituteInPlace "$out/lib/pkgconfig/dri.pc" --replace '$(drivers)' "${driverLink}"
''; '';
#ToDo: @vcunat isn't sure if drirc will be found when in $out/etc/, but it doesn't seem important ATM #ToDo: @vcunat isn't sure if drirc will be found when in $out/etc/, but it doesn't seem important ATM