From 1f09eb4d9e8d52d56ce3a77e14143af3efc4bdbb Mon Sep 17 00:00:00 2001 From: Kiskae Date: Fri, 2 Feb 2024 20:40:17 +0100 Subject: [PATCH] electron_*-bin: fix libGL --- pkgs/development/tools/electron/binary/generic.nix | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/pkgs/development/tools/electron/binary/generic.nix b/pkgs/development/tools/electron/binary/generic.nix index 8f726b410000..daa0c81d2e05 100644 --- a/pkgs/development/tools/electron/binary/generic.nix +++ b/pkgs/development/tools/electron/binary/generic.nix @@ -12,7 +12,7 @@ , mesa , libxkbcommon , libxshmfence -, libglvnd +, libGL , alsa-lib , cairo , cups @@ -102,7 +102,7 @@ let ++ lib.optionals (lib.versionOlder version "10.0.0") [ libXScrnSaver ] ++ lib.optionals (lib.versionAtLeast version "11.0.0") [ libxkbcommon ] ++ lib.optionals (lib.versionAtLeast version "12.0.0") [ libxshmfence ] - ++ lib.optionals (lib.versionAtLeast version "17.0.0") [ libglvnd ] + ++ lib.optionals (lib.versionAtLeast version "17.0.0") [ libGL ] ); linux = { @@ -130,6 +130,11 @@ let --set-rpath "${electronLibPath}:$out/libexec/electron" \ $out/libexec/electron/.electron-wrapped \ ${lib.optionalString (lib.versionAtLeast version "15.0.0") "$out/libexec/electron/.chrome_crashpad_handler-wrapped" } + + # patch libANGLE + patchelf \ + --set-rpath "${lib.makeLibraryPath [ libGL pciutils ]}" \ + $out/libexec/electron/lib*GL* ''; };