about summary refs log tree commit diff
diff options
context:
space:
mode:
authorRobert Scott <code@humanleg.org.uk>2023-04-11 22:53:17 +0100
committerRobert Scott <code@humanleg.org.uk>2023-04-12 00:25:57 +0100
commit0afc44be9a2b6d712f6a4e0f5381403cc8c10ffc (patch)
tree24c556e6596056e09eea762a824b4ee2fe249ebf
parenta2da3d62a6b843ad2f2ac6ff976a13a17cd7dbdd (diff)
ghostscript: 9.56.1 -> 10.01.1
-rw-r--r--pkgs/misc/ghostscript/default.nix49
1 files changed, 37 insertions, 12 deletions
diff --git a/pkgs/misc/ghostscript/default.nix b/pkgs/misc/ghostscript/default.nix
index 922941c55e8d9..65f19cfc6024c 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"
   ];