texlive[65980] trunk: hyperxmp (20feb23)

commits+karl at tug.org commits+karl at tug.org
Mon Feb 20 22:00:05 CET 2023


Revision: 65980
          http://tug.org/svn/texlive?view=revision&revision=65980
Author:   karl
Date:     2023-02-20 22:00:04 +0100 (Mon, 20 Feb 2023)
Log Message:
-----------
hyperxmp (20feb23)

Modified Paths:
--------------
    trunk/Build/source/texk/texlive/linked_scripts/hyperxmp/hyperxmp-add-bytecount.pl
    trunk/Build/source/texk/texlive/linked_scripts/texlive/fmtutil.pl
    trunk/Build/source/texk/texlive/linked_scripts/texlive/tlmgr.pl
    trunk/Build/source/texk/texlive/linked_scripts/texlive/updmap.pl
    trunk/Build/source/texk/texlive/linked_scripts/tlshell/tlshell.tcl
    trunk/Master/texmf-dist/doc/latex/hyperxmp/README
    trunk/Master/texmf-dist/doc/latex/hyperxmp/hyperxmp.pdf
    trunk/Master/texmf-dist/doc/man/man1/hyperxmp-add-bytecount.man1.pdf
    trunk/Master/texmf-dist/scripts/hyperxmp/hyperxmp-add-bytecount.pl
    trunk/Master/texmf-dist/source/latex/hyperxmp/einstein-xmp.tex
    trunk/Master/texmf-dist/source/latex/hyperxmp/hyperxmp-stds.tex
    trunk/Master/texmf-dist/source/latex/hyperxmp/hyperxmp.dtx
    trunk/Master/texmf-dist/source/latex/hyperxmp/hyperxmp.ins
    trunk/Master/texmf-dist/tex/latex/hyperxmp/hyperxmp.sty
    trunk/Master/tlpkg/libexec/ctan2tds

Modified: trunk/Build/source/texk/texlive/linked_scripts/hyperxmp/hyperxmp-add-bytecount.pl
===================================================================
--- trunk/Build/source/texk/texlive/linked_scripts/hyperxmp/hyperxmp-add-bytecount.pl	2023-02-20 20:59:19 UTC (rev 65979)
+++ trunk/Build/source/texk/texlive/linked_scripts/hyperxmp/hyperxmp-add-bytecount.pl	2023-02-20 21:00:04 UTC (rev 65980)
@@ -8,7 +8,7 @@
 # hyperxmp-add-bytecount                                               #
 #   Adds/updates byteCount specification in XMP packet in pdf file(s)  #
 #   made by hyperxmp, with byteCount = file size.                      #
-# Copyright (C) 2020 John Collins <jcc8 at psu.edu>                       #
+# Copyright (C) 2020-2022 John Collins <jcc8 at psu.edu>                  #
 #    and Scott Pakin, <scott+hyxmp at pakin.org>                          #
 #                                                                      #
 # This program may be distributed and/or modified under the conditions #

Modified: trunk/Build/source/texk/texlive/linked_scripts/texlive/fmtutil.pl
===================================================================
--- trunk/Build/source/texk/texlive/linked_scripts/texlive/fmtutil.pl	2023-02-20 20:59:19 UTC (rev 65979)
+++ trunk/Build/source/texk/texlive/linked_scripts/texlive/fmtutil.pl	2023-02-20 21:00:04 UTC (rev 65980)
@@ -1,5 +1,5 @@
 #!/usr/bin/env perl
-# $Id: fmtutil.pl 65770 2023-02-09 21:26:50Z karl $
+# $Id: fmtutil.pl 65932 2023-02-19 20:49:48Z siepo $
 # fmtutil - utility to maintain format files.
 # (Maintained in TeX Live:Master/texmf-dist/scripts/texlive.)
 # 
@@ -24,11 +24,11 @@
   TeX::Update->import();
 }
 
