diff --git a/pkgs/misc/ghostscript/default.nix b/pkgs/misc/ghostscript/default.nix index 922941c55e8d..65f19cfc6024 100644 --- a/pkgs/misc/ghostscript/default.nix +++ b/pkgs/misc/ghostscript/default.nix @@ -1,8 +1,31 @@ -{ config, stdenv, lib, fetchurl, pkg-config, zlib, expat, openssl, autoconf -, libjpeg, libpng, libtiff, freetype, fontconfig, libpaper, jbig2dec -, libiconv, ijs, lcms2, callPackage, bash, buildPackages, openjpeg -, cupsSupport ? config.ghostscript.cups or (!stdenv.isDarwin), cups -, x11Support ? cupsSupport, xorg # with CUPS, X11 only adds very little +{ config +, stdenv +, lib +, fetchurl +, pkg-config +, zlib +, expat +, openssl +, autoconf +, libjpeg +, libpng +, libtiff +, freetype +, fontconfig +, libpaper +, jbig2dec +, libiconv +, ijs +, lcms2 +, callPackage +, bash +, buildPackages +, openjpeg +, cupsSupport ? config.ghostscript.cups or (!stdenv.isDarwin) +, cups +, x11Support ? cupsSupport +, xorg # with CUPS, X11 only adds very little +, dynamicDrivers ? true }: let @@ -30,11 +53,11 @@ let in stdenv.mkDerivation rec { pname = "ghostscript${lib.optionalString (x11Support) "-with-X"}"; - version = "9.56.1"; + version = "10.01.1"; src = fetchurl { - url = "https://github.com/ArtifexSoftware/ghostpdl-downloads/releases/download/gs9${lib.versions.minor version}${lib.versions.patch version}/ghostscript-${version}.tar.xz"; - sha512 = "22ysgdprh960rxmxyk2fy2my47cdrhfhbrwar1955hvad54iw79l916drp92wh3qzbxw6z40i70wk00vz8bn2ryig7qgpc1q01m2npy"; + url = "https://github.com/ArtifexSoftware/ghostpdl-downloads/releases/download/gs${lib.replaceStrings ["."] [""] version}/ghostscript-${version}.tar.xz"; + hash = "sha512-2US+norvaNEXbWTEDbb6htVdDJ4wBH8hR8AoBqthz+msLLANTlshj/PFHMbtR87/4brE3Z1MwXYLeXTzDGwnNQ=="; }; patches = [ @@ -77,11 +100,13 @@ stdenv.mkDerivation rec { configureFlags = [ "--with-system-libtiff" - "--enable-dynamic" "--without-tesseract" - ] - ++ lib.optional x11Support "--with-x" - ++ lib.optionals cupsSupport [ + ] ++ lib.optionals dynamicDrivers [ + "--enable-dynamic" + "--disable-hidden-visibility" + ] ++ lib.optional x11Support [ + "--with-x" + ] ++ lib.optionals cupsSupport [ "--enable-cups" ];