about summary refs log tree commit diff
path: root/pkgs/applications/editors/poke
diff options
context:
space:
mode:
authorKira Bruneau <kira.bruneau@pm.me>2022-07-26 08:22:32 -0400
committerKira Bruneau <kira.bruneau@pm.me>2022-07-26 10:38:44 -0400
commitc8438227293eb0f2c0f1bf8ea48198620dc3a0d5 (patch)
tree71e0cda209505849fc3d770a30f1f7ed392eb843 /pkgs/applications/editors/poke
parentc027d1a8f254a981a312575e650e2af9d8ad3885 (diff)
poke: only wrap poke-gui with TCLLIBPATH
Diffstat (limited to 'pkgs/applications/editors/poke')
-rw-r--r--pkgs/applications/editors/poke/default.nix12
1 files changed, 10 insertions, 2 deletions
diff --git a/pkgs/applications/editors/poke/default.nix b/pkgs/applications/editors/poke/default.nix
index d8f2dcf1ffcdd..1bfd690dd24fc 100644
--- a/pkgs/applications/editors/poke/default.nix
+++ b/pkgs/applications/editors/poke/default.nix
@@ -5,10 +5,9 @@
 , help2man
 , pkg-config
 , texinfo
-, makeWrapper
 , boehmgc
 , readline
-, guiSupport ? false, tcl, tcllib, tk
+, guiSupport ? false, makeWrapper, tcl, tcllib, tk
 , miSupport ? true, json_c
 , nbdSupport ? !stdenv.isDarwin, libnbd
 , textStylingSupport ? true
@@ -75,6 +74,15 @@ in stdenv.mkDerivation rec {
     moveToOutput share/vim "$out"
   '';
 
+  postFixup = lib.optionalString guiSupport ''
+    wrapProgram "$out/bin/poke-gui" \
+      --prefix TCLLIBPATH ' ' "$TCLLIBPATH"
+
+    # Prevent tclPackageHook from auto-wrapping all binaries, we only
+    # need to wrap poke-gui
+    unset TCLLIBPATH
+  '';
+
   passthru = {
     updateScript = writeScript "update-poke" ''
       #!/usr/bin/env nix-shell