Unverified Commit caa1f0b8 authored by Lily Foster's avatar Lily Foster
Browse files

mupdf: only build and install shared libraries

parent 4c838ddf
Loading
Loading
Loading
Loading
+2 −5
Original line number Diff line number Diff line
{ stdenv
, lib
, fetchurl
, fetchpatch
, fetchFromGitHub
, copyDesktopItems
, makeDesktopItem
@@ -70,11 +69,9 @@ stdenv.mkDerivation rec {
    substituteInPlace Makerules --replace "(shell pkg-config" "(shell $PKG_CONFIG"
  '';

  # Use shared libraries to decrease size
  buildFlags = [ "shared" ];

  makeFlags = [
    "prefix=$(out)"
    "shared=yes"
    "USE_SYSTEM_LIBS=yes"
    "PKG_CONFIG=${buildPackages.pkg-config}/bin/${buildPackages.pkg-config.targetPrefix}pkg-config"
  ] ++ lib.optionals (!enableX11) [ "HAVE_X11=no" ]
@@ -136,7 +133,7 @@ stdenv.mkDerivation rec {
    Name: mupdf
    Description: Library for rendering PDF documents
    Version: ${version}
    Libs: -L$out/lib -lmupdf -lmupdf-third
    Libs: -L$out/lib -lmupdf
    Cflags: -I$dev/include
    EOF