1
0
mirror of https://git.savannah.gnu.org/git/emacs.git synced 2024-11-22 07:09:54 +00:00
Commit Graph

38 Commits

Author SHA1 Message Date
Paul Eggert
7ae091d933 Update from Gnulib by running admin/merge-gnulib 2024-05-11 18:46:26 -07:00
Paul Eggert
3add626f14 Update from Gnulib by running admin/merge-gnulib 2024-01-20 11:45:38 -08:00
Po Lu
070cb32463 ; Add 2024 to copyright years 2024-01-02 10:30:05 +08:00
Paul Eggert
f3868cb9d1 Update from Gnulib by running admin/merge-gnulib 2023-08-12 12:57:35 -07:00
Paul Eggert
9e98ff562b Update from Gnulib by running admin/merge-gnulib 2023-01-06 18:05:57 -08:00
Eli Zaretskii
cae528457c ; Add 2023 to copyright years. 2023-01-01 05:31:12 -05:00
Paul Eggert
308e63ccfc Update from Gnulib by running admin/merge-gnulib 2022-02-23 11:41:02 -08:00
Paul Eggert
c899d9742a Update from gnulib 2022-01-04 13:17:25 -08:00
Eli Zaretskii
19dcb237b5 ; Add 2022 to copyright years. 2022-01-01 02:45:51 -05:00
Paul Eggert
68a256c892 Update from Gnulib
Make the following changes by hand, and run 'admin/merge-gnulib'.
* .gitignore: Add lib/malloc/*.gl.h.
* admin/merge-gnulib: Copy lib/af_alg.h and lib/save-cwd.h
directly from Gnulib, without worrying about Gnulib modules,
as these files are special cases.
(AVOIDED_MODULES): Remove malloc-posix.
* lib/malloc.c, lib/realloc.c, m4/malloc.m4, m4/realloc.m4:
* m4/year2038.m4: New files, copied from Gnulib.
* lib/malloca.c, lib/malloca.h:
* m4/close-stream.m4, m4/glibc21.m4, m4/malloca.m4:
Remove.  These are either no longer present in Gnulib, or are no
longer needed by modules that Emacs uses.
* oldXMenu/AddPane.c, oldXmenu/Addsel.c: Include XmenuInt.h first;
needed for new Gnulib.
* src/xmenu.c: Call emacs_abort, not abort.
2021-10-04 15:21:31 -07:00
Paul Eggert
1b59478f4c Update from Gnulib by running admin/merge-gnulib. 2021-01-01 01:52:03 -08:00
Paul Eggert
ba05d005e5 Update copyright year to 2021
Run "TZ=UTC0 admin/update-copyright".
2021-01-01 01:13:56 -08:00
Paul Eggert
846657afaf Update from Gnulib
This incorporates:
2020-08-16 time_rz: remove unused functions
2020-08-16 time_rz: fix issues with mktime_z failures
2020-08-16 nstrftime: Guide inlining also on clang
2020-08-16 intprops: Avoid bogus warning on clang
2020-08-16 libc-config: Enable __REDIRECT macro also on clang
2020-08-16 regex: Use initializer shorthand syntax also with clang
2020-08-16 regex: Use space optimization also with clang
2020-08-16 Use _Static_assert and static_assert when present on clang
2020-08-16 Use 'throw ()' for optimization in C++ mode also on clang
2020-08-16 stdio: Don't break attribute 'scanf' on clang
2020-08-16 Fix "warning: 'format' attribute ...: rpl_printf"
2020-08-16 Fix "warning: attribute declaration must precede definition"
2020-08-16 Fix undesired warnings
2020-08-16 Don't use Autoconf quadrigraphsxo
2020-08-16 Fix quoting of AC_LANG_PROGRAM arguments
2020-08-16 Assume autoconf >= 2.64
2020-08-15 nstrftime: be more predictable about errno
2020-08-15 canonicalize: Fix autoconf test on MSVC/clang
2020-08-15 Support compiling without -loldnames on native Windows
2020-08-14 mktime, mktime-internal: Remove obsolete code
2020-08-14 Assume tzset exists
* lib/c++defs.h, lib/canonicalize-lgpl.c, lib/cdefs.h, lib/dup2.c:
* lib/fcntl.in.h, lib/getopt-cdefs.in.h, lib/intprops.h, lib/md5.h:
* lib/mktime.c, lib/nstrftime.c, lib/open.c, lib/regcomp.c:
* lib/regex_internal.h, lib/stdio.in.h, lib/stdlib.in.h:
* lib/strftime.h, lib/string.in.h, lib/sys_select.in.h:
* lib/sys_stat.in.h, lib/sys_time.in.h, lib/time.in.h, lib/time_rz.c:
* lib/unistd.in.h, lib/verify.h, m4/00gnulib.m4:
* m4/absolute-header.m4, m4/alloca.m4, m4/canonicalize.m4, m4/dup2.m4:
* m4/fchmodat.m4, m4/fcntl.m4, m4/fdopendir.m4, m4/fpending.m4:
* m4/futimens.m4, m4/getdtablesize.m4, m4/getloadavg.m4:
* m4/gnulib-common.m4, m4/include_next.m4, m4/largefile.m4:
* m4/manywarnings.m4, m4/mktime.m4, m4/nstrftime.m4, m4/open-slash.m4:
* m4/pselect.m4, m4/pthread_sigmask.m4, m4/time_h.m4, m4/utimens.m4:
* m4/utimensat.m4, m4/utimes.m4, m4/warnings.m4:
Copy from Gnulib.
* lib/gnulib.mk.in: Regenerate.
2020-08-16 14:30:29 -07:00
Paul Eggert
5d89a9c284 Update from Gnulib
This incorporates:
2020-07-30 work around some Oracle Studio attribute bugs
2020-07-29 fsusage, regex, stat-size: remove Cray support
2020-07-26 inttypes: remove support for AIX 4
2020-07-26 gettimeofday: remove workaround for Mac OS X 10.0
2020-07-26 don't require gl_LOCALTIME_BUFFER_DEFAULTS
2020-07-26 alloca: remove Cray-2 and Cray Y-MP support
2020-07-26 libgmp: remove dependency on havelib
2020-07-26 libgmp: remove HAVE_GMP, LIB_GMP
2020-07-25 multiarch: prepare for x86_64+arm64 universal in macOS 11
2020-07-25 sigprocmask: small autoconf macro improvement
2020-07-25 small autoconf macro improvements
2020-07-24 timespec: remove dependence on ‘verify’
2020-07-24 optimize a few more three-valued comparisons
2020-07-24 fix _GL_CMP parenthesization typo
2020-07-23 optimize three-valued comparison between integers
2020-07-24 doc: update for Mac OS X 10.13
2020-07-23 fchmodat, lchmod: use /proc on Cygwin
2020-07-21 inttypes: fix PRI*PTR and SCN*PTR on 64-bit native Windows
2020-07-12 libgmp: avoid warning when --without-libgmp is used
2020-07-12 libgmp: link to the correct shared library
* lib/mini-gmp-gnulib.c: Ignore -Wsuggest-attribute=malloc only for
* build-aux/config.guess, build-aux/config.sub:
* build-aux/install-sh, doc/misc/texinfo.tex, lib/c-strcasecmp.c:
* lib/c-strncasecmp.c, lib/fchmodat.c, lib/fsusage.c:
* lib/gettimeofday.c, lib/inttypes.in.h, lib/lchmod.c:
* lib/mini-gmp-gnulib.c, lib/nstrftime.c, lib/regex.h, lib/timespec.h:
* m4/alloca.m4, m4/getgroups.m4, m4/gettimeofday.m4:
* m4/gnulib-common.m4, m4/inttypes.m4, m4/libgmp.m4, m4/mktime.m4:
* m4/multiarch.m4:
Copy from Gnulib.
* lib/gnulib.mk.in, m4/gnulib-comp.m4: Regenerate.
* src/Makefile.in, test/Makefile.in (LIBGMP):
Rename from LIB_GMP for compatibility with Gnulib.
All uses changed.
2020-07-30 14:01:49 -07:00
Paul Eggert
64d1b9fd8a Update from gnulib
This incorporates:
2019-12-23 mktime, nstrftime: tweak division performance
2019-12-22 count-leading-zeros: assume 'long long'
2019-12-22 count-one-bits: assume 'long long'
2019-12-22 count-trailing-zeros: assume 'long long'
2019-12-12 inttypes-incomplete: assume 'long long'
2019-12-22 malloca: assume 'long long'
2019-12-22 stdint: assume 'long long'
2019-12-22 strtoll, strtoimax, strtoumax: assume 'long long'
2019-12-22 prefer lib_SOURCES to unconditional AC_LIBOBJ
2019-12-19 nstrftime: avoid a shadowing warning
2019-12-18 improve port of AC_C_RESTRICT to Oracle C++
2019-12-12 stdalign: port to xlclang 16.01
2019-12-11 stddef, unistd: fix compilation error in C++ mode on MSVC
2019-12-08 fix compilation errors in C++ mode on Haiku
2019-12-08 fix compilation errors in 32-bit C++ mode on HP-UX 11/ia64
2019-12-08 fix compilation error in C++ mode on OpenBSD
* build-aux/config.guess, doc/misc/texinfo.tex:
* lib/count-leading-zeros.h, lib/count-one-bits.h:
* lib/count-trailing-zeros.h, lib/inttypes.in.h, lib/malloca.h:
* lib/mktime.c, lib/nstrftime.c, lib/signal.in.h, lib/stdalign.in.h:
* lib/stddef.in.h, lib/stdint.in.h, lib/stdio.in.h, lib/stdlib.in.h:
* lib/strtoimax.c, lib/unistd.in.h, m4/gnulib-common.m4:
* m4/inttypes.m4, m4/largefile.m4, m4/malloca.m4, m4/strtoimax.m4:
* m4/strtoll.m4:
Copy from Gnulib.  Also, change copyright notices in some other
Gnulib-copied files to exactly match Gnulib, as Gnulib updated
them in a trivially different way.
* lib/gnulib.mk.in, m4/gnulib-comp.m4: Regenerate.
2019-12-31 19:11:56 -08:00
Paul Eggert
365e01cc9f Update copyright year to 2020
Run "TZ=UTC0 admin/update-copyright $(git ls-files)".
2020-01-01 00:59:52 +00:00
Paul Eggert
78669517dc Update from Gnulib
This incorporates:
2019-09-22 Update some URLs
2019-09-15 fcntl-h: fix compilation error of creat.c on MSVC
2019-09-15 creat: new module
2019-09-15 access: new module
2019-09-09 Add option to assume best, not worst, when cross-compiling.
* build-aux/config.guess, build-aux/config.sub, doc/misc/texinfo.tex:
* lib/careadlinkat.c, lib/careadlinkat.h, lib/count-leading-zeros.h:
* lib/count-trailing-zeros.h, lib/diffseq.h, lib/fcntl.in.h:
* lib/ftoastr.c, lib/get-permissions.c:
* lib/ieee754.in.h, lib/inttypes.in.h, lib/mktime.c, lib/open.c:
* lib/pathmax.h, lib/pipe2.c, lib/stddef.in.h, lib/stdint.in.h:
* lib/stdlib.in.h, lib/str-two-way.h, lib/string.in.h, lib/time.in.h:
* lib/timegm.c, lib/unistd.in.h, m4/canonicalize.m4:
* m4/extern-inline.m4, m4/fcntl_h.m4, m4/fdopendir.m4:
* m4/getgroups.m4, m4/getopt.m4, m4/gettimeofday.m4:
* m4/gnulib-common.m4, m4/largefile.m4:
* m4/lstat.m4, m4/memmem.m4, m4/mktime.m4, m4/nocrash.m4, m4/open.m4:
* m4/pselect.m4, m4/putenv.m4, m4/readlink.m4, m4/regex.m4:
* m4/symlink.m4, m4/unistd_h.m4, m4/utimens.m4, m4/utimes.m4:
Copy from Gnulib.
* lib/gnulib.mk.in, m4/gnulib-comp.m4: Regenerate.
* m4/open-slash.m4: New file, copied from Gnulib.
2019-09-22 23:51:44 -07:00
Paul Eggert
115498702d Update from Gnulib
This incorporates mostly just copyright-year changes, plus
recent minor updates from glibc for the non-Emacs regular
expression code.
2018-12-31 18:20:07 -08:00
Paul Eggert
26bed8ba10 Update copyright year to 2019
Run 'TZ=UTC0 admin/update-copyright $(git ls-files)'.
2019-01-01 01:01:13 +00:00
Paul Eggert
220a9ecba1 Merge from Gnulib
This incorporates:
2018-01-01 maint: Run 'make update-copyright'
2017-12-29 Add cross-compilation results for GNU/Hurd.
2017-12-12 explicit_bzero: port to macOS + Clang 9.0.0
2017-12-31 17:21:33 -08:00
Paul Eggert
3ab2f9bbb9 Merge from gnulib
This incorporates:
2017-09-28 string: code style
2017-09-25 sys_types: update URL
2017-09-23 install-sh: do not assume / = //
2017-09-21 mktime: port to OpenVMS
* build-aux/install-sh, m4/mktime.m4, m4/string_h.m4:
* m4/sys_types_h.m4: Copy from Gnulib.
* lib/gnulib.mk.in: Regenerate.
2017-09-29 21:56:21 -07:00
Paul Eggert
3128d5d10e Merge from gnulib
This incorporates:
2017-07-13 Improve cross-compilation guesses for native Windows
2017-07-11 More systematic m4 quoting and indentation
2017-07-10 Make sure $host and $host_os are defined when used
2017-07-03 stdioext: Port to OpenVMS
2017-06-24 xalloc-oversized: port to icc
* doc/misc/texinfo.tex, lib/fpending.c, lib/stdio-impl.h:
* lib/xalloc-oversized.h, m4/dirfd.m4, m4/gettimeofday.m4:
* m4/lstat.m4, m4/mktime.m4, m4/pselect.m4, m4/putenv.m4:
* m4/stdint.m4, m4/strtoimax.m4, m4/utimes.m4:
Copy from Gnulib.
2017-07-13 19:24:49 -07:00
Paul Eggert
b6aa3446df Merge from gnulib
This incorporates:
2017-04-30 strftime-fixes: New module
2017-04-30 mktime: Work around TZ problem on native Windows
2017-04-30 ctime, localtime: New modules
2017-04-30 gettimeofday: Provide higher resolution on native Windows
2017-04-29 utime-h: Modernize handling of 'struct utimbuf'
2017-04-29 Make use of module 'utime-h'
2017-04-30 Fix a few typos
* admin/merge-gnulib (AVOIDED_MODULES): Avoid utime-h, too.
* lib/gettimeofday.c, lib/mktime.c, lib/time.in.h, lib/utimens.c:
* m4/gettimeofday.m4, m4/include_next.m4, m4/mktime.m4:
* m4/strftime.m4, m4/time_h.m4, m4/timegm.m4, m4/utimens.m4:
Copy from gnulib.
* lib/gnulib.mk.in, m4/gnulib-comp.m4: Regenerate.
2017-04-30 14:53:17 -07:00
Paul Eggert
5a59e28dec Merge from gnulib
This incorporates:
2016-12-19 stdint: Fix WINT_MAX to match wint_t on mingw
2016-12-18 getopt: Fix link error for users of getopt() in <unistd.h>
2016-12-17 getlogin: Port to newer mingw
2016-12-17 stdint: Fix WINT_MAX to match wint_t on MSVC
2016-12-17 Avoid redefinition errors on MSVC
* lib/getopt.in.h, lib/stdint.in.h, lib/stdio.in.h, lib/unistd.in.h:
* m4/stdint.m4, m4/unistd_h.m4:
Copy from gnulib.
* lib/gnulib.mk, m4/gnulib-comp.m4: Regenerate.
Plus, this commit updates the indenting on copyright notices to
match that of gnulib.
2017-01-01 01:32:56 -08:00
Paul Eggert
7f9721d399 Update from gnulib
This incorporates:
2016-07-03 mktime: call tzset as per POSIX
* doc/misc/texinfo.tex, lib/mktime.c, m4/mktime.m4:
Copy from gnulib.
2016-08-03 15:12:06 -07:00
Paul Eggert
3707f609cb Sync from gnulib
This incorporates:
2016-05-01 mktime: port to stricter signed overflow checking
2016-05-01 mktime: speed up DEBUG_MKTIME benchmarks
2016-05-01 mktime: resurrect DEBUG_MKTIME testing
2016-05-01 mktime: simplify DEBUG_MKTIME
2016-05-01 Port mktime_internal offset to unsigned time_t
2016-04-27 xstrtol: prohibit monstrosities like "1bB"
2016-04-13 mktime: improve integer overflow checking
2016-04-13 intprops: check two's complement assumption
2016-04-13 intprops, mktime, strtol: assume two's complement
* lib/intprops.h, lib/mktime-internal.h, lib/mktime.c:
* lib/strtol.c, lib/timegm.c, m4/mktime.m4, m4/std-gnu11.m4:
Copy from gnulib.
2016-05-01 18:37:01 -07:00
Paul Eggert
cd19641ed3 Merge from gnulib
This mostly just updates copyright dates of gnulib files.
It also updates to the latest version of texinfo.tex.
2016-01-18 22:29:10 -08:00
Paul Eggert
035f5aaa91 Merge from gnulib, incorporating:
2015-01-01 version-etc: new year
2015-01-01 11:06:53 -08:00
Paul Eggert
ba3189039a Update copyright year to 2014 by running admin/update-copyright. 2014-01-01 07:43:34 +00:00
Paul Eggert
5615c9a9af Merge from gnulib.
This incorporates:
2013-03-12 mktime: fix configure typo
2013-03-11 regex: port to mingw's recent addition of undeclared alarm
2013-03-11 putenv: avoid compilation warning on mingw
2013-03-11 unistd: don't prevent Tru64 Unix from using gnulib strtod.
2013-03-12 17:38:42 -07:00
Paul Eggert
ab422c4d68 Update copyright notices for 2013. 2013-01-01 09:11:05 +00:00
Paul Eggert
562d4436bc Merge from gnulib.
2012-08-19 ignore-value, stat-time, timespec: omit AC_C_INLINE
2012-08-19 mktime, sys_select: avoid 'static inline'
2012-08-19 gnulib-tool: Fix indentation.
2012-08-19 16:31:24 -07:00
Paul Eggert
057306483c Merge from gnulib.
* lib/filemode.h, lib/signal.in.h, lib/stat.c, lib/stdint.in.h:
* lib/stdlib.in.h, lib/unistd.in.h, m4/extensions.m4, m4/getloadavg.m4:
* m4/getopt.m4, m4/gnulib-common.m4, m4/largefile.m4, m4/mktime.m4:
* m4/multiarch.m4, m4/nocrash.m4, m4/stdio_h.m4, m4/time_r.m4:
Copy new versions from gnulib, incorporating the following changes:
2012-06-22 time_r: fix typo that always overrode localtime_r decl
2012-06-22 Write "Mac OS X" instead of "MacOS X".
2012-06-21 mktime: fix integer overflow in 'configure'-time test
2012-06-21 nonblocking: Avoid compilation error on mingw64.
2012-06-19 stat, fstat: Avoid warnings on mingw64.
2012-06-19 getopt-gnu: Fix exit code overflow in autoconf test.
2012-06-22 10:20:00 -07:00
Paul Eggert
caf8a9b2b3 Merge from gnulib.
Fixes: debbugs:11527
2012-05-26 16:14:36 -07:00
Paul Eggert
8aeb5be96a Merge from gnulib: lib/gnulib.mk, m4/*.m4. 2011-06-15 15:27:54 -07:00
Paul Eggert
f518ae90a6 Merge from gnulib. 2011-05-22 14:02:48 -07:00
Paul Eggert
3de84ad9c4 gnulib: import mktime and move-if-change fixes from gnulib
* configure: Regenerate from the following.

2011-01-30  Paul Eggert  <eggert@cs.ucla.edu>

mktime: clarify long_int width checking
* lib/mktime.c (long_int_is_wide_enough): Move this assertion to
the top level, to make it clearer that the assumption about
long_int width is being checked.  See
<http://lists.gnu.org/archive/html/bug-gnulib/2011-01/msg00554.html>.

2011-01-29  Paul Eggert  <eggert@cs.ucla.edu>

TYPE_MAXIMUM: avoid theoretically undefined behavior
* lib/intprops.h (TYPE_MINIMUM, TYPE_MAXIMUM): Do not shift a
negative number, which the C Standard says has undefined behavior.
In practice this is not a problem, but might as well do it by the book.
Reported by Rich Felker and Eric Blake; see
<http://lists.gnu.org/archive/html/bug-gnulib/2011-01/msg00493.html>.
* m4/mktime.m4 (AC_FUNC_MKTIME): Likewise.
* lib/mktime.c (TYPE_MAXIMUM): Redo slightly to match the others.

mktime: #undef mktime before #defining it
* lib/mktime.c (mktime) [DEBUG]: #undef mktime before #defining it.

mktime: systematically normalize tm_isdst comparisons
* lib/mktime.c (isdst_differ): New function.
(__mktime_internal): Use it systematically for all isdst comparisons.
This completes the fix for libc BZ #6723, and removes the need for
normalizing tm_isdst.  See
<http://sourceware.org/bugzilla/show_bug.cgi?id=6723>
(not_equal_tm) [DEBUG]: Use isdst_differ here, too.

mktime: fix some integer overflow issues and sidestep the rest

This was prompted by a bug report by Benjamin Lindner for MinGW
<http://lists.gnu.org/archive/html/bug-gnulib/2011-01/msg00472.html>.
His bug is due to signed integer overflow (0 - INT_MIN), and I
I scanned through mktime.c looking for other integer overflow
problems, fixing all the bugs I found.

Although the C Standard says the resulting code is still not safe
in the presence of integer overflow, in practice it should be good
enough for all real-world two's-complement implementations, except
for debugging environments that deliberately trap on integer
overflow (e.g., gcc -ftrapv).

* lib/mktime.c (WRAPV): New macro.
(SHR): Also check that long_int and time_t shift right in the
usual way, before using the fast-but-unportable method.
(TYPE_ONES_COMPLEMENT, TYPE_SIGNED_MAGNITUDE): Remove, no longer
used.  The code already assumed two's complement, so there's
no need to test for alternatives.  All uses removed.
(TYPE_MAXIMUM): Don't rely here on overflow behavior not defined by
the C standard.  Problem reported by Rich Felker in
<http://lists.gnu.org/archive/html/bug-gnulib/2011-01/msg00488.html>.
(twos_complement_arithmetic): Also check long_int and time_t.
(time_t_avg, time_t_add_ok, time_t_int_add_ok): New functions.
(guess_time_tm, ranged_convert, __mktime_internal): Use them.
(__mktime_internal): Avoid integer overflow with unary subtraction
in two instances where -1 - X is an adequate replacement for -X,
since the calculations are approximate.

2011-01-29  Eric Blake  <eblake@redhat.com>

mktime: avoid infinite loop
* m4/mktime.m4 (AC_FUNC_MKTIME): Avoid overflow on possibly-signed
type; behavior is still undefined but portable to all known targets.
Reported by Rich Felker.

2011-01-28  Paul Eggert  <eggert@cs.ucla.edu>

mktime: avoid problems on NetBSD 5 / i386
* lib/mktime.c (long_int): New type.  This works around a problem
on NetBSD 5 / i386, where 'long int' and 'int' are both 32 bits
but time_t is 64 bits, and where I expect the existing code is
wrong in some cases.
(leapyear, ydhms_diff, guess_time_tm, __mktime_internal): Use it.
(ydhms_diff): Bring back the compile-time check for wide-enough
year and yday.

mktime: fix misspelling in comment
* lib/mktime.c (__mktime_internal): Fix misspelling in comment.
This merges all recent glibc changes of importance.

2011-01-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>

move-if-change: cope with concurrent mv of identical file.
* move-if-change (CMPPROG): Accept environment
variable as an override for `cmp'.
(usage): Document CMPPROG.
Adjust comparison to drop stdout.  Cope with failure of mv if
the target file exists and is identical to the source, for
parallel builds.
Report from H.J. Lu against binutils in PR binutils/12283.
2011-01-30 11:22:02 -08:00
Paul Eggert
1fd182f018 Regenerate. 2011-01-08 22:57:07 -08:00