From eeb7ae4de7332d6c9cd5b58e81748dc9d681887b Mon Sep 17 00:00:00 2001 From: Karl Berry Date: Wed, 10 Nov 2021 15:35:19 +0000 Subject: doc,sync git-svn-id: svn://tug.org/texlive/trunk@61016 c570f23f-e606-0410-a88d-b1316a301751 --- Build/source/build-aux/missing | 2 +- Build/source/build-aux/test-driver | 11 ++-- Build/source/build-aux/ylwrap | 2 +- Build/source/texk/tests/TeXLive/TLUtils.pm | 34 +++++++------ Build/source/texk/web2c/tests/xeteximage.tex | 76 ++++++++++++++++++++++++++++ 5 files changed, 104 insertions(+), 21 deletions(-) create mode 100644 Build/source/texk/web2c/tests/xeteximage.tex (limited to 'Build') diff --git a/Build/source/build-aux/missing b/Build/source/build-aux/missing index 8d0eaad250f..1fe1611f185 100755 --- a/Build/source/build-aux/missing +++ b/Build/source/build-aux/missing @@ -3,7 +3,7 @@ scriptversion=2018-03-07.03; # UTC -# Copyright (C) 1996-2020 Free Software Foundation, Inc. +# Copyright (C) 1996-2021 Free Software Foundation, Inc. # Originally written by Fran,cois Pinard , 1996. # This program is free software; you can redistribute it and/or modify diff --git a/Build/source/build-aux/test-driver b/Build/source/build-aux/test-driver index 9759384aa72..be73b80adf9 100755 --- a/Build/source/build-aux/test-driver +++ b/Build/source/build-aux/test-driver @@ -3,7 +3,7 @@ scriptversion=2018-03-07.03; # UTC -# Copyright (C) 2011-2020 Free Software Foundation, Inc. +# Copyright (C) 2011-2021 Free Software Foundation, Inc. # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -105,8 +105,11 @@ trap "st=130; $do_exit" 2 trap "st=141; $do_exit" 13 trap "st=143; $do_exit" 15 -# Test script is run here. -"$@" >$log_file 2>&1 +# Test script is run here. We create the file first, then append to it, +# to ameliorate tests themselves also writing to the log file. Our tests +# don't, but others can (automake bug#35762). +: >"$log_file" +"$@" >>"$log_file" 2>&1 estatus=$? if test $enable_hard_errors = no && test $estatus -eq 99; then @@ -128,7 +131,7 @@ esac # know whether the test passed or failed simply by looking at the '.log' # file, without the need of also peaking into the corresponding '.trs' # file (automake bug#11814). -echo "$res $test_name (exit status: $estatus)" >>$log_file +echo "$res $test_name (exit status: $estatus)" >>"$log_file" # Report outcome to console. echo "${col}${res}${std}: $test_name" diff --git a/Build/source/build-aux/ylwrap b/Build/source/build-aux/ylwrap index d1533360b6e..e8ec109fa26 100755 --- a/Build/source/build-aux/ylwrap +++ b/Build/source/build-aux/ylwrap @@ -3,7 +3,7 @@ scriptversion=2018-03-07.03; # UTC -# Copyright (C) 1996-2020 Free Software Foundation, Inc. +# Copyright (C) 1996-2021 Free Software Foundation, Inc. # # Written by Tom Tromey . # diff --git a/Build/source/texk/tests/TeXLive/TLUtils.pm b/Build/source/texk/tests/TeXLive/TLUtils.pm index db2ef3421cc..4036f441b38 100644 --- a/Build/source/texk/tests/TeXLive/TLUtils.pm +++ b/Build/source/texk/tests/TeXLive/TLUtils.pm @@ -1,4 +1,3 @@ -# $Id: TLUtils.pm 59259 2021-05-18 21:39:53Z karl $ # TeXLive::TLUtils.pm - the inevitable utilities for TeX Live. # Copyright 2007-2021 Norbert Preining, Reinhard Kotucha # This file is licensed under the GNU General Public License version 2 @@ -6,7 +5,7 @@ package TeXLive::TLUtils; -my $svnrev = '$Revision: 59259 $'; +my $svnrev = '$Revision: 60823 $'; my $_modulerevision = ($svnrev =~ m/: ([0-9]+) /) ? $1 : "unknown"; sub module_revision { return $_modulerevision; } @@ -112,7 +111,7 @@ C - TeX Live infrastructure miscellany TeXLive::TLUtils::report_tlpdb_differences(\%ret); TeXLive::TLUtils::tlnet_disabled_packages($root); TeXLive::TLUtils::mktexupd(); - TeXLive::TLUtils::setup_sys_user_mode($optsref,$tmfc, $tmfsc, $tmfv, $tmfsv); + TeXLive::TLUtils::setup_sys_user_mode($prg,$optsref,$tmfc,$tmfsc,$tmfv,$tmfsv); TeXLive::TLUtils::prepend_own_path(); TeXLive::TLUtils::repository_to_array($str); @@ -1184,14 +1183,14 @@ time stamps are preserved and symlinks are created on Unix systems. On Windows, C<(-l $file)> will never return 'C' and so symlinks will be (uselessly) copied as regular files. -If the argument is C<"-L"> and C<$file> is a symlink, the link is +If the first argument is C<"-L"> and C<$file> is a symlink, the link is dereferenced before the copying is done. (If both C<"-f"> and C<"-L"> -are desired, they must be given in that order, although the current code -has no need to do this.) +are desired, they must be given in that order, although the codebase +currently has no need to do this.) -C invokes C if target directories do not exist. Files -have mode C<0777> if they are executable and C<0666> otherwise, with -the set bits in I cleared in each case. +C invokes C if target directories do not exist. Files +start with mode C<0777> if they are executable and C<0666> otherwise, +with the set bits in I cleared in each case. C<$file> can begin with a C prefix. @@ -1753,7 +1752,7 @@ sub _do_postaction_filetype { } my $cmd = $keyval{'cmd'}; - my $texdir = `kpsewhich -var-value=SELFAUTOPARENT`; + my $texdir = `kpsewhich -var-value=TEXMFROOT`; chomp($texdir); my $texdir_bsl = conv_to_w32_path($texdir); $cmd =~ s!^("?)TEXDIR/!$1$texdir/!g; @@ -1828,7 +1827,7 @@ sub _do_postaction_script { if (win32() && defined($keyval{'filew32'})) { $file = $keyval{'filew32'}; } - my $texdir = `kpsewhich -var-value=SELFAUTOPARENT`; + my $texdir = `kpsewhich -var-value=TEXMFROOT`; chomp($texdir); my @syscmd; if ($file =~ m/\.pl$/i) { @@ -1903,7 +1902,7 @@ sub _do_postaction_shortcut { &log("postaction $how shortcut for " . $tlpobj->name . "\n"); if ($how eq "install") { - my $texdir = `kpsewhich -var-value=SELFAUTOPARENT`; + my $texdir = `kpsewhich -var-value=TEXMFROOT`; chomp($texdir); my $texdir_bsl = conv_to_w32_path($texdir); $icon =~ s!^TEXDIR/!$texdir/!; @@ -4677,9 +4676,14 @@ sub mktexupd { =item C -Return two-element list C<($texmfconfig,$texmfvar)> of which directories -to use, either user or sys. If C<$prg> is C, and the system -dirs are writable, use them even if we are in user mode. +Return two-element list C<($texmfconfig,$texmfvar)> specifying which +directories to use, either user or sys. If C<$optsref->{'sys'}> is +true, we are in sys mode; else if C<$optsref->{'user'}> is set, we are +in user mode; else a fatal error. + +If C<$prg> eq C<"mktexfmt">, and C<$TEXMFSYSVAR/web2c> is writable, use +it instead of C<$TEXMFVAR>, even if we are in user mode. C<$TEXMFCONFIG> +is not switched, however. =cut diff --git a/Build/source/texk/web2c/tests/xeteximage.tex b/Build/source/texk/web2c/tests/xeteximage.tex new file mode 100644 index 00000000000..7657ddf7918 --- /dev/null +++ b/Build/source/texk/web2c/tests/xeteximage.tex @@ -0,0 +1,76 @@ +% $Id$ +% Copyright 2020 Bruno Voisin +% You may freely use, modify and/or distribute this file. +% +\ifx\fmtname\undefined + \input basic + \def\fmtname{basic} + \expandafter\dump +\fi +%================== +\special{pdf:minorversion 7} + +\topskip0pt + +\hbox{\XeTeXpicfile "1-4.jpg" width \hsize height \vsize} +\vfill\eject + +\hbox{\XeTeXpdffile "B.pdf" width \hsize height \vsize} +\vfill\eject + +\hbox{\XeTeXpicfile "lily-ledger-broken.png" width \hsize height \vsize} +\vfill\eject + +\vbox to\vsize{\vfill% + \special{pdf:image + width \the\hsize +% height \the\vsize + (1-4.jpg)}} +\eject + +\vbox to\vsize{\vfill% + \special{pdf:epdf + width \the\hsize +% height \the\vsize + (B.pdf)}} +\eject + +\vbox to\vsize{\vfill% + \special{pdf:image + width \the\hsize +% height \the\vsize + (lily-ledger-broken.png)}} +\eject + +\bye + +Date: Sat, 16 May 2020 01:33:51 +0200 +From: Bruno Voisin via tex-live +To: tex-live@tug.org +Subject: Re: xetex test creation for reading pdf images? + +Here's a (very quickly) hacked adaptation of luaimage.tex to xetex. I commented out the format creation section at the beginning to test on my setup, after downloading + +Build/source/texk/web2c/luatexdir/tests/luaimage.tex + +Build/source/texk/web2c/tests/1-4.jpg +Build/source/texk/web2c/tests/B.pdf +Build/source/texk/web2c/tests/lily-ledger-broken.png + +Two forms of image inclusion commands are used: + +- \XeTeXpicfile and \XeTeXpdffile which are the original XeTeX commands, + +- \special{pdf:image and \special{pdf:epdf which are the (x)dvipdfm(x) specials, + +based on XeTeX-notes.pdf, xetex-reference.pdf, dvipdfm.pdf and dvipdfmx.pdf. + +There are some subtle differences between the two forms, not just their syntax but also the way they work. With the latter, specifying both the width and height in a way that alters the aspect ratio of the image does not seem to work: in this case, the image is nowhere to be seen. + +That's odd, because I looked at the associated xetex.def and dvipdfmx.def from the graphics package for double-checking and inspiration, and there seems to be no trick to deal with this, it seems to be business as usual with \Gin@req@width and \Gin@req@height. + +I won't be able to pursue the matter or maintain this file, it's just to get this thing started. (And I didn't attempt to modify the copyright at the beginning.) + +Bruno Voisin + +untyped binary data, xeteximage.tex [Press RETURN to save to a file] -- cgit v1.2.3