summaryrefslogtreecommitdiffstats
path: root/pkgs/development/tools/electron
diff options
context:
space:
mode:
authorJörg Thalheim <Mic92@users.noreply.github.com>2019-06-25 07:59:31 +0100
committerGitHub <noreply@github.com>2019-06-25 07:59:31 +0100
commitb552d72a9a480e9bee81b32f91dfae207188f008 (patch)
tree4e06f17ef67883e55e53b81c3a48ffc99952843a /pkgs/development/tools/electron
parente3afc85cbaf57637f829712f338aa12eff2f253a (diff)
parent205296f55a45b1dabb5e91568feccffd1fedee3f (diff)
Fix electron crash when using file chooser dialog (#55057)
Fix electron crash when using file chooser dialog
Diffstat (limited to 'pkgs/development/tools/electron')
-rw-r--r--pkgs/development/tools/electron/default.nix15
1 files changed, 12 insertions, 3 deletions
diff --git a/pkgs/development/tools/electron/default.nix b/pkgs/development/tools/electron/default.nix
index b6f7d0b072b2..fca9bc866fac 100644
--- a/pkgs/development/tools/electron/default.nix
+++ b/pkgs/development/tools/electron/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, libXScrnSaver, makeWrapper, fetchurl, unzip, atomEnv, libuuid, at-spi2-atk }:
+{ stdenv, libXScrnSaver, makeWrapper, fetchurl, wrapGAppsHook, gtk3, unzip, atomEnv, libuuid, at-spi2-atk }:
let
version = "4.1.5";
@@ -35,7 +35,15 @@ let
};
}.${stdenv.hostPlatform.system} or throwSystem;
- buildInputs = [ unzip makeWrapper ];
+ buildInputs = [ gtk3 ];
+
+ nativeBuildInputs = [
+ unzip
+ makeWrapper
+ wrapGAppsHook
+ ];
+
+ dontWrapGApps = true; # electron is in lib, we need to wrap it manually
buildCommand = ''
mkdir -p $out/lib/electron $out/bin
@@ -50,7 +58,8 @@ let
$out/lib/electron/electron
wrapProgram $out/lib/electron/electron \
- --prefix LD_PRELOAD : ${stdenv.lib.makeLibraryPath [ libXScrnSaver ]}/libXss.so.1
+ --prefix LD_PRELOAD : ${stdenv.lib.makeLibraryPath [ libXScrnSaver ]}/libXss.so.1 \
+ "''${gappsWrapperArgs[@]}"
'';
};