From 6e9b71f0e197a8e15a7b70eab6060147fa4ecaca Mon Sep 17 00:00:00 2001 From: Jonathan Ringer Date: Fri, 13 Nov 2020 10:19:37 -0800 Subject: [PATCH] zathura-pdf-mupdf: 0.3.5 -> 0.3.6, fix linking --- .../misc/zathura/pdf-mupdf/default.nix | 40 +++++++++++++------ 1 file changed, 28 insertions(+), 12 deletions(-) diff --git a/pkgs/applications/misc/zathura/pdf-mupdf/default.nix b/pkgs/applications/misc/zathura/pdf-mupdf/default.nix index 32a2ec420110..97f36f828472 100644 --- a/pkgs/applications/misc/zathura/pdf-mupdf/default.nix +++ b/pkgs/applications/misc/zathura/pdf-mupdf/default.nix @@ -1,29 +1,45 @@ { stdenv, lib, meson, ninja, fetchurl, fetchpatch -, pkgconfig, zathura_core, cairo , gtk-mac-integration, girara, mupdf }: +, cairo +, girara +, gtk-mac-integration +, gumbo +, jbig2dec +, libjpeg +, mupdf +, openjpeg_2 +, pkgconfig +, zathura_core +}: stdenv.mkDerivation rec { - version = "0.3.5"; + version = "0.3.6"; pname = "zathura-pdf-mupdf"; src = fetchurl { url = "https://pwmt.org/projects/${pname}/download/${pname}-${version}.tar.xz"; - sha256 = "1pjwsb7zwclxsvz229fl7y2saf1pv3ifwv3ay8viqxgrp9x3z9hq"; + sha256 = "1r3v37k9fl2rxipvacgxr36llywvy7n20a25h3ajlyk70697sa66"; }; - patches = [ - # compatibility with MuPDF 1.17 - (fetchpatch { - url = "https://git.pwmt.org/pwmt/zathura-pdf-mupdf/-/commit/c7f341addb76d5e6fd8c24c666d8fe97c451a4cb.patch"; - sha256 = "12rikx2j7dpngfma9x4i504w58a8xx3rc0gmyz183v19hn54c075"; - }) - ]; - nativeBuildInputs = [ meson ninja pkgconfig ]; buildInputs = [ - zathura_core girara mupdf cairo + cairo + girara + gumbo + jbig2dec + libjpeg + mupdf + openjpeg_2 + zathura_core ] ++ lib.optional stdenv.isDarwin gtk-mac-integration; + mesonFlags = [ + "-Dlink-external=true" + ]; + + # avoid: undefined symbol: gumbo_destroy_output + NIX_LDFLAGS = [ "-lgumbo" ]; + PKG_CONFIG_ZATHURA_PLUGINDIR= "lib/zathura"; meta = with lib; {