about summary refs log tree commit diff
path: root/pkgs/applications/misc/zathura
diff options
context:
space:
mode:
authorDmitry Kalinkin <dmitry.kalinkin@gmail.com>2018-12-10 09:11:55 -0500
committerGitHub <noreply@github.com>2018-12-10 09:11:55 -0500
commit6fb67ca241c13d5e17118bd37bc1b9bb37e7d9d5 (patch)
tree257c0bb7ccce201af2e0c72f1e5a1701bd8f5b84 /pkgs/applications/misc/zathura
parented46fe4f04bda1aecea23808b525baf29908f316 (diff)
parent7bf3f0911fc29e0e85b47e0960a569dc75a0f562 (diff)
Merge pull request #44909 from mnacamura/zathura
zathura: keep wrapper's WM_CLASS consistent with unwrapped binary
Diffstat (limited to 'pkgs/applications/misc/zathura')
-rw-r--r--pkgs/applications/misc/zathura/core/default.nix11
-rw-r--r--pkgs/applications/misc/zathura/wrapper.nix8
2 files changed, 9 insertions, 10 deletions
diff --git a/pkgs/applications/misc/zathura/core/default.nix b/pkgs/applications/misc/zathura/core/default.nix
index 56701cffb8cff..4cf05a21636ae 100644
--- a/pkgs/applications/misc/zathura/core/default.nix
+++ b/pkgs/applications/misc/zathura/core/default.nix
@@ -1,7 +1,7 @@
 { stdenv, fetchurl, meson, ninja, makeWrapper, pkgconfig
 , appstream-glib, desktop-file-utils, python3
 , gtk, girara, gettext, libxml2
-, file, sqlite, glib, texlive, libintl, libseccomp
+, sqlite, glib, texlive, libintl, libseccomp
 , gtk-mac-integration, synctexSupport ? true
 }:
 
@@ -18,22 +18,19 @@ stdenv.mkDerivation rec {
     sha256 = "1znr3psqda06xklzj8mn452w908llapcg1rj468jwpg0wzv6pxfn";
   };
 
+  outputs = [ "bin" "man" "dev" "out" ];
+
   nativeBuildInputs = [
     meson ninja pkgconfig appstream-glib desktop-file-utils python3.pkgs.sphinx
     gettext makeWrapper libxml2
   ];
 
   buildInputs = [
-    file gtk girara libintl libseccomp
+    gtk girara libintl libseccomp
     sqlite glib
   ] ++ optional synctexSupport texlive.bin.core
     ++ optional stdenv.isDarwin [ gtk-mac-integration ];
 
-  postInstall = ''
-    wrapProgram "$out/bin/zathura" \
-      --prefix PATH ":" "${makeBinPath [ file ]}"
-  '';
-
   meta = {
     homepage = https://pwmt.org/projects/zathura/;
     description = "A core component for zathura PDF viewer";
diff --git a/pkgs/applications/misc/zathura/wrapper.nix b/pkgs/applications/misc/zathura/wrapper.nix
index 64f617782f2d6..b81d12947e41d 100644
--- a/pkgs/applications/misc/zathura/wrapper.nix
+++ b/pkgs/applications/misc/zathura/wrapper.nix
@@ -1,4 +1,4 @@
-{ symlinkJoin, lib, makeWrapper, zathura_core, plugins ? [] }:
+{ symlinkJoin, lib, makeWrapper, zathura_core, file, plugins ? [] }:
 
 let
   pluginsPath = lib.makeSearchPath "lib/zathura" plugins;
@@ -6,12 +6,14 @@ let
 in symlinkJoin {
   name = "zathura-with-plugins-${zathura_core.version}";
 
-  paths = [ zathura_core ];
+  paths = with zathura_core; [ man dev out ];
 
   buildInputs = [ makeWrapper ];
 
   postBuild = ''
-    wrapProgram $out/bin/zathura --add-flags --plugins-dir=${pluginsPath}
+    makeWrapper ${zathura_core.bin}/bin/zathura $out/bin/zathura \
+      --prefix PATH ":" "${lib.makeBinPath [ file ]}" \
+      --add-flags --plugins-dir=${pluginsPath}
   '';
 
   meta = with lib; {