1
0
mirror of https://git.savannah.gnu.org/git/emacs.git synced 2025-02-07 20:54:32 +00:00

Update from Gnulib by running admin/merge-gnulib

This commit is contained in:
Paul Eggert 2023-08-12 12:50:15 -07:00
parent b66c16c789
commit f3868cb9d1
14 changed files with 371 additions and 164 deletions

View File

@ -4,7 +4,7 @@
# shellcheck disable=SC2006,SC2268 # see below for rationale # shellcheck disable=SC2006,SC2268 # see below for rationale
timestamp='2023-06-23' timestamp='2023-07-20'
# This file is free software; you can redistribute it and/or modify it # 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 # under the terms of the GNU General Public License as published by
@ -976,7 +976,27 @@ EOF
GUESS=$UNAME_MACHINE-unknown-minix GUESS=$UNAME_MACHINE-unknown-minix
;; ;;
aarch64:Linux:*:*) aarch64:Linux:*:*)
GUESS=$UNAME_MACHINE-unknown-linux-$LIBC set_cc_for_build
CPU=$UNAME_MACHINE
LIBCABI=$LIBC
if test "$CC_FOR_BUILD" != no_compiler_found; then
ABI=64
sed 's/^ //' << EOF > "$dummy.c"
#ifdef __ARM_EABI__
#ifdef __ARM_PCS_VFP
ABI=eabihf
#else
ABI=eabi
#endif
#endif
EOF
cc_set_abi=`$CC_FOR_BUILD -E "$dummy.c" 2>/dev/null | grep '^ABI' | sed 's, ,,g'`
eval "$cc_set_abi"
case $ABI in
eabi | eabihf) CPU=armv8l; LIBCABI=$LIBC$ABI ;;
esac
fi
GUESS=$CPU-unknown-linux-$LIBCABI
;; ;;
aarch64_be:Linux:*:*) aarch64_be:Linux:*:*)
UNAME_MACHINE=aarch64_be UNAME_MACHINE=aarch64_be
@ -1042,6 +1062,15 @@ EOF
k1om:Linux:*:*) k1om:Linux:*:*)
GUESS=$UNAME_MACHINE-unknown-linux-$LIBC GUESS=$UNAME_MACHINE-unknown-linux-$LIBC
;; ;;
kvx:Linux:*:*)
GUESS=$UNAME_MACHINE-unknown-linux-$LIBC
;;
kvx:cos:*:*)
GUESS=$UNAME_MACHINE-unknown-cos
;;
kvx:mbr:*:*)
GUESS=$UNAME_MACHINE-unknown-mbr
;;
loongarch32:Linux:*:* | loongarch64:Linux:*:*) loongarch32:Linux:*:* | loongarch64:Linux:*:*)
GUESS=$UNAME_MACHINE-unknown-linux-$LIBC GUESS=$UNAME_MACHINE-unknown-linux-$LIBC
;; ;;

37
build-aux/config.sub vendored
View File

@ -4,7 +4,7 @@
# shellcheck disable=SC2006,SC2268 # see below for rationale # shellcheck disable=SC2006,SC2268 # see below for rationale
timestamp='2023-06-26' timestamp='2023-07-31'
# This file is free software; you can redistribute it and/or modify it # 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 # under the terms of the GNU General Public License as published by
@ -1206,6 +1206,7 @@ case $cpu-$vendor in
| i370 | i*86 | i860 | i960 | ia16 | ia64 \ | i370 | i*86 | i860 | i960 | ia16 | ia64 \
| ip2k | iq2000 \ | ip2k | iq2000 \
| k1om \ | k1om \
| kvx \
| le32 | le64 \ | le32 | le64 \
| lm32 \ | lm32 \
| loongarch32 | loongarch64 \ | loongarch32 | loongarch64 \
@ -1214,31 +1215,7 @@ case $cpu-$vendor in
| m6811 | m68hc11 | m6812 | m68hc12 | m68hcs12x \ | m6811 | m68hc11 | m6812 | m68hc12 | m68hcs12x \
| m88110 | m88k | maxq | mb | mcore | mep | metag \ | m88110 | m88k | maxq | mb | mcore | mep | metag \
| microblaze | microblazeel \ | microblaze | microblazeel \
| mips | mipsbe | mipseb | mipsel | mipsle \ | mips* \
| mips16 \
| mips64 | mips64eb | mips64el \
| mips64octeon | mips64octeonel \
| mips64orion | mips64orionel \
| mips64r5900 | mips64r5900el \
| mips64vr | mips64vrel \
| mips64vr4100 | mips64vr4100el \
| mips64vr4300 | mips64vr4300el \
| mips64vr5000 | mips64vr5000el \
| mips64vr5900 | mips64vr5900el \
| mipsisa32 | mipsisa32el \
| mipsisa32r2 | mipsisa32r2el \
| mipsisa32r3 | mipsisa32r3el \
| mipsisa32r5 | mipsisa32r5el \
| mipsisa32r6 | mipsisa32r6el \
| mipsisa64 | mipsisa64el \
| mipsisa64r2 | mipsisa64r2el \
| mipsisa64r3 | mipsisa64r3el \
| mipsisa64r5 | mipsisa64r5el \
| mipsisa64r6 | mipsisa64r6el \
| mipsisa64sb1 | mipsisa64sb1el \
| mipsisa64sr71k | mipsisa64sr71kel \
| mipsr5900 | mipsr5900el \
| mipstx39 | mipstx39el \
| mmix \ | mmix \
| mn10200 | mn10300 \ | mn10200 | mn10300 \
| moxie \ | moxie \
@ -1733,7 +1710,7 @@ case $os in
| hpux* | unos* | osf* | luna* | dgux* | auroraux* | solaris* \ | hpux* | unos* | osf* | luna* | dgux* | auroraux* | solaris* \
| sym* | plan9* | psp* | sim* | xray* | os68k* | v88r* \ | sym* | plan9* | psp* | sim* | xray* | os68k* | v88r* \
| hiux* | abug | nacl* | netware* | windows* \ | hiux* | abug | nacl* | netware* | windows* \
| os9* | macos* | osx* | ios* \ | os9* | macos* | osx* | ios* | tvos* | watchos* \
| mpw* | magic* | mmixware* | mon960* | lnews* \ | mpw* | magic* | mmixware* | mon960* | lnews* \
| amigaos* | amigados* | msdos* | newsos* | unicos* | aof* \ | amigaos* | amigados* | msdos* | newsos* | unicos* | aof* \
| aos* | aros* | cloudabi* | sortix* | twizzler* \ | aos* | aros* | cloudabi* | sortix* | twizzler* \
@ -1759,7 +1736,7 @@ case $os in
| onefs* | tirtos* | phoenix* | fuchsia* | redox* | bme* \ | onefs* | tirtos* | phoenix* | fuchsia* | redox* | bme* \
| midnightbsd* | amdhsa* | unleashed* | emscripten* | wasi* \ | midnightbsd* | amdhsa* | unleashed* | emscripten* | wasi* \
| nsk* | powerunix* | genode* | zvmoe* | qnx* | emx* | zephyr* \ | nsk* | powerunix* | genode* | zvmoe* | qnx* | emx* | zephyr* \
| fiwix* | mlibc* ) | fiwix* | mlibc* | cos* | mbr* )
;; ;;
# This one is extra strict with allowed versions # This one is extra strict with allowed versions
sco3.2v2 | sco3.2v[4-9]* | sco5v6*) sco3.2v2 | sco3.2v[4-9]* | sco5v6*)
@ -1816,6 +1793,10 @@ case $kernel-$os in
;; ;;
*-eabi* | *-gnueabi*) *-eabi* | *-gnueabi*)
;; ;;
none-coff* | none-elf*)
# None (no kernel, i.e. freestanding / bare metal),
# can be paired with an output format "OS"
;;
-*) -*)
# Blank kernel with real OS is always fine. # Blank kernel with real OS is always fine.
;; ;;