-my $svnid = '$Id: fmtutil.pl 65770 2023-02-09 21:26:50Z karl $';
-my $lastchdate = '$Date: 2023-02-09 22:26:50 +0100 (Thu, 09 Feb 2023) $';
+my $svnid = '$Id: fmtutil.pl 65932 2023-02-19 20:49:48Z siepo $';
+my $lastchdate = '$Date: 2023-02-19 21:49:48 +0100 (Sun, 19 Feb 2023) $';
 $lastchdate =~ s/^\$Date:\s*//;
 $lastchdate =~ s/ \(.*$//;
-my $svnrev = '$Revision: 65770 $';
+my $svnrev = '$Revision: 65932 $';
 $svnrev =~ s/^\$Revision:\s*//;
 $svnrev =~ s/\s*\$$//;
 my $version = "r$svnrev ($lastchdate)";
@@ -42,9 +42,9 @@
 # don't import anything automatically, this requires us to explicitly
 # call functions with TeXLive::TLUtils prefix, and makes it easier to
 # find and if necessary remove references to TLUtils
-use TeXLive::TLUtils qw();
+use TeXLive::TLUtils qw(wndws);
 
-require TeXLive::TLWinGoo if TeXLive::TLUtils::win32;
+require TeXLive::TLWinGoo if wndws();
 
 # numerical constants
 my $FMT_NOTSELECTED = 0;
@@ -53,8 +53,8 @@
 my $FMT_SUCCESS     = 3;
 my $FMT_NOTAVAIL    = 4;
 
-my $nul = (win32() ? 'nul' : '/dev/null');
-my $sep = (win32() ? ';' : ':');
+my $nul = (wndws() ? 'nul' : '/dev/null');
+my $sep = (wndws() ? ';' : ':');
 
 my @deferred_stderr;
 my @deferred_stdout;
@@ -84,7 +84,7 @@
 chomp(our $TEXMFHOME = `kpsewhich -var-value=TEXMFHOME`);
 
 # make sure that on windows *everything* is in lower case for comparison
-if (win32()) {
+if (wndws()) {
   $TEXMFDIST = lc($TEXMFDIST);
   $TEXMFVAR = lc($TEXMFVAR);
   $TEXMFSYSVAR = lc($TEXMFSYSVAR);
@@ -280,7 +280,7 @@
     # but for compatibility we'll silently keep the option.
     $cmd = 'edit';
     my $editor = $ENV{'VISUAL'} || $ENV{'EDITOR'};
-    $editor ||= (&win32 ? "notepad" : "vi");
+    $editor ||= (&wndws ? "notepad" : "vi");
     if (-r $changes_config_file) {
       &copyFile($changes_config_file, $bakFile);
     } else {
@@ -389,7 +389,7 @@
   # So make our own temp dir.
   my $tmpdir = "";
   if (! $opts{"dry-run"}) {
-    if (win32()) {
+    if (wndws()) {
       my $foo;
       my $tmp_deflt = File::Spec->tmpdir;
       for my $i (1..5) {
@@ -519,7 +519,7 @@
   print_info("failed to build: $err (@err)\n")       if ($err);
   print_info("total formats: $total\n");
   chdir($thisdir) || warn "chdir($thisdir) failed: $!";
-  if (win32()) {
+  if (wndws()) {
     # try to remove the tmpdir with all files
     TeXLive::TLUtils::rmtree($tmpdir);
   }
@@ -1199,7 +1199,7 @@
           die "$prg: Config file \"$f\" not found";
         }
       }
-      push @tmp, (win32() ? lc($f) : $f);
+      push @tmp, (wndws() ? lc($f) : $f);
     }
     @{$opts{'cnffile'}} = @tmp;
     # in case that config files are given on the command line, the first
@@ -1210,12 +1210,12 @@
     chomp(@all_files);
     my @used_files;
     for my $f (@all_files) {
-      push @used_files, (win32() ? lc($f) : $f);
+      push @used_files, (wndws() ? lc($f) : $f);
     }
     #
     my $TEXMFLOCALVAR;
     my @TEXMFLOCAL;
-    if (win32()) {
+    if (wndws()) {
       chomp($TEXMFLOCALVAR =`kpsewhich --expand-path=\$TEXMFLOCAL`);
       @TEXMFLOCAL = map { lc } split(/;/ , $TEXMFLOCALVAR);
     } else {
@@ -1351,7 +1351,7 @@
 #   and reset it to the real home dir of root.
 
 sub reset_root_home {
-  if (!win32() && ($> == 0)) {  # $> is effective uid
+  if (!wndws() && ($> == 0)) {  # $> is effective uid
     my $envhome = $ENV{'HOME'};
     # if $HOME isn't an existing directory, we don't care.
     if (defined($envhome) && (-d $envhome)) {
@@ -1420,16 +1420,6 @@
 }
 
 
-# copied from TeXLive::TLUtils to reduce dependencies
-sub win32 {
-  if ($^O =~ /^MSWin/i) {
-    return 1;
-  } else {
-    return 0;
-  }
-}
-
-
 

 # version, help.
 

Modified: trunk/Build/source/texk/texlive/linked_scripts/texlive/tlmgr.pl
===================================================================
--- trunk/Build/source/texk/texlive/linked_scripts/texlive/tlmgr.pl	2023-02-20 20:59:19 UTC (rev 65979)
+++ trunk/Build/source/texk/texlive/linked_scripts/texlive/tlmgr.pl	2023-02-20 21:00:04 UTC (rev 65980)
@@ -1,14 +1,14 @@
 #!/usr/bin/env perl
-# $Id: tlmgr.pl 63068 2022-04-18 05:58:07Z preining $
+# $Id: tlmgr.pl 65965 2023-02-20 17:26:54Z karl $
 #
-# Copyright 2008-2022 Norbert Preining
+# Copyright 2008-2023 Norbert Preining
 # This file is licensed under the GNU General Public License version 2
 # or any later version.
 
 use strict; use warnings;
 
-my $svnrev = '$Revision: 63068 $';
-my $datrev = '$Date: 2022-04-18 07:58:07 +0200 (Mon, 18 Apr 2022) $';
+my $svnrev = '$Revision: 65965 $';
+my $datrev = '$Date: 2023-02-20 18:26:54 +0100 (Mon, 20 Feb 2023) $';
 my $tlmgrrevision;
 my $tlmgrversion;
 my $prg;
@@ -51,7 +51,7 @@
     $Master =~ s!\\!/!g;
     $Master =~ s![^/]*$!../../..!
       unless ($Master =~ s!/texmf-dist/scripts/texlive/tlmgr\.pl$!!i);
-    $bindir = "$Master/bin/win32";
+    $bindir = "$Master/bin/windows";
     $kpsewhichname = "kpsewhich.exe";
     # path already set by wrapper batchfile
   } else {
@@ -96,7 +96,7 @@
 use TeXLive::TLDownload;
 use TeXLive::TLConfFile;
 use TeXLive::TLCrypto;
-TeXLive::TLUtils->import(qw(member info give_ctan_mirror win32 dirname
+TeXLive::TLUtils->import(qw(member info give_ctan_mirror wndws dirname
                             mkdirhier copy debug tlcmp repository_to_array));
 use TeXLive::TLPaper;
 
@@ -520,7 +520,7 @@
     # and on Windows our Config.pm can apparently interfere, so always
     # skip it there.  Or if users have NOPERLDOC set in the environment.
     my @noperldoc = ();
-    if (win32() || $ENV{"NOPERLDOC"}) {
+    if (wndws() || $ENV{"NOPERLDOC"}) {
       @noperldoc = ("-noperldoc", "1");
     } else {
       if (!TeXLive::TLUtils::which("perldoc")) {
@@ -843,7 +843,7 @@
   if ($opts{"dry-run"}) {
     $ret = $F_OK;
     $out = "";
-  } elsif (win32() && (! -r "$Master/bin/win32/luatex.dll")) {
+  } elsif (wndws() && (! -r "$Master/bin/windows/luatex.dll")) {
     # deal with the case where only scheme-infrastructure is installed
     # on Windows, thus no luatex.dll is available and the wrapper cannot be started
     tlwarn("Cannot run wrapper due to missing luatex.dll\n");
@@ -895,6 +895,7 @@
     if (defined($localtlpdb->get_package('context'))
 	    && (-x "$bindir/texlua" || -x "$bindir/texlua.exe")) {
       $errors += do_cmd_and_check("mtxrun --generate");
+      $errors += run_postinst_cmd("context --luatex --generate");
     }
     $::files_changed = 0;
   }
@@ -1013,7 +1014,7 @@
     if ($regenerate_language) {
       for my $ext ("dat", "def", "dat.lua") {
         my $lang = "language.$ext";
-        if (! TeXLive::TLUtils::win32()) {
+        if (! TeXLive::TLUtils::wndws()) {
           # Use full path for external command, except on Windows.
           $lang = "$TEXMFSYSVAR/tex/generic/config/$lang";
         }
@@ -1502,7 +1503,7 @@
   }
   init_local_db();
   my $winadminmode = 0;
-  if (win32()) {
+  if (wndws()) {
     #
     # for w32 we do system wide vs user setting detection as follows:
     # - if --w32mode is NOT given,
@@ -1561,9 +1562,9 @@
   }
   my $ret = $F_OK;
   if ($what =~ m/^add$/i) {
-    if (win32()) {
+    if (wndws()) {
       $ret |= TeXLive::TLUtils::w32_add_to_path(
-        $localtlpdb->root . "/bin/win32",
+        $localtlpdb->root . "/bin/windows",
         $winadminmode);
       # ignore this return value, since broadcase_env might return
       # nothing in case of errors, and there is no way around it.
@@ -1576,9 +1577,9 @@
         $localtlpdb->option("sys_info"));
     }
   } elsif ($what =~ m/^remove$/i) {
-    if (win32()) {
+    if (wndws()) {
       $ret |= TeXLive::TLUtils::w32_remove_from_path(
-        $localtlpdb->root . "/bin/win32",
+        $localtlpdb->root . "/bin/windows",
         $winadminmode);
       # ignore this return value, since broadcase_env might return
       # nothing in case of errors, and there is no way around it.
@@ -3291,7 +3292,7 @@
         }
         $updated{$pkg} = 1;
         next;
-      } elsif (win32() && ($pkg =~ m/$CriticalPackagesRegexp/)) {
+      } elsif (wndws() && ($pkg =~ m/$CriticalPackagesRegexp/)) {
         # we pretend that the update happened
         # in order to calculate file changes properly
         $updated{$pkg} = 1;
@@ -3395,7 +3396,7 @@
             my $parentobj = $localtlpdb->get_package($parent);
             if (!defined($parentobj)) {
               # well, in this case we might have hit a package that only
-              # has .ARCH package, like psv.win32, so do nothing
+              # has .ARCH package, like psv.windows, so do nothing
               debug("$prg: .ARCH package without parent, not announcing postaction\n");
             } else {
               debug("$prg: announcing parent execute action for $pkg\n");
@@ -3410,7 +3411,7 @@
         # TODO
         logpackage("failed update: $pkg ($rev -> $mediarevstr)");
         tlwarn("$prg: Installation of new version of $pkg failed, trying to unwind.\n");
-        if (win32()) {
+        if (wndws()) {
           # w32 is notorious for not releasing a file immediately
           # we experienced permission denied errors
           my $newname = $unwind_package;
@@ -3557,7 +3558,7 @@
         my @found_pkgs = $localtlpdb->find_file($k);
         if ($#found_pkgs >= 0) {
           my $bad_file = 1;
-          if (win32()) {
+          if (wndws()) {
             # on w32 the packages have not been removed already,
             # so we check that the only package listed in @found_pkgs
             # is the one we are working on ($pkg)
@@ -3583,7 +3584,7 @@
       }
     }
 
-    if (!win32()) {
+    if (!wndws()) {
       for my $f (@infra_files_to_be_removed) {
         # TODO actually unlink the stuff
         #unlink("$Master/$f");
@@ -3614,7 +3615,7 @@
   }
 
   # infra update and tlmgr restart on w32 is done by the updater batch script
-  if (win32() && $opts{'self'} && !$opts{"list"} && @critical) {
+  if (wndws() && $opts{'self'} && !$opts{"list"} && @critical) {
     info("$prg: Preparing TeX Live infrastructure update...\n");
     for my $f (@infra_files_to_be_removed) {
       debug("file scheduled for removal $f\n");
@@ -3629,7 +3630,7 @@
   }
 
   # only when we are not dry-running we restart the program
-  if (!win32() && $restart_tlmgr && !$opts{"dry-run"} && !$opts{"list"}) {
+  if (!wndws() && $restart_tlmgr && !$opts{"dry-run"} && !$opts{"list"}) {
     info("$prg: Restarting to complete update ...\n");
     debug("restarting tlmgr @::SAVEDARGV\n");
     # cleanup temp files before re-exec-ing tlmgr
@@ -4760,11 +4761,11 @@
       # ignore generate_update which is no longer used or needed.
       next if ($o eq "generate_updmap");
       # ignore some things which are w32 specific
-      next if ($o eq "desktop_integration" && !win32());
-      next if ($o eq "file_assocs" && !win32());
-      next if ($o eq "w32_multi_user" && !win32());
+      next if ($o eq "desktop_integration" && !wndws());
+      next if ($o eq "file_assocs" && !wndws());
+      next if ($o eq "w32_multi_user" && !wndws());
       #
-      if (win32()) {
+      if (wndws()) {
         next if ($o =~ m/^sys_/);
       }
       if (defined $TLPDBOptions{$o}) {
@@ -4828,7 +4829,7 @@
             # when running w32 do not allow that a non-admin users sets
             # this from false to true
             my $do_it = 0;
-            if (win32()) {
+            if (wndws()) {
               if (admin()) {
                 $do_it = 1;
               } else {
@@ -4937,9 +4938,9 @@
 #
 sub action_platform {
   my $ret = $F_OK;
-  my @extra_w32_packs = qw/tlperl.win32 tlgs.win32
+  my @extra_w32_packs = qw/tlperl.windows tlgs.windows
                            collection-wintools
-                           dviout.win32 wintools.win32/;
+                           dviout.windows wintools.windows/;
   if ($^O =~ /^MSWin/i) {
     warn("action `platform' not supported on Windows\n");
     # return an error here so that we don't go into post-actions
@@ -5011,7 +5012,7 @@
         }
       }
     }
-    if (TeXLive::TLUtils::member('win32', @todoarchs)) {
+    if (TeXLive::TLUtils::member('windows', @todoarchs)) {
       # install the necessary w32 stuff
       for my $p (@extra_w32_packs) {
         info("install: $p\n");
@@ -5069,7 +5070,7 @@
         }
       }
     }
-    if (TeXLive::TLUtils::member('win32', @todoarchs)) {
+    if (TeXLive::TLUtils::member('windows', @todoarchs)) {
       for my $p (@extra_w32_packs) {
         info("remove: $p\n");
         $localtlpdb->remove_package($p) if (!$opts{"dry-run"});
@@ -5315,7 +5316,7 @@
 # Return zero if successful, nonzero if failure.
 # 
 sub uninstall_texlive {
-  if (win32()) {
+  if (wndws()) {
     printf STDERR "Please use \"Add/Remove Programs\" from the Control Panel "
                   . "to uninstall TeX Live!\n";
     return ($F_ERROR);
@@ -5499,7 +5500,7 @@
 
   # if we are on W32, die (no find).  
   my $arch = $localtlpdb->platform();
-  if ($arch eq "win32") {
+  if ($arch eq "windows") {
     tldie("$prg: sorry, cannot check this on Windows.\n");
   }
 
@@ -5516,6 +5517,7 @@
 }
 
 sub action_check {
+  ddebug("starting action_check\n");
   my $svn = defined($opts{"use-svn"}) ? $opts{"use-svn"} : 0;
   my $what = shift @ARGV;
   $what || ($what = "all");
@@ -5776,6 +5778,7 @@
 # check executes
 #
 sub check_executes {
+  ddebug("starting check_executes\n");
   my $Master = $localtlpdb->root;
   my (%maps,%langcodes,%fmtlines);
   for my $pkg ($localtlpdb->list_packages) {
@@ -5799,8 +5802,10 @@
       }
     }
   }
+
+  ddebug(" check_executes: checking maps\n");
   my %badmaps;
-  foreach my $mf (keys %maps) {
+  foreach my $mf (sort keys %maps) {
     my @pkgsfound = @{$maps{$mf}};
     if ($#pkgsfound > 0) {
       tlwarn("$prg: map file $mf is referenced in the executes of @pkgsfound\n");
@@ -5840,9 +5845,11 @@
       print "\t$mf (execute in @{$badmaps{$mf}})\n";
     }
   }
+
+  ddebug(" check_executes: checking hyphcodes\n");
   my %badhyphcodes;
   my %problemhyphen;
-  foreach my $lc (keys %langcodes) {
+  foreach my $lc (sort keys %langcodes) {
     next if ($lc eq "zerohyph.tex");
     my @found = $localtlpdb->find_file("texmf-dist/tex/generic/hyph-utf8/loadhyph/$lc");
     if ($#found < 0) {
@@ -5868,7 +5875,7 @@
   #    print "\t$mf (@{$problemhyphen{$mf}})\n";
   #  }
   #}
-  #
+
   # what should be checked for the executes? we could check
   # - the existence of the engine in bin/i386-linux or all $arch
   # - the existence of the format name link/bat
@@ -5879,8 +5886,9 @@
   my %missingengines;
   my %missinginis;
   my @archs_to_check = $localtlpdb->available_architectures;
-  for (keys %fmtlines) {
-    my %r = TeXLive::TLUtils::parse_AddFormat_line("$_");
+  ddebug("archs_to_check: @archs_to_check\n");
+  for (sort keys %fmtlines) {
+    my %r = TeXLive::TLUtils::parse_AddFormat_line($_);
     if (defined($r{"error"})) {
       die "$r{'error'}, parsing $_, package(s) @{$fmtlines{$_}}";
     }
@@ -6005,7 +6013,7 @@
     return 1;
   } else {
     # not -r, so check for the extensions .bat and .exe on windoze-ish.
-    if ($a =~ /win[0-9]|.*-cygwin/) {
+    if ($a =~ /windows|win[0-9]|.*-cygwin/) {
       if (-r "$f.exe" || -r "$f.bat") {
         return 1;
       }
@@ -6038,7 +6046,7 @@
     # For each package, check that it is a dependency of some collection.
     if (! exists $coll_deps{$pkg}) {
       # Except that schemes and our ugly Windows packages are ok.
-      push (@no_dep, $pkg) unless $pkg =~/^scheme-|\.win32$/;
+      push (@no_dep, $pkg) unless $pkg =~/^scheme-|\.windows$/;
     }
 
     # For each dependency, check that we have a package.
@@ -6156,7 +6164,7 @@
     tlwarn("$prg: action postaction needs as second argument one from 'shortcut', 'fileassoc', 'script'\n");
     return;
   }
-  if (win32()) {
+  if (wndws()) {
     if ($opts{"w32mode"}) {
       if ($opts{"w32mode"} eq "user") {
         if (TeXLive::TLWinGoo::admin()) {
@@ -6191,7 +6199,7 @@
     @todo = $localtlpdb->expand_dependencies("-only-arch", $localtlpdb, @todo);
   }
   if ($type =~ m/^shortcut$/i) {
-    if (!win32()) {
+    if (!wndws()) {
       tlwarn("$prg: action postaction shortcut only works on windows.\n");
       return;
     }
@@ -6205,7 +6213,7 @@
       }
     }
   } elsif ($type =~ m/^fileassoc$/i) {
-    if (!win32()) {
+    if (!wndws()) {
       tlwarn("$prg: action postaction fileassoc only works on windows.\n");
       return;
     }
@@ -6919,7 +6927,7 @@
   # - if we are on Windows, it does not start with Drive:[\/]
   if (! ( $location =~ m!^(https?|ftp)://!i  || 
           $location =~ m!$TeXLive::TLUtils::SshURIRegex!i ||
-          (win32() && (!(-e $location) || ($location =~ m!^.:[\\/]!) ) ) ) ) {
+          (wndws() && (!(-e $location) || ($location =~ m!^.:[\\/]!) ) ) ) ) {
     # seems to be a local path, try to normalize it
     my $testloc = abs_path($location);
     # however, if we were given a url, that will get "normalized" to the
@@ -10240,7 +10248,7 @@
 distribution (L<https://tug.org/texlive>) and both are licensed under the
 GNU General Public License Version 2 or later.
 
-$Id: tlmgr.pl 63068 2022-04-18 05:58:07Z preining $
+$Id: tlmgr.pl 65965 2023-02-20 17:26:54Z karl $
 =cut
 
 # test HTML version: pod2html --cachedir=/tmp tlmgr.pl >/tmp/tlmgr.html

Modified: trunk/Build/source/texk/texlive/linked_scripts/texlive/updmap.pl
===================================================================
--- trunk/Build/source/texk/texlive/linked_scripts/texlive/updmap.pl	2023-02-20 20:59:19 UTC (rev 65979)
+++ trunk/Build/source/texk/texlive/linked_scripts/texlive/updmap.pl	2023-02-20 21:00:04 UTC (rev 65980)
@@ -1,5 +1,5 @@
 #!/usr/bin/env perl
-# $Id: updmap.pl 63644 2022-06-18 22:30:39Z karl $
+# $Id: updmap.pl 65932 2023-02-19 20:49:48Z siepo $
 # updmap - maintain map files for outline fonts.
 # (Maintained in TeX Live:Master/texmf-dist/scripts/texlive.)
 # 
@@ -13,7 +13,7 @@
 # later adaptions by Reinhard Kotucha, and Karl Berry.
 # The current implementation is a complete rewrite.
 
-my $svnid = '$Id: updmap.pl 63644 2022-06-18 22:30:39Z karl $';
+my $svnid = '$Id: updmap.pl 65932 2023-02-19 20:49:48Z siepo $';
 
 my $TEXMFROOT;
 BEGIN {
@@ -26,10 +26,10 @@
   unshift(@INC, "$TEXMFROOT/tlpkg");
 }
 
-my $lastchdate = '$Date: 2022-06-19 00:30:39 +0200 (Sun, 19 Jun 2022) $';
+my $lastchdate = '$Date: 2023-02-19 21:49:48 +0100 (Sun, 19 Feb 2023) $';
 $lastchdate =~ s/^\$Date:\s*//;
 $lastchdate =~ s/ \(.*$//;
-my $svnrev = '$Revision: 63644 $';
+my $svnrev = '$Revision: 65932 $';
 $svnrev =~ s/^\$Revision:\s*//;
 $svnrev =~ s/\s*\$$//;
 my $version = "r$svnrev ($lastchdate)";
@@ -36,7 +36,7 @@
 
 use Getopt::Long qw(:config no_autoabbrev ignore_case_always);
 use strict;
-use TeXLive::TLUtils qw(mkdirhier mktexupd win32 basename dirname 
+use TeXLive::TLUtils qw(mkdirhier mktexupd wndws basename dirname 
   sort_uniq member touch);
 
 (my $prg = basename($0)) =~ s/\.pl$//;
@@ -53,7 +53,7 @@
 chomp(my $TEXMFHOME = `kpsewhich -var-value=TEXMFHOME`);
 
 # make sure that on windows *everything* is in lower case for comparison
-if (win32()) {
+if (wndws()) {
   $TEXMFDIST = lc($TEXMFDIST);
   $TEXMFVAR = lc($TEXMFVAR);
   $TEXMFSYSVAR = lc($TEXMFSYSVAR);
@@ -231,7 +231,7 @@
       if (! -f $f) {
         die "$prg: Config file \"$f\" not found.";
       }
-      push @tmp, (win32() ? lc($f) : $f);
+      push @tmp, (wndws() ? lc($f) : $f);
     }
     @{$opts{'cnffile'}} = @tmp;
     # in case that config files are given on the command line, the first
@@ -242,12 +242,12 @@
     chomp(@all_files);
     my @used_files;
     for my $f (@all_files) {
-      push @used_files, (win32() ? lc($f) : $f);
+      push @used_files, (wndws() ? lc($f) : $f);
     }
     #
     my $TEXMFLOCALVAR;
     my @TEXMFLOCAL;
-    if (win32()) {
+    if (wndws()) {
       chomp($TEXMFLOCALVAR =`kpsewhich --expand-path=\$TEXMFLOCAL`);
       @TEXMFLOCAL = map { lc } split(/;/ , $TEXMFLOCALVAR);
     } else {
@@ -421,7 +421,7 @@
     # but for compatibility we'll silently keep the option.
     $cmd = 'edit';
     my $editor = $ENV{'VISUAL'} || $ENV{'EDITOR'};
-    $editor ||= (&win32 ? "notepad" : "vi");
+    $editor ||= (wndws() ? "notepad" : "vi");
     if (-r $changes_config_file) {
       &copyFile($changes_config_file, $bakFile);
     } else {
@@ -593,7 +593,7 @@
 sub SymlinkOrCopy {
   my ($dir, $src, $dest) = @_;
   return ($src, $dest) if $opts{"dry-run"};
-  if (&win32 || $opts{'copy'}) {  # always copy
+  if (wndws() || $opts{'copy'}) {  # always copy
     &copyFile("$dir/$src", "$dir/$dest");
   } else { # symlink if supported by fs, copy otherwise
     system("cd \"$dir\" && ln -s $src $dest 2>/dev/null || "
@@ -2216,7 +2216,7 @@
 #   and reset it to the real home dir of root.
 
 sub reset_root_home {
-  if (!win32() && ($> == 0)) {  # $> is effective uid
+  if (!wndws() && ($> == 0)) {  # $> is effective uid
     my $envhome = $ENV{'HOME'};
     # if $HOME isn't an existing directory, we don't care.
     if (defined($envhome) && (-d $envhome)) {

Modified: trunk/Build/source/texk/texlive/linked_scripts/tlshell/tlshell.tcl
===================================================================
--- trunk/Build/source/texk/texlive/linked_scripts/tlshell/tlshell.tcl	2023-02-20 20:59:19 UTC (rev 65979)
+++ trunk/Build/source/texk/texlive/linked_scripts/tlshell/tlshell.tcl	2023-02-20 21:00:04 UTC (rev 65980)
@@ -1,10 +1,6 @@
-#!/bin/sh
-# next line ignored by wish but not by sh \
-TK_SILENCE_DEPRECATION=1 exec wish "$0" -- "$@"
-# The above environment variable is set to suppress
-# a warning message under MacOS Catalina and Big Sur
+#!/usr/bin/env wish
 
-# Copyright 2017-2022 Siep Kroonenberg
+# Copyright 2017-2023 Siep Kroonenberg
 
 # This file is licensed under the GNU General Public License version 2
 # or any later version.
@@ -357,7 +353,9 @@
   }
 
   # 64-bit windows
-  if {$::tcl_platform(platform) eq "windows" && $::wprocessor eq "AMD64"} {
+  # we disable this menu, but we may possibly resurrect it later
+  # for windows on arm support; therefore 'if {0 && ...}
+  if {0 && $::tcl_platform(platform) eq "windows" && $::wprocessor eq "AMD64"} {
     dis_enable_w64
   }
 }; # selective_dis_enable
@@ -939,7 +937,7 @@
   unset -nocomplain ::loaded
   track_err
   set catv "rcat-version"
-  if {[dict get $::pkgs texlive.infra localrev] < 56458} { set catv "cat-version" }
+
   if [catch {run_cmd \
     "info --data name,remoterev,$catv,category,shortdesc"}] {
     do_debug [get_stacktrace]
@@ -2350,6 +2348,7 @@
 # with 'unzip -T', but this can only be done AFTER downloading.
 # See also tcl commands 'file mtime', and 'clock scan'
 
+if 0 {
 # $::wprocessor will later decide whether a w64 menu will be created.
 if {$::tcl_platform(platform) eq "windows"} {
   set ::wprocessor $::env(PROCESSOR_ARCHITECTURE)
@@ -2630,7 +2629,7 @@
   update idletasks
   return 1
 }
-
+}; # if 0
 ##### main window #####################################################
 
 proc populate_main {} {
@@ -2710,7 +2709,7 @@
     .mn.opt add command -label "[__ "Platforms"] ..." -command platforms_select
   }
 
-  if {$::tcl_platform(platform) eq "windows" && $::wprocessor eq "AMD64"} {
+  if {0 && $::tcl_platform(platform) eq "windows" && $::wprocessor eq "AMD64"} {
     .mn add cascade -label "64-bit Windows" -menu .mn.w64
     menu .mn.w64
     set inx -1

Modified: trunk/Master/texmf-dist/doc/latex/hyperxmp/README
===================================================================
--- trunk/Master/texmf-dist/doc/latex/hyperxmp/README	2023-02-20 20:59:19 UTC (rev 65979)
+++ trunk/Master/texmf-dist/doc/latex/hyperxmp/README	2023-02-20 21:00:04 UTC (rev 65980)
@@ -47,7 +47,7 @@
 Copyright and license
 =====================
 
-Copyright (C) 2011-2020 Scott Pakin
+Copyright (C) 2011-2023 Scott Pakin
 
 This file may be distributed and/or modified under the conditions of
 the LaTeX Project Public License, either version 1.3c of this license

Modified: trunk/Master/texmf-dist/doc/latex/hyperxmp/hyperxmp.pdf
===================================================================
(Binary files differ)

Modified: trunk/Master/texmf-dist/doc/man/man1/hyperxmp-add-bytecount.man1.pdf
===================================================================
(Binary files differ)

Modified: trunk/Master/texmf-dist/scripts/hyperxmp/hyperxmp-add-bytecount.pl
===================================================================
--- trunk/Master/texmf-dist/scripts/hyperxmp/hyperxmp-add-bytecount.pl	2023-02-20 20:59:19 UTC (rev 65979)
+++ trunk/Master/texmf-dist/scripts/hyperxmp/hyperxmp-add-bytecount.pl	2023-02-20 21:00:04 UTC (rev 65980)
@@ -8,7 +8,7 @@
 # hyperxmp-add-bytecount                                               #
 #   Adds/updates byteCount specification in XMP packet in pdf file(s)  #
 #   made by hyperxmp, with byteCount = file size.                      #
-# Copyright (C) 2020 John Collins <jcc8 at psu.edu>                       #
+# Copyright (C) 2020-2022 John Collins <jcc8 at psu.edu>                  #
 #    and Scott Pakin, <scott+hyxmp at pakin.org>                          #
 #                                                                      #
 # This program may be distributed and/or modified under the conditions #

Modified: trunk/Master/texmf-dist/source/latex/hyperxmp/einstein-xmp.tex
===================================================================
--- trunk/Master/texmf-dist/source/latex/hyperxmp/einstein-xmp.tex	2023-02-20 20:59:19 UTC (rev 65979)
+++ trunk/Master/texmf-dist/source/latex/hyperxmp/einstein-xmp.tex	2023-02-20 21:00:04 UTC (rev 65980)
@@ -21,7 +21,6 @@
                  xmlns:pdfaid="http://www.aiim.org/pdfa/ns/id/"
                  xmlns:pdfuaid="http://www.aiim.org/pdfua/ns/id/"
                  xmlns:pdfx="http://ns.adobe.com/pdfx/1.3/"
-                 xmlns:pdfxid="http://www.npes.org/pdfx/ns/id/"
                  xmlns:prism="http://prismstandard.org/namespaces/basic/3.0/"
                  xmlns:jav="http://www.niso.org/schemas/jav/1.0/"
                  xmlns:xmpTPg="http://ns.adobe.com/xap/1.0/t/pg/"

Modified: trunk/Master/texmf-dist/source/latex/hyperxmp/hyperxmp-stds.tex
===================================================================
--- trunk/Master/texmf-dist/source/latex/hyperxmp/hyperxmp-stds.tex	2023-02-20 20:59:19 UTC (rev 65979)
+++ trunk/Master/texmf-dist/source/latex/hyperxmp/hyperxmp-stds.tex	2023-02-20 21:00:04 UTC (rev 65980)
@@ -8,7 +8,7 @@
 %% 
 %% This is a generated file.
 %% 
-%% Copyright (C) 2011-2020 by Scott Pakin <scott+hyxmp at pakin.org>
+%% Copyright (C) 2011-2023 by Scott Pakin <scott+hyxmp at pakin.org>
 %% 
 %% This file may be distributed and/or modified under the conditions of
 %% the LaTeX Project Public License, either version 1.3c of this license

Modified: trunk/Master/texmf-dist/source/latex/hyperxmp/hyperxmp.dtx
===================================================================
--- trunk/Master/texmf-dist/source/latex/hyperxmp/hyperxmp.dtx	2023-02-20 20:59:19 UTC (rev 65979)
+++ trunk/Master/texmf-dist/source/latex/hyperxmp/hyperxmp.dtx	2023-02-20 21:00:04 UTC (rev 65980)
@@ -1,6 +1,6 @@
 % \iffalse meta-comment
 %
-% Copyright (C) 2011-2020 by Scott Pakin <scott+hyxmp at pakin.org>
+% Copyright (C) 2011-2023 by Scott Pakin <scott+hyxmp at pakin.org>
 % --------------------------------------------------------------
 %
 % This file may be distributed and/or modified under the
@@ -22,7 +22,7 @@
 %<package>\NeedsTeXFormat{LaTeX2e}[1999/12/01]
 %<package>\ProvidesPackage{hyperxmp}
 %<*package>
-    [2020/11/22 v5.9 Store hyperref metadata in XMP format]
+    [2022/10/16 v5.11 Store hyperref metadata in XMP format]
 %</package>
 %
 %<*driver>
@@ -76,7 +76,7 @@
   pdftitle={The hyperxmp package},
   pdfsubject={LaTeX2e support for XMP metadata},
   pdfkeywords={LaTeX, embedded metadata, XMP, PDF, copyright, license, comments},
-  pdfcopyright={Copyright (C) 2011-2020, Scott Pakin},
+  pdfcopyright={Copyright (C) 2011-2023, Scott Pakin},
   pdflicenseurl={http://www.latex-project.org/lppl/},
   pdfcaptionwriter={Scott Pakin},
   pdfcontactemail={scott+hyxmp at pakin.org},
@@ -98,18 +98,33 @@
   bookmarksnumbered
 }
 
+% Redefine \changes to properly sort v5.10 *after* v5.9.
+\makeatletter
+\let\orig at changes=\changes
+\def\discard at suffix#1\relax{}
+\def\pad at minor@ver v#1.#2\relax{%
+  \afterassignment\discard at suffix
+  \@tempcnta=#2\relax
+  \edef\new at change@ver{%
+    v#1.%
+    \ifnum\@tempcnta<10
+      0#2
+    \else
+      #2
+    \fi
+  }%
+}
+\renewcommand{\changes}[2]{%
+  \pad at minor@ver#1\relax
+  \orig at changes{\new at change@ver=#1}{#2}%
+}
+\makeatother
+
 \begin{document}
   \DocInput{hyperxmp.dtx}
   \Needspace{10\baselineskip}
-  \phantomsection\addcontentsline{toc}{section}{Change History}
+  \renewcommand*{\glossaryname}{Change History}
   \PrintChanges
-  \makeatletter
-  \let\orig at index@prologue=\index at prologue
-  \def\index at prologue{%
-    \phantomsection\addcontentsline{toc}{section}{Index}
-    \orig at index@prologue
-  }%
-  \makeatother
   \Needspace{12\baselineskip}
   \PrintIndex
 \end{document}
@@ -116,7 +131,7 @@
 %</driver>
 % \fi
 %
-% \CheckSum{2836}
+% \CheckSum{2844}
 %
 % \CharacterTable
 %  {Upper-case    \A\B\C\D\E\F\G\H\I\J\K\L\M\N\O\P\Q\R\S\T\U\V\W\X\Y\Z
@@ -203,11 +218,12 @@
 % \DoNotIndex{\@ifpackageloaded,\@ifundefined,\@nil,\@secondoftwo}
 % \DoNotIndex{\@tempcnta,\@tempcntb,\MessageBreak,\advance,\afterassignment}
 % \DoNotIndex{\aftergroup,\begin,\begingroup,\bgroup,\catcode,\csname,\def}
-% \DoNotIndex{\divide,\edef,\egroup,\else,\end,\endcsname,\endgroup}
-% \DoNotIndex{\expandafter,\fi,\futurelet,\g at addto@macro,\gdef,\global,\if}
-% \DoNotIndex{\ifcase,\ifnum,\ifx,\immediate,\lccode,\let,\loop,\lowercase}
-% \DoNotIndex{\multiply,\newcommand,\noexpand,\or,\relax,\repeat,\space}
-% \DoNotIndex{\string,\the,\toks,\uccode,\uppercase,\usepackage,\xdef}
+% \DoNotIndex{\divide,\do,\edef,\egroup,\else,\end,\endcsname,\endgroup}
+% \DoNotIndex{\expandafter,\fi,\futurelet,\g at addto@macro,\gdef,\global}
+% \DoNotIndex{\hbox,\if,\ifcase,\ifnum,\ifx,\immediate,\lccode,\let,\loop}
+% \DoNotIndex{\lowercase,\multiply,\newcommand,\noexpand,\or,\relax,\repeat}
+% \DoNotIndex{\space,\string,\the,\toks,\uccode,\uppercase,\usepackage}
+% \DoNotIndex{\xdef}
 %
 % ^^A  Define a few logical styles.
 % \DeclareRobustCommand{\term}[1]{#1\SortIndex{#1}{#1}}
@@ -1114,21 +1130,23 @@
 %   \item \pdfLaTeX
 %   \item \LuaLaTeX
 %   \item \XeLaTeX
-%   \item \LaTeX~$+$ Dvipdfm
+%   \item \LaTeX~$+$ \term{Dvipdfm}
+%   \item \LaTeX~$+$ \Dvips~$+$ \term{Ghostscript}
 %   \item \LaTeX~$+$ \Dvips~$+$ Adobe Acrobat Distiller
 % \end{itemize}
 %
 % \noindent
-% Unfortunately, the \LaTeX~$+$ \Dvips~$+$ \term{Ghostscript} path
-% doesn't work.
-% \href{http://bugs.ghostscript.com/show_bug.cgi?id=690066}{Ghostscript
-%   bug report~\#690066}, closed with ``\textsc{wontfix}'' status on
-% 2012-05-28, explains that \term{Ghostscript} doesn't honor the
-% \pdfterm{Metadata} tag needed to inject a custom \acro{XMP} packet.
-% Instead, \term{Ghostscript} fabricates an \acro{XMP} packet of its own
-% based on the metadata it finds in the \acro{PDF} file's \pdfterm{Info}
-% dictionary (\pdfterm{Author}, \pdfterm{Title}, \pdfterm{Subject}, and
-% \pdfterm{Keywords}).
+% The \LaTeX~$+$ \Dvips~$+$ \term{Ghostscript} path stores the
+% \acro{XMP} packet in a compressed stream, which implies that a
+% \acro{PDF} reader is needed to access it.  Ideally, \acro{XMP}
+% metadata should be stored uncompressed so it can be extracted as
+% ordinary text.  Unfortunately, as of 2022-10-07, Ghostscript has no
+% plans to support uncompressed metadata streams
+% (\href{https://bugs.ghostscript.com/show_bug.cgi?id=705962}{Ghostscript
+%   bug report~\#705962}).  It is possible to leave \emph{all} streams
+% uncompressed by passing |-dCompressStreams=false| to \term{Ghostscript}
+% (e.g.,~via the \progname{ps2pdf} wrapper script), but this leads to
+% larger file sizes.
 %
 % \bigskip
 %
@@ -1742,6 +1760,19 @@
 % \subsection{Initial preparation}
 % \label{sec:initial-prep}
 %
+% \changes{v5.11}{2022/10/02}{Disable \protect\pkgname{hyperxmp} if
+%    \LaTeX3 document metadata is available.  Document metadata implies
+%    the presence of PDF management, which completely breaks
+%    \protect\pkgname{hyperxmp}}
+%    \begin{macrocode}
+\IfDocumentMetadataTF{%
+  \PackageWarning
+      {hyperxmp}
+      {Disabling hyperxmp because it is incompatible with PDF management}
+}{}
+\IfDocumentMetadataTF{\endinput}{}
+%    \end{macrocode}
+%
 % \changes{v1.2}{2011/04/17}{Made the package compatible with \pkgname{ngerman}.
 %   Thanks to Tobias Mueller for the bug report.}
 %
@@ -1772,12 +1803,19 @@
 %   \protect\tex\ back ends that provide it.  Thanks to Nelson Posse
 %   Lago for pointing out why \protect\pkgname{atenddvi} is best avoided
 %   if possible}
+% \changes{v5.11}{2022/10/16}{Use \protect\cs{AddToHook} when available.
+%   This addresses a bug reported on \protect\TeX\ StackExchange by joHub
+%   and solved by Ulrike Fischer}
 %    \begin{macrocode}
-\@ifundefined{AtEndDocument}{%
-  \RequirePackage{atenddvi}
-  \let\hyxmp at at@end=\AtEndDvi
+\@ifundefined{AddToHook}{%
+  \@ifundefined{AtEndDocument}{%
+    \RequirePackage{atenddvi}
+    \let\hyxmp at at@end=\AtEndDvi
+  }{%
+    \let\hyxmp at at@end=\AtEndDocument
+  }
 }{%
-  \let\hyxmp at at@end=\AtEndDocument
+  \def\hyxmp at at@end{\AddToHook{shipout/lastpage}}
 }
 %    \end{macrocode}
 % \end{macro}
@@ -2056,6 +2094,18 @@
 %    \end{macrocode}
 % \end{macro}
 %
+% \begin{macro}{\@hyxmp at count}
+% \changes{v5.11}{2022/10/02}{Added this macro to fix a bug with
+%   \protect\optname{pdfapart}.  Thanks to John H. Lienhard and
+%   Kartik Singhal for their bug reports}
+% Define a temporary counter.  The code previously used \cs{@tempcnta},
+% but this is no longer safe within \cs{pdfstringdef} as of more recent
+% versions of \pkgname{hyperref}.
+%    \begin{macrocode}
+\newcount\@hyxmp at count
+%    \end{macrocode}
+% \end{macro}
+%
 % \begin{macro}{\@pdfapart}
 % Prepare to store the \acro{PDF/A} part ID, which defaults to~``1''
 % if \optname{pdfa} is passed to \pkgname{hyperref}.
@@ -2062,8 +2112,8 @@
 %    \begin{macrocode}
 \def\@pdfapart{}
 \define at key{Hyp}{pdfapart}{%
-  \afterassignment\hyxmp at no@bad at parts\@tempcnta=0#1\relax
-  \hyxmp at pdfstringdef\@pdfapart{\the\@tempcnta}%
+  \afterassignment\hyxmp at no@bad at parts\@hyxmp at count=0#1\relax
+  \hyxmp at pdfstringdef\@pdfapart{\the\@hyxmp at count}%
 }
 %    \end{macrocode}
 % \end{macro}
@@ -2085,8 +2135,8 @@
 %    \begin{macrocode}
 \def\@pdfuapart{}
 \define at key{Hyp}{pdfuapart}{%
-  \afterassignment\hyxmp at no@bad at parts\@tempcnta=0#1\relax
-  \hyxmp at pdfstringdef\@pdfuapart{\the\@tempcnta}%
+  \afterassignment\hyxmp at no@bad at parts\@hyxmp at count=0#1\relax
+  \hyxmp at pdfstringdef\@pdfuapart{\the\@hyxmp at count}%
 }
 %    \end{macrocode}
 % \end{macro}
@@ -2101,11 +2151,11 @@
 %
 % \begin{macro}{\hyxmp at set@pdfx at major@i}
 % This is the first helper macro for |\hyxmp at set@pdfx at major|.  It stores
-% the \acro{PDF/X} major version in |\@tempcnta|.
+% the \acro{PDF/X} major version in |\@hyxmp at count|.
 %    \begin{macrocode}
 \def\hyxmp at set@pdfx at major@i PDF/X-{%
   \afterassignment\hyxmp at set@pdfx at major@ii
-  \@tempcnta=%
+  \@hyxmp at count=%
 }
 %    \end{macrocode}
 % \end{macro}
@@ -2113,12 +2163,12 @@
 % \begin{macro}{\hyxmp at set@pdfx at major@ii}
 % \begin{macro}{\hyxmp at pdfx@major}
 % This is the second helper macro for |\hyxmp at set@pdfx at major|.  It
-% copies the \acro{PDF/X} major version from |\@tempcnta| to
+% copies the \acro{PDF/X} major version from |\@hyxmp at count| to
 % |\@hyxmp at pdfx@major| and discards the rest of the \acro{PDF/X}
 % standard string.
 %    \begin{macrocode}
 \def\hyxmp at set@pdfx at major@ii#1!{%
-  \edef\hyxmp at pdfx@major{\the\@tempcnta}%
+  \edef\hyxmp at pdfx@major{\the\@hyxmp at count}%
 }
 %    \end{macrocode}
 % \end{macro}
@@ -2719,6 +2769,9 @@
 %
 % \begin{macro}{\hyxmp at ProcessKeyvalOptions}
 % \changes{v2.0}{2012/09/05}{Added this macro}
+% \changes{v5.11}{2022/10/02}{Bug fix: Restore
+%   \protect\cs{ProcessKeyvalOptions} after first use.  Thanks to
+%   Ulrike Fischer for the bug report}
 % \begin{macro}{\ProcessKeyvalOptions}
 % \changes{v2.0}{2012/09/05}{Added this macro}
 % Redefine \pkgname{kvoptions}'s |\ProcessOptions| command to invoke
@@ -2726,6 +2779,7 @@
 %    \begin{macrocode}
 \let\hyxmp at ProcessKeyvalOptions=\ProcessKeyvalOptions
 \renewcommand*{\ProcessKeyvalOptions}{%
+  \global\let\ProcessKeyvalOptions=\hyxmp at ProcessKeyvalOptions
   \hyxmp at redefine@Hyp
   \hyxmp at ProcessKeyvalOptions
 }
@@ -3183,17 +3237,6 @@
 %    \end{macrocode}
 % \end{macro}
 %
-% \pkgname{hyperxmp} can directly query the page count using
-% \LuaTeX\ features.  When any other \TeX\ engine is used,
-% \pkgname{hyperxmp} employs the \pkgname{totpages} package to help
-% tally the total number of pages.
-%    \begin{macrocode}
-\ifLuaTeX
-\else
-  \RequirePackage{totpages}
-\fi
-%    \end{macrocode}
-%
 % Determine the size of the output file from the \emph{previous} run of
 % \LuaLaTeX\@.  This action has to be performed before the
 % |\begin{document}| because at that point the size of the output file
@@ -3331,26 +3374,17 @@
 %    \begin{macrocode}
 \newcommand*{\hyxmp at query@self}{%
 %    \end{macrocode}
-% \LuaTeX\ exposes via \texttt{status.total\_pages} the number of pages
-% written.  We use this mechanism when available to assign
-% \cs{@pdfnumpages}.  To finalize the page count we first issue a
-% \cs{clearpage}.
+% \LaTeX's |totalpages| counter tracks the number of pages written.  We
+% use this mechanism to assign \cs{@pdfnumpages}.
+% \changes{v5.11}{2022/10/16}{Use \protect\cs{thetotalpages} to compute
+%   the page count in an engine-independent manner.  Thanks to Ulrike
+%   Fischer for recommending this mechanism}
 %    \begin{macrocode}
-  \ifLuaTeX
-    \@if at def@and at nonempty{@pdfnumpages}{%
-    }{%
-      \clearpage
-      \xdef\@pdfnumpages{\luadirect{tex.print(status.total_pages)}}%
-    }%
-  \else
+  \@if at def@and at nonempty{@pdfnumpages}{%
+  }{%
+    \xdef\@pdfnumpages{\thetotalpages}%
+  }%
 %    \end{macrocode}
-% Without \LuaTeX\ we rely on the \pkgname{totpages} package to help
-% count the number of pages.  This may require an additional run of
-% \LaTeX, but the user will be notified in that case.
-%    \begin{macrocode}
-    \pdfstringdef\@pdfnumpages{\ref*{TotPages}}%
-  \fi
-%    \end{macrocode}
 % If \optname{pdfbytes} hasn't been set, set it to the output file's size
 % from the previous run.
 %    \begin{macrocode}
@@ -4134,19 +4168,19 @@
 % midnight or the timezone so we omit those fields when defining
 % macro~|#1|.
 %    \begin{macrocode}
-  \@tempcnta=\time
-  \divide\@tempcnta by 60
-  \ifnum\@tempcnta<10
-    \xdef#1{#1T0\the\@tempcnta}%
+  \@hyxmp at count=\time
+  \divide\@hyxmp at count by 60
+  \ifnum\@hyxmp at count<10
+    \xdef#1{#1T0\the\@hyxmp at count}%
   \else
-    \xdef#1{#1T\the\@tempcnta}%
+    \xdef#1{#1T\the\@hyxmp at count}%
   \fi
-  \multiply\@tempcnta by -60
-  \advance\@tempcnta by \time
-  \ifnum\@tempcnta<10
-    \xdef#1{#1:0\the\@tempcnta}%
+  \multiply\@hyxmp at count by -60
+  \advance\@hyxmp at count by \time
+  \ifnum\@hyxmp at count<10
+    \xdef#1{#1:0\the\@hyxmp at count}%
   \else
-    \xdef#1{#1:\the\@tempcnta}%
+    \xdef#1{#1:\the\@hyxmp at count}%
   \fi
   \xdef#1{#1Z}%
 }
@@ -4923,14 +4957,14 @@
 % \xmpprop{xmpMM:InstanceID} fields.
 %
 % \begin{macro}{\hyxmp at modulo@a}
-% Replace the contents of |\@tempcnta| with the contents modulo~|#1|.
+% Replace the contents of |\@hyxmp at count| with the contents modulo~|#1|.
 % Note that |\@tempcntb| is overwritten in the process.
 %    \begin{macrocode}
 \def\hyxmp at modulo@a#1{%
-  \@tempcntb=\@tempcnta
+  \@tempcntb=\@hyxmp at count
   \divide\@tempcntb by #1
   \multiply\@tempcntb by #1
-  \advance\@tempcnta by -\@tempcntb
+  \advance\@hyxmp at count by -\@tempcntb
 }
 %    \end{macrocode}
 % \end{macro}
@@ -4952,7 +4986,7 @@
 % of text.
 %    \begin{macrocode}
 \def\hyxmp at seed@rng#1{%
-  \@tempcnta=\hyxmp at big@prime
+  \@hyxmp at count=\hyxmp at big@prime
   \futurelet\hyxmp at one@token\hyxmp at seed@rng at i#1\@empty
 }
 %    \end{macrocode}
@@ -4963,8 +4997,8 @@
 % \begin{macro}{\hyxmp at one@token}
 % \begin{macro}{\next}
 % Do all of the work for |\hyxmp at seed@rng|.  For each character code $c$
-% of the input text, assign $\mathtt{\string\@tempcnta} \leftarrow 3
-% \cdot \mathtt{\string\@tempcnta} + c
+% of the input text, assign $\mathtt{\string\@hyxmp at count} \leftarrow 3
+% \cdot \mathtt{\string\@hyxmp at count} + c
 % \pmod{\mathtt{\string\hyxmp at big@prime}}$.
 %    \begin{macrocode}
 \def\hyxmp at seed@rng at i{%
@@ -4972,8 +5006,8 @@
     \let\next=\relax
   \else
     \def\next##1{%
-      \multiply\@tempcnta by 3
-      \advance\@tempcnta by `##1
+      \multiply\@hyxmp at count by 3
+      \advance\@hyxmp at count by `##1
       \hyxmp at modulo@a{\hyxmp at big@prime}%
       \futurelet\hyxmp at one@token\hyxmp at seed@rng at i
     }%
@@ -4991,15 +5025,15 @@
 % sequence.  Specifically, we assign $\mathtt{\string\hyxmp at rand@num}
 % \leftarrow 3 \cdot \mathtt{\string\hyxmp at rand@num} +
 % \mathtt{\string\hyxmp at big@prime at ii}
-% \pmod{\mathtt{\string\hyxmp at big@prime}}$.  Note that both |\@tempcnta|
+% \pmod{\mathtt{\string\hyxmp at big@prime}}$.  Note that both |\@hyxmp at count|
 % and |\@tempcntb| are overwritten in the process.
 %    \begin{macrocode}
 \def\hyxmp at set@rand at num{%
-  \@tempcnta=\hyxmp at rand@num
-  \multiply\@tempcnta by 3
-  \advance\@tempcnta by \hyxmp at big@prime at ii
+  \@hyxmp at count=\hyxmp at rand@num
+  \multiply\@hyxmp at count by 3
+  \advance\@hyxmp at count by \hyxmp at big@prime at ii
   \hyxmp at modulo@a{\hyxmp at big@prime}%
-  \xdef\hyxmp at rand@num{\the\@tempcnta}%
+  \xdef\hyxmp at rand@num{\the\@hyxmp at count}%
 }
 %    \end{macrocode}
 % \end{macro}
@@ -5007,21 +5041,21 @@
 %
 % \begin{macro}{\hyxmp at append@hex}
 % Append a randomly selected hexadecimal digit to macro~|#1|.  Note that
-% both |\@tempcnta| and |\@tempcntb| are overwritten in the process.
+% both |\@hyxmp at count| and |\@tempcntb| are overwritten in the process.
 %    \begin{macrocode}
 \def\hyxmp at append@hex#1{%
   \hyxmp at set@rand at num
-  \@tempcnta=\hyxmp at rand@num
+  \@hyxmp at count=\hyxmp at rand@num
   \hyxmp at modulo@a{16}%
-  \ifnum\@tempcnta<10
-    \xdef#1{#1\the\@tempcnta}%
+  \ifnum\@hyxmp at count<10
+    \xdef#1{#1\the\@hyxmp at count}%
   \else
 %    \end{macrocode}
 % There \emph{must} be a better way to handle the numbers~10--15 than
 % with |\ifcase|.
 %    \begin{macrocode}
-    \advance\@tempcnta by -10
-    \ifcase\@tempcnta
+    \advance\@hyxmp at count by -10
+    \ifcase\@hyxmp at count
       \xdef#1{#1a}%
       \or\xdef#1{#1b}%
       \or\xdef#1{#1c}%
@@ -5063,7 +5097,7 @@
 % in which each ``\textit{x}'' is a lowercase hexadecimal digit and
 % ``\textit{y}'' is one of ``|8|'', ``|9|'', ``|a|'', or~``|b|''.  We
 % assume that the random-number generator is already seeded.  Note that
-% |\hyxmp at create@uuid| overwrites both |\@tempcnta| and |\@tempcntb|.
+% |\hyxmp at create@uuid| overwrites both |\@hyxmp at count| and |\@tempcntb|.
 % \changes{v2.4}{2014/01/02}{Modified this macro to produce a proper
 %   version~4 (random or pseudorandom) \protect\acro{UUID}}
 %    \begin{macrocode}
@@ -5080,9 +5114,9 @@
 % Randomly select one of ``|8|'', ``|9|'', ``|a|'', or~``|b|''.
 %    \begin{macrocode}
   \hyxmp at set@rand at num
-  \@tempcnta=\hyxmp at rand@num
+  \@hyxmp at count=\hyxmp at rand@num
   \hyxmp at modulo@a{4}%
-  \ifcase\@tempcnta
+  \ifcase\@hyxmp at count
     \g at addto@macro#1{8}%
     \or\g at addto@macro#1{9}%
     \or\g at addto@macro#1{a}%
@@ -5109,7 +5143,7 @@
 \newcommand*{\hyxmp at def@DocumentID}{%
   \edef\hyxmp at seed@string{\hyxmp at jobname:\@pdftitle:\@pdfauthor:}%
   \expandafter\hyxmp at seed@rng\expandafter{\hyxmp at seed@string}%
-  \edef\hyxmp at rand@num{\the\@tempcnta}%
+  \edef\hyxmp at rand@num{\the\@hyxmp at count}%
   \hyxmp at create@uuid\hyxmp at DocumentID
 }
 %    \end{macrocode}
@@ -5138,7 +5172,7 @@
     \hyxmp at jobname:\@pdftitle:\@pdfauthor:\hyxmp at today@xmp:\hyxmp at seed@string
   }%
   \expandafter\hyxmp at seed@rng\expandafter{\hyxmp at seed@string}%
-  \edef\hyxmp at rand@num{\the\@tempcnta}%
+  \edef\hyxmp at rand@num{\the\@hyxmp at count}%
   \hyxmp at create@uuid\hyxmp at InstanceID
 }
 %    \end{macrocode}
@@ -5196,7 +5230,7 @@
 %    \begin{macrocode}
 \newcommand*{\hyxmp at add@to at xml}[1]{%
   \bgroup
-    \@tempcnta=0
+    \@hyxmp at count=0
     \ifhyxmp at unicodetex
       \@tempcntb=65536%
     \else
@@ -5203,9 +5237,9 @@
       \@tempcntb=256%
     \fi
     \loop
-      \lccode\@tempcnta=\@tempcnta
-      \advance\@tempcnta by 1
-      \ifnum\@tempcnta<\@tempcntb
+      \lccode\@hyxmp at count=\@hyxmp at count
+      \advance\@hyxmp at count by 1
+      \ifnum\@hyxmp at count<\@tempcntb
     \repeat
     \lccode`\_=`\ \relax
     \lccode`\^^C=`\,\relax
@@ -6011,14 +6045,14 @@
 % \changes{v5.0}{2020/02/26}{Added this macro}
 %    \begin{macrocode}
 \newcommand*{\hyxmp at pdfx@id at schema}{%
-  \@tempcnta=0\hyxmp at pdfx@major\relax
-  \ifnum\@tempcnta=0
+  \@hyxmp at count=0\hyxmp at pdfx@major\relax
+  \ifnum\@hyxmp at count=0
   \else
-    \ifnum\@tempcnta=1
+    \ifnum\@hyxmp at count=1
       \hyxmp at add@simple{pdfx:GTS_PDFXVersion}{PDF/X-1:2001}%
       \hyxmp at add@simple{pdfx:GTS_PDFXConformance}{\@pdfxstandard}%
     \else
-      \ifnum\@tempcnta<4
+      \ifnum\@hyxmp at count<4
         \hyxmp at add@simple{pdfx:GTS_PDFXVersion}{\@pdfxstandard}%
       \else
         \hyxmp at add@simple{pdfxid:GTS_PDFXVersion}{\@pdfxstandard}%
@@ -6629,8 +6663,8 @@
 %    \end{macrocode}
 % Declare the schema used in \PDFstd{X}{4}{}{} and later versions.
 %    \begin{macrocode}
-  \@tempcnta=0\hyxmp at pdfx@major\relax
-  \ifnum\@tempcnta>3
+  \@hyxmp at count=0\hyxmp at pdfx@major\relax
+  \ifnum\@hyxmp at count>3
     \hyxmp at begin@ext at decl
         {PDF/X ID Schema}%
         {pdfxid}%
@@ -6958,7 +6992,27 @@
 _____________________xmlns:pdfaid="http://www.aiim.org/pdfa/ns/id/"^^J%
 _____________________xmlns:pdfuaid="http://www.aiim.org/pdfua/ns/id/"^^J%
 _____________________xmlns:pdfx="http://ns.adobe.com/pdfx/1.3/"^^J%
+  }%
+%    \end{macrocode}
+% We make one exception to the rule of including every namespace we can
+% potentially use: We don't define the \texttt{pdfxid} namespace unless
+% the \acro{PDF/X} version (specified by the \optname{pdfxstandard})
+% option is~4 or greater.  Otherwise, Adobe Acrobat---at least Adobe
+% Acrobat DC 2020---alters the way it displays color.  (I believe it
+% renders color in a printer gamut instead of a screen gamut.)
+% \changes{v5.10}{2020/01/05}{Include the \string\texttt{pdfxid} namespace
+%   only if the \protect\acro{PDF/X} version is~4 or greater.  Thanks to
+%   John Lienhard for the bug report}
+%    \begin{macrocode}
+  \ifnum0\hyxmp at pdfx@major>3
+    \hyxmp at add@to at xml{%
 _____________________xmlns:pdfxid="http://www.npes.org/pdfx/ns/id/"^^J%
+    }%
+  \fi
+%    \end{macrocode}
+% Revert to ``include every namespace'' mode.
+%    \begin{macrocode}
+  \hyxmp at add@to at xml{%
 _____________________xmlns:prism="http://prismstandard.org/namespaces/basic/3.0/"^^J%
 _____________________xmlns:jav="http://www.niso.org/schemas/jav/1.0/"^^J%
 _____________________xmlns:xmpTPg="http://ns.adobe.com/xap/1.0/t/pg/"^^J%
@@ -7177,7 +7231,7 @@
     <<
       /Type /Metadata
       /Subtype /XML
-      /Length \the\@tempcnta
+      /Length \the\@hyxmp at count
     >>
     stream^^J\hyxmp at xml endstream%
   }%
@@ -7191,7 +7245,7 @@
 % \end{macro}
 %
 % \begin{macro}{\hyxmp at string@len}
-% Set |\@tempcnta| to the number of characters in a given string~(|#1|).
+% Set |\@hyxmp at count| to the number of characters in a given string~(|#1|).
 % The approach is first to tally the number of space characters then to
 % tally the number of non-space characters.  While this is rather
 % sloppy I haven't found a better way to achieve the same effect,
@@ -7199,7 +7253,7 @@
 % assigned their category codes.
 %    \begin{macrocode}
 \newcommand*{\hyxmp at string@len}[1]{%
-  \@tempcnta=0
+  \@hyxmp at count=0
   \expandafter\hyxmp at count@spaces#1 {} %
   \expandafter\hyxmp at count@non at spaces#1{}%
 }
@@ -7214,9 +7268,9 @@
 \def\hyxmp at count@spaces#1 {%
   \def\hyxmp at one@token{#1}%
   \ifx\hyxmp at one@token\@empty
-    \advance\@tempcnta by -1
+    \advance\@hyxmp at count by -1
   \else
-    \advance\@tempcnta by 1
+    \advance\@hyxmp at count by 1
     \expandafter\hyxmp at count@spaces
   \fi
 }
@@ -7233,7 +7287,7 @@
   \def\hyxmp at one@token{#1}%
   \ifx\hyxmp at one@token\@empty
   \else
-    \advance\@tempcnta by 1
+    \advance\@hyxmp at count by 1
     \expandafter\hyxmp at count@non at spaces
   \fi
 }

Modified: trunk/Master/texmf-dist/source/latex/hyperxmp/hyperxmp.ins
===================================================================
--- trunk/Master/texmf-dist/source/latex/hyperxmp/hyperxmp.ins	2023-02-20 20:59:19 UTC (rev 65979)
+++ trunk/Master/texmf-dist/source/latex/hyperxmp/hyperxmp.ins	2023-02-20 21:00:04 UTC (rev 65980)
@@ -1,5 +1,5 @@
 %%
-%% Copyright (C) 2011-2020 by Scott Pakin <scott+hyxmp at pakin.org>
+%% Copyright (C) 2011-2023 by Scott Pakin <scott+hyxmp at pakin.org>
 %%
 %% This file may be distributed and/or modified under the conditions of
 %% the LaTeX Project Public License, either version 1.3c of this license
@@ -21,7 +21,7 @@
 
 This is a generated file.
 
-Copyright (C) 2011-2020 by Scott Pakin <scott+hyxmp at pakin.org>
+Copyright (C) 2011-2023 by Scott Pakin <scott+hyxmp at pakin.org>
 
 This file may be distributed and/or modified under the conditions of
 the LaTeX Project Public License, either version 1.3c of this license

Modified: trunk/Master/texmf-dist/tex/latex/hyperxmp/hyperxmp.sty
===================================================================
--- trunk/Master/texmf-dist/tex/latex/hyperxmp/hyperxmp.sty	2023-02-20 20:59:19 UTC (rev 65979)
+++ trunk/Master/texmf-dist/tex/latex/hyperxmp/hyperxmp.sty	2023-02-20 21:00:04 UTC (rev 65980)
@@ -8,7 +8,7 @@
 %% 
 %% This is a generated file.
 %% 
-%% Copyright (C) 2011-2020 by Scott Pakin <scott+hyxmp at pakin.org>
+%% Copyright (C) 2011-2023 by Scott Pakin <scott+hyxmp at pakin.org>
 %% 
 %% This file may be distributed and/or modified under the conditions of
 %% the LaTeX Project Public License, either version 1.3c of this license
@@ -22,14 +22,24 @@
 %% 
 \NeedsTeXFormat{LaTeX2e}[1999/12/01]
 \ProvidesPackage{hyperxmp}
-    [2020/11/22 v5.9 Store hyperref metadata in XMP format]
+    [2022/10/16 v5.11 Store hyperref metadata in XMP format]
+\IfDocumentMetadataTF{%
+  \PackageWarning
+      {hyperxmp}
+      {Disabling hyperxmp because it is incompatible with PDF management}
+}{}
+\IfDocumentMetadataTF{\endinput}{}
 \edef\hyxmp at dq@code{\the\catcode`\"}
 \catcode`\"=12
-\@ifundefined{AtEndDocument}{%
-  \RequirePackage{atenddvi}
-  \let\hyxmp at at@end=\AtEndDvi
+\@ifundefined{AddToHook}{%
+  \@ifundefined{AtEndDocument}{%
+    \RequirePackage{atenddvi}
+    \let\hyxmp at at@end=\AtEndDvi
+  }{%
+    \let\hyxmp at at@end=\AtEndDocument
+  }
 }{%
-  \let\hyxmp at at@end=\AtEndDocument
+  \def\hyxmp at at@end{\AddToHook{shipout/lastpage}}
 }
 \def\hyxmp at set@jobname#1\relax{%
   \@ifnextchar"{\hyxmp at set@jobname at dbl}{\hyxmp at set@jobname at plain}#1\relax
@@ -101,10 +111,11 @@
     \PackageWarning{hyperxmp}{pdfapart and pdfuapart must be numeric}%
   }%
 }
+\newcount\@hyxmp at count
 \def\@pdfapart{}
 \define at key{Hyp}{pdfapart}{%
-  \afterassignment\hyxmp at no@bad at parts\@tempcnta=0#1\relax
-  \hyxmp at pdfstringdef\@pdfapart{\the\@tempcnta}%
+  \afterassignment\hyxmp at no@bad at parts\@hyxmp at count=0#1\relax
+  \hyxmp at pdfstringdef\@pdfapart{\the\@hyxmp at count}%
 }
 \def\@pdfaconformance{}
 \define at key{Hyp}{pdfaconformance}{%
@@ -112,16 +123,16 @@
 }
 \def\@pdfuapart{}
 \define at key{Hyp}{pdfuapart}{%
-  \afterassignment\hyxmp at no@bad at parts\@tempcnta=0#1\relax
-  \hyxmp at pdfstringdef\@pdfuapart{\the\@tempcnta}%
+  \afterassignment\hyxmp at no@bad at parts\@hyxmp at count=0#1\relax
+  \hyxmp at pdfstringdef\@pdfuapart{\the\@hyxmp at count}%
 }
 \newcommand*{\hyxmp at set@pdfx at major}[1]{\hyxmp at set@pdfx at major@i#1!}
 \def\hyxmp at set@pdfx at major@i PDF/X-{%
   \afterassignment\hyxmp at set@pdfx at major@ii
-  \@tempcnta=%
+  \@hyxmp at count=%
 }
 \def\hyxmp at set@pdfx at major@ii#1!{%
-  \edef\hyxmp at pdfx@major{\the\@tempcnta}%
+  \edef\hyxmp at pdfx@major{\the\@hyxmp at count}%
 }
 \newcommand*\hyxmp at check@std[2]{%
   \ifthenelse{\equal{#1}{#2}}%
@@ -299,6 +310,7 @@
 }
 \let\hyxmp at ProcessKeyvalOptions=\ProcessKeyvalOptions
 \renewcommand*{\ProcessKeyvalOptions}{%
+  \global\let\ProcessKeyvalOptions=\hyxmp at ProcessKeyvalOptions
   \hyxmp at redefine@Hyp
   \hyxmp at ProcessKeyvalOptions
 }
@@ -501,10 +513,6 @@
   \hyxmp at query@self
 }
 \ifLuaTeX
-\else
-  \RequirePackage{totpages}
-\fi
-\ifLuaTeX
   \begin{luacode*}
 function get_pdf_size (bname)
    local odir = ""
@@ -537,15 +545,10 @@
   }%
 \fi
 \newcommand*{\hyxmp at query@self}{%
-  \ifLuaTeX
-    \@if at def@and at nonempty{@pdfnumpages}{%
-    }{%
-      \clearpage
-      \xdef\@pdfnumpages{\luadirect{tex.print(status.total_pages)}}%
-    }%
-  \else
-    \pdfstringdef\@pdfnumpages{\ref*{TotPages}}%
-  \fi
+  \@if at def@and at nonempty{@pdfnumpages}{%
+  }{%
+    \xdef\@pdfnumpages{\thetotalpages}%
+  }%
   \hyxmp at use@first at valid{pdfbytes}{\@pdfbytes}{%
     \hyxmp at prev@pdf at size
   }%
@@ -820,19 +823,19 @@
   \else
     \xdef#1{#1-\the\day}%
   \fi
-  \@tempcnta=\time
-  \divide\@tempcnta by 60
-  \ifnum\@tempcnta<10
-    \xdef#1{#1T0\the\@tempcnta}%
+  \@hyxmp at count=\time
+  \divide\@hyxmp at count by 60
+  \ifnum\@hyxmp at count<10
+    \xdef#1{#1T0\the\@hyxmp at count}%
   \else
-    \xdef#1{#1T\the\@tempcnta}%
+    \xdef#1{#1T\the\@hyxmp at count}%
   \fi
-  \multiply\@tempcnta by -60
-  \advance\@tempcnta by \time
-  \ifnum\@tempcnta<10
-    \xdef#1{#1:0\the\@tempcnta}%
+  \multiply\@hyxmp at count by -60
+  \advance\@hyxmp at count by \time
+  \ifnum\@hyxmp at count<10
+    \xdef#1{#1:0\the\@hyxmp at count}%
   \else
-    \xdef#1{#1:\the\@tempcnta}%
+    \xdef#1{#1:\the\@hyxmp at count}%
   \fi
   \xdef#1{#1Z}%
 }
@@ -1142,15 +1145,15 @@
   \setkeys{hyxmp at LA}{#2}%
 }
 \def\hyxmp at modulo@a#1{%
-  \@tempcntb=\@tempcnta
+  \@tempcntb=\@hyxmp at count
   \divide\@tempcntb by #1
   \multiply\@tempcntb by #1
-  \advance\@tempcnta by -\@tempcntb
+  \advance\@hyxmp at count by -\@tempcntb
 }
 \def\hyxmp at big@prime{536870923}
 \def\hyxmp at big@prime at ii{536870027}
 \def\hyxmp at seed@rng#1{%
-  \@tempcnta=\hyxmp at big@prime
+  \@hyxmp at count=\hyxmp at big@prime
   \futurelet\hyxmp at one@token\hyxmp at seed@rng at i#1\@empty
 }
 \def\hyxmp at seed@rng at i{%
@@ -1158,8 +1161,8 @@
     \let\next=\relax
   \else
     \def\next##1{%
-      \multiply\@tempcnta by 3
-      \advance\@tempcnta by `##1
+      \multiply\@hyxmp at count by 3
+      \advance\@hyxmp at count by `##1
       \hyxmp at modulo@a{\hyxmp at big@prime}%
       \futurelet\hyxmp at one@token\hyxmp at seed@rng at i
     }%
@@ -1167,21 +1170,21 @@
   \next
 }
 \def\hyxmp at set@rand at num{%
-  \@tempcnta=\hyxmp at rand@num
-  \multiply\@tempcnta by 3
-  \advance\@tempcnta by \hyxmp at big@prime at ii
+  \@hyxmp at count=\hyxmp at rand@num
+  \multiply\@hyxmp at count by 3
+  \advance\@hyxmp at count by \hyxmp at big@prime at ii
   \hyxmp at modulo@a{\hyxmp at big@prime}%
-  \xdef\hyxmp at rand@num{\the\@tempcnta}%
+  \xdef\hyxmp at rand@num{\the\@hyxmp at count}%
 }
 \def\hyxmp at append@hex#1{%
   \hyxmp at set@rand at num
-  \@tempcnta=\hyxmp at rand@num
+  \@hyxmp at count=\hyxmp at rand@num
   \hyxmp at modulo@a{16}%
-  \ifnum\@tempcnta<10
-    \xdef#1{#1\the\@tempcnta}%
+  \ifnum\@hyxmp at count<10
+    \xdef#1{#1\the\@hyxmp at count}%
   \else
-    \advance\@tempcnta by -10
-    \ifcase\@tempcnta
+    \advance\@hyxmp at count by -10
+    \ifcase\@hyxmp at count
       \xdef#1{#1a}%
       \or\xdef#1{#1b}%
       \or\xdef#1{#1c}%
@@ -1210,9 +1213,9 @@
   \hyxmp at append@hex at iii#1%
   \g at addto@macro#1{-}%
   \hyxmp at set@rand at num
-  \@tempcnta=\hyxmp at rand@num
+  \@hyxmp at count=\hyxmp at rand@num
   \hyxmp at modulo@a{4}%
-  \ifcase\@tempcnta
+  \ifcase\@hyxmp at count
     \g at addto@macro#1{8}%
     \or\g at addto@macro#1{9}%
     \or\g at addto@macro#1{a}%
@@ -1227,7 +1230,7 @@
 \newcommand*{\hyxmp at def@DocumentID}{%
   \edef\hyxmp at seed@string{\hyxmp at jobname:\@pdftitle:\@pdfauthor:}%
   \expandafter\hyxmp at seed@rng\expandafter{\hyxmp at seed@string}%
-  \edef\hyxmp at rand@num{\the\@tempcnta}%
+  \edef\hyxmp at rand@num{\the\@hyxmp at count}%
   \hyxmp at create@uuid\hyxmp at DocumentID
 }
 \newcommand*{\hyxmp at def@InstanceID}{%
@@ -1236,12 +1239,12 @@
     \hyxmp at jobname:\@pdftitle:\@pdfauthor:\hyxmp at today@xmp:\hyxmp at seed@string
   }%
   \expandafter\hyxmp at seed@rng\expandafter{\hyxmp at seed@string}%
-  \edef\hyxmp at rand@num{\the\@tempcnta}%
+  \edef\hyxmp at rand@num{\the\@hyxmp at count}%
   \hyxmp at create@uuid\hyxmp at InstanceID
 }
 \newcommand*{\hyxmp at add@to at xml}[1]{%
   \bgroup
-    \@tempcnta=0
+    \@hyxmp at count=0
     \ifhyxmp at unicodetex
       \@tempcntb=65536%
     \else
@@ -1248,9 +1251,9 @@
       \@tempcntb=256%
     \fi
     \loop
-      \lccode\@tempcnta=\@tempcnta
-      \advance\@tempcnta by 1
-      \ifnum\@tempcnta<\@tempcntb
+      \lccode\@hyxmp at count=\@hyxmp at count
+      \advance\@hyxmp at count by 1
+      \ifnum\@hyxmp at count<\@tempcntb
     \repeat
     \lccode`\_=`\ \relax
     \lccode`\^^C=`\,\relax
@@ -1527,14 +1530,14 @@
   \hyxmp at add@simple{pdfuaid:part}{\@pdfuapart}%
 }
 \newcommand*{\hyxmp at pdfx@id at schema}{%
-  \@tempcnta=0\hyxmp at pdfx@major\relax
-  \ifnum\@tempcnta=0
+  \@hyxmp at count=0\hyxmp at pdfx@major\relax
+  \ifnum\@hyxmp at count=0
   \else
-    \ifnum\@tempcnta=1
+    \ifnum\@hyxmp at count=1
       \hyxmp at add@simple{pdfx:GTS_PDFXVersion}{PDF/X-1:2001}%
       \hyxmp at add@simple{pdfx:GTS_PDFXConformance}{\@pdfxstandard}%
     \else
-      \ifnum\@tempcnta<4
+      \ifnum\@hyxmp at count<4
         \hyxmp at add@simple{pdfx:GTS_PDFXVersion}{\@pdfxstandard}%
       \else
         \hyxmp at add@simple{pdfxid:GTS_PDFXVersion}{\@pdfxstandard}%
@@ -1842,8 +1845,8 @@
         {Conformance level of PDF/X standard}%
     \hyxmp at end@ext at decl
   \fi
-  \@tempcnta=0\hyxmp at pdfx@major\relax
-  \ifnum\@tempcnta>3
+  \@hyxmp at count=0\hyxmp at pdfx@major\relax
+  \ifnum\@hyxmp at count>3
     \hyxmp at begin@ext at decl
         {PDF/X ID Schema}%
         {pdfxid}%
@@ -2055,7 +2058,13 @@
 _____________________xmlns:pdfaid="http://www.aiim.org/pdfa/ns/id/"^^J%
 _____________________xmlns:pdfuaid="http://www.aiim.org/pdfua/ns/id/"^^J%
 _____________________xmlns:pdfx="http://ns.adobe.com/pdfx/1.3/"^^J%
+  }%
+  \ifnum0\hyxmp at pdfx@major>3
+    \hyxmp at add@to at xml{%
 _____________________xmlns:pdfxid="http://www.npes.org/pdfx/ns/id/"^^J%
+    }%
+  \fi
+  \hyxmp at add@to at xml{%
 _____________________xmlns:prism="http://prismstandard.org/namespaces/basic/3.0/"^^J%
 _____________________xmlns:jav="http://www.niso.org/schemas/jav/1.0/"^^J%
 _____________________xmlns:xmpTPg="http://ns.adobe.com/xap/1.0/t/pg/"^^J%
@@ -2180,7 +2189,7 @@
     <<
       /Type /Metadata
       /Subtype /XML
-      /Length \the\@tempcnta
+      /Length \the\@hyxmp at count
     >>
     stream^^J\hyxmp at xml endstream%
   }%
@@ -2191,7 +2200,7 @@
   }%
 }
 \newcommand*{\hyxmp at string@len}[1]{%
-  \@tempcnta=0
+  \@hyxmp at count=0
   \expandafter\hyxmp at count@spaces#1 {} %
   \expandafter\hyxmp at count@non at spaces#1{}%
 }
@@ -2198,9 +2207,9 @@
 \def\hyxmp at count@spaces#1 {%
   \def\hyxmp at one@token{#1}%
   \ifx\hyxmp at one@token\@empty
-    \advance\@tempcnta by -1
+    \advance\@hyxmp at count by -1
   \else
-    \advance\@tempcnta by 1
+    \advance\@hyxmp at count by 1
     \expandafter\hyxmp at count@spaces
   \fi
 }
@@ -2208,7 +2217,7 @@
   \def\hyxmp at one@token{#1}%
   \ifx\hyxmp at one@token\@empty
   \else
-    \advance\@tempcnta by 1
+    \advance\@hyxmp at count by 1
     \expandafter\hyxmp at count@non at spaces
   \fi
 }

Modified: trunk/Master/tlpkg/libexec/ctan2tds
===================================================================
--- trunk/Master/tlpkg/libexec/ctan2tds	2023-02-20 20:59:19 UTC (rev 65979)
+++ trunk/Master/tlpkg/libexec/ctan2tds	2023-02-20 21:00:04 UTC (rev 65980)
@@ -1705,6 +1705,7 @@
  'haranoaji'		=> 'POST_preserve_postcode',
  'hmtrump'		=> '&POSThmtrump',
  'hustthesis'		=> '&POSThustthesis',
+ 'hyperxmp'		=> 'POST_do_man',
  'ibygrk'               => '&POSTibygrk',
  'isodoc'		=> '&POSTisodoc',
  'impatient'            => '&POSTimpatient',
@@ -4554,7 +4555,7 @@
       my $platdir = "$TOPDEST/bin/$p";
       &xmkdir ($platdir);
       #
-      if ($p ne "win32") {
+      if ($p !~ /win32|windows/) {
         my $linktarget = "../../$DEST_TREE/scripts/$package/$s";
         &SYSTEM ("ln -s $linktarget $platdir/$linkname");
         #
@@ -4617,7 +4618,7 @@
         # next bit of ugliness: can be better to use the GUI wrapper
         # wrunscript.exe (which only exists in Master/bin/win32) instead
         # of the usual runscript.exe
-        my $w32_wrapper = "$Master/bin/win32/"
+        my $w32_wrapper = "$Master/bin/windows/"
                  . ($s eq "tlcockpit.sh" ? "wrunscript.exe" : "runscript.exe");
         #
         # xx here too, should merge with bin_links in
@@ -5952,7 +5953,7 @@
   &runjob("$CP -r source $DEST/source/fontinst/base");
   &runjob("$CP -r latex/* $DEST/tex/latex/fontinst");
   &runjob("$CP -r inputs/* $DEST/tex/fontinst");
-  print "\t YOU-MUST-DO $package copy fontinst.bat to bin/win32\n";  
+  print "\t YOU-MUST-DO $package copy fontinst.bat to bin/windows\n";  
 }
 
 

@@ -6575,7 +6576,7 @@
   # executables go in both the Master bin dir and the
   # Build linked_scripts dir.  The executables are cherry-picked from
   # ConTeXt's stubs directory.
-  my $w32_bindir = "$TOPDEST/bin/win32";
+  my $w32_bindir = "$TOPDEST/bin/windows";
   &xmkdir ($w32_bindir);
   #
   my $pkg_subdir = "stubs/unix"; # where hans keeps them
@@ -6630,8 +6631,8 @@
   
   chomp (my @platforms = `cd $Master/bin && ls`);  
   for my $p (@platforms) {
-    next if $p eq "win32";  # windows handled separately
-    next if $p eq "man";    # non-platform pain
+    next if $p =~ /win32|windows/;  # windows handled separately
+    next if $p eq "man";            # non-platform pain
     my $platdir = "$TOPDEST/bin/$p";
     &xmkdir ($platdir);
     &SYSTEM ("ln -s $linktarget $platdir/$linkname");
@@ -6839,7 +6840,7 @@
   &xmkdir ("images");
   &SYSTEM ("$MV *.png logo.* images/");
   &SYSTEM ("$MV *.bat epspdf.texlua /tmp/");
-  print "YOU-MUST-DO! update /tmp/$package* into bin/win32, etc.\n";
+  print "YOU-MUST-DO! update /tmp/$package* into bin/windows, etc.\n";
 }
 
 sub POSTexam_zh {
@@ -7194,7 +7195,7 @@
   # But there are enough differences that trying to factor out the
   # commonalities doesn't make sense.  Sigh.
   print "POST$package - user-level executables\n";
-  my $w32_bindir = "$TOPDEST/bin/win32";
+  my $w32_bindir = "$TOPDEST/bin/windows";
   &xmkdir ($w32_bindir);
   #
   my $pkg_subdir = "perl"; # where hans keeps it



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