From 301e3f93a270b098802c9781bc3970fbec4c2e84 Mon Sep 17 00:00:00 2001 From: Alexandre Duret-Lutz Date: Tue, 11 Nov 2003 21:08:15 +0000 Subject: [PATCH] * Makefile.am (fetch): Get all files from savannah. Do not postprocess Struct.pm and XFiles.pm, since we now are the master of these. * lib/config.sub, lib/config.guess, lib/config-ml.in, lib/texinfo.tex: New upstream versions. --- ChangeLog | 6 + Makefile.am | 15 +- Makefile.in | 15 +- lib/config-ml.in | 1 + lib/config.guess | 24 ++- lib/config.sub | 29 ++- lib/texinfo.tex | 515 ++++++++++++++++++++++++----------------------- 7 files changed, 331 insertions(+), 274 deletions(-) diff --git a/ChangeLog b/ChangeLog index 38b42d66..5f64c138 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,11 @@ 2003-11-11 Alexandre Duret-Lutz + * Makefile.am (fetch): Get all files from savannah. Do not + postprocess Struct.pm and XFiles.pm, since we now are the master + of these. + * lib/config.sub, lib/config.guess, lib/config-ml.in, + lib/texinfo.tex: New upstream versions. + * configure.ac: Check that autoconf is installed, that it works, and that it is recent enough in three steps, not one. diff --git a/Makefile.am b/Makefile.am index e5cb1d0d..93a15f6d 100644 --- a/Makefile.am +++ b/Makefile.am @@ -276,6 +276,7 @@ path-check: distdir ## Program to use to fetch files. WGET = wget +WGETSGO = $(WGET) http://savannah.gnu.org/cgi-bin/viewcvs/~checkout~ ## Files that we fetch and which we compare against. ## FIXME should be a lot more here @@ -293,14 +294,12 @@ fetch: mkdir Fetchdir ## If a get fails then that is a problem. (cd Fetchdir && \ - $(WGET) ftp://ftp.gnu.org/gnu/config/config.guess; \ - $(WGET) ftp://ftp.gnu.org/gnu/config/config.sub; \ - $(WGET) ftp://ftp.gnu.org/gnu/texinfo/texinfo.tex; \ - $(WGET) http://savannah.gnu.org/cgi-bin/viewcvs/~checkout~/autoconf/autoconf/INSTALL?content-type=text/plain -O INSTALL; \ - $(WGET) http://savannah.gnu.org/cgi-bin/viewcvs/~checkout~/gcc/gcc/config-ml.in; \ - $(WGET) http://savannah.gnu.org/cgi-bin/viewcvs/~checkout~/gcc/gcc/symlink-tree) - perl -pi -e 's/Autom4te::/Automake::/g' \ - Fetchdir/Automake/Struct.pm Fetchdir/Automake/XFile.pm + $(WGETSGO)/config/config/config.guess; \ + $(WGETSGO)/config/config/config.sub; \ + $(WGETSGO)/texinfo/texinfo/doc/texinfo.tex; \ + $(WGETSGO)/autoconf/autoconf/INSTALL; \ + $(WGETSGO)/gcc/gcc/config-ml.in; \ + $(WGETSGO)/gcc/gcc/symlink-tree) ## Don't exit after test because we want to give as many errors as ## possible. @stat=0; for file in $(FETCHFILES); do \ diff --git a/Makefile.in b/Makefile.in index 13b8b1c4..8da0908b 100644 --- a/Makefile.in +++ b/Makefile.in @@ -157,6 +157,7 @@ do_subst = sed -e 's,[@]datadir[@],$(datadir),g' -e 's,[@]PERL[@],$(PERL),g' \ -e 's,[@]SHELL[@],$(SHELL),g' WGET = wget +WGETSGO = $(WGET) http://savannah.gnu.org/cgi-bin/viewcvs/~checkout~ FETCHFILES = \ INSTALL \ config-ml.in \ @@ -764,14 +765,12 @@ fetch: rm -rf Fetchdir > /dev/null 2>&1 mkdir Fetchdir (cd Fetchdir && \ - $(WGET) ftp://ftp.gnu.org/gnu/config/config.guess; \ - $(WGET) ftp://ftp.gnu.org/gnu/config/config.sub; \ - $(WGET) ftp://ftp.gnu.org/gnu/texinfo/texinfo.tex; \ - $(WGET) http://savannah.gnu.org/cgi-bin/viewcvs/~checkout~/autoconf/autoconf/INSTALL?content-type=text/plain -O INSTALL; \ - $(WGET) http://savannah.gnu.org/cgi-bin/viewcvs/~checkout~/gcc/gcc/config-ml.in; \ - $(WGET) http://savannah.gnu.org/cgi-bin/viewcvs/~checkout~/gcc/gcc/symlink-tree) - perl -pi -e 's/Autom4te::/Automake::/g' \ - Fetchdir/Automake/Struct.pm Fetchdir/Automake/XFile.pm + $(WGETSGO)/config/config/config.guess; \ + $(WGETSGO)/config/config/config.sub; \ + $(WGETSGO)/texinfo/texinfo/doc/texinfo.tex; \ + $(WGETSGO)/autoconf/autoconf/INSTALL; \ + $(WGETSGO)/gcc/gcc/config-ml.in; \ + $(WGETSGO)/gcc/gcc/symlink-tree) @stat=0; for file in $(FETCHFILES); do \ if diff -u $(srcdir)/lib/$$file Fetchdir/$$file \ >>Fetchdir/update.patch 2>/dev/null; then :; \ diff --git a/lib/config-ml.in b/lib/config-ml.in index 06752b7a..fb9e050b 100644 --- a/lib/config-ml.in +++ b/lib/config-ml.in @@ -553,6 +553,7 @@ multi-do: LIBCFLAGS="$(LIBCFLAGS) $${flags}" \ LIBCXXFLAGS="$(LIBCXXFLAGS) $${flags}" \ LDFLAGS="$(LDFLAGS) $${flags}" \ + MULTIFLAGS="$${flags}" \ DESTDIR="$(DESTDIR)" \ INSTALL="$(INSTALL)" \ INSTALL_DATA="$(INSTALL_DATA)" \ diff --git a/lib/config.guess b/lib/config.guess index 500ee74b..193e3282 100755 --- a/lib/config.guess +++ b/lib/config.guess @@ -3,7 +3,7 @@ # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, # 2000, 2001, 2002, 2003 Free Software Foundation, Inc. -timestamp='2003-10-03' +timestamp='2003-10-16' # This file is free software; you can redistribute it and/or modify it # under the terms of the GNU General Public License as published by @@ -221,6 +221,9 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in mvmeppc:OpenBSD:*:*) echo powerpc-unknown-openbsd${UNAME_RELEASE} exit 0 ;; + pegasos:OpenBSD:*:*) + echo powerpc-unknown-openbsd${UNAME_RELEASE} + exit 0 ;; pmax:OpenBSD:*:*) echo mipsel-unknown-openbsd${UNAME_RELEASE} exit 0 ;; @@ -307,6 +310,9 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in *:OS/390:*:*) echo i370-ibm-openedition exit 0 ;; + *:OS400:*:*) + echo powerpc-ibm-os400 + exit 0 ;; arm:RISC*:1.[012]*:*|arm:riscix:1.[012]*:*) echo arm-acorn-riscix${UNAME_RELEASE} exit 0;; @@ -742,6 +748,11 @@ EOF FUJITSU_REL=`echo ${UNAME_RELEASE} | sed -e 's/ /_/'` echo "${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" exit 0 ;; + 5000:UNIX_System_V:4.*:*) + FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'` + FUJITSU_REL=`echo ${UNAME_RELEASE} | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/ /_/'` + echo "sparc-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" + exit 0 ;; i*86:BSD/386:*:* | i*86:BSD/OS:*:* | *:Ascend\ Embedded/OS:*:*) echo ${UNAME_MACHINE}-pc-bsdi${UNAME_RELEASE} exit 0 ;; @@ -751,7 +762,7 @@ EOF *:BSD/OS:*:*) echo ${UNAME_MACHINE}-unknown-bsdi${UNAME_RELEASE} exit 0 ;; - *:FreeBSD:*:*|*:GNU/FreeBSD:*:*) + *:FreeBSD:*:*) # Determine whether the default compiler uses glibc. eval $set_cc_for_build sed 's/^ //' << EOF >$dummy.c @@ -763,7 +774,7 @@ EOF #endif EOF eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep ^LIBC=` - # GNU/FreeBSD systems have a "k" prefix to indicate we are using + # GNU/KFreeBSD systems have a "k" prefix to indicate we are using # FreeBSD's kernel, but not the complete OS. case ${LIBC} in gnu) kernel_only='k' ;; esac echo ${UNAME_MACHINE}-unknown-${kernel_only}freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`${LIBC:+-$LIBC} @@ -799,8 +810,13 @@ EOF echo powerpcle-unknown-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` exit 0 ;; *:GNU:*:*) + # the GNU system echo `echo ${UNAME_MACHINE}|sed -e 's,[-/].*$,,'`-unknown-gnu`echo ${UNAME_RELEASE}|sed -e 's,/.*$,,'` exit 0 ;; + *:GNU/*:*:*) + # other systems with GNU libc and userland + echo ${UNAME_MACHINE}-unknown-`echo ${UNAME_SYSTEM} | sed 's,^[^/]*/,,' | tr '[A-Z]' '[a-z]'``echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`-gnu + exit 0 ;; i*86:Minix:*:*) echo ${UNAME_MACHINE}-pc-minix exit 0 ;; @@ -1052,7 +1068,7 @@ EOF exit 0 ;; M68*:*:R3V[567]*:*) test -r /sysV68 && echo 'm68k-motorola-sysv' && exit 0 ;; - 3[34]??:*:4.0:3.0 | 3[34]??A:*:4.0:3.0 | 3[34]??,*:*:4.0:3.0 | 3[34]??/*:*:4.0:3.0 | 4400:*:4.0:3.0 | 4850:*:4.0:3.0 | SKA40:*:4.0:3.0 | SDS2:*:4.0:3.0 | SHG2:*:4.0:3.0) + 3[345]??:*:4.0:3.0 | 3[34]??A:*:4.0:3.0 | 3[34]??,*:*:4.0:3.0 | 3[34]??/*:*:4.0:3.0 | 4400:*:4.0:3.0 | 4850:*:4.0:3.0 | SKA40:*:4.0:3.0 | SDS2:*:4.0:3.0 | SHG2:*:4.0:3.0) OS_REL='' test -r /etc/.relid \ && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid` diff --git a/lib/config.sub b/lib/config.sub index 1f31816b..e1e455b7 100644 --- a/lib/config.sub +++ b/lib/config.sub @@ -3,7 +3,7 @@ # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, # 2000, 2001, 2002, 2003 Free Software Foundation, Inc. -timestamp='2003-08-18' +timestamp='2003-11-03' # This file is (in principle) common to ALL GNU software. # The presence of a machine in this file suggests that SOME GNU software @@ -118,7 +118,8 @@ esac # Here we must recognize all the valid KERNEL-OS combinations. maybe_os=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\2/'` case $maybe_os in - nto-qnx* | linux-gnu* | linux-dietlibc | kfreebsd*-gnu* | netbsd*-gnu* | storm-chaos* | os2-emx* | rtmk-nova*) + nto-qnx* | linux-gnu* | linux-dietlibc | linux-uclibc* | uclinux-uclibc* | uclinux-gnu* | \ + kfreebsd*-gnu* | knetbsd*-gnu* | netbsd*-gnu* | storm-chaos* | os2-emx* | rtmk-nova*) os=-$maybe_os basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'` ;; @@ -743,6 +744,10 @@ case $basic_machine in basic_machine=or32-unknown os=-coff ;; + os400) + basic_machine=powerpc-ibm + os=-os400 + ;; OSE68000 | ose68000) basic_machine=m68000-ericsson os=-ose @@ -963,6 +968,10 @@ case $basic_machine in tower | tower-32) basic_machine=m68k-ncr ;; + tpf) + basic_machine=s390x-ibm + os=-tpf + ;; udi29k) basic_machine=a29k-amd os=-udi @@ -1131,13 +1140,13 @@ case $os in | -aos* \ | -nindy* | -vxsim* | -vxworks* | -ebmon* | -hms* | -mvs* \ | -clix* | -riscos* | -uniplus* | -iris* | -rtu* | -xenix* \ - | -hiux* | -386bsd* | -netbsd* | -openbsd* | -kfreebsd* | -freebsd* | -riscix* \ + | -hiux* | -386bsd* | -knetbsd* | -netbsd* | -openbsd* | -kfreebsd* | -freebsd* | -riscix* \ | -lynxos* | -bosx* | -nextstep* | -cxux* | -aout* | -elf* | -oabi* \ | -ptx* | -coff* | -ecoff* | -winnt* | -domain* | -vsta* \ | -udi* | -eabi* | -lites* | -ieee* | -go32* | -aux* \ | -chorusos* | -chorusrdb* \ | -cygwin* | -pe* | -psos* | -moss* | -proelf* | -rtems* \ - | -mingw32* | -linux-gnu* | -uxpv* | -beos* | -mpeix* | -udk* \ + | -mingw32* | -linux-gnu* | -linux-uclibc* | -uxpv* | -beos* | -mpeix* | -udk* \ | -interix* | -uwin* | -mks* | -rhapsody* | -darwin* | -opened* \ | -openstep* | -oskit* | -conix* | -pw32* | -nonstopux* \ | -storm-chaos* | -tops10* | -tenex* | -tops20* | -its* \ @@ -1182,6 +1191,9 @@ case $os in -opened*) os=-openedition ;; + -os400*) + os=-os400 + ;; -wince*) os=-wince ;; @@ -1225,6 +1237,9 @@ case $os in -sinix*) os=-sysv4 ;; + -tpf*) + os=-tpf + ;; -triton*) os=-sysv3 ;; @@ -1473,9 +1488,15 @@ case $basic_machine in -mvs* | -opened*) vendor=ibm ;; + -os400*) + vendor=ibm + ;; -ptx*) vendor=sequent ;; + -tpf*) + vendor=ibm + ;; -vxsim* | -vxworks* | -windiss*) vendor=wrs ;; diff --git a/lib/texinfo.tex b/lib/texinfo.tex index d5c8121f..2b41c6eb 100644 --- a/lib/texinfo.tex +++ b/lib/texinfo.tex @@ -3,7 +3,7 @@ % Load plain if necessary, i.e., if running under initex. \expandafter\ifx\csname fmtname\endcsname\relax\input plain\fi % -\def\texinfoversion{2003-10-06.08} +\def\texinfoversion{2003-10-29.10} % % Copyright (C) 1985, 1986, 1988, 1990, 1991, 1992, 1993, 1994, 1995, % 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003 Free Software Foundation, Inc. @@ -23,21 +23,16 @@ % to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, % Boston, MA 02111-1307, USA. % -% In other words, you are welcome to use, share and improve this program. -% You are forbidden to forbid anyone else to use, share and improve -% what you give them. Help stamp out software-hoarding! -% +% As a special exception, when this file is read by TeX when processing +% a Texinfo source document, you may use the result without +% restriction. (This has been our intent since Texinfo was invented.) +% % Please try the latest version of texinfo.tex before submitting bug % reports; you can get the latest version from: -% ftp://ftp.gnu.org/gnu/texinfo/texinfo.tex -% (and all GNU mirrors, see http://www.gnu.org/order/ftp.html) +% http://www.gnu.org/software/texinfo/ (the Texinfo home page), or % ftp://tug.org/tex/texinfo.tex -% (and all CTAN mirrors, see http://www.ctan.org), -% and /home/gd/gnu/doc/texinfo.tex on the GNU machines. -% -% The GNU Texinfo home page is http://www.gnu.org/software/texinfo. -% -% The texinfo.tex in any given Texinfo distribution could well be out +% (and all CTAN mirrors, see http://www.ctan.org). +% The texinfo.tex in any given distribution could well be out % of date, so if that's what you're using, please check. % % Send bug reports to bug-texinfo@gnu.org. Please include including a @@ -59,6 +54,9 @@ % It is possible to adapt texinfo.tex for other languages, to some % extent. You can get the existing language-specific files from the % full Texinfo distribution. +% +% The GNU Texinfo home page is http://www.gnu.org/software/texinfo. + \message{Loading texinfo [version \texinfoversion]:} @@ -160,11 +158,6 @@ % \def\gobble#1{} -% True if #1 is the empty string, i.e., called like `\ifempty{}'. -% -\def\ifempty#1{\ifemptyx #1\emptymarkA\emptymarkB}% -\def\ifemptyx#1#2\emptymarkB{\ifx #1\emptymarkA}% - % Hyphenation fixes. \hyphenation{ap-pen-dix} \hyphenation{eshell} @@ -259,7 +252,7 @@ % the page break happens to be in the middle of an example. \shipout\vbox{% % Do this early so pdf references go to the beginning of the page. - \ifpdfmakepagedest \pdfmkdest{\the\pageno}\fi + \ifpdfmakepagedest \pdfdest name{\the\pageno} xyz\fi % \ifcropmarks \vbox to \outervsize\bgroup \hsize = \outerhsize @@ -340,81 +333,82 @@ % the input line (except we remove a trailing comment). #1 should be a % macro which expects an ordinary undelimited TeX argument. % -\def\parsearg#1{% - \let\next = #1% +\def\parsearg{\parseargusing{}} +\def\parseargusing#1#2{% + \def\next{#2}% \begingroup \obeylines - \futurelet\temp\parseargx + #1% + \parseargx } % If the next token is an obeyed space (from an @example environment or % the like), remove it and recurse. Otherwise, we're done. -\def\parseargx{% - % \obeyedspace is defined far below, after the definition of \sepspaces. - \ifx\obeyedspace\temp - \expandafter\parseargdiscardspace +\def\parseargx{\futurelet\temp\parseargy} +\def\parseargy{% + \expandafter\ifx\obeyedspace\temp + \def\temp{\expandafter\parseargx\gobble} \else - \expandafter\parseargline + \def\temp{\parseargline\empty}% Insert the \empty token, see below. \fi + \temp } -% Remove a single space (as the delimiter token to the macro call). -{\obeyspaces % - \gdef\parseargdiscardspace {\futurelet\temp\parseargx}} - {\obeylines % \gdef\parseargline#1^^M{% \endgroup % End of the group started in \parsearg. - % - % First remove any @c comment, then any @comment. - % Result of each macro is put in \toks0. - \argremovec #1\c\relax % - \expandafter\argremovecomment \the\toks0 \comment\relax % - % - % Call the caller's macro, saved as \next in \parsearg. - \expandafter\next\expandafter{\the\toks0}% + \argremovecomment #1\comment\ArgTerm% }% } -% Since all \c{,omment} does is throw away the argument, we can let TeX -% do that for us. The \relax here is matched by the \relax in the call -% in \parseargline; it could be more or less anything, its purpose is -% just to delimit the argument to the \c. -\def\argremovec#1\c#2\relax{\toks0 = {#1}} -\def\argremovecomment#1\comment#2\relax{\toks0 = {#1}} - -% \argremovec{,omment} might leave us with trailing spaces, though; e.g., +% First remove any @comment, then any @c comment. +\def\argremovecomment#1\comment#2\ArgTerm{\argremovec #1\c\ArgTerm} +\def\argremovec#1\c#2\ArgTerm{\removeactivespaces#1\ArgTerm} +% \argremovec might leave us with trailing spaces, though; e.g., % @end itemize @c foo -% will have two active spaces as part of the argument with the -% `itemize'. Here we remove all active spaces from #1, and assign the -% result to \toks0. -% -% This loses if there are any *other* active characters besides spaces -% in the argument -- _ ^ +, for example -- since they get expanded. -% Fortunately, Texinfo does not define any such commands. (If it ever -% does, the catcode of the characters in questionwill have to be changed -% here.) But this means we cannot call \removeactivespaces as part of -% \argremovec{,omment}, since @c uses \parsearg, and thus the argument -% that \parsearg gets might well have any character at all in it. -% -\def\removeactivespaces#1{% - \begingroup - \ignoreactivespaces - \edef\temp{#1}% - \global\toks0 = \expandafter{\temp}% - \endgroup +{\obeyspaces + \gdef\removeactivespaces#1\ArgTerm{\removeactivespacesX#1\RemSpac \RemSpac\ArgTerm} + \gdef\removeactivespacesX#1 \RemSpac{\removeactivespacesY{#1}} +} +\def\removeactivespacesY#1#2\ArgTerm{% + \def\temp{#2}% + \ifx\temp\empty + \let\temp\finishparsearg + \else + \let\temp\removeactivespaces + \fi + \temp #1\ArgTerm } -% Change the active space to expand to nothing. -% -\begingroup +% If a _delimited_ argument is enclosed in braces, they get stripped; so +% to get _exactly_ the rest of the line, we had to prevent such situation. +% We prepended an \empty token at the very beginning and we expand it +% just before passing the control to \next. +% (But first, we have to remove the remaining \RemSpac token.) +\def\finishparsearg#1\RemSpac\ArgTerm{\expandafter\next\expandafter{#1}} + +% Several utility definitions with active space: +{ \obeyspaces - \gdef\ignoreactivespaces{\obeyspaces\let =\empty} -\endgroup + \gdef\obeyedspace{ } + + % Make each space character in the input produce a normal interword + % space in the output. Don't allow a line break at this space, as this + % is used only in environments like @example, where each line of input + % should produce a line of output anyway. + % + \gdef\sepspaces{\obeyspaces\let =\tie} + + % If an index command is used in an @example environment, any spaces + % therein should become regular spaces in the raw index file, not the + % expansion of \tie (\leavevmode \penalty \@M \ ). + \gdef\unsepspaces{\let =\space} +} \def\flushcr{\ifx\par\lisppar \def\next##1{}\else \let\next=\relax \fi \next} + %% These are used to keep @begin/@end levels from running away %% Call \inENV within environments (after a \begingroup) \newif\ifENV \ENVfalse \def\inENV{\ifENV\relax\else\ENVtrue\fi} @@ -436,20 +430,21 @@ % \def\end{\parsearg\endxxx} \def\endxxx #1{% - \removeactivespaces{#1}% - \edef\endthing{\the\toks0}% - % - \expandafter\ifx\csname E\endthing\endcsname\relax - \expandafter\ifx\csname \endthing\endcsname\relax - % There's no \foo, i.e., no ``environment'' foo. - \errhelp = \EMsimple - \errmessage{Undefined command `@end \endthing'}% - \else - \unmatchedenderror\endthing - \fi + \expandafter\ifx\csname E#1\endcsname\relax + \badenderror{#1}% \else % Everything's ok; the right environment has been started. - \csname E\endthing\endcsname + \csname E#1\endcsname + \fi +} + +\def\badenderror#1{% + \expandafter\ifx\csname#1\endcsname\relax + % There's no \foo, i.e., no ``environment'' foo. + \errhelp = \EMsimple + \errmessage{Undefined command `@end #1'}% + \else + \unmatchedenderror{#1}% \fi } @@ -1096,7 +1091,13 @@ where each line of input produces a line of output.} \ifnum\pdftexversion < 14 \else \pdfrefximage \pdflastximage \fi} - \def\pdfmkdest#1{{\normalturnoffactive \pdfdest name{#1} xyz}} + \def\pdfmkdest#1{{% + % We have to set dummies so commands such as @code in a section title + % aren't expanded. + \atdummies + \normalturnoffactive + \pdfdest name{#1} xyz% + }} \def\pdfmkpgn#1{#1} \let\linkcolor = \Blue % was Cyan, but that seems light? \def\endlink{\Black\pdfendlink} @@ -1329,10 +1330,6 @@ where each line of input produces a line of output.} \setfont\textrm\rmshape{10}{\mainmagstep} \setfont\texttt\ttshape{10}{\mainmagstep} \fi -% Instead of cmb10, you may want to use cmbx10. -% cmbx10 is a prettier font on its own, but cmb10 -% looks better when embedded in a line with cmr10 -% (in Bob's opinion). \setfont\textbf\bfshape{10}{\mainmagstep} \setfont\textit\itshape{10}{\mainmagstep} \setfont\textsl\slshape{10}{\mainmagstep} @@ -1343,7 +1340,7 @@ where each line of input produces a line of output.} \font\textsy=cmsy10 scaled \mainmagstep % A few fonts for @defun, etc. -\setfont\defbf\bxshape{10}{\magstep1} %was 1314 +\setfont\defbf\bfshape{10}{\magstep1} \setfont\deftt\ttshape{10}{\magstep1} \def\df{\let\tentt=\deftt \let\tenbf = \defbf \bf} @@ -1514,7 +1511,7 @@ where each line of input produces a line of output.} % Fonts for short table of contents. \setfont\shortcontrm\rmshape{12}{1000} -\setfont\shortcontbf\bxshape{12}{1000} +\setfont\shortcontbf\bfshape{10}{\magstep1} % no cmb12 \setfont\shortcontsl\slshape{12}{1000} \setfont\shortconttt\ttshape{12}{1000} @@ -1747,6 +1744,7 @@ where each line of input produces a line of output.} \def\ii#1{{\it #1}} % italic font % @acronym downcases the argument and prints in smallcaps. +% It would be nicer to go one point size down. \def\acronym#1{{\smallcaps \lowercase{#1}}} % @pounds{} is a sterling sign. @@ -2134,9 +2132,10 @@ where each line of input produces a line of output.} \def\fnitemindex #1{\doind {fn}{\code{#1}}}% \def\vritemindex #1{\doind {vr}{\code{#1}}}% -{\obeyspaces % +{\obeyspaces \gdef\tabley#1#2 #3 #4 #5 #6 #7\endtabley{\endgroup% -\tablez{#1}{#2}{#3}{#4}{#5}{#6}}} +\tablez{#1}{#2}{#3}{#4}{#5}{#6}}% +} \def\tablez #1#2#3#4#5#6{% \aboveenvbreak % @@ -2597,7 +2596,9 @@ width0pt\relax} \fi \def\direntry{\doignore{direntry}} \def\documentdescriptionword{documentdescription} \def\documentdescription{\doignore{documentdescription}} +\def\docbook{\doignore{docbook}} \def\html{\doignore{html}} +\def\ifdocbook{\doignore{ifdocbook}} \def\ifhtml{\doignore{ifhtml}} \def\ifinfo{\doignore{ifinfo}} \def\ifnottex{\doignore{ifnottex}} @@ -3030,6 +3031,7 @@ width0pt\relax} \fi % Assorted special characters. \definedummyword{bullet}% \definedummyword{copyright}% + \definedummyword{registeredsymbol}% \definedummyword{dots}% \definedummyword{enddots}% \definedummyword{equiv}% @@ -3053,12 +3055,6 @@ width0pt\relax} \fi \turnoffmacros } -% If an index command is used in an @example environment, any spaces -% therein should become regular spaces in the raw index file, not the -% expansion of \tie (\leavevmode \penalty \@M \ ). -{\obeyspaces - \gdef\unsepspaces{\obeyspaces\let =\space}} - % \indexnofonts is used when outputting the strings to sort the index % by, and when constructing control sequence names. It eliminates all @@ -3208,7 +3204,7 @@ width0pt\relax} \fi \temp } -% Take care of unwanted page breaks: +% Take care of unwanted page breaks: % % If a skip is the last thing on the list now, preserve it % by backing up by \lastskip, doing the \write, then inserting @@ -3727,7 +3723,10 @@ width0pt\relax} \fi \outer\def\chapter{\parsearg\chapteryyy} \def\chapteryyy#1{\numhead0{#1}} % normally numhead0 calls chapterzzz \def\chapterzzz#1{% - \secno=0 \subsecno=0 \subsubsecno=0 \advance\chapno by 1 + % section resetting is \global in case the chapter is in a group, such + % as an @include file. + \global\secno=0 \global\subsecno=0 \global\subsubsecno=0 + \global\advance\chapno by 1 \message{\putwordChapter\space \the\chapno}% % % Write the actual heading. @@ -3742,7 +3741,8 @@ width0pt\relax} \fi \outer\def\appendix{\parsearg\appendixyyy} \def\appendixyyy#1{\apphead0{#1}} % normally apphead0 calls appendixzzz \def\appendixzzz#1{% - \secno=0 \subsecno=0 \subsubsecno=0 \advance\appendixno by 1 + \global\secno=0 \global\subsecno=0 \global\subsubsecno=0 + \global\advance\appendixno by 1 \def\appendixnum{\putwordAppendix\space \appendixletter}% \message{\appendixnum}% \chapmacro{#1}{Yappendix}{\appendixletter}% @@ -3761,7 +3761,8 @@ width0pt\relax} \fi \outer\def\unnumbered{\parsearg\unnumberedyyy} \def\unnumberedyyy#1{\unnmhead0{#1}} % normally unnmhead0 calls unnumberedzzz \def\unnumberedzzz#1{% - \secno=0 \subsecno=0 \subsubsecno=0 \advance\unnumberedno by 1 + \global\secno=0 \global\subsecno=0 \global\subsubsecno=0 + \global\advance\unnumberedno by 1 % % This used to be simply \message{#1}, but TeX fully expands the % argument to \message. Therefore, if #1 contained @-commands, TeX @@ -3787,7 +3788,7 @@ width0pt\relax} \fi \outer\def\numberedsec{\parsearg\secyyy} \def\secyyy#1{\numhead1{#1}} % normally calls seczzz \def\seczzz#1{% - \subsecno=0 \subsubsecno=0 \advance\secno by 1 + \global\subsecno=0 \global\subsubsecno=0 \global\advance\secno by 1 \sectionheading{#1}{sec}{Ynumbered}{\the\chapno.\the\secno}% } @@ -3795,14 +3796,14 @@ width0pt\relax} \fi \outer\def\appendixsec{\parsearg\appendixsecyyy} \def\appendixsecyyy#1{\apphead1{#1}} % normally calls appendixsectionzzz \def\appendixsectionzzz#1{% - \subsecno=0 \subsubsecno=0 \advance\secno by 1 + \global\subsecno=0 \global\subsubsecno=0 \global\advance\secno by 1 \sectionheading{#1}{sec}{Yappendix}{\appendixletter.\the\secno}% } \outer\def\unnumberedsec{\parsearg\unnumberedsecyyy} \def\unnumberedsecyyy#1{\unnmhead1{#1}} % normally calls unnumberedseczzz \def\unnumberedseczzz#1{% - \subsecno=0 \subsubsecno=0 \advance\secno by 1 + \global\subsecno=0 \global\subsubsecno=0 \global\advance\secno by 1 \sectionheading{#1}{sec}{Ynothing}{\the\unnumberedno.\the\secno}% } @@ -3810,14 +3811,14 @@ width0pt\relax} \fi \outer\def\numberedsubsec{\parsearg\numberedsubsecyyy} \def\numberedsubsecyyy#1{\numhead2{#1}} % normally calls numberedsubseczzz \def\numberedsubseczzz#1{% - \subsubsecno=0 \advance\subsecno by 1 + \global\subsubsecno=0 \global\advance\subsecno by 1 \sectionheading{#1}{subsec}{Ynumbered}{\the\chapno.\the\secno.\the\subsecno}% } \outer\def\appendixsubsec{\parsearg\appendixsubsecyyy} \def\appendixsubsecyyy#1{\apphead2{#1}} % normally calls appendixsubseczzz \def\appendixsubseczzz#1{% - \subsubsecno=0 \advance\subsecno by 1 + \global\subsubsecno=0 \global\advance\subsecno by 1 \sectionheading{#1}{subsec}{Yappendix}% {\appendixletter.\the\secno.\the\subsecno}% } @@ -3825,7 +3826,7 @@ width0pt\relax} \fi \outer\def\unnumberedsubsec{\parsearg\unnumberedsubsecyyy} \def\unnumberedsubsecyyy#1{\unnmhead2{#1}} %normally calls unnumberedsubseczzz \def\unnumberedsubseczzz#1{% - \subsubsecno=0 \advance\subsecno by 1 + \global\subsubsecno=0 \global\advance\subsecno by 1 \sectionheading{#1}{subsec}{Ynothing}% {\the\unnumberedno.\the\secno.\the\subsecno}% } @@ -3834,7 +3835,7 @@ width0pt\relax} \fi \outer\def\numberedsubsubsec{\parsearg\numberedsubsubsecyyy} \def\numberedsubsubsecyyy#1{\numhead3{#1}} % normally numberedsubsubseczzz \def\numberedsubsubseczzz#1{% - \advance\subsubsecno by 1 + \global\advance\subsubsecno by 1 \sectionheading{#1}{subsubsec}{Ynumbered}% {\the\chapno.\the\secno.\the\subsecno.\the\subsubsecno}% } @@ -3842,7 +3843,7 @@ width0pt\relax} \fi \outer\def\appendixsubsubsec{\parsearg\appendixsubsubsecyyy} \def\appendixsubsubsecyyy#1{\apphead3{#1}} % normally appendixsubsubseczzz \def\appendixsubsubseczzz#1{% - \advance\subsubsecno by 1 + \global\advance\subsubsecno by 1 \sectionheading{#1}{subsubsec}{Yappendix}% {\appendixletter.\the\secno.\the\subsecno.\the\subsubsecno}% } @@ -3850,7 +3851,7 @@ width0pt\relax} \fi \outer\def\unnumberedsubsubsec{\parsearg\unnumberedsubsubsecyyy} \def\unnumberedsubsubsecyyy#1{\unnmhead3{#1}} %normally unnumberedsubsubseczzz \def\unnumberedsubsubseczzz#1{% - \advance\subsubsecno by 1 + \global\advance\subsubsecno by 1 \sectionheading{#1}{subsubsec}{Ynothing}% {\the\unnumberedno.\the\secno.\the\subsecno.\the\subsubsecno}% } @@ -3975,9 +3976,8 @@ width0pt\relax} \fi \chapfonts \rm % % Have to define \thissection before calling \donoderef, because the - % xref code eventually uses it, as \Ytitle. On the other hand, it - % has to be called after \pchapsepmacro, or the headline will change - % too soon. + % xref code eventually uses it. On the other hand, it has to be called + % after \pchapsepmacro, or the headline will change too soon. \gdef\thissection{#1}% \gdef\thischaptername{#1}% % @@ -4493,19 +4493,6 @@ width0pt\relax} \fi % have any width. \def\lisppar{\null\endgraf} -% Make each space character in the input produce a normal interword -% space in the output. Don't allow a line break at this space, as this -% is used only in environments like @example, where each line of input -% should produce a line of output anyway. -% -{\obeyspaces % -\gdef\sepspaces{\obeyspaces\let =\tie}} - -% Define \obeyedspace to be our active space, whatever it is. This is -% for use in \parsearg. -{\sepspaces% -\global\let\obeyedspace= } - % This space is always present above and below environments. \newskip\envskipamount \envskipamount = 0pt @@ -4839,7 +4826,7 @@ width0pt\relax} \fi % ignore everything up to the first ^^M, that's the newline at the end % of the @verbatim input line itself. Otherwise we get an extra blank % line in the output. - \gdef\doverbatim#1^^M#2@end verbatim{#2\end{verbatim}}% + \gdef\doverbatim#1^^M#2@end verbatim{#2\end verbatim}% \endgroup % \def\verbatim{% @@ -4960,63 +4947,88 @@ width0pt\relax} \fi \newskip\defargsindent \defargsindent=50pt \newskip\deflastargmargin \deflastargmargin=18pt -\newcount\parencount - % We want ()&[] to print specially on the defun line. % \def\activeparens{% \catcode`\(=\active \catcode`\)=\active - \catcode`\&=\active \catcode`\[=\active \catcode`\]=\active + \catcode`\&=\active } % Make control sequences which act like normal parenthesis chars. \let\lparen = ( \let\rparen = ) -{\activeparens % Now, smart parens don't turn on until &foo (see \amprm) - % Be sure that we always have a definition for `(', etc. For example, % if the fn name has parens in it, \boldbrax will not be in effect yet, % so TeX would otherwise complain about undefined control sequence. -\global\let(=\lparen \global\let)=\rparen -\global\let[=\lbrack \global\let]=\rbrack - -\gdef\functionparens{\boldbrax\let&=\amprm\parencount=0 } -\gdef\boldbrax{\let(=\opnr\let)=\clnr\let[=\lbrb\let]=\rbrb} -% This is used to turn on special parens -% but make & act ordinary (given that it's active). -\gdef\boldbraxnoamp{\let(=\opnr\let)=\clnr\let[=\lbrb\let]=\rbrb\let&=\ampnr} - -% Definitions of (, ) and & used in args for functions. -% This is the definition of ( outside of all parentheses. -\gdef\oprm#1 {{\rm\char`\(}#1 \bf \let(=\opnested - \global\advance\parencount by 1 +{ + \activeparens + \global\let(=\lparen \global\let)=\rparen + \global\let[=\lbrack \global\let]=\rbrack + \global\let& = \& + + \gdef\functionparens{\boldbrax\let&=\amprm} + \gdef\boldbrax{\let(=\opnr\let)=\clnr\let[=\lbrb\let]=\rbrb} } -% -% This is the definition of ( when already inside a level of parens. -\gdef\opnested{\char`\(\global\advance\parencount by 1 } -% -\gdef\clrm{% Print a paren in roman if it is taking us back to depth of 0. - % also in that case restore the outer-level definition of (. - \ifnum \parencount=1 {\rm \char `\)}\sl \let(=\oprm \else \char `\) \fi - \global\advance \parencount by -1 } + +\newcount\parencount + % If we encounter &foo, then turn on ()-hacking afterwards -\gdef\amprm#1 {{\rm\}\let(=\oprm \let)=\clrm\ } -% -\gdef\normalparens{\boldbrax\let&=\ampnr} -} % End of definition inside \activeparens -%% These parens (in \boldbrax) actually are a little bolder than the -%% contained text. This is especially needed for [ and ] -\def\opnr{{\sf\char`\(}\global\advance\parencount by 1 } -\def\clnr{{\sf\char`\)}\global\advance\parencount by -1 } -\let\ampnr = \& -\def\lbrb{{\bf\char`\[}} -\def\rbrb{{\bf\char`\]}} - -% Active &'s sneak into the index arguments, so make sure it's defined. -{ - \catcode`& = \active - \global\let& = \ampnr +\newif\ifampseen +\def\amprm#1 {\ampseentrue{\rm\} } + +\def\parenfont{% + \ifampseen + % At the first level, print parens in roman, + % otherwise use the default font. + \ifnum \parencount=1 \rm \fi + \else + % The \sf parens (in \boldbrax) actually are a little bolder than + % the contained text. This is especially needed for [ and ] . + \sf + \fi +} +\def\infirstlevel#1{% + \ifampseen + \ifnum\parencount=1 + #1% + \fi + \fi +} +\def\bfafterword#1 {#1 \bf} + +\def\opnr{% + \global\advance\parencount by 1 + {\parenfont(}% + \infirstlevel \bfafterword +} +\def\clnr{% + {\parenfont)}% + \infirstlevel \sl + \global\advance\parencount by -1 +} + +\newcount\brackcount +\def\lbrb{% + \global\advance\brackcount by 1 + {\bf[}% +} +\def\rbrb{% + {\bf]}% + \global\advance\brackcount by -1 +} + +\def\checkparencounts{% + \ifnum\parencount=0 \else \badparencount \fi + \ifnum\brackcount=0 \else \badbrackcount \fi +} +\def\badparencount{% + \errmessage{Unbalanced parentheses in @def}% + \global\parencount=0 +} +\def\badbrackcount{% + \errmessage{Unbalanced square braces in @def}% + \global\brackcount=0 } % \defname, which formats the name of the @def (not the args). @@ -5024,39 +5036,35 @@ width0pt\relax} \fi % #2 is the type of definition, such as "Function". % \def\defname#1#2{% - % How we'll output the type name. Putting it in brackets helps - % distinguish it from the body text that may end up on the next line - % just below it. - \ifempty{#2}% - \def\defnametype{}% - \else - \def\defnametype{[\rm #2]}% - \fi - % % Get the values of \leftskip and \rightskip as they were outside the @def... - \dimen2=\leftskip - \advance\dimen2 by -\defbodyindent - % - % Figure out values for the paragraph shape. - \setbox0=\hbox{\hskip \deflastargmargin{\defnametype}}% - \dimen0=\hsize \advance \dimen0 by -\wd0 % compute size for first line - \dimen1=\hsize \advance \dimen1 by -\defargsindent % size for continuations - \parshape 2 0in \dimen0 \defargsindent \dimen1 + \advance\leftskip by -\defbodyindent % - % Output arg 2 ("Function" or some such) but stuck inside a box of - % width 0 so it does not interfere with linebreaking. + % How we'll format the type name. Putting it in brackets helps + % distinguish it from the body text that may end up on the next line + % just below it. + \def\temp{#2}% + \setbox0=\hbox{\kern\deflastargmargin \ifx\temp\empty\else [\rm\temp]\fi} + % + % Figure out line sizes for the paragraph shape. + % The first line needs space for \box0; but if \rightskip is nonzero, + % we need only space for the part of \box0 which exceeds it: + \dimen0=\hsize \advance\dimen0 by -\wd0 \advance\dimen0 by \rightskip + % The continuations: + \dimen2=\hsize \advance\dimen2 by -\defargsindent + % (plain.tex says that \dimen1 should be used only as global.) + \parshape 2 0in \dimen0 \defargsindent \dimen2 + % + % Put the type name to the right margin. \noindent - % - {% Adjust \hsize to exclude the ambient margins, - % so that \rightline will obey them. - \advance \hsize by -\dimen2 - \dimen3 = 0pt % was -1.25pc - \rlap{\rightline{\defnametype\kern\dimen3}}% + \hbox to 0pt{% + \hfil\box0 \kern-\hsize + % \hsize has to be shortened this way: + \kern\leftskip + % Intentionally do not respect \rightskip, since we need the space. }% % % Allow all lines to be underfull without complaint: \tolerance=10000 \hbadness=10000 - \advance\leftskip by -\defbodyindent \exdentamount=\defbodyindent {\df #1}\enskip % output function name % \defunargs will be called next to output the arguments, if any. @@ -5069,19 +5077,21 @@ width0pt\relax} \fi % \def\parsebodycommon#1#2#3{% \begingroup\inENV - % If there are two @def commands in a row, we'll have a \nobreak, - % which is there to keep the function description together with its - % header. But if there's nothing but headers, we need to allow a - % break somewhere. Check for penalty 10002 (inserted by - % \defargscommonending) instead of 10000, since the sectioning - % commands insert a \penalty10000, and we don't want to allow a break - % between a section heading and a defun. - \ifnum\lastpenalty=10002 \penalty2000 \fi - % - % Similarly, after a section heading, do not allow a break. - % But do insert the glue. - \ifnum\lastpenalty<10000 \medbreak - \else \medskip % preceded by discardable penalty, so not a breakpoint + \ifnum\lastpenalty<10000 + \medbreak + \else + % If there are two @def commands in a row, we'll have a \nobreak, + % which is there to keep the function description together with its + % header. But if there's nothing but headers, we need to allow a + % break somewhere. Check for penalty 10002 (inserted by + % \defargscommonending) instead of 10000, since the sectioning + % commands insert a \penalty10000, and we don't want to allow a break + % between a section heading and a defun. + \ifnum\lastpenalty=10002 \penalty2000 \fi + % + % Similarly, after a section heading, do not allow a break. + % But do insert the glue. + \medskip % preceded by discardable penalty, so not a breakpoint \fi % % Define the \E... end token that this defining construct specifies @@ -5098,7 +5108,7 @@ width0pt\relax} \fi \def\defxbodycommon{% % As with \parsebodycommon above, allow line break if we have multiple % x headers in a row. It's not a great place, though. - \ifnum\lastpenalty=10002 \penalty2000 \fi + \ifnum\lastpenalty=10002 \penalty3000 \fi % \begingroup\obeylines } @@ -5258,15 +5268,15 @@ width0pt\relax} \fi {\tensl\hyphenchar\font=0}% #1% {\tensl\hyphenchar\font=45}% -\ifnum\parencount=0 \else \errmessage{Unbalanced parentheses in @def}\fi% + \checkparencounts \defargscommonending } \def\deftypefunargs #1{% % Expand, preventing hyphenation at `-' chars. % Note that groups don't affect changes in \hyphenchar. -% Use \boldbraxnoamp, not \functionparens, so that & is not special. -\boldbraxnoamp +% Use \boldbrax, not \functionparens, so that & is not special. +\boldbrax \tclose{#1}% avoid \code because of side effects on active chars \defargscommonending } @@ -5320,8 +5330,6 @@ width0pt\relax} \fi \def\deftypefnheaderx #1#2#3 #4\relax{% \doind {fn}{\code{#3}}% Make entry in function index \begingroup -\normalparens % notably, turn off `&' magic, which prevents -% at least some C++ text from working \defname {\defheaderxcond#2\relax$.$#3}{#1}% \deftypefunargs {#4}\endgroup % \catcode\equalChar=\other % Turn off change made in \defparsebody @@ -5447,7 +5455,9 @@ width0pt\relax} \fi % First, define the processing that is wanted for arguments of @defvar. % This is actually simple: just print them in roman. % This must expand the args and terminate the paragraph they make up -\def\defvarargs #1{\normalparens #1% +\def\defvarargs #1{% + \boldbrax + #1% \defargscommonending } @@ -5817,12 +5827,16 @@ width0pt\relax} \fi % @alias. % We need some trickery to remove the optional spaces around the equal % sign. Just make them active and then expand them all to nothing. -\def\alias{\begingroup\obeyspaces\parsearg\aliasxxx} +\def\alias{\parseargusing\obeyspaces\aliasxxx} \def\aliasxxx #1{\aliasyyy#1\relax} -\def\aliasyyy #1=#2\relax{\ignoreactivespaces -\edef\next{\global\let\expandafter\noexpand\csname#1\endcsname=% - \expandafter\noexpand\csname#2\endcsname}% -\expandafter\endgroup\next} +\def\aliasyyy #1=#2\relax{% + {% + \expandafter\let\obeyedspace=\empty + \xdef\next{\global\let\makecsname{#1}=\makecsname{#2}}% + }% + \next +} +\def\makecsname#1{\expandafter\noexpand\csname#1\endcsname} \message{cross references,} @@ -5850,7 +5864,7 @@ width0pt\relax} \fi % \def\donoderef#1{% \ifx\lastnode\empty\else - \expandafter\expandafter\expandafter\setref{\lastnode}{#1}% + \setref{\lastnode}{#1}% \global\let\lastnode=\empty \fi } @@ -5866,26 +5880,30 @@ width0pt\relax} \fi % \setref{NAME}{SNT} defines a cross-reference point NAME (a node or an % anchor), namely NAME-title (the corresponding @chapter/etc. name), % NAME-pg (the page number), and NAME-snt (section number and type). -% Called from \foonoderef. +% Called from \donoderef and \anchor. % -% We have to set dummies so commands such as @code in a section title -% aren't expanded. It would be nicer not to expand the titles in the -% first place, but that is hard to do. +% We take care not to fully expand the title, since it may contain +% arbitrary macros. % -% Likewise, use \turnoffactive so that punctuation chars such as underscore +% Use \turnoffactive so that punctuation chars such as underscore % and backslash work in node names. % -\def\setref#1#2{{% - \atdummies +\def\setref#1#2{% \pdfmkdest{#1}% - % \iflinks - \turnoffactive - \dosetq{#1-title}{Ytitle}% - \dosetq{#1-pg}{Ypagenumber}% - \dosetq{#1-snt}{#2}% + {% + \turnoffactive + \edef\writexrdef##1##2{% + \write\auxfile{@xrdef{#1-% #1 of \setref, expanded by the \edef + ##1}{##2}}% these are parameters of \writexrdef + }% + \toks0 = \expandafter{\thissection}% + \immediate \writexrdef{title}{\the\toks0 }% + \immediate \writexrdef{snt}{\csname #2\endcsname}% \Ynumbered etc. + \writexrdef{pg}{\folio}% will be written later, during \shipout + }% \fi -}} +} % @xref, @pxref, and @ref generate cross-references. For \xrefX, #1 is % the node name, #2 the name of the Info cross-reference, #3 the printed @@ -5978,21 +5996,8 @@ width0pt\relax} \fi % \def\xrefprintnodename#1{[#1]} -% \dosetq is called from \setref to do the actual \write (\iflinks). +% Things referred to by \setref. % -\def\dosetq#1#2{% - \edef\next{\write\auxfile{\internalsetq{#1}{#2}}}% - \next -} - -% \internalsetq{foo}{page} expands into -% CHARACTERS @xrdef{foo}{...expansion of \page...} -\def\internalsetq#1#2{@xrdef{#1}{\csname #2\endcsname}} - -% Things to be expanded by \internalsetq. -% -\def\Ypagenumber{\noexpand\folio} -\def\Ytitle{\thissection} \def\Ynothing{} \def\Yomitfromtoc{} \def\Ynumbered{% @@ -6063,6 +6068,8 @@ width0pt\relax} \fi \def\xrdef#1{\expandafter\gdef\csname X#1\endcsname} % Read the last existing aux file, if any. No error if none exists. +% Open the new one. +% \def\readauxfile{\begingroup \catcode`\^^@=\other \catcode`\^^A=\other @@ -6149,8 +6156,10 @@ width0pt\relax} \fi \input \jobname.aux \global\havexrefstrue \fi - % Open the new aux file. TeX will close it automatically at exit. - \openout\auxfile=\jobname.aux + % Open the new aux file right away (otherwise the \immediate's in + % \setref cause spurious terminal output). TeX will close it + % automatically at exit. + \immediate\openout\auxfile=\jobname.aux \endgroup} @@ -6742,3 +6751,9 @@ should work if nowhere else does.} @c time-stamp-format: "%:y-%02m-%02d.%02H" @c time-stamp-end: "}" @c End: + +@c vim:sw=2: + +@ignore + arch-tag: e1b36e32-c96e-4135-a41a-0b2efa2ea115 +@end ignore -- 2.43.5