View File

@ -3,7 +3,7 @@
% Load plain if necessary, i.e., if running under initex. % Load plain if necessary, i.e., if running under initex.
\expandafter\ifx\csname fmtname\endcsname\relax\input plain\fi \expandafter\ifx\csname fmtname\endcsname\relax\input plain\fi
% %
\def\texinfoversion{2023-07-02.10} \def\texinfoversion{2023-07-27.21}
% %
% Copyright 1985, 1986, 1988, 1990-2023 Free Software Foundation, Inc. % Copyright 1985, 1986, 1988, 1990-2023 Free Software Foundation, Inc.
% %
@ -426,42 +426,21 @@
} }
% First remove any @comment, then any @c comment. Pass the result on to % First remove any @comment, then any @c comment. Pass the result on to
% \argcheckspaces. % \argremovespace.
\def\argremovecomment#1\comment#2\ArgTerm{\argremovec #1\c\ArgTerm} \def\argremovecomment#1\comment#2\ArgTerm{\argremovec #1\c\ArgTerm}
\def\argremovec#1\c#2\ArgTerm{\argcheckspaces#1\^^M\ArgTerm} \def\argremovec#1\c#2\ArgTerm{\argremovespace#1$ $\ArgTerm}
% \argremovec might leave us with trailing space, though; e.g.,
% Each occurrence of `\^^M' or `<space>\^^M' is replaced by a single space.
%
% \argremovec might leave us with trailing space, e.g.,
% @end itemize @c foo % @end itemize @c foo
% This space token undergoes the same procedure and is eventually removed % Note that the argument cannot contain the TeX $, as its catcode is
% by \finishparsearg. % changed to \other when Texinfo source is read.
% \def\argremovespace#1 $#2\ArgTerm{\finishparsearg#1$\ArgTerm}
\def\argcheckspaces#1\^^M{\argcheckspacesX#1\^^M \^^M}
\def\argcheckspacesX#1 \^^M{\argcheckspacesY#1\^^M}
\def\argcheckspacesY#1\^^M#2\^^M#3\ArgTerm{%
\def\temp{#3}%
\ifx\temp\empty
% Do not use \next, perhaps the caller of \parsearg uses it; reuse \temp:
\let\temp\finishparsearg
\else
\let\temp\argcheckspaces
\fi
% Put the space token in:
\temp#1 #3\ArgTerm
}
% If a _delimited_ argument is enclosed in braces, they get stripped; so % 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. % 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 now, % We prepended an \empty token at the very beginning and we expand it
% just before passing the control to \argtorun. % just before passing the control to \next.
% (Similarly, we have to think about #3 of \argcheckspacesY above: it is % (But first, we have to remove the remaining $ or two.)
% either the null string, or it ends with \^^M---thus there is no danger \def\finishparsearg#1$#2\ArgTerm{\expandafter\argtorun\expandafter{#1}}
% that a pair of braces would be stripped.
%
% But first, we have to remove the trailing space token.
%
\def\finishparsearg#1 \ArgTerm{\expandafter\argtorun\expandafter{#1}}
% \parseargdef - define a command taking an argument on the line % \parseargdef - define a command taking an argument on the line
@ -5575,6 +5554,11 @@ might help (with 'rm \jobname.?? \jobname.??s')%
\newdimen\entryrightmargin \newdimen\entryrightmargin
\entryrightmargin=0pt \entryrightmargin=0pt
% amount to indent subsequent lines in an entry when it spans more than
% one line.
\newdimen\entrycontskip
\entrycontskip=1em
% for PDF output, whether to make the text of the entry a link to the page % for PDF output, whether to make the text of the entry a link to the page
% number. set for @contents and @shortcontents where there is only one % number. set for @contents and @shortcontents where there is only one
% page number. % page number.
@ -5684,25 +5668,30 @@ might help (with 'rm \jobname.?? \jobname.??s')%
\advance\dimen@ii by 1\dimen@i \advance\dimen@ii by 1\dimen@i
\ifdim\wd\boxA > \dimen@ii % If the entry doesn't fit in one line \ifdim\wd\boxA > \dimen@ii % If the entry doesn't fit in one line
\ifdim\dimen@ > 0.8\dimen@ii % due to long index text \ifdim\dimen@ > 0.8\dimen@ii % due to long index text
% Undo changes above
\advance \parfillskip by 0pt minus -1\dimen@i
\advance\dimen@ii by -1\dimen@i
%
% Try to split the text roughly evenly. \dimen@ will be the length of % Try to split the text roughly evenly. \dimen@ will be the length of
% the first line. % the first line.
\dimen@ = 0.7\dimen@ \dimen@ = 0.7\dimen@
\dimen@ii = \hsize \dimen@ii = \hsize
\ifnum\dimen@>\dimen@ii \ifnum\dimen@>\dimen@ii
% If the entry is too long (for example, if it needs more than % If the entry is too long (for example, if it needs more than
% two lines), use all the space in the first line. % two lines), use the same line length for all lines.
\dimen@ = \dimen@ii \dimen@ = \dimen@ii
\else
\advance \dimen@ by 1\rightskip
\fi \fi
\advance\leftskip by 0pt plus 1fill % ragged right \advance\leftskip by 0pt plus 1fill % ragged right
\advance \dimen@ by 1\rightskip
\parshape = 2 0pt \dimen@ 0em \dimen@ii \parshape = 2 0pt \dimen@ 0em \dimen@ii
% Ideally we'd add a finite glue at the end of the first line only, % Ideally we'd add a finite glue at the end of the first line only,
% instead of using \parshape with explicit line lengths, but TeX % instead of using \parshape with explicit line lengths, but TeX
% doesn't seem to provide a way to do such a thing. % doesn't seem to provide a way to do such a thing.
% %
% Indent all lines but the first one. % Indent all lines but the first one.
\advance\leftskip by 1em \advance\leftskip by \entrycontskip
\advance\parindent by -1em \advance\parindent by -\entrycontskip
\fi\fi \fi\fi
\indent % start paragraph \indent % start paragraph
\unhbox\boxA \unhbox\boxA
@ -6721,6 +6710,82 @@ might help (with 'rm \jobname.?? \jobname.??s')%
\input \tocreadfilename \input \tocreadfilename
} }
% process toc file to find the maximum width of the section numbers for
% each chapter
\def\findsecnowidths{%
\begingroup
\setupdatafile
\activecatcodes
\secentryfonts
% Redefinitions
\def\numchapentry##1##2##3##4{%
\def\curchapname{secnowidth-##2}%
\curchapmax=0pt
}%
\let\appentry\numchapentry
%
\def\numsecentry##1##2##3##4{%
\def\cursecname{secnowidth-##2}%
\cursecmax=0pt
%
\setbox0=\hbox{##2}%
\ifdim\wd0>\curchapmax
\curchapmax=\wd0
\expandafter\xdef\csname\curchapname\endcsname{\the\wd0}%
\fi
}%
\let\appsecentry\numsecentry
%
\def\numsubsecentry##1##2##3##4{%
\def\curssecname{secnowidth-##2}%
\curssecmax=0pt
%
\setbox0=\hbox{##2}%
\ifdim\wd0>\cursecmax
\cursecmax=\wd0
\expandafter\xdef\csname\cursecname\endcsname{\the\wd0}%
\fi
}%
\let\appsubsecentry\numsubsecentry
%
\def\numsubsubsecentry##1##2##3##4{%
\setbox0=\hbox{##2}%
\ifdim\wd0>\curssecmax
\curssecmax=\wd0
\expandafter\xdef\csname\curssecname\endcsname{\the\wd0}%
\fi
}%
\let\appsubsubsecentry\numsubsubsecentry
%
% Discard any output by outputting to dummy vbox, in case the toc file
% contains macros that we have not redefined above.
\setbox\dummybox\vbox\bgroup
\input \tocreadfilename\relax
\egroup
\endgroup
}
\newdimen\curchapmax
\newdimen\cursecmax
\newdimen\curssecmax
% set #1 to the maximum section width for #2
\def\retrievesecnowidth#1#2{%
\expandafter\let\expandafter\savedsecnowidth \csname secnowidth-#2\endcsname
\ifx\savedsecnowidth\relax
#1=0pt
\else
#1=\savedsecnowidth
\fi
}
\newdimen\secnowidthchap
\secnowidthchap=0pt
\newdimen\secnowidthsec
\secnowidthsec=0pt
\newdimen\secnowidthssec
\secnowidthssec=0pt
\newskip\contentsrightmargin \contentsrightmargin=1in \newskip\contentsrightmargin \contentsrightmargin=1in
\newcount\savepageno \newcount\savepageno
\newcount\lastnegativepageno \lastnegativepageno = -1 \newcount\lastnegativepageno \lastnegativepageno = -1
@ -6766,6 +6831,7 @@ might help (with 'rm \jobname.?? \jobname.??s')%
\startcontents{\putwordTOC}% \startcontents{\putwordTOC}%
\openin 1 \tocreadfilename\space \openin 1 \tocreadfilename\space
\ifeof 1 \else \ifeof 1 \else
\findsecnowidths
\readtocfile \readtocfile
\fi \fi
\vfill \eject \vfill \eject
@ -6793,6 +6859,7 @@ might help (with 'rm \jobname.?? \jobname.??s')%
\rm \rm
\hyphenpenalty = 10000 \hyphenpenalty = 10000
\advance\baselineskip by 1pt % Open it up a little. \advance\baselineskip by 1pt % Open it up a little.
\extrasecnoskip=0.4pt
\def\numsecentry##1##2##3##4{} \def\numsecentry##1##2##3##4{}
\let\appsecentry = \numsecentry \let\appsecentry = \numsecentry
\let\unnsecentry = \numsecentry \let\unnsecentry = \numsecentry
@ -6828,8 +6895,6 @@ might help (with 'rm \jobname.?? \jobname.??s')%
% This space should be enough, since a single number is .5em, and the % This space should be enough, since a single number is .5em, and the
% widest letter (M) is 1em, at least in the Computer Modern fonts. % widest letter (M) is 1em, at least in the Computer Modern fonts.
% But use \hss just in case. % But use \hss just in case.
% (This space doesn't include the extra space that gets added after
% the label; that gets put in by \shortchapentry above.)
% %
% We'd like to right-justify chapter numbers, but that looks strange % We'd like to right-justify chapter numbers, but that looks strange
% with appendix letters. And right-justifying numbers and % with appendix letters. And right-justifying numbers and
@ -6839,10 +6904,15 @@ might help (with 'rm \jobname.?? \jobname.??s')%
\hbox to 1em{#1\hss}% \hbox to 1em{#1\hss}%
} }
% These macros generate individual entries in the table of contents. % These macros generate individual entries in the table of contents,
% The first argument is the chapter or section name. % and are read in from the *.toc file.
% The last argument is the page number. %
% The arguments in between are the chapter number, section number, ... % The arguments are like:
% \def\numchapentry#1#2#3#4
% #1 - the chapter or section name.
% #2 - section number
% #3 - level of section (e.g "chap", "sec")
% #4 - page number
% Parts, in the main contents. Replace the part number, which doesn't % Parts, in the main contents. Replace the part number, which doesn't
% exist, with an empty box. Let's hope all the numbers have the same width. % exist, with an empty box. Let's hope all the numbers have the same width.
@ -6855,7 +6925,7 @@ might help (with 'rm \jobname.?? \jobname.??s')%
\vskip 0pt plus 5\baselineskip \vskip 0pt plus 5\baselineskip
\penalty-300 \penalty-300
\vskip 0pt plus -5\baselineskip \vskip 0pt plus -5\baselineskip
\dochapentry{\numeralbox\labelspace#1}{}% \dochapentry{#1}{\numeralbox}{}%
} }
% %
% Parts, in the short toc. % Parts, in the short toc.
@ -6866,12 +6936,14 @@ might help (with 'rm \jobname.?? \jobname.??s')%
} }
% Chapters, in the main contents. % Chapters, in the main contents.
\def\numchapentry#1#2#3#4{\dochapentry{#2\labelspace#1}{#4}} \def\numchapentry#1#2#3#4{%
\retrievesecnowidth\secnowidthchap{#2}%
\dochapentry{#1}{#2}{#4}%
}
% Chapters, in the short toc. % Chapters, in the short toc.
% See comments in \dochapentry re vbox and related settings.
\def\shortchapentry#1#2#3#4{% \def\shortchapentry#1#2#3#4{%
\tocentry{\shortchaplabel{#2}\labelspace #1}{#4}% \tocentry{#1}{\shortchaplabel{#2}}{#4}%
} }
% Appendices, in the main contents. % Appendices, in the main contents.
@ -6882,67 +6954,111 @@ might help (with 'rm \jobname.?? \jobname.??s')%
\setbox0 = \hbox{\putwordAppendix{} M}% \setbox0 = \hbox{\putwordAppendix{} M}%
\hbox to \wd0{\putwordAppendix{} #1\hss}} \hbox to \wd0{\putwordAppendix{} #1\hss}}
% %
\def\appentry#1#2#3#4{\dochapentry{\appendixbox{#2}\hskip.7em#1}{#4}} \def\appentry#1#2#3#4{%
\retrievesecnowidth\secnowidthchap{#2}%
\dochapentry{\appendixbox{#2}\hskip.7em#1}{}{#4}%
}
% Unnumbered chapters. % Unnumbered chapters.
\def\unnchapentry#1#2#3#4{\dochapentry{#1}{#4}} \def\unnchapentry#1#2#3#4{\dochapentry{#1}{}{#4}}
\def\shortunnchapentry#1#2#3#4{\tocentry{#1}{#4}} \def\shortunnchapentry#1#2#3#4{\tocentry{#1}{}{#4}}
% Sections. % Sections.
\def\numsecentry#1#2#3#4{\dosecentry{#2\labelspace#1}{#4}} \def\numsecentry#1#2#3#4{\dosecentry{#1}{#2}{#4}}
\def\numsecentry#1#2#3#4{%
\retrievesecnowidth\secnowidthsec{#2}%
\dosecentry{#1}{#2}{#4}%
}
\let\appsecentry=\numsecentry \let\appsecentry=\numsecentry
\def\unnsecentry#1#2#3#4{\dosecentry{#1}{#4}} \def\unnsecentry#1#2#3#4{%
\retrievesecnowidth\secnowidthsec{#2}%
\dosecentry{#1}{}{#4}%
}
% Subsections. % Subsections.
\def\numsubsecentry#1#2#3#4{\dosubsecentry{#2\labelspace#1}{#4}} \def\numsubsecentry#1#2#3#4{%
\retrievesecnowidth\secnowidthssec{#2}%
\dosubsecentry{#1}{#2}{#4}%
}
\let\appsubsecentry=\numsubsecentry \let\appsubsecentry=\numsubsecentry
\def\unnsubsecentry#1#2#3#4{\dosubsecentry{#1}{#4}} \def\unnsubsecentry#1#2#3#4{%
\retrievesecnowidth\secnowidthssec{#2}%
\dosubsecentry{#1}{}{#4}%
}
% And subsubsections. % And subsubsections.
\def\numsubsubsecentry#1#2#3#4{\dosubsubsecentry{#2\labelspace#1}{#4}} \def\numsubsubsecentry#1#2#3#4{\dosubsubsecentry{#1}{#2}{#4}}
\let\appsubsubsecentry=\numsubsubsecentry \let\appsubsubsecentry=\numsubsubsecentry
\def\unnsubsubsecentry#1#2#3#4{\dosubsubsecentry{#1}{#4}} \def\unnsubsubsecentry#1#2#3#4{\dosubsubsecentry{#1}{}{#4}}
% This parameter controls the indentation of the various levels. % This parameter controls the indentation of the various levels.
% Same as \defaultparindent. % Same as \defaultparindent.
\newdimen\tocindent \tocindent = 15pt \newdimen\tocindent \tocindent = 15pt
% Now for the actual typesetting. In all these, #1 is the text and #2 is the % Now for the actual typesetting. In all these, #1 is the text, #2 is
% page number. % a section number if present, and #3 is the page number.
% %
% If the toc has to be broken over pages, we want it to be at chapters % If the toc has to be broken over pages, we want it to be at chapters
% if at all possible; hence the \penalty. % if at all possible; hence the \penalty.
\def\dochapentry#1#2{% \def\dochapentry#1#2#3{%
\penalty-300 \vskip1\baselineskip plus.33\baselineskip minus.25\baselineskip \penalty-300 \vskip1\baselineskip plus.33\baselineskip minus.25\baselineskip
\begingroup \begingroup
% Move the page numbers slightly to the right % Move the page numbers slightly to the right
\advance\entryrightmargin by -0.05em \advance\entryrightmargin by -0.05em
\chapentryfonts \chapentryfonts
\tocentry{#1}{#2}% \extrasecnoskip=0.4em % separate chapter number more
\tocentry{#1}{#2}{#3}%
\endgroup \endgroup
\nobreak\vskip .25\baselineskip plus.1\baselineskip \nobreak\vskip .25\baselineskip plus.1\baselineskip
} }
\def\dosecentry#1#2{\begingroup \def\dosecentry#1#2#3{\begingroup
\secnowidth=\secnowidthchap
\secentryfonts \leftskip=\tocindent \secentryfonts \leftskip=\tocindent
\tocentry{#1}{#2}% \tocentry{#1}{#2}{#3}%
\endgroup} \endgroup}
\def\dosubsecentry#1#2{\begingroup \def\dosubsecentry#1#2#3{\begingroup
\secnowidth=\secnowidthsec
\subsecentryfonts \leftskip=2\tocindent \subsecentryfonts \leftskip=2\tocindent
\tocentry{#1}{#2}% \tocentry{#1}{#2}{#3}%
\endgroup} \endgroup}
\def\dosubsubsecentry#1#2{\begingroup \def\dosubsubsecentry#1#2#3{\begingroup
\secnowidth=\secnowidthssec
\subsubsecentryfonts \leftskip=3\tocindent \subsubsecentryfonts \leftskip=3\tocindent
\tocentry{#1}{#2}% \tocentry{#1}{#2}{#3}%
\endgroup} \endgroup}
% We use the same \entry macro as for the index entries. % Used for the maximum width of a section number so we can align
\let\tocentry = \entry % section titles.
\newdimen\secnowidth
\secnowidth=0pt
\newdimen\extrasecnoskip
\extrasecnoskip=0pt
% Space between chapter (or whatever) number and the title. % \tocentry{TITLE}{SEC NO}{PAGE}
\def\labelspace{\hskip1em \relax} %
\def\tocentry#1#2#3{%
\def\secno{#2}%
\ifx\empty\secno
\entry{#1}{#3}%
\else
\ifdim 0pt=\secnowidth
\setbox0=\hbox{#2\hskip\labelspace\hskip\extrasecnoskip}%
\else
\advance\secnowidth by \labelspace
\advance\secnowidth by \extrasecnoskip
\setbox0=\hbox to \secnowidth{%
#2\hskip\labelspace\hskip\extrasecnoskip\hfill}%
\fi
\entrycontskip=\wd0
\entry{\box0 #1}{#3}%
\fi
}
\newdimen\labelspace
\labelspace=0.6em
\def\chapentryfonts{\secfonts \rm} \def\chapentryfonts{\secfonts \rm}
\def\secentryfonts{\textfonts} \def\secentryfonts{\textfonts}
@ -7787,6 +7903,8 @@ might help (with 'rm \jobname.?? \jobname.??s')%
\tolerance=10000 \hbadness=10000 \tolerance=10000 \hbadness=10000
\exdentamount=\defbodyindent \exdentamount=\defbodyindent
{% {%
\def\^^M{}% for line continuation
%
% defun fonts. We use typewriter by default (used to be bold) because: % defun fonts. We use typewriter by default (used to be bold) because:
% . we're printing identifiers, they should be in tt in principle. % . we're printing identifiers, they should be in tt in principle.
% . in languages with many accents, such as Czech or French, it's % . in languages with many accents, such as Czech or French, it's
@ -7819,6 +7937,7 @@ might help (with 'rm \jobname.?? \jobname.??s')%
% Print arguments. Use slanted for @def*, typewriter for @deftype*. % Print arguments. Use slanted for @def*, typewriter for @deftype*.
\def\defunargs#1{% \def\defunargs#1{%
\bgroup \bgroup
\def\^^M{}% for line continuation
\df \ifdoingtypefn \tt \else \sl \fi \df \ifdoingtypefn \tt \else \sl \fi
\ifflagclear{txicodevaristt}{}% \ifflagclear{txicodevaristt}{}%
{\def\var##1{{\setregularquotes \ttsl ##1}}}% {\def\var##1{{\setregularquotes \ttsl ##1}}}%

View File

@ -92,20 +92,11 @@
# define NOTE_ORDERED false # define NOTE_ORDERED false
#endif #endif
/* Use this to suppress gcc's "...may be used before initialized" warnings. /* Suppress gcc's "...may be used before initialized" warnings,
Beware: The Code argument must not contain commas. */ generated by GCC versions up to at least GCC 13.2. */
#if __GNUC__ + (__GNUC_MINOR__ >= 7) > 4 #if __GNUC__ + (__GNUC_MINOR__ >= 7) > 4
# pragma GCC diagnostic push # pragma GCC diagnostic push
#endif # pragma GCC diagnostic ignored "-Wmaybe-uninitialized"
#ifndef IF_LINT
# if defined GCC_LINT || defined lint
# define IF_LINT(Code) Code
# else
# define IF_LINT(Code) /* empty */
# if __GNUC__ + (__GNUC_MINOR__ >= 7) > 4
# pragma GCC diagnostic ignored "-Wmaybe-uninitialized"
# endif
# endif
#endif #endif
/* /*
@ -388,13 +379,8 @@ diag (OFFSET xoff, OFFSET xlim, OFFSET yoff, OFFSET ylim, bool find_minimal,
and report halfway between our best results so far. */ and report halfway between our best results so far. */
if (c >= ctxt->too_expensive) if (c >= ctxt->too_expensive)
{ {
OFFSET fxybest;
OFFSET fxbest IF_LINT (= 0);
OFFSET bxybest;
OFFSET bxbest IF_LINT (= 0);
/* Find forward diagonal that maximizes X + Y. */ /* Find forward diagonal that maximizes X + Y. */
fxybest = -1; OFFSET fxybest = -1, fxbest;
for (d = fmax; d >= fmin; d -= 2) for (d = fmax; d >= fmin; d -= 2)
{ {
OFFSET x = MIN (fd[d], xlim); OFFSET x = MIN (fd[d], xlim);
@ -412,7 +398,7 @@ diag (OFFSET xoff, OFFSET xlim, OFFSET yoff, OFFSET ylim, bool find_minimal,
} }
/* Find backward diagonal that minimizes X + Y. */ /* Find backward diagonal that minimizes X + Y. */
bxybest = OFFSET_MAX; OFFSET bxybest = OFFSET_MAX, bxbest;
for (d = bmax; d >= bmin; d -= 2) for (d = bmax; d >= bmin; d -= 2)
{ {
OFFSET x = MAX (xoff, bd[d]); OFFSET x = MAX (xoff, bd[d]);

View File

@ -41,6 +41,10 @@
# --avoid=dup \ # --avoid=dup \
# --avoid=fchdir \ # --avoid=fchdir \
# --avoid=fstat \ # --avoid=fstat \
# --avoid=iswblank \
# --avoid=iswctype \
# --avoid=iswdigit \
# --avoid=iswxdigit \
# --avoid=langinfo \ # --avoid=langinfo \
# --avoid=lock \ # --avoid=lock \
# --avoid=mbrtowc \ # --avoid=mbrtowc \
@ -67,6 +71,7 @@
# --avoid=utime-h \ # --avoid=utime-h \
# --avoid=wchar \ # --avoid=wchar \
# --avoid=wcrtomb \ # --avoid=wcrtomb \
# --avoid=wctype \
# --avoid=wctype-h \ # --avoid=wctype-h \
# alignasof \ # alignasof \
# alloca-opt \ # alloca-opt \
@ -658,7 +663,6 @@ GL_GNULIB__EXIT = @GL_GNULIB__EXIT@
GMALLOC_OBJ = @GMALLOC_OBJ@ GMALLOC_OBJ = @GMALLOC_OBJ@
GMP_H = @GMP_H@ GMP_H = @GMP_H@
GNULIBHEADERS_OVERRIDE_WINT_T = @GNULIBHEADERS_OVERRIDE_WINT_T@ GNULIBHEADERS_OVERRIDE_WINT_T = @GNULIBHEADERS_OVERRIDE_WINT_T@
GNULIB_GETTIMEOFDAY = @GNULIB_GETTIMEOFDAY@
GNULIB_WARN_CFLAGS = @GNULIB_WARN_CFLAGS@ GNULIB_WARN_CFLAGS = @GNULIB_WARN_CFLAGS@
GNUSTEP_CFLAGS = @GNUSTEP_CFLAGS@ GNUSTEP_CFLAGS = @GNUSTEP_CFLAGS@
GNU_OBJC_CFLAGS = @GNU_OBJC_CFLAGS@ GNU_OBJC_CFLAGS = @GNU_OBJC_CFLAGS@

View File

@ -143,6 +143,12 @@ _GL_CXXALIAS_SYS (timespec_get, int, (struct timespec *ts, int base));
# if __GLIBC__ >= 2 # if __GLIBC__ >= 2
_GL_CXXALIASWARN (timespec_get); _GL_CXXALIASWARN (timespec_get);
# endif # endif
# elif defined GNULIB_POSIXCHECK
# undef timespec_get
# if HAVE_RAW_DECL_TIMESPEC_GET
_GL_WARN_ON_USE (timespec_get, "timespec_get is unportable - "
"use gnulib module timespec_get for portability");
# endif
# endif # endif
/* Set *TS to the current time resolution, and return BASE. /* Set *TS to the current time resolution, and return BASE.
@ -154,6 +160,12 @@ _GL_FUNCDECL_SYS (timespec_getres, int, (struct timespec *ts, int base)
# endif # endif
_GL_CXXALIAS_SYS (timespec_getres, int, (struct timespec *ts, int base)); _GL_CXXALIAS_SYS (timespec_getres, int, (struct timespec *ts, int base));
_GL_CXXALIASWARN (timespec_getres); _GL_CXXALIASWARN (timespec_getres);
# elif defined GNULIB_POSIXCHECK
# undef timespec_getres
# if HAVE_RAW_DECL_TIMESPEC_GETRES
_GL_WARN_ON_USE (timespec_getres, "timespec_getres is unportable - "
"use gnulib module timespec_getres for portability");
# endif
# endif # endif
/* Return the number of seconds that have elapsed since the Epoch. */ /* Return the number of seconds that have elapsed since the Epoch. */
@ -170,6 +182,12 @@ _GL_CXXALIAS_SYS (time, time_t, (time_t *__tp));
# if __GLIBC__ >= 2 # if __GLIBC__ >= 2
_GL_CXXALIASWARN (time); _GL_CXXALIASWARN (time);
# endif # endif
# elif defined GNULIB_POSIXCHECK
# undef time
# if HAVE_RAW_DECL_TIME
_GL_WARN_ON_USE (time, "time has consistency problems - "
"use gnulib module time for portability");
# endif
# endif # endif
/* Sleep for at least RQTP seconds unless interrupted, If interrupted, /* Sleep for at least RQTP seconds unless interrupted, If interrupted,
@ -195,6 +213,12 @@ _GL_CXXALIAS_SYS (nanosleep, int,
(struct timespec const *__rqtp, struct timespec *__rmtp)); (struct timespec const *__rqtp, struct timespec *__rmtp));
# endif # endif
_GL_CXXALIASWARN (nanosleep); _GL_CXXALIASWARN (nanosleep);
# elif defined GNULIB_POSIXCHECK
# undef nanosleep
# if HAVE_RAW_DECL_NANOSLEEP
_GL_WARN_ON_USE (nanosleep, "nanosleep is unportable - "
"use gnulib module nanosleep for portability");
# endif
# endif # endif
/* Initialize time conversion information. */ /* Initialize time conversion information. */
@ -230,6 +254,12 @@ _GL_CXXALIAS_MDA (tzset, void, (void));
_GL_CXXALIAS_SYS (tzset, void, (void)); _GL_CXXALIAS_SYS (tzset, void, (void));
# endif # endif
_GL_CXXALIASWARN (tzset); _GL_CXXALIASWARN (tzset);
# elif defined GNULIB_POSIXCHECK
# undef tzset
# if HAVE_RAW_DECL_TZSET
_GL_WARN_ON_USE (tzset, "tzset has portability problems - "
"use gnulib module tzset for portability");
# endif
# endif # endif
/* Return the 'time_t' representation of TP and normalize TP. */ /* Return the 'time_t' representation of TP and normalize TP. */
@ -246,6 +276,12 @@ _GL_CXXALIAS_SYS (mktime, time_t, (struct tm *__tp));
# if __GLIBC__ >= 2 # if __GLIBC__ >= 2
_GL_CXXALIASWARN (mktime); _GL_CXXALIASWARN (mktime);
# endif # endif
# elif defined GNULIB_POSIXCHECK
# undef mktime
# if HAVE_RAW_DECL_MKTIME
_GL_WARN_ON_USE (mktime, "mktime has portability problems - "
"use gnulib module mktime for portability");
# endif
# endif # endif
/* Convert TIMER to RESULT, assuming local time and UTC respectively. See /* Convert TIMER to RESULT, assuming local time and UTC respectively. See
@ -296,6 +332,17 @@ _GL_CXXALIAS_SYS (gmtime_r, struct tm *, (time_t const *restrict __timer,
# if @HAVE_DECL_LOCALTIME_R@ # if @HAVE_DECL_LOCALTIME_R@
_GL_CXXALIASWARN (gmtime_r); _GL_CXXALIASWARN (gmtime_r);
# endif # endif
# elif defined GNULIB_POSIXCHECK
# undef localtime_r
# if HAVE_RAW_DECL_LOCALTIME_R
_GL_WARN_ON_USE (localtime_r, "localtime_r is unportable - "
"use gnulib module time_r for portability");
# endif
# undef gmtime_r
# if HAVE_RAW_DECL_GMTIME_R
_GL_WARN_ON_USE (gmtime_r, "gmtime_r is unportable - "
"use gnulib module time_r for portability");
# endif
# endif # endif
/* Convert TIMER to RESULT, assuming local time and UTC respectively. See /* Convert TIMER to RESULT, assuming local time and UTC respectively. See
@ -316,6 +363,12 @@ _GL_CXXALIAS_SYS (localtime, struct tm *, (time_t const *__timer));
# if __GLIBC__ >= 2 # if __GLIBC__ >= 2
_GL_CXXALIASWARN (localtime); _GL_CXXALIASWARN (localtime);
# endif # endif
# elif defined GNULIB_POSIXCHECK
# undef localtime
# if HAVE_RAW_DECL_LOCALTIME
_GL_WARN_ON_USE (localtime, "localtime has portability problems - "
"use gnulib module localtime for portability");
# endif
# endif # endif
# if 0 || @REPLACE_GMTIME@ # if 0 || @REPLACE_GMTIME@
@ -347,6 +400,12 @@ _GL_CXXALIAS_SYS (strptime, char *, (char const *restrict __buf,
char const *restrict __format, char const *restrict __format,
struct tm *restrict __tm)); struct tm *restrict __tm));
_GL_CXXALIASWARN (strptime); _GL_CXXALIASWARN (strptime);
# elif defined GNULIB_POSIXCHECK
# undef strptime
# if HAVE_RAW_DECL_STRPTIME
_GL_WARN_ON_USE (strptime, "strptime is unportable - "
"use gnulib module strptime for portability");
# endif
# endif # endif
/* Convert *TP to a date and time string. See /* Convert *TP to a date and time string. See
@ -368,6 +427,12 @@ _GL_CXXALIAS_SYS (ctime, char *, (time_t const *__tp));
# if __GLIBC__ >= 2 # if __GLIBC__ >= 2
_GL_CXXALIASWARN (ctime); _GL_CXXALIASWARN (ctime);
# endif # endif
# elif defined GNULIB_POSIXCHECK
# undef ctime
# if HAVE_RAW_DECL_CTIME
_GL_WARN_ON_USE (ctime, "ctime has portability problems - "
"use gnulib module ctime for portability");
# endif
# endif # endif
/* Convert *TP to a date and time string. See /* Convert *TP to a date and time string. See
@ -392,6 +457,12 @@ _GL_CXXALIAS_SYS (strftime, size_t,
# if __GLIBC__ >= 2 # if __GLIBC__ >= 2
_GL_CXXALIASWARN (strftime); _GL_CXXALIASWARN (strftime);
# endif # endif
# elif defined GNULIB_POSIXCHECK
# undef strftime
# if HAVE_RAW_DECL_STRFTIME
_GL_WARN_ON_USE (strftime, "strftime has portability problems - "
"use gnulib module strftime-fixes for portability");
# endif
# endif # endif
# if defined _GNU_SOURCE && @GNULIB_TIME_RZ@ && ! @HAVE_TIMEZONE_T@ # if defined _GNU_SOURCE && @GNULIB_TIME_RZ@ && ! @HAVE_TIMEZONE_T@
@ -469,6 +540,12 @@ _GL_CXXALIAS_SYS (timegm, time_t, (struct tm *__tm));
# if __GLIBC__ >= 2 # if __GLIBC__ >= 2
_GL_CXXALIASWARN (timegm); _GL_CXXALIASWARN (timegm);
# endif # endif
# elif defined GNULIB_POSIXCHECK
# undef timegm
# if HAVE_RAW_DECL_TIMEGM
_GL_WARN_ON_USE (timegm, "timegm is unportable - "
"use gnulib module timegm for portability");
# endif
# endif # endif
/* Encourage applications to avoid unsafe functions that can overrun /* Encourage applications to avoid unsafe functions that can overrun
@ -476,8 +553,10 @@ _GL_CXXALIASWARN (timegm);
applications should use strftime (or even sprintf) instead. */ applications should use strftime (or even sprintf) instead. */
# if defined GNULIB_POSIXCHECK # if defined GNULIB_POSIXCHECK
# undef asctime # undef asctime
# if HAVE_RAW_DECL_ASCTIME
_GL_WARN_ON_USE (asctime, "asctime can overrun buffers in some cases - " _GL_WARN_ON_USE (asctime, "asctime can overrun buffers in some cases - "
"better use strftime (or even sprintf) instead"); "better use strftime (or even sprintf) instead");
# endif
# endif # endif
# if defined GNULIB_POSIXCHECK # if defined GNULIB_POSIXCHECK
# undef asctime_r # undef asctime_r
@ -488,8 +567,10 @@ _GL_WARN_ON_USE (asctime_r, "asctime_r can overrun buffers in some cases - "
# endif # endif
# if defined GNULIB_POSIXCHECK # if defined GNULIB_POSIXCHECK
# undef ctime # undef ctime
# if HAVE_RAW_DECL_CTIME
_GL_WARN_ON_USE (ctime, "ctime can overrun buffers in some cases - " _GL_WARN_ON_USE (ctime, "ctime can overrun buffers in some cases - "
"better use strftime (or even sprintf) instead"); "better use strftime (or even sprintf) instead");
# endif
# endif # endif
# if defined GNULIB_POSIXCHECK # if defined GNULIB_POSIXCHECK
# undef ctime_r # undef ctime_r

View File

@ -1,4 +1,4 @@
# clock_time.m4 serial 12 # clock_time.m4 serial 13
dnl Copyright (C) 2002-2006, 2009-2023 Free Software Foundation, Inc. dnl Copyright (C) 2002-2006, 2009-2023 Free Software Foundation, Inc.
dnl This file is free software; the Free Software Foundation dnl This file is free software; the Free Software Foundation
dnl gives unlimited permission to copy and/or distribute it, dnl gives unlimited permission to copy and/or distribute it,
@ -12,9 +12,17 @@ dnl with or without modifications, as long as this notice is preserved.
AC_DEFUN([gl_CLOCK_TIME], AC_DEFUN([gl_CLOCK_TIME],
[ [
AC_REQUIRE([AC_CANONICAL_HOST])
dnl Persuade glibc and Solaris <time.h> to declare these functions. dnl Persuade glibc and Solaris <time.h> to declare these functions.
AC_REQUIRE([gl_USE_SYSTEM_EXTENSIONS]) AC_REQUIRE([gl_USE_SYSTEM_EXTENSIONS])
# On mingw, these functions are defined in the libwinpthread library,
# which is better avoided. In fact, the clock_gettime function is buggy
# in 32-bit mingw, when -D__MINGW_USE_VC2005_COMPAT is used (which Gnulib's
# year2038 module does): It leaves the upper 32 bits of the tv_sec field
# of the result uninitialized.
# Solaris 2.5.1 needs -lposix4 to get the clock_gettime function. # Solaris 2.5.1 needs -lposix4 to get the clock_gettime function.
# Solaris 7 prefers the library name -lrt to the obsolescent name -lposix4. # Solaris 7 prefers the library name -lrt to the obsolescent name -lposix4.
@ -23,12 +31,22 @@ AC_DEFUN([gl_CLOCK_TIME],
# library, inducing unnecessary run-time overhead. # library, inducing unnecessary run-time overhead.
CLOCK_TIME_LIB= CLOCK_TIME_LIB=
AC_SUBST([CLOCK_TIME_LIB]) AC_SUBST([CLOCK_TIME_LIB])
gl_saved_libs=$LIBS case "$host_os" in
AC_SEARCH_LIBS([clock_gettime], [rt posix4], mingw*)
[test "$ac_cv_search_clock_gettime" = "none required" || ac_cv_func_clock_getres=no
CLOCK_TIME_LIB=$ac_cv_search_clock_gettime]) ac_cv_func_clock_gettime=no
AC_CHECK_FUNCS([clock_getres clock_gettime clock_settime]) ac_cv_func_clock_settime=no
LIBS=$gl_saved_libs ;;
*)
gl_saved_libs=$LIBS
AC_SEARCH_LIBS([clock_gettime], [rt posix4],
[test "$ac_cv_search_clock_gettime" = "none required" ||
CLOCK_TIME_LIB=$ac_cv_search_clock_gettime])
AC_CHECK_FUNCS([clock_getres clock_gettime clock_settime])
LIBS=$gl_saved_libs
;;
esac
# For backward compatibility. # For backward compatibility.
LIB_CLOCK_GETTIME="$CLOCK_TIME_LIB" LIB_CLOCK_GETTIME="$CLOCK_TIME_LIB"
AC_SUBST([LIB_CLOCK_GETTIME]) AC_SUBST([LIB_CLOCK_GETTIME])

View File

@ -1,4 +1,4 @@
# serial 37 # serial 38
dnl Copyright (C) 2002-2003, 2005-2007, 2009-2023 Free Software Foundation, dnl Copyright (C) 2002-2003, 2005-2007, 2009-2023 Free Software Foundation,
dnl Inc. dnl Inc.
dnl This file is free software; the Free Software Foundation dnl This file is free software; the Free Software Foundation
@ -280,7 +280,6 @@ AC_DEFUN([gl_FUNC_MKTIME],
AC_REQUIRE([AC_CANONICAL_HOST]) AC_REQUIRE([AC_CANONICAL_HOST])
AC_REQUIRE([gl_FUNC_MKTIME_WORKS]) AC_REQUIRE([gl_FUNC_MKTIME_WORKS])
REPLACE_MKTIME=0
if test "$gl_cv_func_working_mktime" != yes; then if test "$gl_cv_func_working_mktime" != yes; then
REPLACE_MKTIME=1 REPLACE_MKTIME=1
AC_DEFINE([NEED_MKTIME_WORKING], [1], AC_DEFINE([NEED_MKTIME_WORKING], [1],

View File

@ -1,4 +1,4 @@
# serial 43 # serial 44
dnl From Jim Meyering. dnl From Jim Meyering.
dnl Check for the nanosleep function. dnl Check for the nanosleep function.
@ -126,9 +126,7 @@ AC_DEFUN([gl_FUNC_NANOSLEEP],
]) ])
]) ])
case "$gl_cv_func_nanosleep" in case "$gl_cv_func_nanosleep" in
*yes) *yes) ;;
REPLACE_NANOSLEEP=0
;;
*) *)
REPLACE_NANOSLEEP=1 REPLACE_NANOSLEEP=1
case "$gl_cv_func_nanosleep" in case "$gl_cv_func_nanosleep" in

View File

@ -68,8 +68,10 @@ AC_DEFUN([gl_ALIGNASOF],
dnl The "zz" puts this toward config.h's end, to avoid potential dnl The "zz" puts this toward config.h's end, to avoid potential
dnl collisions with other definitions. dnl collisions with other definitions.
AH_VERBATIM([zzalignas], AH_VERBATIM([zzalignas],
[#if !defined HAVE_C_ALIGNASOF && __cplusplus < 201103 && !defined alignof [#if !defined HAVE_C_ALIGNASOF \
# if HAVE_STDALIGN_H && !(defined __cplusplus && 201103 <= __cplusplus) \
&& !defined alignof
# if defined HAVE_STDALIGN_H
# include <stdalign.h> # include <stdalign.h>
# endif # endif
@ -166,7 +168,7 @@ AC_DEFUN([gl_ALIGNASOF],
# define _Alignas(a) __declspec (align (a)) # define _Alignas(a) __declspec (align (a))
# endif # endif
# endif # endif
# if !HAVE_STDALIGN_H # if !defined HAVE_STDALIGN_H
# if ((defined _Alignas \ # if ((defined _Alignas \
&& !(defined __cplusplus \ && !(defined __cplusplus \
&& (201103 <= __cplusplus || defined _MSC_VER))) \ && (201103 <= __cplusplus || defined _MSC_VER))) \
@ -175,7 +177,7 @@ AC_DEFUN([gl_ALIGNASOF],
# endif # endif
# endif # endif
# if _GL_STDALIGN_NEEDS_STDDEF # if defined _GL_STDALIGN_NEEDS_STDDEF
# include <stddef.h> # include <stddef.h>
# endif # endif
#endif]) #endif])

View File

@ -2,7 +2,7 @@
# Copyright (C) 2000-2001, 2003-2007, 2009-2023 Free Software Foundation, Inc. # Copyright (C) 2000-2001, 2003-2007, 2009-2023 Free Software Foundation, Inc.
# serial 22 # serial 24
# This file is free software; the Free Software Foundation # This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it, # gives unlimited permission to copy and/or distribute it,
@ -23,7 +23,10 @@ AC_DEFUN_ONCE([gl_TIME_H],
dnl corresponding gnulib module is not in use. dnl corresponding gnulib module is not in use.
gl_WARN_ON_USE_PREPARE([[ gl_WARN_ON_USE_PREPARE([[
#include <time.h> #include <time.h>
]], [asctime_r ctime_r]) ]], [
asctime asctime_r ctime ctime_r gmtime_r localtime localtime_r mktime
nanosleep strftime strptime time timegm timespec_get timespec_getres tzset
])
AC_REQUIRE([AC_C_RESTRICT]) AC_REQUIRE([AC_C_RESTRICT])
@ -162,25 +165,15 @@ AC_DEFUN([gl_TIME_H_DEFAULTS],
HAVE_TIMESPEC_GETRES=1; AC_SUBST([HAVE_TIMESPEC_GETRES]) HAVE_TIMESPEC_GETRES=1; AC_SUBST([HAVE_TIMESPEC_GETRES])
dnl Even GNU libc does not have timezone_t yet. dnl Even GNU libc does not have timezone_t yet.
HAVE_TIMEZONE_T=0; AC_SUBST([HAVE_TIMEZONE_T]) HAVE_TIMEZONE_T=0; AC_SUBST([HAVE_TIMEZONE_T])
dnl If another module says to replace or to not replace, do that. REPLACE_CTIME=0; AC_SUBST([REPLACE_CTIME])
dnl Otherwise, replace only if someone compiles with -DGNULIB_PORTCHECK;
dnl this lets maintainers check for portability.
REPLACE_CTIME=GNULIB_PORTCHECK; AC_SUBST([REPLACE_CTIME])
REPLACE_LOCALTIME_R=GNULIB_PORTCHECK; AC_SUBST([REPLACE_LOCALTIME_R])
REPLACE_MKTIME=GNULIB_PORTCHECK; AC_SUBST([REPLACE_MKTIME])
REPLACE_NANOSLEEP=GNULIB_PORTCHECK; AC_SUBST([REPLACE_NANOSLEEP])
REPLACE_STRFTIME=GNULIB_PORTCHECK; AC_SUBST([REPLACE_STRFTIME])
REPLACE_TIME=0; AC_SUBST([REPLACE_TIME])
REPLACE_TIMEGM=GNULIB_PORTCHECK; AC_SUBST([REPLACE_TIMEGM])
REPLACE_TIMESPEC_GET=GNULIB_PORTCHECK; AC_SUBST([REPLACE_TIMESPEC_GET])
REPLACE_TZSET=GNULIB_PORTCHECK; AC_SUBST([REPLACE_TZSET])
dnl Hack so that the time module doesn't depend on the sys_time module.
dnl First, default GNULIB_GETTIMEOFDAY to 0 if sys_time is absent.
: ${GNULIB_GETTIMEOFDAY=0}; AC_SUBST([GNULIB_GETTIMEOFDAY])
dnl Second, it's OK to not use GNULIB_PORTCHECK for REPLACE_GMTIME
dnl and REPLACE_LOCALTIME, as portability to Solaris 2.6 and earlier
dnl is no longer a big deal.
REPLACE_GMTIME=0; AC_SUBST([REPLACE_GMTIME]) REPLACE_GMTIME=0; AC_SUBST([REPLACE_GMTIME])
REPLACE_LOCALTIME=0; AC_SUBST([REPLACE_LOCALTIME]) REPLACE_LOCALTIME=0; AC_SUBST([REPLACE_LOCALTIME])
REPLACE_LOCALTIME_R=0; AC_SUBST([REPLACE_LOCALTIME_R])
REPLACE_MKTIME=0; AC_SUBST([REPLACE_MKTIME])
REPLACE_NANOSLEEP=0; AC_SUBST([REPLACE_NANOSLEEP])
REPLACE_STRFTIME=0; AC_SUBST([REPLACE_STRFTIME])
REPLACE_TIME=0; AC_SUBST([REPLACE_TIME])
REPLACE_TIMEGM=0; AC_SUBST([REPLACE_TIMEGM])
REPLACE_TIMESPEC_GET=0; AC_SUBST([REPLACE_TIMESPEC_GET])
REPLACE_TZSET=0; AC_SUBST([REPLACE_TZSET])
]) ])

View File

@ -57,9 +57,7 @@ AC_DEFUN([gl_TIME_R],
[gl_cv_time_r_posix=yes], [gl_cv_time_r_posix=yes],
[gl_cv_time_r_posix=no]) [gl_cv_time_r_posix=no])
]) ])
if test $gl_cv_time_r_posix = yes; then if test $gl_cv_time_r_posix != yes; then
REPLACE_LOCALTIME_R=0
else
REPLACE_LOCALTIME_R=1 REPLACE_LOCALTIME_R=1
fi fi
else else

View File

@ -1,4 +1,4 @@
# timegm.m4 serial 15 # timegm.m4 serial 16
dnl Copyright (C) 2003, 2007, 2009-2023 Free Software Foundation, Inc. dnl Copyright (C) 2003, 2007, 2009-2023 Free Software Foundation, Inc.
dnl This file is free software; the Free Software Foundation dnl This file is free software; the Free Software Foundation
dnl gives unlimited permission to copy and/or distribute it, dnl gives unlimited permission to copy and/or distribute it,
@ -8,7 +8,6 @@ AC_DEFUN([gl_FUNC_TIMEGM],
[ [
AC_REQUIRE([gl_TIME_H_DEFAULTS]) AC_REQUIRE([gl_TIME_H_DEFAULTS])
AC_REQUIRE([gl_FUNC_MKTIME_WORKS]) AC_REQUIRE([gl_FUNC_MKTIME_WORKS])
REPLACE_TIMEGM=0
gl_CHECK_FUNCS_ANDROID([timegm], [[#include <time.h>]]) gl_CHECK_FUNCS_ANDROID([timegm], [[#include <time.h>]])
if test $ac_cv_func_timegm = yes; then if test $ac_cv_func_timegm = yes; then
if test "$gl_cv_func_working_mktime" != yes; then if test "$gl_cv_func_working_mktime" != yes; then

View File

@ -167,7 +167,7 @@ CLOCK_TIME_LIB=@CLOCK_TIME_LIB@
EUIDACCESS_LIBGEN=@EUIDACCESS_LIBGEN@ EUIDACCESS_LIBGEN=@EUIDACCESS_LIBGEN@
NANOSLEEP_LIB=@NANOSLEEP_LIB@ NANOSLEEP_LIB=@NANOSLEEP_LIB@
QCOPY_ACL_LIB=@QCOPY_ACL_LIB@ QCOPY_ACL_LIB=@QCOPY_ACL_LIB@
LIB_TIMER_TIME=@LIB_TIMER_TIME@ TIMER_TIME_LIB=@TIMER_TIME_LIB@
DBUS_CFLAGS = @DBUS_CFLAGS@ DBUS_CFLAGS = @DBUS_CFLAGS@
DBUS_LIBS = @DBUS_LIBS@ DBUS_LIBS = @DBUS_LIBS@
@ -596,7 +596,7 @@ LIBES = $(LIBS) $(W32_LIBS) $(LIBS_GNUSTEP) $(PGTK_LIBS) $(LIBX_BASE) $(LIBIMAGE
$(LIBX_OTHER) $(LIBSOUND) \ $(LIBX_OTHER) $(LIBSOUND) \
$(RSVG_LIBS) $(IMAGEMAGICK_LIBS) $(LIB_ACL) $(CLOCK_TIME_LIB) \ $(RSVG_LIBS) $(IMAGEMAGICK_LIBS) $(LIB_ACL) $(CLOCK_TIME_LIB) \
$(NANOSLEEP_LIB) $(QCOPY_ACL_LIB) $(WEBKIT_LIBS) \ $(NANOSLEEP_LIB) $(QCOPY_ACL_LIB) $(WEBKIT_LIBS) \
$(EUIDACCESS_LIBGEN) $(LIB_TIMER_TIME) $(DBUS_LIBS) \ $(EUIDACCESS_LIBGEN) $(TIMER_TIME_LIB) $(DBUS_LIBS) \
$(LIB_EXECINFO) $(XRANDR_LIBS) $(XINERAMA_LIBS) $(XFIXES_LIBS) \ $(LIB_EXECINFO) $(XRANDR_LIBS) $(XINERAMA_LIBS) $(XFIXES_LIBS) \
$(XDBE_LIBS) $(XSYNC_LIBS) \ $(XDBE_LIBS) $(XSYNC_LIBS) \
$(LIBXML2_LIBS) $(LIBGPM) $(LIBS_SYSTEM) $(CAIRO_LIBS) \ $(LIBXML2_LIBS) $(LIBGPM) $(LIBS_SYSTEM) $(CAIRO_LIBS) \