texlive[74599] Master: Upgrade gs10.04.0 -> gs10.05.0

commits+reinhardk at tug.org commits+reinhardk at tug.org
Thu Mar 13 02:14:15 CET 2025


Revision: 74599
          https://tug.org/svn/texlive?view=revision&revision=74599
Author:   reinhardk
Date:     2025-03-13 02:14:14 +0100 (Thu, 13 Mar 2025)
Log Message:
-----------
Upgrade gs10.04.0 -> gs10.05.0

Modified Paths:
--------------
    trunk/Master/tlpkg/tlgs/README.TEXLIVE
    trunk/Master/tlpkg/tlgs/Resource/Init/gs_init.ps
    trunk/Master/tlpkg/tlgs/Resource/Init/gs_pdfwr.ps
    trunk/Master/tlpkg/tlgs/Resource/Init/gs_setpd.ps
    trunk/Master/tlpkg/tlgs/Resource/Init/pdf_main.ps
    trunk/Master/tlpkg/tlgs/bin/gsdll64.dll
    trunk/Master/tlpkg/tlgs/bin/gswin64.exe
    trunk/Master/tlpkg/tlgs/bin/gswin64c.exe
    trunk/Master/tlpkg/tlgs/lib/PDFX_def.ps
    trunk/Master/tlpkg/tlgs/lib/zugferd.ps

Added Paths:
-----------
    trunk/Master/source/ghostscript-10.05.0.tar.xz

Removed Paths:
-------------
    trunk/Master/source/ghostscript-10.04.0.tar.xz

Deleted: trunk/Master/source/ghostscript-10.04.0.tar.xz
===================================================================
(Binary files differ)

Added: trunk/Master/source/ghostscript-10.05.0.tar.xz
===================================================================
(Binary files differ)

Index: trunk/Master/source/ghostscript-10.05.0.tar.xz
===================================================================
--- trunk/Master/source/ghostscript-10.05.0.tar.xz	2025-03-13 00:42:04 UTC (rev 74598)
+++ trunk/Master/source/ghostscript-10.05.0.tar.xz	2025-03-13 01:14:14 UTC (rev 74599)

Property changes on: trunk/Master/source/ghostscript-10.05.0.tar.xz
___________________________________________________________________
Added: svn:mime-type
## -0,0 +1 ##
+application/x-xz
\ No newline at end of property
Modified: trunk/Master/tlpkg/tlgs/README.TEXLIVE
===================================================================
--- trunk/Master/tlpkg/tlgs/README.TEXLIVE	2025-03-13 00:42:04 UTC (rev 74598)
+++ trunk/Master/tlpkg/tlgs/README.TEXLIVE	2025-03-13 01:14:14 UTC (rev 74599)
@@ -1,5 +1,5 @@
 
-This directory contains a subset of the Ghostscript 10.04.0 distribution
+This directory contains a subset of the Ghostscript 10.05.0 distribution
 for Windows.  The only purpose of this package is to support programs
 shipped with TeX Live.  It's not intended for general use. 
 

Modified: trunk/Master/tlpkg/tlgs/Resource/Init/gs_init.ps
===================================================================
--- trunk/Master/tlpkg/tlgs/Resource/Init/gs_init.ps	2025-03-13 00:42:04 UTC (rev 74598)
+++ trunk/Master/tlpkg/tlgs/Resource/Init/gs_init.ps	2025-03-13 01:14:14 UTC (rev 74599)
@@ -1,4 +1,4 @@
-% Copyright (C) 2001-2024 Artifex Software, Inc.
+% Copyright (C) 2001-2025 Artifex Software, Inc.
 % All Rights Reserved.
 %
 % This software is provided AS-IS with no warranty, either express or
@@ -34,7 +34,7 @@
 % Interpreter library version number
 % NOTE: the interpreter code requires that the first non-comment token
 % in this file be an integer, and that it match the compiled-in version!
-10040
+10050
 
 % Check the interpreter revision.
 dup revision ne
@@ -1589,6 +1589,8 @@
 % Special handling for device parameters. Must follow definition of 'type'
 % make -dPDFA equivalent to -dPDFA=1 (backwards compatible)
 currentdict /PDFA known { PDFA type /booleantype eq { /PDFA 1 def } if } if
+% make -dPDFX equivalent to -dPDFX=3 (backwards compatible)
+currentdict /PDFX known { PDFX type /booleantype eq { /PDFX 3 def } if } if
 
 % Construct a dictionary of all available devices.
 % These are (read-only) device prototypes that can't be

