From 4f9e46af5d2371109d51863c8d772c4964dc401f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Thalheim?= Date: Wed, 16 Jan 2019 20:38:42 +0000 Subject: [PATCH] racket: fix drracket crashes on file dialogs --- pkgs/development/interpreters/racket/default.nix | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) diff --git a/pkgs/development/interpreters/racket/default.nix b/pkgs/development/interpreters/racket/default.nix index ba66404062be..15536c6370a3 100644 --- a/pkgs/development/interpreters/racket/default.nix +++ b/pkgs/development/interpreters/racket/default.nix @@ -10,6 +10,7 @@ , disableDocs ? false , CoreFoundation , gsettings-desktop-schemas +, wrapGAppsHook }: let @@ -59,7 +60,9 @@ stdenv.mkDerivation rec { (stdenv.lib.optionalString stdenv.isDarwin "-framework CoreFoundation") ]; - buildInputs = [ fontconfig libffi libtool makeWrapper sqlite gsettings-desktop-schemas gtk3 ] + nativeBuildInputs = [ wrapGAppsHook ]; + + buildInputs = [ fontconfig libffi libtool sqlite gsettings-desktop-schemas gtk3 ] ++ stdenv.lib.optionals stdenv.isDarwin [ libiconv CoreFoundation ]; preConfigure = '' @@ -69,6 +72,8 @@ stdenv.mkDerivation rec { done mkdir src/build cd src/build + + gappsWrapperArgs+=("--prefix" "LD_LIBRARY_PATH" ":" $LD_LIBRARY_PATH) ''; shared = if stdenv.isDarwin then "dylib" else "shared"; @@ -80,13 +85,6 @@ stdenv.mkDerivation rec { enableParallelBuilding = false; - postInstall = '' - for p in $(ls $out/bin/) ; do - wrapProgram $out/bin/$p \ - --prefix LD_LIBRARY_PATH ":" "${LD_LIBRARY_PATH}" \ - --prefix XDG_DATA_DIRS ":" "$GSETTINGS_SCHEMAS_PATH"; - done - ''; meta = with stdenv.lib; { description = "A programmable programming language";