* build failures in mingw64
@ 2023-07-08 21:50 Stephen Leake
2023-07-09 5:58 ` Eli Zaretskii
0 siblings, 1 reply; 14+ messages in thread
From: Stephen Leake @ 2023-07-08 21:50 UTC (permalink / raw)
To: emacs-devel
I'm getting build failures on master (pulled today).
First is:
In file included from C:/Projects/emacs/master/nt/inc/sys/socket.h:82,
from thread.h:25,
from lisp.h:2261,
from dispnew.c:27:
./w32.h:253:10: fatal error: gnutls/gnutls.h: No such file or directory
253 | #include <gnutls/gnutls.h>
| ^~~~~~~~~~~~~~~~~
The file is present in D:/msys64/mingw64/include/gnutls/gnutls.h, but
D:/msys64/mingw64/include is not in the gcc include path. I can work
around that with LIBGNUTLS_CFLAGS="-isystem D:/msys64/mingw64/include".
This appears to be due to a bug in mingw pkgconf; it says:
$ pkgconf --cflags gnutls
-ID:/msys64/mingw64/include/p11-kit-1
but gnutls.h is not in p11-kit-1.
Continuing the make, I get another error:
d:/apps/gnat-gpl_2021/bin/../libexec/gcc/x86_64-w64-mingw32/10.3.1/ld.exe: gnutls.o: in function `gn
utls_try_handshake':
C:\Projects\emacs\master\src/gnutls.c:648: undefined reference to `nanosleep'
C:\Projects\emacs\master\src/gnutls.c:648:(.text+0x49ce): relocation truncated to fit: R_X86_64_PC32
against undefined symbol `nanosleep'
This is from emacs/src/gnutls.c, which contains "GnuTLS glue for GNU
Emacs". The reference to 'nanosleep' is on line 648; vc-annotate says:
cdbc2f9d274a (Lars Ingebrigtsen 2022-03-04 648)
so I don't see why this only started failing recently. I'll try
bisecting.
I don't have a workaround for this error; trying to add #ifdef on
WindowsNT leads to other errors.
--
-- Stephe
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: build failures in mingw64
2023-07-08 21:50 Stephen Leake
@ 2023-07-09 5:58 ` Eli Zaretskii
0 siblings, 0 replies; 14+ messages in thread
From: Eli Zaretskii @ 2023-07-09 5:58 UTC (permalink / raw)
To: Stephen Leake; +Cc: emacs-devel
> From: Stephen Leake <stephen_leake@stephe-leake.org>
> Date: Sat, 08 Jul 2023 14:50:45 -0700
>
> I'm getting build failures on master (pulled today).
>
> First is:
>
> In file included from C:/Projects/emacs/master/nt/inc/sys/socket.h:82,
> from thread.h:25,
> from lisp.h:2261,
> from dispnew.c:27:
> ./w32.h:253:10: fatal error: gnutls/gnutls.h: No such file or directory
> 253 | #include <gnutls/gnutls.h>
> | ^~~~~~~~~~~~~~~~~
>
> The file is present in D:/msys64/mingw64/include/gnutls/gnutls.h, but
> D:/msys64/mingw64/include is not in the gcc include path. I can work
> around that with LIBGNUTLS_CFLAGS="-isystem D:/msys64/mingw64/include".
>
> This appears to be due to a bug in mingw pkgconf; it says:
>
> $ pkgconf --cflags gnutls
> -ID:/msys64/mingw64/include/p11-kit-1
>
> but gnutls.h is not in p11-kit-1.
Please take this issue up with the MinGW64 folks who produce the
MinGW64 GnuTLS package. You can meanwhile fix the gnutls.pc file
locally on your system, to specify the correct -I flag (which IMO
should be simply -I${includedir}).
> Continuing the make, I get another error:
>
> d:/apps/gnat-gpl_2021/bin/../libexec/gcc/x86_64-w64-mingw32/10.3.1/ld.exe: gnutls.o: in function `gn
> utls_try_handshake':
> C:\Projects\emacs\master\src/gnutls.c:648: undefined reference to `nanosleep'
> C:\Projects\emacs\master\src/gnutls.c:648:(.text+0x49ce): relocation truncated to fit: R_X86_64_PC32
> against undefined symbol `nanosleep'
>
> This is from emacs/src/gnutls.c, which contains "GnuTLS glue for GNU
> Emacs". The reference to 'nanosleep' is on line 648; vc-annotate says:
>
> cdbc2f9d274a (Lars Ingebrigtsen 2022-03-04 648)
>
> so I don't see why this only started failing recently. I'll try
> bisecting.
Does this mean MinGW64 recently removed nanosleep from their runtime
library or something? The MS-Windows build assumes MinGW does have
nanosleep, so it did exist at some point.
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: build failures in mingw64
@ 2023-07-09 8:05 Angelo Graziosi
2023-07-09 8:51 ` Eli Zaretskii
2023-07-09 16:17 ` Stephen Leake
0 siblings, 2 replies; 14+ messages in thread
From: Angelo Graziosi @ 2023-07-09 8:05 UTC (permalink / raw)
To: emacs-devel@gnu.org
> I'm getting build failures on master (pulled today).
I have built Emacs from master yesterday and just now without issues:
Configured for 'x86_64-w64-mingw32'.
[...]
Does Emacs use a file notification library? yes (w32)
Does Emacs use access control lists? yes
Does Emacs use -lselinux? no
Does Emacs use -lgnutls? yes
Does Emacs use -lxml2? yes
Does Emacs use -lfreetype? no
Does Emacs use HarfBuzz? yes
[...]
Which dumping strategy does Emacs use? pdumper
Does Emacs have native lisp compiler? no
Does Emacs use version 2 of the X Input Extension? no
Does Emacs generate a smaller-size Japanese dictionary? no
I just noticed this in configure:
checking whether MB_CUR_MAX is correct... ./configure: line 33322: test: !=: unary operator expected
My MSYS2 installation is uptodate and her GCC is 13.1.0.
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: build failures in mingw64
2023-07-09 8:05 build failures in mingw64 Angelo Graziosi
@ 2023-07-09 8:51 ` Eli Zaretskii
2023-07-09 9:33 ` Angelo Graziosi
2023-07-09 16:17 ` Stephen Leake
1 sibling, 1 reply; 14+ messages in thread
From: Eli Zaretskii @ 2023-07-09 8:51 UTC (permalink / raw)
To: Angelo Graziosi; +Cc: emacs-devel
> Date: Sun, 9 Jul 2023 10:05:13 +0200 (CEST)
> From: Angelo Graziosi <angelo.g0@libero.it>
>
> I just noticed this in configure:
>
> checking whether MB_CUR_MAX is correct... ./configure: line 33322: test: !=: unary operator expected
Please show the relevant part of the configure script. Since the
configure is generated on each user's system as part of the build, it
is hard to guess what you have there without seeing the actual code
you get. For example, on my system, line 33322 of the configure
script is an empty line, and I see no "!=" anywhere around that.
So more data is needed to investigate this.
Thanks.
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: build failures in mingw64
2023-07-09 8:51 ` Eli Zaretskii
@ 2023-07-09 9:33 ` Angelo Graziosi
2023-07-09 10:01 ` Angelo Graziosi
2023-07-09 11:19 ` Eli Zaretskii
0 siblings, 2 replies; 14+ messages in thread
From: Angelo Graziosi @ 2023-07-09 9:33 UTC (permalink / raw)
To: Eli Zaretskii; +Cc: emacs-devel
> Il 09/07/2023 10:51 CEST Eli Zaretskii ha scritto:
>
>
> > Date: Sun, 9 Jul 2023 10:05:13 +0200 (CEST)
> > From: Angelo Graziosi
> >
> > I just noticed this in configure:
> >
> > checking whether MB_CUR_MAX is correct... ./configure: line 33322: test: !=: unary operator expected
>
> Please show the relevant part of the configure script. Since the
> configure is generated on each user's system as part of the build, it
> is hard to guess what you have there without seeing the actual code
> you get. For example, on my system, line 33322 of the configure
> script is an empty line, and I see no "!=" anywhere around that.
>
> So more data is needed to investigate this.
This should be:
[...]
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether MB_CUR_MAX is correct" >&5
printf %s "checking whether MB_CUR_MAX is correct... " >&6; }
if test ${gl_cv_macro_MB_CUR_MAX_good+y}
then :
printf %s "(cached) " >&6
else $as_nop
case "$host_os" in
# Guess no on Solaris.
solaris*) gl_cv_macro_MB_CUR_MAX_good="guessing no" ;;
# Guess yes otherwise.
*) gl_cv_macro_MB_CUR_MAX_good="guessing yes" ;;
esac
if test $LOCALE_FR_UTF8 != none; then ### *** LINE 33322 *** ###
if test "$cross_compiling" = yes
then :
:
else $as_nop
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
[...]
>
> Thanks.
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: build failures in mingw64
2023-07-09 9:33 ` Angelo Graziosi
@ 2023-07-09 10:01 ` Angelo Graziosi
2023-07-09 11:22 ` Eli Zaretskii
2023-07-09 11:19 ` Eli Zaretskii
1 sibling, 1 reply; 14+ messages in thread
From: Angelo Graziosi @ 2023-07-09 10:01 UTC (permalink / raw)
To: Eli Zaretskii; +Cc: emacs-devel
> Il 09/07/2023 11:33 CEST Angelo Graziosi ha scritto:
>
>
> > Il 09/07/2023 10:51 CEST Eli Zaretskii ha scritto:
> >
> >
> > > Date: Sun, 9 Jul 2023 10:05:13 +0200 (CEST)
> > > From: Angelo Graziosi
> > >
> > > I just noticed this in configure:
> > >
> > > checking whether MB_CUR_MAX is correct... ./configure: line 33322: test: !=: unary operator expected
> >
> > Please show the relevant part of the configure script. Since the
> > configure is generated on each user's system as part of the build, it
> > is hard to guess what you have there without seeing the actual code
> > you get. For example, on my system, line 33322 of the configure
> > script is an empty line, and I see no "!=" anywhere around that.
> >
> > So more data is needed to investigate this.
>
> This should be:
>
> [...]
>
> { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether MB_CUR_MAX is correct" >&5
> printf %s "checking whether MB_CUR_MAX is correct... " >&6; }
> if test ${gl_cv_macro_MB_CUR_MAX_good+y}
> then :
> printf %s "(cached) " >&6
> else $as_nop
>
> case "$host_os" in
> # Guess no on Solaris.
> solaris*) gl_cv_macro_MB_CUR_MAX_good="guessing no" ;;
> # Guess yes otherwise.
> *) gl_cv_macro_MB_CUR_MAX_good="guessing yes" ;;
> esac
> if test $LOCALE_FR_UTF8 != none; then ### *** LINE 33322 *** ###
> if test "$cross_compiling" = yes
> then :
> :
> else $as_nop
> cat confdefs.h - <<_ACEOF >conftest.$ac_ext
>
>
> [...]
>
I played a bit from command line:
1)
$ A=1
$ if test $A != 1; then echo bar; fi
<EMPTY>
$ if test $A != none; then echo bar; fi
bar
2)
$ A=
$ if test $A != none; then echo bar; fi
bash: test: !=: atteso operatore unario
but:
$ if test "$A" != none; then echo bar; fi
bar
i.e. it prints that message if the variable is undefined and not quoted..
Here it is:
$ bash --version
GNU bash, versione 5.2.15(1)-release (x86_64-pc-msys)
[...]
See also: https://linuxconfig.org/correct-variable-parsing-and-quoting-in-bash
> > Thanks.
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: build failures in mingw64
2023-07-09 9:33 ` Angelo Graziosi
2023-07-09 10:01 ` Angelo Graziosi
@ 2023-07-09 11:19 ` Eli Zaretskii
2023-07-09 20:57 ` Paul Eggert
1 sibling, 1 reply; 14+ messages in thread
From: Eli Zaretskii @ 2023-07-09 11:19 UTC (permalink / raw)
To: Angelo Graziosi, Paul Eggert; +Cc: emacs-devel
> Date: Sun, 9 Jul 2023 11:33:25 +0200 (CEST)
> From: Angelo Graziosi <angelo.g0@libero.it>
> Cc: emacs-devel@gnu.org
>
>
> { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether MB_CUR_MAX is correct" >&5
> printf %s "checking whether MB_CUR_MAX is correct... " >&6; }
> if test ${gl_cv_macro_MB_CUR_MAX_good+y}
> then :
> printf %s "(cached) " >&6
> else $as_nop
>
> case "$host_os" in
> # Guess no on Solaris.
> solaris*) gl_cv_macro_MB_CUR_MAX_good="guessing no" ;;
> # Guess yes otherwise.
> *) gl_cv_macro_MB_CUR_MAX_good="guessing yes" ;;
> esac
> if test $LOCALE_FR_UTF8 != none; then ### *** LINE 33322 *** ###
> if test "$cross_compiling" = yes
> then :
> :
> else $as_nop
> cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Thanks. This is a Gnulib bug, we've "inherited" it 2 months ago.
Paul, could you please fix this in Gnulib?
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: build failures in mingw64
2023-07-09 10:01 ` Angelo Graziosi
@ 2023-07-09 11:22 ` Eli Zaretskii
0 siblings, 0 replies; 14+ messages in thread
From: Eli Zaretskii @ 2023-07-09 11:22 UTC (permalink / raw)
To: Angelo Graziosi; +Cc: emacs-devel
> Date: Sun, 9 Jul 2023 12:01:56 +0200 (CEST)
> From: Angelo Graziosi <angelo.g0@libero.it>
> Cc: emacs-devel@gnu.org
>
> i.e. it prints that message if the variable is undefined and not quoted..
Yes, it should be quoted. That's the bug.
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: build failures in mingw64
2023-07-09 8:05 build failures in mingw64 Angelo Graziosi
2023-07-09 8:51 ` Eli Zaretskii
@ 2023-07-09 16:17 ` Stephen Leake
1 sibling, 0 replies; 14+ messages in thread
From: Stephen Leake @ 2023-07-09 16:17 UTC (permalink / raw)
To: Angelo Graziosi; +Cc: emacs-devel@gnu.org
Angelo Graziosi <angelo.g0@libero.it> writes:
>> I'm getting build failures on master (pulled today).
>
> I have built Emacs from master yesterday and just now without issues:
>
>
> Configured for 'x86_64-w64-mingw32'.
>
> [...]
> Does Emacs use a file notification library? yes (w32)
> Does Emacs use access control lists? yes
> Does Emacs use -lselinux? no
> Does Emacs use -lgnutls? yes
> Does Emacs use -lxml2? yes
> Does Emacs use -lfreetype? no
> Does Emacs use HarfBuzz? yes
> [...]
> Which dumping strategy does Emacs use? pdumper
> Does Emacs have native lisp compiler? no
> Does Emacs use version 2 of the X Input Extension? no
> Does Emacs generate a smaller-size Japanese dictionary? no
>
>
> I just noticed this in configure:
>
> checking whether MB_CUR_MAX is correct... ./configure: line 33322: test: !=: unary operator expected
>
>
> My MSYS2 installation is uptodate and her GCC is 13.1.0.
A web search implies nanosleep is in the mingw-runtime package, since at
least 10 years ago. So my mingw is corrupted; I'll reinstall from scratch.
--
-- Stephe
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: build failures in mingw64
2023-07-09 11:19 ` Eli Zaretskii
@ 2023-07-09 20:57 ` Paul Eggert
2023-07-09 22:48 ` Angelo Graziosi
2023-07-10 12:28 ` Eli Zaretskii
0 siblings, 2 replies; 14+ messages in thread
From: Paul Eggert @ 2023-07-09 20:57 UTC (permalink / raw)
To: Eli Zaretskii, Angelo Graziosi; +Cc: emacs-devel
[-- Attachment #1: Type: text/plain, Size: 712 bytes --]
On 2023-07-09 04:19, Eli Zaretskii wrote:
> This is a Gnulib bug, we've "inherited" it 2 months ago.
Odd, that could happen if one ran 'configure' with an unusual argument,
e.g., './configure gt_cv_locale_fr=', but I don't see how it could
happen otherwise.
The configure-time test for French locales is present only to work
around a Solaris 10 bug, and looking into that bug I don't see how it
could affect Emacs. So I installed the attached patches to bring Emacs
up to speed on recent Gnulib (I fixed Gnulib to handle the "unusual
argument" issue), and to remove the unnecessary-for-Emacs French locale
testing so this should work around whatever obscure issue Angelo ran
into. Please give it a try.
[-- Attachment #2: 0001-Update-from-Gnulib-by-running-admin-merge-gnulib.patch --]
[-- Type: text/x-patch, Size: 33091 bytes --]
From c3cfada3c075991d7a38fafbdcf5daba06794d7a Mon Sep 17 00:00:00 2001
From: Paul Eggert <eggert@cs.ucla.edu>
Date: Sun, 9 Jul 2023 13:05:01 -0700
Subject: [PATCH 1/2] Update from Gnulib by running admin/merge-gnulib
---
build-aux/config.guess | 16 +--
build-aux/config.sub | 31 +++--
build-aux/gitlog-to-changelog | 4 +-
build-aux/update-copyright | 20 ++--
doc/misc/texinfo.tex | 214 +++++++++++++++++-----------------
lib/gnulib.mk.in | 4 +
lib/limits.in.h | 2 +-
lib/regcomp.c | 2 +-
m4/fsusage.m4 | 2 +-
m4/largefile.m4 | 21 +++-
m4/locale-fr.m4 | 131 ++++++++++++++-------
m4/warnings.m4 | 22 +++-
12 files changed, 278 insertions(+), 191 deletions(-)
diff --git a/build-aux/config.guess b/build-aux/config.guess
index 69188da73d7..354a8ccde42 100755
--- a/build-aux/config.guess
+++ b/build-aux/config.guess
@@ -4,7 +4,7 @@
# shellcheck disable=SC2006,SC2268 # see below for rationale
-timestamp='2023-01-01'
+timestamp='2023-06-23'
# 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
@@ -47,7 +47,7 @@ me=
usage="\
Usage: $0 [OPTION]
-Output the configuration name of the system \`$me' is run on.
+Output the configuration name of the system '$me' is run on.
Options:
-h, --help print this help, then exit
@@ -66,7 +66,7 @@ version=
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE."
help="
-Try \`$me --help' for more information."
+Try '$me --help' for more information."
# Parse command line
while test $# -gt 0 ; do
@@ -102,8 +102,8 @@ GUESS=
# temporary files to be created and, as you can see below, it is a
# headache to deal with in a portable fashion.
-# Historically, `CC_FOR_BUILD' used to be named `HOST_CC'. We still
-# use `HOST_CC' if defined, but it is deprecated.
+# Historically, 'CC_FOR_BUILD' used to be named 'HOST_CC'. We still
+# use 'HOST_CC' if defined, but it is deprecated.
# Portable tmp directory creation inspired by the Autoconf team.
@@ -459,7 +459,7 @@ UNAME_VERSION=
UNAME_RELEASE=`uname -v`
;;
esac
- # Japanese Language versions have a version number like `4.1.3-JL'.
+ # Japanese Language versions have a version number like '4.1.3-JL'.
SUN_REL=`echo "$UNAME_RELEASE" | sed -e 's/-/_/'`
GUESS=sparc-sun-sunos$SUN_REL
;;
@@ -1197,7 +1197,7 @@ main ()
GUESS=$UNAME_MACHINE-pc-sysv4.2uw$UNAME_VERSION
;;
i*86:OS/2:*:*)
- # If we were able to find `uname', then EMX Unix compatibility
+ # If we were able to find 'uname', then EMX Unix compatibility
# is probably installed.
GUESS=$UNAME_MACHINE-pc-os2-emx
;;
@@ -1338,7 +1338,7 @@ main ()
GUESS=ns32k-sni-sysv
fi
;;
- PENTIUM:*:4.0*:*) # Unisys `ClearPath HMP IX 4000' SVR4/MP effort
+ PENTIUM:*:4.0*:*) # Unisys 'ClearPath HMP IX 4000' SVR4/MP effort
# says <Richard.M.Bartel@ccMail.Census.GOV>
GUESS=i586-unisys-sysv4
;;
diff --git a/build-aux/config.sub b/build-aux/config.sub
index de4259e4047..9865d6ea4d1 100755
--- a/build-aux/config.sub
+++ b/build-aux/config.sub
@@ -4,7 +4,7 @@
# shellcheck disable=SC2006,SC2268 # see below for rationale
-timestamp='2023-01-21'
+timestamp='2023-06-26'
# 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
@@ -82,7 +82,7 @@ version=
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE."
help="
-Try \`$me --help' for more information."
+Try '$me --help' for more information."
# Parse command line
while test $# -gt 0 ; do
@@ -130,7 +130,7 @@ IFS=
# Separate into logical components for further validation
case $1 in
*-*-*-*-*)
- echo Invalid configuration \`"$1"\': more than four components >&2
+ echo "Invalid configuration '$1': more than four components" >&2
exit 1
;;
*-*-*-*)
@@ -145,7 +145,8 @@ IFS=
nto-qnx* | linux-* | uclinux-uclibc* \
| uclinux-gnu* | kfreebsd*-gnu* | knetbsd*-gnu* | netbsd*-gnu* \
| netbsd*-eabi* | kopensolaris*-gnu* | cloudabi*-eabi* \
- | storm-chaos* | os2-emx* | rtmk-nova* | managarm-*)
+ | storm-chaos* | os2-emx* | rtmk-nova* | managarm-* \
+ | windows-* )
basic_machine=$field1
basic_os=$maybe_os
;;
@@ -943,7 +944,7 @@ IFS=
EOF
IFS=$saved_IFS
;;
- # We use `pc' rather than `unknown'
+ # We use 'pc' rather than 'unknown'
# because (1) that's what they normally are, and
# (2) the word "unknown" tends to confuse beginning users.
i*86 | x86_64)
@@ -1285,7 +1286,7 @@ IFS=
;;
*)
- echo Invalid configuration \`"$1"\': machine \`"$cpu-$vendor"\' not recognized 1>&2
+ echo "Invalid configuration '$1': machine '$cpu-$vendor' not recognized" 1>&2
exit 1
;;
esac
@@ -1766,11 +1767,11 @@ kernel=
;;
none)
;;
- kernel* )
+ kernel* | msvc* )
# Restricted further below
;;
*)
- echo Invalid configuration \`"$1"\': OS \`"$os"\' not recognized 1>&2
+ echo "Invalid configuration '$1': OS '$os' not recognized" 1>&2
exit 1
;;
esac
@@ -1785,18 +1786,24 @@ kernel=
;;
managarm-mlibc* | managarm-kernel* )
;;
+ windows*-gnu* | windows*-msvc*)
+ ;;
-dietlibc* | -newlib* | -musl* | -relibc* | -uclibc* | -mlibc* )
# These are just libc implementations, not actual OSes, and thus
# require a kernel.
- echo "Invalid configuration \`$1': libc \`$os' needs explicit kernel." 1>&2
+ echo "Invalid configuration '$1': libc '$os' needs explicit kernel." 1>&2
exit 1
;;
-kernel* )
- echo "Invalid configuration \`$1': \`$os' needs explicit kernel." 1>&2
+ echo "Invalid configuration '$1': '$os' needs explicit kernel." 1>&2
exit 1
;;
*-kernel* )
- echo "Invalid configuration \`$1': \`$kernel' does not support \`$os'." 1>&2
+ echo "Invalid configuration '$1': '$kernel' does not support '$os'." 1>&2
+ exit 1
+ ;;
+ *-msvc* )
+ echo "Invalid configuration '$1': '$os' needs 'windows'." 1>&2
exit 1
;;
kfreebsd*-gnu* | kopensolaris*-gnu*)
@@ -1813,7 +1820,7 @@ kernel=
# Blank kernel with real OS is always fine.
;;
*-*)
- echo "Invalid configuration \`$1': Kernel \`$kernel' not known to work with OS \`$os'." 1>&2
+ echo "Invalid configuration '$1': Kernel '$kernel' not known to work with OS '$os'." 1>&2
exit 1
;;
esac
diff --git a/build-aux/gitlog-to-changelog b/build-aux/gitlog-to-changelog
index 4678bad1050..43e4a37adf4 100755
--- a/build-aux/gitlog-to-changelog
+++ b/build-aux/gitlog-to-changelog
@@ -35,7 +35,7 @@
eval 'exec perl -wSx "$0" "$@"'
if 0;
-my $VERSION = '2022-01-27 18:49'; # UTC
+my $VERSION = '2023-06-24 21:59'; # UTC
# The definition above must lie within the first 8 lines in order
# for the Emacs time-stamp write hook (at end) to update it.
# If you change this file with Emacs, please let the write hook
@@ -355,7 +355,7 @@ sub git_dir_option($)
. "(expected date/author/email):\n$author_line\n";
# Format 'Copyright-paperwork-exempt: Yes' as a standard ChangeLog
- # `(tiny change)' annotation.
+ # '(tiny change)' annotation.
my $tiny = (grep (/^(?:Copyright-paperwork-exempt|Tiny-change):\s+[Yy]es$/, @line)
? ' (tiny change)' : '');
diff --git a/build-aux/update-copyright b/build-aux/update-copyright
index 99196fceef6..0343eaa72c1 100755
--- a/build-aux/update-copyright
+++ b/build-aux/update-copyright
@@ -98,7 +98,8 @@
# 6. Blank lines, even if preceded by the prefix, do not appear
# within the FSF copyright statement.
# 7. Each copyright year is 2 or 4 digits, and years are separated by
-# commas, "-", or "--". Whitespace may appear after commas.
+# commas, "-", "--", or "\(en" (for troff). Whitespace may appear
+# after commas.
#
# Environment variables:
#
@@ -137,7 +138,7 @@
eval 'exec perl -wSx -0777 -pi "$0" "$@"'
if 0;
-my $VERSION = '2023-01-11.04:24'; # UTC
+my $VERSION = '2023-06-18.01:14'; # UTC
# The definition above must lie within the first 8 lines in order
# for the Emacs time-stamp write hook (at end) to update it.
# If you change this file with Emacs, please let the write hook
@@ -148,6 +149,7 @@ use warnings;
my $copyright_re = 'Copyright';
my $circle_c_re = '(?:\([cC]\)|@copyright\{}|\\\\\(co|©|©)';
+my $ndash_re = '(?:--?|\\\\\(en)';
my $holder = $ENV{UPDATE_COPYRIGHT_HOLDER};
$holder ||= 'Free Software Foundation, Inc.';
my $prefix_max = 5;
@@ -192,7 +194,7 @@ while (/(^|\n)(.{0,$prefix_max})$copyright_re/g)
$holder_re =~ s/\s/$ws_re/g;
my $stmt_remainder_re =
"(?:$ws_re$circle_c_re)?"
- . "$ws_re(?:(?:\\d\\d)?\\d\\d(?:,$ws_re?|--?))*"
+ . "$ws_re(?:(?:\\d\\d)?\\d\\d(?:,$ws_re?|$ndash_re))*"
. "((?:\\d\\d)?\\d\\d)$ws_re$holder_re";
if (/\G$stmt_remainder_re/)
{
@@ -215,7 +217,7 @@ if (defined $stmt_re)
if ($final_year != $this_year)
{
# Update the year.
- $stmt =~ s/\b$final_year_orig\b/$final_year, $this_year/;
+ $stmt =~ s/(^|[^\d])$final_year_orig\b/$1$final_year, $this_year/;
}
if ($final_year != $this_year || $ENV{'UPDATE_COPYRIGHT_FORCE'})
{
@@ -231,17 +233,19 @@ if (defined $stmt_re)
# Make the use of intervals consistent.
if (!$ENV{UPDATE_COPYRIGHT_USE_INTERVALS})
{
- $stmt =~ s/(\d{4})--?(\d{4})/join(', ', $1..$2)/eg;
+ $stmt =~ s/(\d{4})$ndash_re(\d{4})/join(', ', $1..$2)/eg;
}
else
{
- my $ndash = $ARGV =~ /\.tex(i(nfo)?)?$/ ? "--" : "-";
+ my $ndash = ($ARGV =~ /\.tex(i(nfo)?)?$/ ? "--"
+ : $ARGV =~ /\.(\d[a-z]*|man)$/ ? "\\(en"
+ : "-");
$stmt =~
s/
(\d{4})
(?:
- (,\ |--?)
+ (,\ |$ndash_re)
((??{
if ($2 ne ', ') { '\d{4}'; }
elsif (!$3) { $1 + 1; }
@@ -252,7 +256,7 @@ if (defined $stmt_re)
# When it's 2, emit a single range encompassing all year numbers.
$ENV{UPDATE_COPYRIGHT_USE_INTERVALS} == 2
- and $stmt =~ s/\b(\d{4})\b.*\b(\d{4})\b/$1$ndash$2/;
+ and $stmt =~ s/(^|[^\d])(\d{4})\b.*(?:[^\d])(\d{4})\b/$1$2$ndash$3/;
}
# Format within margin.
diff --git a/doc/misc/texinfo.tex b/doc/misc/texinfo.tex
index a32c84197ae..b1d2999e5d7 100644
--- a/doc/misc/texinfo.tex
+++ b/doc/misc/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{2023-03-27.21}
+\def\texinfoversion{2023-07-02.10}
%
% Copyright 1985, 1986, 1988, 1990-2023 Free Software Foundation, Inc.
%
@@ -275,8 +275,7 @@
% \topmark doesn't work for the very first chapter (after the title
% page or the contents), so we use \firstmark there -- this gets us
% the mark with the chapter defs, unless the user sneaks in, e.g.,
-% @setcolor (or @url, or @link, etc.) between @contents and the very
-% first @chapter.
+% @setcolor (or @url etc.) between @contents and the very first @chapter.
\def\gettopheadingmarks{%
\ifcase0\the\savedtopmark\fi
\ifx\thischapter\empty \ifcase0\firstmark\fi \fi
@@ -4950,6 +4949,7 @@
\commondummyword\inforef {}%
\commondummyword\kbd {}%
\commondummyword\key {}%
+ \commondummyword\link {}%
\commondummyword\math {}%
\commondummyword\option {}%
\commondummyword\pxref {}%
@@ -5783,7 +5783,7 @@
% below is chosen so that the gutter has the same value (well, +-<1pt)
% as it did when we hard-coded it.
%
- % We put the result in a separate register, \doublecolumhsize, so we
+ % We put the result in a separate register, \doublecolumnhsize, so we
% can restore it in \pagesofar, after \hsize itself has (potentially)
% been clobbered.
%
@@ -8180,7 +8180,7 @@
% Read recursive and nonrecursive macro bodies. (They're different since
% rec and nonrec macros end differently.)
%
-% We are in \macrobodyctxt, and the \xdef causes backslashshes in the macro
+% We are in \macrobodyctxt, and the \xdef causes backslashes in the macro
% body to be transformed.
% Set \macrobody to the body of the macro, and call \macrodef.
%
@@ -8808,109 +8808,11 @@
\def\xrefX[#1,#2,#3,#4,#5,#6]{\begingroup
\unsepspaces
%
- % Get args without leading/trailing spaces.
- \def\printedrefname{\ignorespaces #3}%
- \setbox\printedrefnamebox = \hbox{\printedrefname\unskip}%
- %
+ \getprintedrefname{#1}{#3}{#5}%
\def\infofilename{\ignorespaces #4}%
\setbox\infofilenamebox = \hbox{\infofilename\unskip}%
%
- \def\printedmanual{\ignorespaces #5}%
- \setbox\printedmanualbox = \hbox{\printedmanual\unskip}%
- %
- % If the printed reference name (arg #3) was not explicitly given in
- % the @xref, figure out what we want to use.
- \ifdim \wd\printedrefnamebox = 0pt
- % No printed node name was explicitly given.
- \expandafter\ifx\csname SETxref-automatic-section-title\endcsname \relax
- % Not auto section-title: use node name inside the square brackets.
- \def\printedrefname{\ignorespaces #1}%
- \else
- % Auto section-title: use chapter/section title inside
- % the square brackets if we have it.
- \ifdim \wd\printedmanualbox > 0pt
- % It is in another manual, so we don't have it; use node name.
- \def\printedrefname{\ignorespaces #1}%
- \else
- \ifhavexrefs
- % We (should) know the real title if we have the xref values.
- \def\printedrefname{\refx{#1-title}}%
- \else
- % Otherwise just copy the Info node name.
- \def\printedrefname{\ignorespaces #1}%
- \fi%
- \fi
- \fi
- \fi
- %
- % Make link in pdf output.
- \ifpdf
- % For pdfTeX and LuaTeX
- {\indexnofonts
- \makevalueexpandable
- \turnoffactive
- % This expands tokens, so do it after making catcode changes, so _
- % etc. don't get their TeX definitions. This ignores all spaces in
- % #4, including (wrongly) those in the middle of the filename.
- \getfilename{#4}%
- %
- % This (wrongly) does not take account of leading or trailing
- % spaces in #1, which should be ignored.
- \setpdfdestname{#1}%
- %
- \ifx\pdfdestname\empty
- \def\pdfdestname{Top}% no empty targets
- \fi
- %
- \leavevmode
- \startlink attr{/Border [0 0 0]}%
- \ifnum\filenamelength>0
- goto file{\the\filename.pdf} name{\pdfdestname}%
- \else
- goto name{\pdfmkpgn{\pdfdestname}}%
- \fi
- }%
- \setcolor{\linkcolor}%
- \else
- \ifx\XeTeXrevision\thisisundefined
- \else
- % For XeTeX
- {\indexnofonts
- \makevalueexpandable
- \turnoffactive
- % This expands tokens, so do it after making catcode changes, so _
- % etc. don't get their TeX definitions. This ignores all spaces in
- % #4, including (wrongly) those in the middle of the filename.
- \getfilename{#4}%
- %
- % This (wrongly) does not take account of leading or trailing
- % spaces in #1, which should be ignored.
- \setpdfdestname{#1}%
- %
- \ifx\pdfdestname\empty
- \def\pdfdestname{Top}% no empty targets
- \fi
- %
- \leavevmode
- \ifnum\filenamelength>0
- % With default settings,
- % XeTeX (xdvipdfmx) replaces link destination names with integers.
- % In this case, the replaced destination names of
- % remote PDFs are no longer known. In order to avoid a replacement,
- % you can use xdvipdfmx's command line option `-C 0x0010'.
- % If you use XeTeX 0.99996+ (TeX Live 2016+),
- % this command line option is no longer necessary
- % because we can use the `dvipdfmx:config' special.
- \special{pdf:bann << /Border [0 0 0] /Type /Annot /Subtype /Link /A
- << /S /GoToR /F (\the\filename.pdf) /D (\pdfdestname) >> >>}%
- \else
- \special{pdf:bann << /Border [0 0 0] /Type /Annot /Subtype /Link /A
- << /S /GoTo /D (\pdfdestname) >> >>}%
- \fi
- }%
- \setcolor{\linkcolor}%
- \fi
- \fi
+ \startxreflink{#1}{#4}%
{%
% Have to otherify everything special to allow the \csname to
% include an _ in the xref name, etc.
@@ -8991,6 +8893,93 @@
\endlink
\endgroup}
+% \getprintedrefname{NODE}{LABEL}{MANUAL}
+% - set \printedrefname and \printedmanual
+%
+\def\getprintedrefname#1#2#3{%
+ % Get args without leading/trailing spaces.
+ \def\printedrefname{\ignorespaces #2}%
+ \setbox\printedrefnamebox = \hbox{\printedrefname\unskip}%
+ %
+ \def\printedmanual{\ignorespaces #3}%
+ \setbox\printedmanualbox = \hbox{\printedmanual\unskip}%
+ %
+ % If the printed reference name (arg #2) was not explicitly given in
+ % the @xref, figure out what we want to use.
+ \ifdim \wd\printedrefnamebox = 0pt
+ % No printed node name was explicitly given.
+ \expandafter\ifx\csname SETxref-automatic-section-title\endcsname \relax
+ % Not auto section-title: use node name inside the square brackets.
+ \def\printedrefname{\ignorespaces #1}%
+ \else
+ % Auto section-title: use chapter/section title inside
+ % the square brackets if we have it.
+ \ifdim \wd\printedmanualbox > 0pt
+ % It is in another manual, so we don't have it; use node name.
+ \def\printedrefname{\ignorespaces #1}%
+ \else
+ \ifhavexrefs
+ % We (should) know the real title if we have the xref values.
+ \def\printedrefname{\refx{#1-title}}%
+ \else
+ % Otherwise just copy the Info node name.
+ \def\printedrefname{\ignorespaces #1}%
+ \fi%
+ \fi
+ \fi
+ \fi
+}
+
+% \startxreflink{NODE}{FILE} - start link in pdf output.
+\def\startxreflink#1#2{%
+ \ifpdforxetex
+ % For pdfTeX and LuaTeX
+ {\indexnofonts
+ \makevalueexpandable
+ \turnoffactive
+ % This expands tokens, so do it after making catcode changes, so _
+ % etc. don't get their TeX definitions. This ignores all spaces in
+ % #2, including (wrongly) those in the middle of the filename.
+ \getfilename{#2}%
+ %
+ % This (wrongly) does not take account of leading or trailing
+ % spaces in #1, which should be ignored.
+ \setpdfdestname{#1}%
+ %
+ \ifx\pdfdestname\empty
+ \def\pdfdestname{Top}% no empty targets
+ \fi
+ %
+ \leavevmode
+ \ifpdf
+ \startlink attr{/Border [0 0 0]}%
+ \ifnum\filenamelength>0
+ goto file{\the\filename.pdf} name{\pdfdestname}%
+ \else
+ goto name{\pdfmkpgn{\pdfdestname}}%
+ \fi
+ \else % XeTeX
+ \ifnum\filenamelength>0
+ % With default settings,
+ % XeTeX (xdvipdfmx) replaces link destination names with integers.
+ % In this case, the replaced destination names of
+ % remote PDFs are no longer known. In order to avoid a replacement,
+ % you can use xdvipdfmx's command line option `-C 0x0010'.
+ % If you use XeTeX 0.99996+ (TeX Live 2016+),
+ % this command line option is no longer necessary
+ % because we can use the `dvipdfmx:config' special.
+ \special{pdf:bann << /Border [0 0 0] /Type /Annot /Subtype /Link /A
+ << /S /GoToR /F (\the\filename.pdf) /D (\pdfdestname) >> >>}%
+ \else
+ \special{pdf:bann << /Border [0 0 0] /Type /Annot /Subtype /Link /A
+ << /S /GoTo /D (\pdfdestname) >> >>}%
+ \fi
+ \fi
+ }%
+ \setcolor{\linkcolor}%
+ \fi
+}
+
% can be overridden in translation files
\def\putpageref#1{%
\space\putwordpage\tie\refx{#1-pg}}
@@ -9028,6 +9017,21 @@
%
\def\xrefprintnodename#1{[#1]}
+% @link{NODENAME, LABEL, MANUAL} - create a "plain" link, with no
+% page number. Not useful if printed on paper.
+%
+\def\link#1{\linkX[#1,,,]}
+\def\linkX[#1,#2,#3,#4]{%
+ \begingroup
+ \unsepspaces
+ \getprintedrefname{#1}{#2}{#3}%
+ \startxreflink{#1}{#3}%
+ \printedrefname
+ \endlink
+ \endgroup
+}
+
+
% Things referred to by \setref.
%
\def\Ynothing{}
diff --git a/lib/gnulib.mk.in b/lib/gnulib.mk.in
index a25bee25aae..0812dc80135 100644
--- a/lib/gnulib.mk.in
+++ b/lib/gnulib.mk.in
@@ -901,6 +901,10 @@ KRB4LIB = @KRB4LIB@
KRB5LIB = @KRB5LIB@
LCMS2_CFLAGS = @LCMS2_CFLAGS@
LCMS2_LIBS = @LCMS2_LIBS@
+LC_COLLATE_IMPLEMENTED = @LC_COLLATE_IMPLEMENTED@
+LC_MONETARY_IMPLEMENTED = @LC_MONETARY_IMPLEMENTED@
+LC_NUMERIC_IMPLEMENTED = @LC_NUMERIC_IMPLEMENTED@
+LC_TIME_IMPLEMENTED = @LC_TIME_IMPLEMENTED@
LDFLAGS = @LDFLAGS@
LD_SWITCH_SYSTEM = @LD_SWITCH_SYSTEM@
LD_SWITCH_SYSTEM_TEMACS = @LD_SWITCH_SYSTEM_TEMACS@
diff --git a/lib/limits.in.h b/lib/limits.in.h
index 1d479c3d192..e2e173eb2de 100644
--- a/lib/limits.in.h
+++ b/lib/limits.in.h
@@ -136,7 +136,7 @@ #define _GL_COB4(n) (!!((n) & 8) + !!((n) & 4) + !!((n) & 2) + !!((n) & 1))
/* Macro specified by POSIX. */
-/* The maximal size_t value. Although it might not be of ssize_t type
+/* The maximum ssize_t value. Although it might not be of ssize_t type
as it should be, it's too much trouble to fix this minor detail. */
#ifndef SSIZE_MAX
# ifdef _WIN64
diff --git a/lib/regcomp.c b/lib/regcomp.c
index 89478396855..1f6a131107b 100644
--- a/lib/regcomp.c
+++ b/lib/regcomp.c
@@ -905,7 +905,7 @@ init_word_char (re_dfa_t *dfa)
bitset_word_t bits3 = 0x07fffffe;
if (BITSET_WORD_BITS == 64)
{
- /* Pacify gcc -Woverflow on 32-bit platformns. */
+ /* Pacify gcc -Woverflow on 32-bit platforms. */
dfa->word_char[0] = bits1 << 31 << 1 | bits0;
dfa->word_char[1] = bits3 << 31 << 1 | bits2;
i = 2;
diff --git a/m4/fsusage.m4 b/m4/fsusage.m4
index 88f3ca817cb..724a863ac30 100644
--- a/m4/fsusage.m4
+++ b/m4/fsusage.m4
@@ -269,7 +269,7 @@ AC_DEFUN
# Check for SunOS statfs brokenness wrt partitions 2GB and larger.
# If <sys/vfs.h> exists and struct statfs has a member named f_spare,
-# enable the work-around code in fsusage.c.
+# enable the workaround code in fsusage.c.
AC_DEFUN([gl_STATFS_TRUNCATES],
[
AC_CACHE_CHECK([for statfs that truncates block counts],
diff --git a/m4/largefile.m4 b/m4/largefile.m4
index a2adb533ae6..8b051c0042b 100644
--- a/m4/largefile.m4
+++ b/m4/largefile.m4
@@ -181,13 +181,16 @@ AC_DEFUN
# C code used to probe for large file support.
m4_define([_AC_SYS_LARGEFILE_TEST_CODE],
[@%:@include <sys/types.h>
- /* Check that off_t can represent 2**63 - 1 correctly.
- We can't simply define LARGE_OFF_T to be 9223372036854775807,
+@%:@ifndef FTYPE
+@%:@ define FTYPE off_t
+@%:@endif
+ /* Check that FTYPE can represent 2**63 - 1 correctly.
+ We can't simply define LARGE_FTYPE to be 9223372036854775807,
since some C++ compilers masquerading as C compilers
incorrectly reject 9223372036854775807. */
-@%:@define LARGE_OFF_T (((off_t) 1 << 31 << 31) - 1 + ((off_t) 1 << 31 << 31))
- int off_t_is_large[[(LARGE_OFF_T % 2147483629 == 721
- && LARGE_OFF_T % 2147483647 == 1)
+@%:@define LARGE_FTYPE (((FTYPE) 1 << 31 << 31) - 1 + ((FTYPE) 1 << 31 << 31))
+ int FTYPE_is_large[[(LARGE_FTYPE % 2147483629 == 721
+ && LARGE_FTYPE % 2147483647 == 1)
? 1 : -1]];[]dnl
])
# Defined by Autoconf 2.71 and circa 2022 Gnulib unwisely depended on it.
@@ -227,7 +230,13 @@ AC_DEFUN
AS_IF([test x"$ac_opt" != x"none needed"],
[CC="$ac_save_CC $ac_opt"])
AC_COMPILE_IFELSE([AC_LANG_PROGRAM([_AC_SYS_LARGEFILE_TEST_CODE])],
- [ac_cv_sys_largefile_opts="$ac_opt"
+ [AS_IF([test x"$ac_opt" = x"none needed"],
+ [# GNU/Linux s390x and alpha need _FILE_OFFSET_BITS=64 for wide ino_t.
+ CC="$CC -DFTYPE=ino_t"
+ AC_COMPILE_IFELSE([], [],
+ [CC="$CC -D_FILE_OFFSET_BITS=64"
+ AC_COMPILE_IFELSE([], [ac_opt='-D_FILE_OFFSET_BITS=64'])])])
+ ac_cv_sys_largefile_opts=$ac_opt
ac_opt_found=yes])
test $ac_opt_found = no || break
done
diff --git a/m4/locale-fr.m4 b/m4/locale-fr.m4
index 5e13f3945d2..40b13aeaa79 100644
--- a/m4/locale-fr.m4
+++ b/m4/locale-fr.m4
@@ -1,4 +1,4 @@
-# locale-fr.m4 serial 21
+# locale-fr.m4 serial 22
dnl Copyright (C) 2003, 2005-2023 Free Software Foundation, Inc.
dnl This file is free software; the Free Software Foundation
dnl gives unlimited permission to copy and/or distribute it,
@@ -133,15 +133,31 @@ AC_DEFUN_ONCE
rm -fr conftest*
])
LOCALE_FR=$gt_cv_locale_fr
+ case $LOCALE_FR in #(
+ '' | *[[[:space:]\"\$\'*@<:@]]*)
+ dnl This locale name might cause trouble with sh or make.
+ AC_MSG_WARN([invalid locale "$LOCALE_FR"; assuming "none"])
+ LOCALE_FR=none;;
+ esac
AC_SUBST([LOCALE_FR])
])
dnl Determine the name of a french locale with UTF-8 encoding.
AC_DEFUN_ONCE([gt_LOCALE_FR_UTF8],
[
+ AC_REQUIRE([AC_CANONICAL_HOST])
AC_REQUIRE([AM_LANGINFO_CODESET])
AC_CACHE_CHECK([for a french Unicode locale], [gt_cv_locale_fr_utf8], [
- AC_LANG_CONFTEST([AC_LANG_SOURCE([[
+ case "$host_os" in
+ *-musl* | midipix*)
+ dnl On musl libc, all kinds of ll_CC.UTF-8 locales exist, even without
+ dnl any locale file on disk. But they are effectively equivalent to the
+ dnl C.UTF-8 locale, except for locale categories (such as LC_MESSSAGES)
+ dnl for which localizations (.mo files) have been installed.
+ gt_cv_locale_fr_utf8=fr_FR.UTF-8
+ ;;
+ *)
+ AC_LANG_CONFTEST([AC_LANG_SOURCE([[
#include <locale.h>
#include <time.h>
#if HAVE_LANGINFO_CODESET
@@ -203,51 +219,82 @@ AC_DEFUN_ONCE
#endif
return 0;
}
- ]])])
- if AC_TRY_EVAL([ac_link]) && test -s conftest$ac_exeext; then
- case "$host_os" in
- # Handle native Windows specially, because there setlocale() interprets
- # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
- # "fr" or "fra" as "French" or "French_France.1252",
- # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
- # "ja" as "Japanese" or "Japanese_Japan.932",
- # and similar.
- mingw*)
- # Test for the hypothetical native Windows locale name.
- if (LC_ALL=French_France.65001 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
- gt_cv_locale_fr_utf8=French_France.65001
- else
- # None found.
- gt_cv_locale_fr_utf8=none
- fi
- ;;
- *)
- # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
- # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
- # configure script would override the LC_ALL setting. Likewise for
- # LC_CTYPE, which is also set at the beginning of the configure script.
- # Test for the usual locale name.
- if (LC_ALL=fr_FR LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
- gt_cv_locale_fr_utf8=fr_FR
- else
- # Test for the locale name with explicit encoding suffix.
- if (LC_ALL=fr_FR.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
- gt_cv_locale_fr_utf8=fr_FR.UTF-8
- else
- # Test for the Solaris 7 locale name.
- if (LC_ALL=fr.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
- gt_cv_locale_fr_utf8=fr.UTF-8
+ ]])])
+ if AC_TRY_EVAL([ac_link]) && test -s conftest$ac_exeext; then
+ case "$host_os" in
+ # Handle native Windows specially, because there setlocale() interprets
+ # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
+ # "fr" or "fra" as "French" or "French_France.1252",
+ # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
+ # "ja" as "Japanese" or "Japanese_Japan.932",
+ # and similar.
+ mingw*)
+ # Test for the hypothetical native Windows locale name.
+ if (LC_ALL=French_France.65001 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
+ gt_cv_locale_fr_utf8=French_France.65001
else
# None found.
gt_cv_locale_fr_utf8=none
fi
- fi
- fi
- ;;
- esac
- fi
- rm -fr conftest*
+ ;;
+ *)
+ # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
+ # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
+ # configure script would override the LC_ALL setting. Likewise for
+ # LC_CTYPE, which is also set at the beginning of the configure script.
+ # Test for the usual locale name.
+ if (LC_ALL=fr_FR LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
+ gt_cv_locale_fr_utf8=fr_FR
+ else
+ # Test for the locale name with explicit encoding suffix.
+ if (LC_ALL=fr_FR.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
+ gt_cv_locale_fr_utf8=fr_FR.UTF-8
+ else
+ # Test for the Solaris 7 locale name.
+ if (LC_ALL=fr.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
+ gt_cv_locale_fr_utf8=fr.UTF-8
+ else
+ # None found.
+ gt_cv_locale_fr_utf8=none
+ fi
+ fi
+ fi
+ ;;
+ esac
+ fi
+ rm -fr conftest*
+ ;;
+ esac
])
LOCALE_FR_UTF8=$gt_cv_locale_fr_utf8
+ case $LOCALE_FR_UTF8 in #(
+ '' | *[[[:space:]\"\$\'*@<:@]]*)
+ dnl This locale name might cause trouble with sh or make.
+ AC_MSG_WARN([invalid locale "$LOCALE_FR_UTF8"; assuming "none"])
+ LOCALE_FR_UTF8=none;;
+ esac
AC_SUBST([LOCALE_FR_UTF8])
+
+ dnl Users of $LOCALE_FR_UTF8 need to know which of the locale categories they
+ dnl can rely on.
+ case "$host_os" in
+ *-musl* | midipix*)
+ dnl On musl libc, locale categories other than LC_CTYPE and LC_MESSAGES
+ dnl are effectively unimplemented.
+ LC_COLLATE_IMPLEMENTED=false
+ LC_NUMERIC_IMPLEMENTED=false
+ LC_TIME_IMPLEMENTED=false
+ LC_MONETARY_IMPLEMENTED=false
+ ;;
+ *)
+ LC_COLLATE_IMPLEMENTED=true
+ LC_NUMERIC_IMPLEMENTED=true
+ LC_TIME_IMPLEMENTED=true
+ LC_MONETARY_IMPLEMENTED=true
+ ;;
+ esac
+ AC_SUBST([LC_COLLATE_IMPLEMENTED])
+ AC_SUBST([LC_NUMERIC_IMPLEMENTED])
+ AC_SUBST([LC_TIME_IMPLEMENTED])
+ AC_SUBST([LC_MONETARY_IMPLEMENTED])
])
diff --git a/m4/warnings.m4 b/m4/warnings.m4
index 1a3107f846d..9433cb523bf 100644
--- a/m4/warnings.m4
+++ b/m4/warnings.m4
@@ -1,4 +1,4 @@
-# warnings.m4 serial 18
+# warnings.m4 serial 19
dnl Copyright (C) 2008-2023 Free Software Foundation, Inc.
dnl This file is free software; the Free Software Foundation
dnl gives unlimited permission to copy and/or distribute it,
@@ -81,12 +81,14 @@ AC_DEFUN
# gl_WARN_ADD(OPTION, [VARIABLE = WARN_CFLAGS/WARN_CXXFLAGS],
# [PROGRAM = AC_LANG_PROGRAM()])
# -----------------------------------------------------------
-# Adds parameter to WARN_CFLAGS/WARN_CXXFLAGS if the compiler supports it
-# when compiling PROGRAM. For example, gl_WARN_ADD([-Wparentheses]).
+# Adds OPTION to VARIABLE (which defaults to WARN_CFLAGS or WARN_CXXFLAGS)
+# if the compiler supports it when compiling PROGRAM.
#
# If VARIABLE is a variable name, AC_SUBST it.
#
# The effects of this macro depend on the current language (_AC_LANG).
+#
+# Example: gl_WARN_ADD([-Wparentheses]).
AC_DEFUN([gl_WARN_ADD],
[AC_REQUIRE([gl_UNKNOWN_WARNINGS_ARE_ERRORS(]_AC_LANG[)])
gl_COMPILER_OPTION_IF([$1],
@@ -123,7 +125,12 @@ AC_DEFUN
])
case "$gl_cv_cc_winhibit" in
none) GL_CFLAG_INHIBIT_WARNINGS='' ;;
- *) GL_CFLAG_INHIBIT_WARNINGS="$gl_cv_cc_winhibit" ;;
+ *)
+ GL_CFLAG_INHIBIT_WARNINGS="$gl_cv_cc_winhibit"
+ dnl If all warnings are inhibited, there's no point in having the GCC
+ dnl analyzer enabled. This saves RAM requirements and CPU consumption.
+ gl_WARN_ADD([-fno-analyzer], [GL_CFLAG_INHIBIT_WARNINGS])
+ ;;
esac
AC_SUBST([GL_CFLAG_INHIBIT_WARNINGS])
])
@@ -150,7 +157,12 @@ AC_DEFUN
])
case "$gl_cv_cxx_winhibit" in
none) GL_CXXFLAG_INHIBIT_WARNINGS='' ;;
- *) GL_CXXFLAG_INHIBIT_WARNINGS="$gl_cv_cxx_winhibit" ;;
+ *)
+ GL_CXXFLAG_INHIBIT_WARNINGS="$gl_cv_cxx_winhibit"
+ dnl If all warnings are inhibited, there's no point in having the GCC
+ dnl analyzer enabled. This saves RAM requirements and CPU consumption.
+ gl_WARN_ADD([-fno-analyzer], [GL_CXXFLAG_INHIBIT_WARNINGS])
+ ;;
esac
else
GL_CXXFLAG_INHIBIT_WARNINGS=''
--
2.39.2
[-- Attachment #3: 0002-Simplify-configure-check-for-MB_CUR_MAX.patch --]
[-- Type: text/x-patch, Size: 15330 bytes --]
From b76878cfab1eb681d759ac3b57832baca4df7ef2 Mon Sep 17 00:00:00 2001
From: Paul Eggert <eggert@cs.ucla.edu>
Date: Sun, 9 Jul 2023 13:27:54 -0700
Subject: [PATCH 2/2] =?UTF-8?q?Simplify=20=E2=80=98configure=E2=80=99=20ch?=
=?UTF-8?q?eck=20for=20MB=5FCUR=5FMAX?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
* admin/merge-gnulib: Remove m4/locale-fr.m4.
* configure.ac (gt_LOCALE_FR_UTF8): Replace Gnulib’s
definition with a near no-op, as Emacs doesn’t care
about the Solaris 10 MB_CUR_MAX bug.
* lib/gnulib.mk.in: Regenerate.
* m4/locale-fr.m4: Remove; no longer needed due
to above changes.
---
admin/merge-gnulib | 1 +
configure.ac | 4 +
lib/gnulib.mk.in | 4 -
m4/locale-fr.m4 | 300 ---------------------------------------------
4 files changed, 5 insertions(+), 304 deletions(-)
delete mode 100644 m4/locale-fr.m4
diff --git a/admin/merge-gnulib b/admin/merge-gnulib
index 3e7526102ae..eb790933414 100755
--- a/admin/merge-gnulib
+++ b/admin/merge-gnulib
@@ -121,6 +121,7 @@ avoided_flags=
"$src"m4/fcntl-o.m4 \
"$src"m4/gl-openssl.m4 \
"$src"m4/gnulib-cache.m4 "$src"m4/gnulib-tool.m4 \
+ "$src"m4/locale-fr.m4 \
"$src"m4/manywarnings-c++.m4 \
"$src"m4/warn-on-use.m4 "$src"m4/wint_t.m4 &&
cp -- "$gnulib_srcdir"/build-aux/texinfo.tex "$src"doc/misc &&
diff --git a/configure.ac b/configure.ac
index dffdef48c10..890b06905c1 100644
--- a/configure.ac
+++ b/configure.ac
@@ -901,6 +901,10 @@ AC_DEFUN
AC_DEFUN([gt_TYPE_WINT_T],
[GNULIBHEADERS_OVERRIDE_WINT_T=0
AC_SUBST([GNULIBHEADERS_OVERRIDE_WINT_T])])
+# Emacs does not need precise checks for the Solaris 10 MB_CUR_MAX bug.
+AC_DEFUN([gt_LOCALE_FR_UTF8],
+ [LOCALE_FR_UTF8=none
+ AC_SUBST([LOCALE_FR_UTF8])])
# Initialize gnulib right after choosing the compiler.
dnl Amongst other things, this sets AR and ARFLAGS.
diff --git a/lib/gnulib.mk.in b/lib/gnulib.mk.in
index 0812dc80135..a25bee25aae 100644
--- a/lib/gnulib.mk.in
+++ b/lib/gnulib.mk.in
@@ -901,10 +901,6 @@ KRB4LIB = @KRB4LIB@
KRB5LIB = @KRB5LIB@
LCMS2_CFLAGS = @LCMS2_CFLAGS@
LCMS2_LIBS = @LCMS2_LIBS@
-LC_COLLATE_IMPLEMENTED = @LC_COLLATE_IMPLEMENTED@
-LC_MONETARY_IMPLEMENTED = @LC_MONETARY_IMPLEMENTED@
-LC_NUMERIC_IMPLEMENTED = @LC_NUMERIC_IMPLEMENTED@
-LC_TIME_IMPLEMENTED = @LC_TIME_IMPLEMENTED@
LDFLAGS = @LDFLAGS@
LD_SWITCH_SYSTEM = @LD_SWITCH_SYSTEM@
LD_SWITCH_SYSTEM_TEMACS = @LD_SWITCH_SYSTEM_TEMACS@
diff --git a/m4/locale-fr.m4 b/m4/locale-fr.m4
deleted file mode 100644
index 40b13aeaa79..00000000000
--- a/m4/locale-fr.m4
+++ /dev/null
@@ -1,300 +0,0 @@
-# locale-fr.m4 serial 22
-dnl Copyright (C) 2003, 2005-2023 Free Software Foundation, Inc.
-dnl This file is free software; the Free Software Foundation
-dnl gives unlimited permission to copy and/or distribute it,
-dnl with or without modifications, as long as this notice is preserved.
-
-dnl From Bruno Haible.
-
-dnl Determine the name of a french locale with traditional encoding.
-AC_DEFUN_ONCE([gt_LOCALE_FR],
-[
- AC_REQUIRE([AC_CANONICAL_HOST])
- AC_REQUIRE([AM_LANGINFO_CODESET])
- AC_CACHE_CHECK([for a traditional french locale], [gt_cv_locale_fr], [
- AC_LANG_CONFTEST([AC_LANG_SOURCE([[
-#include <locale.h>
-#include <time.h>
-#if HAVE_LANGINFO_CODESET
-# include <langinfo.h>
-#endif
-#include <stdlib.h>
-#include <string.h>
-struct tm t;
-char buf[16];
-int main () {
- /* On BeOS and Haiku, locales are not implemented in libc. Rather, libintl
- imitates locale dependent behaviour by looking at the environment
- variables, and all locales use the UTF-8 encoding. */
-#if defined __BEOS__ || defined __HAIKU__
- return 1;
-#else
- /* Check whether the given locale name is recognized by the system. */
-# if defined _WIN32 && !defined __CYGWIN__
- /* On native Windows, setlocale(category, "") looks at the system settings,
- not at the environment variables. Also, when an encoding suffix such
- as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
- category of the locale to "C". */
- if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
- || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
- return 1;
-# else
- if (setlocale (LC_ALL, "") == NULL) return 1;
-# endif
- /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
- On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
- is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
- On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
- succeeds but then nl_langinfo(CODESET) is "646". In this situation,
- some unit tests fail.
- On MirBSD 10, when an unsupported locale is specified, setlocale()
- succeeds but then nl_langinfo(CODESET) is "UTF-8". */
-# if HAVE_LANGINFO_CODESET
- {
- const char *cs = nl_langinfo (CODESET);
- if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
- || strcmp (cs, "UTF-8") == 0)
- return 1;
- }
-# endif
-# ifdef __CYGWIN__
- /* On Cygwin, avoid locale names without encoding suffix, because the
- locale_charset() function relies on the encoding suffix. Note that
- LC_ALL is set on the command line. */
- if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
-# endif
- /* Check whether in the abbreviation of the second month, the second
- character (should be U+00E9: LATIN SMALL LETTER E WITH ACUTE) is only
- one byte long. This excludes the UTF-8 encoding. */
- t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
- if (strftime (buf, sizeof (buf), "%b", &t) < 3 || buf[2] != 'v') return 1;
-# if !defined __BIONIC__ /* Bionic libc's 'struct lconv' is just a dummy. */
- /* Check whether the decimal separator is a comma.
- On NetBSD 3.0 in the fr_FR.ISO8859-1 locale, localeconv()->decimal_point
- are nl_langinfo(RADIXCHAR) are both ".". */
- if (localeconv () ->decimal_point[0] != ',') return 1;
-# endif
- return 0;
-#endif
-}
- ]])])
- if AC_TRY_EVAL([ac_link]) && test -s conftest$ac_exeext; then
- case "$host_os" in
- # Handle native Windows specially, because there setlocale() interprets
- # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
- # "fr" or "fra" as "French" or "French_France.1252",
- # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
- # "ja" as "Japanese" or "Japanese_Japan.932",
- # and similar.
- mingw*)
- # Test for the native Windows locale name.
- if (LC_ALL=French_France.1252 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
- gt_cv_locale_fr=French_France.1252
- else
- # None found.
- gt_cv_locale_fr=none
- fi
- ;;
- *)
- # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
- # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
- # configure script would override the LC_ALL setting. Likewise for
- # LC_CTYPE, which is also set at the beginning of the configure script.
- # Test for the usual locale name.
- if (LC_ALL=fr_FR LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
- gt_cv_locale_fr=fr_FR
- else
- # Test for the locale name with explicit encoding suffix.
- if (LC_ALL=fr_FR.ISO-8859-1 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
- gt_cv_locale_fr=fr_FR.ISO-8859-1
- else
- # Test for the AIX, OSF/1, FreeBSD, NetBSD, OpenBSD locale name.
- if (LC_ALL=fr_FR.ISO8859-1 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
- gt_cv_locale_fr=fr_FR.ISO8859-1
- else
- # Test for the HP-UX locale name.
- if (LC_ALL=fr_FR.iso88591 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
- gt_cv_locale_fr=fr_FR.iso88591
- else
- # Test for the Solaris 7 locale name.
- if (LC_ALL=fr LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
- gt_cv_locale_fr=fr
- else
- # None found.
- gt_cv_locale_fr=none
- fi
- fi
- fi
- fi
- fi
- ;;
- esac
- fi
- rm -fr conftest*
- ])
- LOCALE_FR=$gt_cv_locale_fr
- case $LOCALE_FR in #(
- '' | *[[[:space:]\"\$\'*@<:@]]*)
- dnl This locale name might cause trouble with sh or make.
- AC_MSG_WARN([invalid locale "$LOCALE_FR"; assuming "none"])
- LOCALE_FR=none;;
- esac
- AC_SUBST([LOCALE_FR])
-])
-
-dnl Determine the name of a french locale with UTF-8 encoding.
-AC_DEFUN_ONCE([gt_LOCALE_FR_UTF8],
-[
- AC_REQUIRE([AC_CANONICAL_HOST])
- AC_REQUIRE([AM_LANGINFO_CODESET])
- AC_CACHE_CHECK([for a french Unicode locale], [gt_cv_locale_fr_utf8], [
- case "$host_os" in
- *-musl* | midipix*)
- dnl On musl libc, all kinds of ll_CC.UTF-8 locales exist, even without
- dnl any locale file on disk. But they are effectively equivalent to the
- dnl C.UTF-8 locale, except for locale categories (such as LC_MESSSAGES)
- dnl for which localizations (.mo files) have been installed.
- gt_cv_locale_fr_utf8=fr_FR.UTF-8
- ;;
- *)
- AC_LANG_CONFTEST([AC_LANG_SOURCE([[
-#include <locale.h>
-#include <time.h>
-#if HAVE_LANGINFO_CODESET
-# include <langinfo.h>
-#endif
-#include <stdlib.h>
-#include <string.h>
-struct tm t;
-char buf[16];
-int main () {
- /* On BeOS and Haiku, locales are not implemented in libc. Rather, libintl
- imitates locale dependent behaviour by looking at the environment
- variables, and all locales use the UTF-8 encoding. */
-#if !(defined __BEOS__ || defined __HAIKU__)
- /* Check whether the given locale name is recognized by the system. */
-# if defined _WIN32 && !defined __CYGWIN__
- /* On native Windows, setlocale(category, "") looks at the system settings,
- not at the environment variables. Also, when an encoding suffix such
- as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
- category of the locale to "C". */
- if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
- || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
- return 1;
-# else
- if (setlocale (LC_ALL, "") == NULL) return 1;
-# endif
- /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
- On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
- is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
- On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
- succeeds but then nl_langinfo(CODESET) is "646". In this situation,
- some unit tests fail. */
-# if HAVE_LANGINFO_CODESET
- {
- const char *cs = nl_langinfo (CODESET);
- if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0)
- return 1;
- }
-# endif
-# ifdef __CYGWIN__
- /* On Cygwin, avoid locale names without encoding suffix, because the
- locale_charset() function relies on the encoding suffix. Note that
- LC_ALL is set on the command line. */
- if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
-# endif
- /* Check whether in the abbreviation of the second month, the second
- character (should be U+00E9: LATIN SMALL LETTER E WITH ACUTE) is
- two bytes long, with UTF-8 encoding. */
- t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
- if (strftime (buf, sizeof (buf), "%b", &t) < 4
- || buf[1] != (char) 0xc3 || buf[2] != (char) 0xa9 || buf[3] != 'v')
- return 1;
-#endif
-#if !defined __BIONIC__ /* Bionic libc's 'struct lconv' is just a dummy. */
- /* Check whether the decimal separator is a comma.
- On NetBSD 3.0 in the fr_FR.ISO8859-1 locale, localeconv()->decimal_point
- are nl_langinfo(RADIXCHAR) are both ".". */
- if (localeconv () ->decimal_point[0] != ',') return 1;
-#endif
- return 0;
-}
- ]])])
- if AC_TRY_EVAL([ac_link]) && test -s conftest$ac_exeext; then
- case "$host_os" in
- # Handle native Windows specially, because there setlocale() interprets
- # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
- # "fr" or "fra" as "French" or "French_France.1252",
- # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
- # "ja" as "Japanese" or "Japanese_Japan.932",
- # and similar.
- mingw*)
- # Test for the hypothetical native Windows locale name.
- if (LC_ALL=French_France.65001 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
- gt_cv_locale_fr_utf8=French_France.65001
- else
- # None found.
- gt_cv_locale_fr_utf8=none
- fi
- ;;
- *)
- # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
- # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
- # configure script would override the LC_ALL setting. Likewise for
- # LC_CTYPE, which is also set at the beginning of the configure script.
- # Test for the usual locale name.
- if (LC_ALL=fr_FR LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
- gt_cv_locale_fr_utf8=fr_FR
- else
- # Test for the locale name with explicit encoding suffix.
- if (LC_ALL=fr_FR.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
- gt_cv_locale_fr_utf8=fr_FR.UTF-8
- else
- # Test for the Solaris 7 locale name.
- if (LC_ALL=fr.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
- gt_cv_locale_fr_utf8=fr.UTF-8
- else
- # None found.
- gt_cv_locale_fr_utf8=none
- fi
- fi
- fi
- ;;
- esac
- fi
- rm -fr conftest*
- ;;
- esac
- ])
- LOCALE_FR_UTF8=$gt_cv_locale_fr_utf8
- case $LOCALE_FR_UTF8 in #(
- '' | *[[[:space:]\"\$\'*@<:@]]*)
- dnl This locale name might cause trouble with sh or make.
- AC_MSG_WARN([invalid locale "$LOCALE_FR_UTF8"; assuming "none"])
- LOCALE_FR_UTF8=none;;
- esac
- AC_SUBST([LOCALE_FR_UTF8])
-
- dnl Users of $LOCALE_FR_UTF8 need to know which of the locale categories they
- dnl can rely on.
- case "$host_os" in
- *-musl* | midipix*)
- dnl On musl libc, locale categories other than LC_CTYPE and LC_MESSAGES
- dnl are effectively unimplemented.
- LC_COLLATE_IMPLEMENTED=false
- LC_NUMERIC_IMPLEMENTED=false
- LC_TIME_IMPLEMENTED=false
- LC_MONETARY_IMPLEMENTED=false
- ;;
- *)
- LC_COLLATE_IMPLEMENTED=true
- LC_NUMERIC_IMPLEMENTED=true
- LC_TIME_IMPLEMENTED=true
- LC_MONETARY_IMPLEMENTED=true
- ;;
- esac
- AC_SUBST([LC_COLLATE_IMPLEMENTED])
- AC_SUBST([LC_NUMERIC_IMPLEMENTED])
- AC_SUBST([LC_TIME_IMPLEMENTED])
- AC_SUBST([LC_MONETARY_IMPLEMENTED])
-])
--
2.39.2
^ permalink raw reply related [flat|nested] 14+ messages in thread
* Re: build failures in mingw64
2023-07-09 20:57 ` Paul Eggert
@ 2023-07-09 22:48 ` Angelo Graziosi
2023-07-10 12:28 ` Eli Zaretskii
1 sibling, 0 replies; 14+ messages in thread
From: Angelo Graziosi @ 2023-07-09 22:48 UTC (permalink / raw)
To: Paul Eggert, Eli Zaretskii; +Cc: emacs-devel
Hi Paul,
> Il 09/07/2023 22:57 CEST Paul Eggert ha scritto:
>
>
> On 2023-07-09 04:19, Eli Zaretskii wrote:
> > This is a Gnulib bug, we've "inherited" it 2 months ago.
>
> Odd, that could happen if one ran 'configure' with an unusual argument,
> e.g., './configure gt_cv_locale_fr=', but I don't see how it could
> happen otherwise.
>
> The configure-time test for French locales is present only to work
> around a Solaris 10 bug, and looking into that bug I don't see how it
> could affect Emacs. So I installed the attached patches to bring Emacs
> up to speed on recent Gnulib (I fixed Gnulib to handle the "unusual
> argument" issue), and to remove the unnecessary-for-Emacs French locale
> testing so this should work around whatever obscure issue Angelo ran
> into. Please give it a try.
I do not use French, LANG is it_IT.UTF-8 and usually I configure with:
./configure --prefix="/${PREFIXNAME}" \
--build=x86_64-w64-mingw32 \
--without-native-compilation \
--without-dbus \
--without-pop \
--with-modules \
--enable-checking=no \
CFLAGS=-O2 -static
It seems that Emacs is building without that message..
Thanks
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: build failures in mingw64
2023-07-09 20:57 ` Paul Eggert
2023-07-09 22:48 ` Angelo Graziosi
@ 2023-07-10 12:28 ` Eli Zaretskii
2023-07-10 17:00 ` Paul Eggert
1 sibling, 1 reply; 14+ messages in thread
From: Eli Zaretskii @ 2023-07-10 12:28 UTC (permalink / raw)
To: Paul Eggert; +Cc: angelo.g0, emacs-devel
> Date: Sun, 9 Jul 2023 13:57:25 -0700
> Cc: emacs-devel@gnu.org
> From: Paul Eggert <eggert@cs.ucla.edu>
>
> On 2023-07-09 04:19, Eli Zaretskii wrote:
> > This is a Gnulib bug, we've "inherited" it 2 months ago.
>
> Odd, that could happen if one ran 'configure' with an unusual argument,
> e.g., './configure gt_cv_locale_fr=', but I don't see how it could
> happen otherwise.
>
> The configure-time test for French locales is present only to work
> around a Solaris 10 bug, and looking into that bug I don't see how it
> could affect Emacs.
AFAIR, Gnulib-generated configure scripts always check for the French
locale, for whatever reasons.
> So I installed the attached patches to bring Emacs
> up to speed on recent Gnulib (I fixed Gnulib to handle the "unusual
> argument" issue), and to remove the unnecessary-for-Emacs French locale
> testing so this should work around whatever obscure issue Angelo ran
> into. Please give it a try.
But shouldn't LOCALE_FR_UTF8 be quoted in the below fragment?
if test $LOCALE_FR_UTF8 != none; then
if test "$cross_compiling" = yes; then :
This is still present in the configure script regenerated after your
changes on master.
Thanks.
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: build failures in mingw64
2023-07-10 12:28 ` Eli Zaretskii
@ 2023-07-10 17:00 ` Paul Eggert
2023-07-10 23:40 ` Angelo Graziosi
0 siblings, 1 reply; 14+ messages in thread
From: Paul Eggert @ 2023-07-10 17:00 UTC (permalink / raw)
To: Eli Zaretskii; +Cc: angelo.g0, emacs-devel
[-- Attachment #1: Type: text/plain, Size: 663 bytes --]
On 2023-07-10 05:28, Eli Zaretskii wrote:
> AFAIR, Gnulib-generated configure scripts always check for the French
> locale, for whatever reasons.
The recent patch should cause that to stop happening for Emacs's
configure script.
> But shouldn't LOCALE_FR_UTF8 be quoted in the below fragment?
>
> if test $LOCALE_FR_UTF8 != none; then
> if test "$cross_compiling" = yes; then :
Quoting should not be necessary, because at that point LOCALE_FR_UTF8's
value is guaranteed to be safe without quoting.
Come to think of it, that shell script fragment can be optimized away so
this issue won't even come up. I installed the attached to do that.
[-- Attachment #2: 0001-Further-simplify-configure-time-locale-testing.patch --]
[-- Type: text/x-patch, Size: 2011 bytes --]
From 845ff9563d47568ddd5cb37c62a53deade2d4693 Mon Sep 17 00:00:00 2001
From: Paul Eggert <eggert@cs.ucla.edu>
Date: Mon, 10 Jul 2023 09:53:07 -0700
Subject: [PATCH] Further simplify configure-time locale testing
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
* configure.ac (gl_STDLIB_H): Replace this, not gt_LOCALE_FR_UTF8,
as this lets us also omit MB_CUR_MAX checking that will never be
executed, and also lets us remove testing for ecvt, fcvt, gcvt
that Emacs doesn’t need.
(AC_C_RESTRICT): Invoke explicitly, as Emacs uses ‘restrict’
directly. Also, simplifies the replacement for gl_STDLIB_H, which
would otherwise need to AC_REQUIRE AC_C_RESTRICT.
* lib/gnulib.mk.in: Regenerate via admin/merge-gnulib.
---
configure.ac | 7 ++++---
lib/gnulib.mk.in | 1 -
2 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/configure.ac b/configure.ac
index 890b06905c1..a51aa44cf2c 100644
--- a/configure.ac
+++ b/configure.ac
@@ -902,9 +902,9 @@ AC_DEFUN
[GNULIBHEADERS_OVERRIDE_WINT_T=0
AC_SUBST([GNULIBHEADERS_OVERRIDE_WINT_T])])
# Emacs does not need precise checks for the Solaris 10 MB_CUR_MAX bug.
-AC_DEFUN([gt_LOCALE_FR_UTF8],
- [LOCALE_FR_UTF8=none
- AC_SUBST([LOCALE_FR_UTF8])])
+AC_DEFUN_ONCE([gl_STDLIB_H],
+ [AC_REQUIRE([gl_STDLIB_H_DEFAULTS])
+ gl_NEXT_HEADERS([stdlib.h])])
# Initialize gnulib right after choosing the compiler.
dnl Amongst other things, this sets AR and ARFLAGS.
@@ -6305,6 +6305,7 @@ AC_DEFUN
structure to an N-byte boundary.])
fi
+AC_C_RESTRICT
AC_C_TYPEOF
AC_CACHE_CHECK([for statement expressions],
diff --git a/lib/gnulib.mk.in b/lib/gnulib.mk.in
index a25bee25aae..3ef36bf8af6 100644
--- a/lib/gnulib.mk.in
+++ b/lib/gnulib.mk.in
@@ -961,7 +961,6 @@ LIB_WSOCK32 = @LIB_WSOCK32@
LIB_XATTR = @LIB_XATTR@
LIMITS_H = @LIMITS_H@
LN_S_FILEONLY = @LN_S_FILEONLY@
-LOCALE_FR_UTF8 = @LOCALE_FR_UTF8@
LTLIBGMP = @LTLIBGMP@
LTLIBINTL = @LTLIBINTL@
LTLIBOBJS = @LTLIBOBJS@
--
2.39.2
^ permalink raw reply related [flat|nested] 14+ messages in thread
* Re: build failures in mingw64
2023-07-10 17:00 ` Paul Eggert
@ 2023-07-10 23:40 ` Angelo Graziosi
0 siblings, 0 replies; 14+ messages in thread
From: Angelo Graziosi @ 2023-07-10 23:40 UTC (permalink / raw)
To: Paul Eggert, Eli Zaretskii; +Cc: emacs-devel
> Il 10/07/2023 19:00 CEST Paul Eggert ha scritto:
>
>
> On 2023-07-10 05:28, Eli Zaretskii wrote:
>
> > AFAIR, Gnulib-generated configure scripts always check for the French
> > locale, for whatever reasons.
>
> The recent patch should cause that to stop happening for Emacs's
> configure script.
> > But shouldn't LOCALE_FR_UTF8 be quoted in the below fragment?
> >
> > if test $LOCALE_FR_UTF8 != none; then
> > if test "$cross_compiling" = yes; then :
>
> Quoting should not be necessary, because at that point LOCALE_FR_UTF8's
> value is guaranteed to be safe without quoting.
>
> Come to think of it, that shell script fragment can be optimized away so
> this issue won't even come up. I installed the attached to do that.
Just for completeness, with the code before all these patch, just running
$ ./configure
causes that message, so on MSYS2 it does not depend on the options of configure..
^ permalink raw reply [flat|nested] 14+ messages in thread
end of thread, other threads:[~2023-07-10 23:40 UTC | newest]
Thread overview: 14+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-07-09 8:05 build failures in mingw64 Angelo Graziosi
2023-07-09 8:51 ` Eli Zaretskii
2023-07-09 9:33 ` Angelo Graziosi
2023-07-09 10:01 ` Angelo Graziosi
2023-07-09 11:22 ` Eli Zaretskii
2023-07-09 11:19 ` Eli Zaretskii
2023-07-09 20:57 ` Paul Eggert
2023-07-09 22:48 ` Angelo Graziosi
2023-07-10 12:28 ` Eli Zaretskii
2023-07-10 17:00 ` Paul Eggert
2023-07-10 23:40 ` Angelo Graziosi
2023-07-09 16:17 ` Stephen Leake
-- strict thread matches above, loose matches on Subject: below --
2023-07-08 21:50 Stephen Leake
2023-07-09 5:58 ` Eli Zaretskii
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.