Modified: trunk/Master/tlpkg/tlgs/Resource/Init/gs_pdfwr.ps
===================================================================
--- trunk/Master/tlpkg/tlgs/Resource/Init/gs_pdfwr.ps	2025-03-13 00:42:04 UTC (rev 74598)
+++ trunk/Master/tlpkg/tlgs/Resource/Init/gs_pdfwr.ps	2025-03-13 01:14:14 UTC (rev 74599)
@@ -1,4 +1,4 @@
-% Copyright (C) 2001-2024 Artifex Software, Inc.
+% Copyright (C) 2001-2025 Artifex Software, Inc.
 % All Rights Reserved.
 %
 % This software is provided AS-IS with no warranty, either express or
@@ -588,7 +588,7 @@
     newpath -3 -3 moveto closepath stroke % Paints outside the device bbox.
     grestore
   } if
-  dup /PS eq systemdict /PDFX .knownget not { //false } if
+  dup /PS eq systemdict /PDFX .knownget not { //false }{0 eq {//false}{//true} ifelse} ifelse
              systemdict /PDFA .knownget not { //false }{0 eq {//false}{//true} ifelse} ifelse or and {
     % Execute it since PDF/X doesn't allow to embed it.
     pop

Modified: trunk/Master/tlpkg/tlgs/Resource/Init/gs_setpd.ps
===================================================================
--- trunk/Master/tlpkg/tlgs/Resource/Init/gs_setpd.ps	2025-03-13 00:42:04 UTC (rev 74598)
+++ trunk/Master/tlpkg/tlgs/Resource/Init/gs_setpd.ps	2025-03-13 01:14:14 UTC (rev 74599)
@@ -1,4 +1,4 @@
-% Copyright (C) 2001-2023 Artifex Software, Inc.
+% Copyright (C) 2001-2024 Artifex Software, Inc.
 % All Rights Reserved.
 %
 % This software is provided AS-IS with no warranty, either express or
@@ -190,6 +190,7 @@
 % Define all the parameters that should always be copied to the merged
 % dictionary.
 /.copiedkeys [
+  /SeparationColorNames
   /OutputDevice
   //.mergespecial { pop } forall
   .inputattrkeys aload pop

Modified: trunk/Master/tlpkg/tlgs/Resource/Init/pdf_main.ps
===================================================================
--- trunk/Master/tlpkg/tlgs/Resource/Init/pdf_main.ps	2025-03-13 00:42:04 UTC (rev 74598)
+++ trunk/Master/tlpkg/tlgs/Resource/Init/pdf_main.ps	2025-03-13 01:14:14 UTC (rev 74599)
@@ -243,10 +243,19 @@
       }
       {
         270 rotate
-        dup neg 0 translate                     % move 0,0 to bottom right of media to account for rotation
+        dup neg 0 translate                     % move 0,0 to top right of media to account for rotation
         exch                                    % swap media width/height for scaling calculation
       } ifelse
-    }if
+    }{
+      % If we are not rotating the content to better fit the media, then the only existing Rotate
+      % value we need to care about is a 180 rotation, because anything else will cause the content
+      % not to fit the media.
+      7 index dup /Rotate known {/Rotate get}{pop 0}ifelse
+      180 eq {
+        180 rotate
+        2 copy neg exch neg exch translate      % move 0,0 to top right of media to account for rotation
+      } if
+    }ifelse
 
     % Now use the box and media values to calculate the required x/y scale factors
     4 copy                              % Stack - box boxwidth boxheight mediawidth mediaheight boxwidth boxheight mediawidth mediaheight
@@ -1124,64 +1133,74 @@
     % Appletalk PAP sends short strings with %! header expecting a response.
     % 'gv' swallows the %!PS line, then sends DSC comments beginning with %%
     % and also waits for a response. The following avoids those hangs.
-    dup 2 string .peekstring pop dup (%!) eq exch (%%) eq or {
-      cvx .runps
-    } {
-      dup 1023 string .peekstring pop
-      % "1024 string" exceeds current %stdin buffer
-      % Valid PDF file cannot be smaller than 400 bytes.
-      (%PDF-) search {
-        3 1 roll pop pop
-        dup (%!PS) search not {
-          length 0 ne {
-            1 index exch readstring pop pop
-            (%stderr) (w) file dup
-            (   **** Warning: File has some garbage before %PDF- .\n)
-            writestring flushfile
-            PDFSTOPONWARNING {
-              /run cvx /unregistered signalerror
-            } if
-          } {
-            pop
-          } ifelse
-          dup (%stdin) (r) file eq {
-            % Copy PDF from stdin to temporary file then run it.
-            //null (w+) /.tempfile .systemvar exec exch 3 1 roll
-            % stack: tempname stdin tempfile
-            64000 string
-            {
-              % stack: tempname stdin tempfile string
-              2 index 1 index readstring
-              exch 3 index exch writestring
-              not { exit } if
-            }
-            loop
-            pop exch closefile
-            % stack: tempname tempfile
-            dup 0 setfileposition
-            dup
-              pdfavailable {
-                runpdf
-              }{
-                closefile
-                (%stderr) (w) file (   **** ERROR: No PDF interpreter available, unable to process PDF files as input.\n)writestring
-              } ifelse
-            closefile deletefile
-          } {
-              pdfavailable {
-                runpdf
-              }{
-                closefile
-                (%stderr) (w) file (   **** ERROR: No PDF interpreter available, unable to process PDF files as input.\n)writestring
-              } ifelse
-          } ifelse
+    %
+    % This section commented out. It causes problems with (poorly created) PDF files which have
+    % extraneous data prior to the '%PDF-' string which are incorrectly recognised as PostScript
+    % programs. I really don't think we need care about AppleTalk any more and testing with 'gv'
+    % shows no problems with removing this early test, and simply falling into the 'not a PDF file'
+    % case below.
+    %
+    % I've preserved the code in comments for the next release (10.05.0), in case it does prove to be essential.
+    %
+    %    dup 2 string .peekstring pop dup (%!) eq exch (%%) eq or {
+    %      cvx .runps
+    %    } {
+
+    dup 1023 string .peekstring pop
+    % "1024 string" exceeds current %stdin buffer
+    % Valid PDF file cannot be smaller than 400 bytes.
+    (%PDF-) search {
+      3 1 roll pop pop
+      dup (%!PS) search not {
+        length 0 ne {
+          1 index exch readstring pop pop
+          (%stderr) (w) file dup
+          (   **** Warning: File has some garbage before %PDF- .\n)
+          writestring flushfile
+          PDFSTOPONWARNING {
+            /run cvx /unregistered signalerror
+          } if
         } {
-          pop pop pop pop cvx .runps % (%!PS) found first
+          pop
         } ifelse
+        dup (%stdin) (r) file eq {
+          % Copy PDF from stdin to temporary file then run it.
+          //null (w+) /.tempfile .systemvar exec exch 3 1 roll
+          % stack: tempname stdin tempfile
+          64000 string
+          {
+            % stack: tempname stdin tempfile string
+            2 index 1 index readstring
+            exch 3 index exch writestring
+            not { exit } if
+          }
+          loop
+          pop exch closefile
+          % stack: tempname tempfile
+          dup 0 setfileposition
+          dup
+            pdfavailable {
+              runpdf
+            }{
+              closefile
+              (%stderr) (w) file (   **** ERROR: No PDF interpreter available, unable to process PDF files as input.\n)writestring
+            } ifelse
+          closefile deletefile
+        } {
+            pdfavailable {
+              runpdf
+            }{
+              closefile
+              (%stderr) (w) file (   **** ERROR: No PDF interpreter available, unable to process PDF files as input.\n)writestring
+            } ifelse
+        } ifelse
       } {
-        pop cvx .runps % (%PDF-) not found
+        pop pop pop pop cvx .runps % (%!PS) found first
       } ifelse
+    } {
+      pop cvx .runps % (%PDF-) not found
     } ifelse
+    %    } ifelse
   } {
     closefile % file was empty
   } ifelse

Modified: trunk/Master/tlpkg/tlgs/bin/gsdll64.dll
===================================================================
(Binary files differ)

Modified: trunk/Master/tlpkg/tlgs/bin/gswin64.exe
===================================================================
(Binary files differ)

Modified: trunk/Master/tlpkg/tlgs/bin/gswin64c.exe
===================================================================
(Binary files differ)

Modified: trunk/Master/tlpkg/tlgs/lib/PDFX_def.ps
===================================================================
--- trunk/Master/tlpkg/tlgs/lib/PDFX_def.ps	2025-03-13 00:42:04 UTC (rev 74598)
+++ trunk/Master/tlpkg/tlgs/lib/PDFX_def.ps	2025-03-13 01:14:14 UTC (rev 74599)
@@ -20,12 +20,28 @@
 
 % Define entries in the document Info dictionary :
 %
-[ /GTS_PDFXVersion (PDF/X-3:2002) % Must be so (the standard requires).
-  /Title (Title)                  % Customize.
-  /Trapped /False                 % Must be so (Ghostscript doesn't provide other).
-/DOCINFO pdfmark
+systemdict /PDFX known {systemdict /PDFX get}{3} ifelse
 
+dup 1 eq {
+  [ /GTS_PDFXVersion (PDF/X-1a:2001) % Must be so (the standard requires).
+    /Title (Title)                  % Customize.
+    /Trapped /False                 % Must be so (Ghostscript doesn't provide other).
+  /DOCINFO pdfmark
+} if
+dup 3 eq {
+  [ /GTS_PDFXVersion (PDF/X-3:2002) % Must be so (the standard requires).
+    /Title (Title)                  % Customize.
+    /Trapped /False                 % Must be so (Ghostscript doesn't provide other).
+  /DOCINFO pdfmark
+} if
+4 eq {
+  [ /GTS_PDFXVersion (PDF/X-4)    % Must be so (the standard requires).
+    /Title (Title)                  % Customize.
+    /Trapped /False                 % Must be so (Ghostscript doesn't provide other).
+  /DOCINFO pdfmark
+} if
 
+
 /ICCProfile (ISO Coated sb.icc) def  % Customize or remove.
 
 % Define an ICC profile in the output, if the user specified one.
@@ -48,8 +64,11 @@
       pop /N 1 false
     }{
       dup /RGB eq {
-        (RGB is not a valid ColorConversionStrategy for PDF/X output)=
-        /ColorConversionStrategycvx /rangecheck signalerror
+        systemdict /PDFX known {systemdict /PDFX get}{3} ifelse
+        4 lt {
+          (RGB is not a valid ColorConversionStrategy for PDF/X output)=
+          /ColorConversionStrategycvx /rangecheck signalerror
+        } if
       }{
         /CMYK eq {
           /N 4 false
@@ -70,8 +89,11 @@
       pop /N 1
     }{
       dup /DeviceRGB eq {
-        (RGB is not a valid ProcessColorModel for PDF/X output)=
-        /ColorConversionStrategycvx /rangecheck signalerror
+        systemdict /PDFX known {systemdict /PDFX get}{3} ifelse
+        4 lt {
+          (RGB is not a valid ProcessColorModel for PDF/X output)=
+          /ColorConversionStrategycvx /rangecheck signalerror
+        } if
       }{
         dup /DeviceCMYK eq {
           pop /N 4
@@ -91,14 +113,14 @@
 
 [/_objdef {OutputIntent_PDFX} /type /dict /OBJ pdfmark
 [{OutputIntent_PDFX} <<
-  /Type /OutputIntent              % Must be so (the standard requires).
-  /S /GTS_PDFX                     % Must be so (the standard requires).
-  /OutputCondition (Commercial and specialty printing) % Customize
-  /Info (none)                     % Customize
-  /OutputConditionIdentifier (CGATS TR001)      % Customize
-  /RegistryName (http://www.color.org)   % Must be so (the standard requires).
+  /Type /OutputIntent                                   % Must be so (the standard requires).
+  /S /GTS_PDFX                                          % Must be so (the standard requires).
+  /OutputCondition (Commercial and specialty printing)  % Customize
+  /Info (none)                                          % Customize
+  /OutputConditionIdentifier (CGATS TR001)              % Customize
+  /RegistryName (http://www.color.org)                  % Must be so (the standard requires).
   currentdict /ICCProfile known {
-    /DestOutputProfile {icc_PDFX}  % Must be so (see above).
+    /DestOutputProfile {icc_PDFX}                       % Must be so (see above).
   } if
 >> /PUT pdfmark
 [{Catalog} <</OutputIntents [ {OutputIntent_PDFX} ]>> /PUT pdfmark

Modified: trunk/Master/tlpkg/tlgs/lib/zugferd.ps
===================================================================
--- trunk/Master/tlpkg/tlgs/lib/zugferd.ps	2025-03-13 00:42:04 UTC (rev 74598)
+++ trunk/Master/tlpkg/tlgs/lib/zugferd.ps	2025-03-13 01:14:14 UTC (rev 74599)
@@ -1,6 +1,6 @@
 %!PS
 
-% Copyright (C) 2001-2023 Artifex Software, Inc.
+% Copyright (C) 2001-2024 Artifex Software, Inc.
 % All Rights Reserved.
 %
 % This software is provided AS-IS with no warranty, either express or
@@ -490,7 +490,14 @@
     [ {AFArray} {FSDict} /APPEND pdfmark
 
     % Step 5 Add an entry in the Catalog dictionary containing the AF array
-    [ {Catalog} << /AF {AFArray} >> /PUT pdfmark
+    % Since Ghostscript 10.04.0 this is no longer required, providing the output file is
+    % PDF/A-3 or higher. The PDF/A-3 tech note 0010 (p28) clarifies that the /AF in the Catalog
+    % is mandatory and GS 10.04.0 will emit one itself.
+    %
+    % This line retained for historical reference, and as an example for cases where the output
+    % is not PDF/A-3
+    %
+    %    [ {Catalog} << /AF {AFArray} >> /PUT pdfmark
 
     % Step 6 use the EMBED pdfmark to add the XML file and FS dictionary to the PDF name tree
     [ /Name ZUGFeRDDocumentFileName /FS {FSDict} /EMBED pdfmark



More information about the tex-live-commits mailing list.