]> Savannah Git Hosting - gnulib.git/log
gnulib.git
7 years agoautoupdate
Karl Berry [Sun, 11 Mar 2018 21:42:07 +0000 (14:42 -0700)]
autoupdate

7 years agofflush: be more paranoid about libio.h change
Paul Eggert [Fri, 9 Mar 2018 00:42:45 +0000 (16:42 -0800)]
fflush: be more paranoid about libio.h change

Suggested by Eli Zaretskii in:
https://lists.gnu.org/r/emacs-devel/2018-03/msg00270.html
* lib/fbufmode.c (fbufmode):
* lib/fflush.c (clear_ungetc_buffer_preserving_position)
(disable_seek_optimization, rpl_fflush):
* lib/fpending.c (__fpending):
* lib/fpurge.c (fpurge):
* lib/freadable.c (freadable):
* lib/freadahead.c (freadahead):
* lib/freading.c (freading):
* lib/freadptr.c (freadptr):
* lib/freadseek.c (freadptrinc):
* lib/fseeko.c (fseeko):
* lib/fseterr.c (fseterr):
* lib/fwritable.c (fwritable):
* lib/fwriting.c (fwriting):
Look at _IO_ftrylockfile as well as at _IO_EOF_SEEN.

7 years agoautoupdate
Paul Eggert [Thu, 8 Mar 2018 01:26:25 +0000 (17:26 -0800)]
autoupdate

7 years agoautoupdate
Paul Eggert [Thu, 8 Mar 2018 00:44:58 +0000 (16:44 -0800)]
autoupdate

7 years agoautoupdate
Paul Eggert [Wed, 7 Mar 2018 19:45:17 +0000 (11:45 -0800)]
autoupdate

7 years agomaint: write-file-hooks -> before-save-hook
Paul Eggert [Wed, 7 Mar 2018 08:29:38 +0000 (00:29 -0800)]
maint: write-file-hooks -> before-save-hook

write-file-hooks is obsolete since Emacs 22.1 (released June 2007) and
it's time to use the recommended replacement.
Problem reported by Glenn Morris in:
https://lists.gnu.org/r/bug-gnulib/2018-03/msg00008.html
* build-aux/announce-gen, build-aux/bootstrap:
* build-aux/do-release-commit-and-tag, build-aux/gendocs.sh:
* build-aux/git-version-gen, build-aux/gitlog-to-changelog:
* build-aux/gnu-web-doc-update, build-aux/gnupload:
* build-aux/move-if-change, build-aux/prefix-gnulib-mk:
* build-aux/update-copyright, build-aux/useless-if-before-free:
* build-aux/vc-list-files:
Update hook usage for files where Gnulib is the canonical source.

7 years agoautoupdate
Paul Eggert [Wed, 7 Mar 2018 04:29:14 +0000 (20:29 -0800)]
autoupdate

7 years agobinary-io: pacify gcc -Wunused-parameter
Paul Eggert [Mon, 5 Mar 2018 23:30:56 +0000 (15:30 -0800)]
binary-io: pacify gcc -Wunused-parameter

Problem reported by Reuben Thomas in:
https://lists.gnu.org/r/bug-gnulib/2018-03/msg00005.html
* lib/binary-io.h (__gl_setmode, __gl_setmode_check):
Use _GL_UNUSED where appropriate.

7 years agofflush: adjust to glibc 2.28 libio.h removal
Paul Eggert [Mon, 5 Mar 2018 18:56:29 +0000 (10:56 -0800)]
fflush: adjust to glibc 2.28 libio.h removal

Problem reported by Daniel P. Berrangé in:
https://lists.gnu.org/r/bug-gnulib/2018-03/msg00000.html
* lib/fbufmode.c (fbufmode):
* lib/fflush.c (clear_ungetc_buffer_preserving_position)
(disable_seek_optimization, rpl_fflush):
* lib/fpending.c (__fpending):
* lib/fpurge.c (fpurge):
* lib/freadable.c (freadable):
* lib/freadahead.c (freadahead):
* lib/freading.c (freading):
* lib/freadptr.c (freadptr):
* lib/freadseek.c (freadptrinc):
* lib/fseeko.c (fseeko):
* lib/fseterr.c (fseterr):
* lib/fwritable.c (fwritable):
* lib/fwriting.c (fwriting):
Check _IO_EOF_SEEN instead of _IO_ftrylockfile.
* lib/stdio-impl.h (_IO_IN_BACKUP) [_IO_EOF_SEEN]:
Define if not already defined.

7 years agoautoupdate
Karl Berry [Thu, 1 Mar 2018 16:26:50 +0000 (08:26 -0800)]
autoupdate

7 years agoautoupdate
Karl Berry [Wed, 28 Feb 2018 19:09:30 +0000 (11:09 -0800)]
autoupdate

7 years agoenviron: fix link error on 32-bit Cygwin
Paul Eggert [Tue, 27 Feb 2018 17:04:42 +0000 (09:04 -0800)]
environ: fix link error on 32-bit Cygwin

Problem reported for GNU Emacs by Ken Brown in:
https://lists.gnu.org/r/emacs-devel/2018-02/msg00765.html
* lib/unistd.in.h (environ) [__i386__]: Do not redeclare.

7 years agoautoupdate
Karl Berry [Mon, 26 Feb 2018 16:32:38 +0000 (08:32 -0800)]
autoupdate

7 years agombrtowc tests: Fix regression on glibc.
Bruno Haible [Sun, 25 Feb 2018 00:56:35 +0000 (01:56 +0100)]
mbrtowc tests: Fix regression on glibc.

Reported by Bernhard Voelker.

* tests/test-mbrtowc.c (main): Fix expected value of wc.

7 years agoautoupdate
Karl Berry [Sat, 24 Feb 2018 16:55:16 +0000 (08:55 -0800)]
autoupdate

7 years agostriconveha, uniconv/*: Avoid test failures on musl libc.
Bruno Haible [Sat, 24 Feb 2018 14:21:11 +0000 (15:21 +0100)]
striconveha, uniconv/*: Avoid test failures on musl libc.

* tests/iconvsupport.c: New file.
* tests/test-striconveha.c (main): Skip autodetect_jp tests if iconv()
does not support the ISO-2022-JP-2 encoding.
* tests/uniconv/test-u8-conv-from-enc.c (main): Likewise.
* tests/uniconv/test-u8-strconv-from-enc.c (main): Likewise.
* tests/uniconv/test-u16-conv-from-enc.c (main): Likewise.
* tests/uniconv/test-u16-strconv-from-enc.c (main): Likewise.
* tests/uniconv/test-u32-conv-from-enc.c (main): Likewise.
* tests/uniconv/test-u32-strconv-from-enc.c (main): Likewise.
* modules/striconveha-tests (Files): Add tests/iconvsupport.c.
(Makefile.am): Link test-striconveha with iconvsupport.o.
* modules/uniconv/u8-conv-from-enc-tests (Files): Add
tests/iconvsupport.c.
(Makefile.am): Link test-u8-conv-from-enc with iconvsupport.o.
* modules/uniconv/u8-strconv-from-enc-tests (Files): Add
tests/iconvsupport.c.
(Makefile.am): Link test-u8-strconv-from-enc with iconvsupport.o.
* modules/uniconv/u16-conv-from-enc-tests (Files): Add
tests/iconvsupport.c.
(Makefile.am): Link test-u16-conv-from-enc with iconvsupport.o.
* modules/uniconv/u16-strconv-from-enc-tests (Files): Add
tests/iconvsupport.c.
(Makefile.am): Link test-u16-strconv-from-enc with iconvsupport.o.
* modules/uniconv/u32-conv-from-enc-tests (Files): Add
tests/iconvsupport.c.
(Makefile.am): Link test-u32-conv-from-enc with iconvsupport.o.
* modules/uniconv/u32-strconv-from-enc-tests (Files): Add
tests/iconvsupport.c.
(Makefile.am): Link test-u32-strconv-from-enc with iconvsupport.o.

7 years agolocalename: Add support for musl libc.
Bruno Haible [Sat, 24 Feb 2018 11:59:59 +0000 (12:59 +0100)]
localename: Add support for musl libc.

* m4/localename.m4 (gl_LOCALENAME): Check for <langinfo.h>.
* lib/localename.c (gl_locale_name_thread_unsafe): Use NL_LOCALE_NAME
on Linux platforms which define NL_LOCALE_NAME.

7 years agombrtowc tests: Don't make assumptions about the charset the C locale.
Bruno Haible [Sat, 24 Feb 2018 11:01:30 +0000 (12:01 +0100)]
mbrtowc tests: Don't make assumptions about the charset the C locale.

* tests/test-mbrtowc.c (main): For bytes >= 0x80, don't assume a
particular mapping in the C locale.

7 years agoptsname_r: Don't expect that this function sets errno.
Bruno Haible [Sat, 24 Feb 2018 09:53:24 +0000 (10:53 +0100)]
ptsname_r: Don't expect that this function sets errno.

* tests/test-ptsname_r.c (test_errors): Don't test errno after return
from ptsname_r().
* doc/glibc-functions/ptsname_r.texi: Mention the issue.

7 years agoxmalloca: pacify gcc -Wbad-function-cast
Bruno Haible [Sat, 24 Feb 2018 00:33:35 +0000 (01:33 +0100)]
xmalloca: pacify gcc -Wbad-function-cast

* lib/xmalloca.h (xmalloca): Insert intermediate cast here as well.

7 years agonl_langinfo: pacify gcc -Wunused-function
Paul Eggert [Fri, 23 Feb 2018 21:15:24 +0000 (13:15 -0800)]
nl_langinfo: pacify gcc -Wunused-function

* lib/nl_langinfo.c (ctype_codeset): Do not define if
REPLACE_NL_LANGINFO && !GNULIB_defined_CODESET, as it is unused in
this case.  Without this change, I got a diagnostic when building
coreutils on Fedora 27 with gcc 7.3.1 20180130.

7 years agosame: pacify gcc -Wunused-variable
Paul Eggert [Fri, 23 Feb 2018 20:52:42 +0000 (12:52 -0800)]
same: pacify gcc -Wunused-variable

* lib/same.c (same_nameat) [!CHECK_TRUNCATION]:
Omit unused variable.

7 years agomalloca: pacify gcc -Wbad-function-cast
Paul Eggert [Fri, 23 Feb 2018 20:47:38 +0000 (12:47 -0800)]
malloca: pacify gcc -Wbad-function-cast

* lib/malloca.h (malloca): Pacify gcc -Wbad-function-cast
diagnostic that I got on Fedora 27 with gcc 7.3.1 20180130.
To pacify GCC, I had to cast alloca’s result to some type other
than void * before casting that to uintptr_t.

7 years agoautoupdate
Karl Berry [Thu, 22 Feb 2018 15:43:48 +0000 (07:43 -0800)]
autoupdate

7 years agoutimecmp: new function utimecmpat
Paul Eggert [Tue, 20 Feb 2018 17:06:51 +0000 (09:06 -0800)]
utimecmp: new function utimecmpat

* lib/utimecmp.c: Include fcntl.h, sys/stat.h and dirname.h.
Do not include utimens.h.
(utimecmpat): New function, generalizing utimecmp.
(utimecmp): Now a thin layer around utimecmpat.
* modules/utimecmp (Depends-on): Depend on dirname-lgpl, fstatat,
utimensat instead of on lstat and utimens.

7 years agosame: new function same_nameat
Paul Eggert [Tue, 20 Feb 2018 17:05:48 +0000 (09:05 -0800)]
same: new function same_nameat

* lib/same.c: Include fcntl.h.
* lib/same.c (same_nameat): New function, generalizing same_name.
(same_name): Now a thin layer around same_nameat.
* m4/same.m4 (gl_SAME): Check for fpathconf, not pathconf.
* modules/same (Depends-on): Depend on fstatat, openat.

7 years agowarnings: Add support for Objective C.
Eric Gallager [Sun, 18 Feb 2018 14:41:09 +0000 (15:41 +0100)]
warnings: Add support for Objective C.

* m4/warnings.m4 (gl_UNKNOWN_WARNINGS_ARE_ERRORS(Objective C)): New
macro.

7 years agolock: Fix test-once1 crash on FreeBSD11.
Bruno Haible [Sat, 17 Feb 2018 09:23:35 +0000 (10:23 +0100)]
lock: Fix test-once1 crash on FreeBSD11.

* lib/glthread/lock.h: On FreeBSD, test the weak value of the symbol
'pthread_create', not 'pthread_cancel'.

7 years agolock: Add test of gl_once.
Bruno Haible [Sat, 17 Feb 2018 09:05:01 +0000 (10:05 +0100)]
lock: Add test of gl_once.

* tests/test-once.c: New file.
* modules/lock-tests (Files): Add it.
(Makefile.am): Build and test programs 'test-once1' and 'test-once2'.

7 years agothread: Fix compilation error on IRIX.
Bruno Haible [Sat, 17 Feb 2018 08:55:43 +0000 (09:55 +0100)]
thread: Fix compilation error on IRIX.

* lib/glthread/thread.h: Include <unistd.h>. Include <signal.h> when
needed; include it outside the C++ extern "C" {} block.
* doc/posix-headers/pthread.texi: Mention the problem with
pthread_atfork on IRIX.

7 years agonl_langinfo: Override the system's nl_langinfo() when needed.
Bruno Haible [Sun, 4 Feb 2018 10:00:38 +0000 (11:00 +0100)]
nl_langinfo: Override the system's nl_langinfo() when needed.

Reported by Jim Meyering.

* m4/nl_langinfo.m4 (gl_FUNC_NL_LANGINFO): Set REPLACE_NL_LANGINFO=1
also when HAVE_LANGINFO_T_FMT_AMPM or HAVE_LANGINFO_ALTMON is 0.

7 years agosignal-h, monetary, strings: Fix build failure in some cases.
Bruno Haible [Sun, 4 Feb 2018 09:42:45 +0000 (10:42 +0100)]
signal-h, monetary, strings: Fix build failure in some cases.

Reported by Tim Rühsen <tim.ruehsen@gmx.de>.

* modules/signal-h (Makefile.am): In the GNULIB_* substitutions, use '/'
as delimiter in sed command, not '|'.
* modules/monetary (Makefile.am): Likewise.
* modules/strings (Makefile.am): Likewise.

7 years agomaint.mk: exempt "/proc/filesystems" from "file system" syntax check
Jim Meyering [Sun, 4 Feb 2018 00:57:36 +0000 (16:57 -0800)]
maint.mk: exempt "/proc/filesystems" from "file system" syntax check

* top/maint.mk (sc_file_system): Don't complain about
"/proc/filesystems".

7 years agostdlib: Fix compilation error on OpenIndiana.
Bruno Haible [Sat, 3 Feb 2018 13:05:45 +0000 (14:05 +0100)]
stdlib: Fix compilation error on OpenIndiana.

* lib/stdlib.in.h: Before including <sys/loadavg.h>, include
<sys/time.h>.
* m4/stdlib_h.m4 (gl_STDLIB_H): Likewise.
* m4/getloadavg.m4 (gl_GETLOADAVG): Likewise.

7 years agohost-cpu-c-abi: Avoid use of 'grep -E' on OpenIndiana.
Bruno Haible [Sat, 3 Feb 2018 11:50:17 +0000 (12:50 +0100)]
host-cpu-c-abi: Avoid use of 'grep -E' on OpenIndiana.

* m4/asm-underscore.m4 (gl_ASM_SYMBOL_PREFIX): Require AC_PROG_EGREP,
and use $EGREP instead of 'grep -E'.
* m4/host-cpu-c-abi.m4 (gl_HOST_CPU_C_ABI): Use 'grep' instead of
'grep -E'.

7 years agomalloca: Add a compile-time verification.
Paul Eggert [Fri, 2 Feb 2018 23:47:15 +0000 (00:47 +0100)]
malloca: Add a compile-time verification.

* lib/malloca.c (small_t): Verify that it is wide enough.
* modules/malloca (Depends-on): Add verify.

7 years agomalloca: Add an argument check.
Bruno Haible [Fri, 2 Feb 2018 23:32:41 +0000 (00:32 +0100)]
malloca: Add an argument check.

Suggested by Paul Eggert.

* lib/malloca.c (freea): Check against an invalid argument.

7 years agolocalename: Add support for OpenIndiana.
Bruno Haible [Fri, 2 Feb 2018 20:34:14 +0000 (21:34 +0100)]
localename: Add support for OpenIndiana.

* lib/localename.c (gl_locale_name_thread_unsafe): Add code for
Solaris 11 variants with uselocale() but without getlocalename_l().

7 years agomalloca, xmalloca: Make multithread-safe.
Bruno Haible [Fri, 2 Feb 2018 18:32:02 +0000 (19:32 +0100)]
malloca, xmalloca: Make multithread-safe.

Reported by Florian Weimer <fweimer@redhat.com>.
Implements an idea by Ondřej Bílka <neleai@seznam.cz>.

* lib/malloca.h (malloca): In the stack allocation case, return a
pointer that is a multiple of 2 * sa_alignment_max.
(sa_increment): Remove enum item.
* lib/xmalloca.h (xmalloca): In the stack allocation case, return
a pointer that is a multiple of 2 * sa_alignment_max.
* lib/malloca.c (NO_SANITIZE_MEMORY): Remove macro.
(MAGIC_NUMBER, MAGIC_SIZE, preliminary_header, HEADER_SIZE, header,
HASH_TABLE_SIZE, mmalloca_results): Remove.
(small_t): New type.
(mmalloca, free): Rewritten.
* lib/malloca.valgrind: Remove file.
* modules/malloca (Files): Remove it.
(Depends-on): Remove verify.

7 years agoenviron: Fix link error on 64-bit Cygwin.
Bruno Haible [Wed, 31 Jan 2018 08:04:52 +0000 (09:04 +0100)]
environ: Fix link error on 64-bit Cygwin.

* lib/unistd.in.h (environ): On Cygwin, redeclare with the
__declspec(dllimport) attribute.
* doc/posix-functions/environ.texi: Mention the Cygwin problem.

7 years agoget-rusage-data: Add support for Minix 3.
Bruno Haible [Tue, 30 Jan 2018 08:05:57 +0000 (09:05 +0100)]
get-rusage-data: Add support for Minix 3.

* lib/get-rusage-data.c (get_rusage_data): Return 0 on Minix.

7 years agovma-iter: Add support for Minix 3.
Bruno Haible [Tue, 30 Jan 2018 08:02:46 +0000 (09:02 +0100)]
vma-iter: Add support for Minix 3.

* lib/vma-iter.h (VMA_ITERATE_SUPPORTED): Define on Minix.
* lib/vma-iter.c: On Minix, read /proc/<pid>/map.

7 years agoFix malfunction of socket functions on HP-UX in 64-bit mode.
Bruno Haible [Sat, 27 Jan 2018 09:57:59 +0000 (10:57 +0100)]
Fix malfunction of socket functions on HP-UX in 64-bit mode.

* m4/socketlib.m4 (gl_SOCKETLIB): Add comment.
* m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS): Define
_HPUX_ALT_XOPEN_SOCKET_API.
* modules/accept (Depends-on): Add 'extensions'.
* modules/getpeername (Depends-on): Likewise.
* modules/getsockname (Depends-on): Likewise.
* modules/getsockopt (Depends-on): Likewise.
* modules/recvfrom (Depends-on): Likewise.
* doc/posix-functions/accept.texi: Mention the HP-UX socklen_t problem.
* doc/posix-functions/getpeername.texi: Likewise.
* doc/posix-functions/getsockname.texi: Likewise.
* doc/posix-functions/getsockopt.texi: Likewise.
* doc/posix-functions/recvfrom.texi: Likewise.

7 years agogetsockname tests: More tests.
Bruno Haible [Sat, 27 Jan 2018 07:52:31 +0000 (08:52 +0100)]
getsockname tests: More tests.

* tests/test-getsockname.c (open_server_socket): New function, mostly
copied from test-poll.c.
(main): Check that getsockname fills in addr.
* modules/getsockname-tests (Depends-on): Add the necessary
dependencies.
(test_getsockname_LDADD): Link with $(INET_PTON_LIB).

7 years agomanywarnings: fix maintainer comment
Paul Eggert [Sat, 27 Jan 2018 02:08:36 +0000 (18:08 -0800)]
manywarnings: fix maintainer comment

* m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC): Fix comment so that
it does not mistakenly think that ‘-1)’ is an option.

7 years agoautoupdate
Karl Berry [Fri, 26 Jan 2018 16:52:43 +0000 (08:52 -0800)]
autoupdate

7 years agolanginfo: Fix last commit.
Bruno Haible [Fri, 26 Jan 2018 04:51:55 +0000 (05:51 +0100)]
langinfo: Fix last commit.

Reported by Tim Rühsen <tim.ruehsen@gmx.de>.

* modules/langinfo (Makefile.am): Substitute HAVE_LANGINFO_ALTMON.

7 years agolanginfo, nl_langinfo: Add support for alternative month names.
Bruno Haible [Wed, 24 Jan 2018 09:02:17 +0000 (10:02 +0100)]
langinfo, nl_langinfo: Add support for alternative month names.

* m4/langinfo_h.m4 (gl_LANGINFO_H): Define HAVE_LANGINFO_ALTMON.
* lib/langinfo.in.h (ALTMON_1...ALTMON_12): New macros.
* lib/nl_langinfo.c (rpl_nl_langinfo): Treat ALTMON_i like MON_i.
* tests/test-nl_langinfo.c (main): Test ALTMON_*.
* doc/posix-headers/langinfo.texi: Document support of ALTMON_*.
* doc/posix-functions/nl_langinfo.texi: Likewise.

7 years agoMerge strftime.c changes from glibc
Paul Eggert [Tue, 23 Jan 2018 08:42:04 +0000 (00:42 -0800)]
Merge strftime.c changes from glibc

This incorporates:
2017-11-14 [BZ #10871] Implement alternative month names
2017-11-14 [BZ #10871] Abbreviated alternative month names (%Ob)
2017-06-20 Use locale_t, not __locale_t, throughout glibc
* lib/nstrftime.c (ABALTMON_1) [!COMPILE_WIDE]: New macro.
(LOCALE_PARAM) [_LIBC && USE_IN_EXTENDED_LOCALE_MODEL]:
Use locale_t, not __locale_t.
(a_altmonth, f_altmonth, aam_len) [_NL_CURRENT]: New macros.
(__strftime_internal): Add support for alternate months.

7 years agoFix typo in comment.
Reuben Thomas [Tue, 23 Jan 2018 08:15:49 +0000 (09:15 +0100)]
Fix typo in comment.

* lib/glthread/thread.h: Fix typo.

7 years agodoc: Mention another prerequisite for using Gnulib.
Bruno Haible [Tue, 23 Jan 2018 08:13:13 +0000 (09:13 +0100)]
doc: Mention another prerequisite for using Gnulib.

Reported at <https://stackoverflow.com/questions/48378214/>.

* doc/gnulib-tool.texi (Initial import): Mention requirement to use
AC_CONFIG_HEADERS.

7 years agobuild: GuixSD doesn't have /bin/bash
Mathieu Lirzin [Mon, 22 Jan 2018 21:14:55 +0000 (22:14 +0100)]
build: GuixSD doesn't have /bin/bash

* Makefile (SHELL): Search 'bash' in the PATH environment variable.

7 years agoAvoid test failures on Microsoft Windows Subsystem for Linux.
Bruno Haible [Mon, 22 Jan 2018 04:01:48 +0000 (05:01 +0100)]
Avoid test failures on Microsoft Windows Subsystem for Linux.

* tests/test-fcntl.c (main): Allow a different errno.
* tests/test-rename.h (test_rename): Likewise.
* tests/test-renameat.c (main): Likewise.
* tests/test-renameat2.c (main): Likewise.

7 years agocanonicalize-lgpl: fix typo
Paul Eggert [Wed, 17 Jan 2018 23:09:59 +0000 (15:09 -0800)]
canonicalize-lgpl: fix typo

Problem reported by Reuben Thomas.

7 years agoautoupdate
Karl Berry [Wed, 17 Jan 2018 18:09:24 +0000 (10:09 -0800)]
autoupdate

7 years agoautoupdate
Karl Berry [Tue, 16 Jan 2018 17:08:02 +0000 (09:08 -0800)]
autoupdate

7 years agoautoupdate
Karl Berry [Mon, 15 Jan 2018 17:52:48 +0000 (09:52 -0800)]
autoupdate

7 years agofilenamecat: make base a suffix of result
Paul Eggert [Sun, 14 Jan 2018 21:27:20 +0000 (13:27 -0800)]
filenamecat: make base a suffix of result

* lib/filenamecat-lgpl.c (longest_relative_suffix): Remove.
(mfile_name_concat): Always make BASE a suffix of the result, as
cp expects this.  To implement this, separate with '.' instead of
'/' in some rare cases.  Clarify spec to say ./BASE not BASE.
* tests/test-filenamecat.c (main): Adjust tests to match
current behavior.  Check that BASE_IN_RESULT points to
a copy of BASE and is a suffix of the resultk, and that DIR
is a prefix of the result that is no longer than the prefix
indicated by BASE_IN_RESULT.

7 years agoautoupdate
Karl Berry [Sun, 14 Jan 2018 17:51:15 +0000 (09:51 -0800)]
autoupdate

7 years agoautoupdate
Karl Berry [Sat, 13 Jan 2018 17:04:47 +0000 (09:04 -0800)]
autoupdate

7 years agoautoupdate
Karl Berry [Thu, 11 Jan 2018 17:05:03 +0000 (09:05 -0800)]
autoupdate

7 years agoautoupdate
Karl Berry [Wed, 10 Jan 2018 19:03:49 +0000 (11:03 -0800)]
autoupdate

7 years agomaint: Add encoding marker for Emacs to non-ASCII sources.
Bruno Haible [Fri, 5 Jan 2018 21:08:14 +0000 (22:08 +0100)]
maint: Add encoding marker for Emacs to non-ASCII sources.

Similar to commit f406941a8a2ec5fbf3eacc386b9be09d6593d53b
from Paul Eggert <eggert@cs.ucla.edu> 2015-09-24.

To determine the file list that need the marker, I used the command:

for f in `find . -type f | grep -v '^\./\.git/' | grep -v '^\./tests/'`; do
  if iconv -f ASCII -t ASCII < $f > /dev/null 2>&1 ; then : ; else
    if iconv -f UTF-8 -t UTF-8 < $f > /dev/null 2>&1 ; then
      if grep 'The GNU C Library is' $f > /dev/null; then :; else
        if grep 'coding: utf-8' $f > /dev/null; then :; else
          echo $f
        fi
      fi
    fi
  fi
done | LC_ALL=C sort

7 years agoupdate-copyright: Handle use of ©
Mathieu Lirzin [Thu, 4 Jan 2018 14:59:04 +0000 (15:59 +0100)]
update-copyright: Handle use of ©

* build-aux/update-copyright ($circle_c_re): Update regex to
handle use of © in headers.

7 years agoautoupdate
Karl Berry [Fri, 5 Jan 2018 17:36:34 +0000 (09:36 -0800)]
autoupdate

7 years agoFix -Wundef warning in user-included header lib/cdefs.h.
Tim Rühsen [Wed, 3 Jan 2018 10:50:07 +0000 (11:50 +0100)]
Fix -Wundef warning in user-included header lib/cdefs.h.

* lib/cdefs.h: Check if defined before using __USE_FORTIFY_LEVEL.

7 years agopthread_sigmask: Avoid compilation error on mingw.
Bruno Haible [Thu, 4 Jan 2018 09:42:21 +0000 (10:42 +0100)]
pthread_sigmask: Avoid compilation error on mingw.

Reported by Tim Rühsen <tim.ruehsen@gmx.de>.

* lib/signal.in.h (pthread_sigmask): Don't declare it it's defined as a
macro.

7 years agotest-framework-sh: ‘ps -ef’, not ‘ps ef’
Paul Eggert [Wed, 3 Jan 2018 21:29:49 +0000 (13:29 -0800)]
test-framework-sh: ‘ps -ef’, not ‘ps ef’

* tests/init.sh (rand_bytes_): Put ‘-’ before new-style ps options.
Suggested by Bob Proulx (Bug#29968).
* build-aux/mktempd (rand_bytes): Make it like tests/init.sh.

7 years agostat-time: silence -Wunused-parameter regression
Eric Blake [Tue, 2 Jan 2018 21:49:27 +0000 (15:49 -0600)]
stat-time: silence -Wunused-parameter regression

Commit 2c5d5587 causes warnings on non-Sun systems when compiled
under -Wunused-parameter; we've previously tweaked code in commit
81eb8486 to avoid such warnings.  Prefer an attribute rather than
a cast to void (the attribute is always okay to apply; gcc
interprets it as 'may be unused', not 'must not be used', precisely
to cater to #if chains where determining whether or not the
parameter is used gets hairy).

* lib/stat-time.h (get_stat_birthtime_ns, get_stat_birthtime):
Prefer attribute over cast-to-void.
(stat_time_normalize): Mark st as potentially unused.

Signed-off-by: Eric Blake <eblake@redhat.com>
7 years agotest-framework-sh: avoid netstat
Paul Eggert [Wed, 3 Jan 2018 03:05:05 +0000 (19:05 -0800)]
test-framework-sh: avoid netstat

Problem reported by Kristýna Streitová (Bug#29947).
* tests/init.sh (rand_bytes_): Stop using netstat, as it's
deprecated on SuSE and it's not that important anyway.

7 years agoautoupdate
Karl Berry [Tue, 2 Jan 2018 16:30:34 +0000 (08:30 -0800)]
autoupdate

7 years agoupdate-copyright: add code to handle more special cases
Jim Meyering [Tue, 2 Jan 2018 00:12:39 +0000 (16:12 -0800)]
update-copyright: add code to handle more special cases

After running "make update-copyright" this year, five files
required additional manual changes.  Automate those adjustments
for next year.
* Makefile (_year_and_prev): Define.
(update-copyright): Add perl commands to induce this year's post-
update-copyright adjustments.

7 years agoautoupdate
Karl Berry [Mon, 1 Jan 2018 16:52:44 +0000 (08:52 -0800)]
autoupdate

7 years agoversion-etc: new year
Paul Eggert [Mon, 1 Jan 2018 00:57:25 +0000 (00:57 +0000)]
version-etc: new year

* build-aux/gendocs.sh (version):
* doc/gendocs_template:
* doc/gendocs_template_min:
* doc/gnulib.texi:
* lib/version-etc.c (COPYRIGHT_YEAR):
Update copyright dates by hand in templates and the like.

7 years agomaint: Run 'make update-copyright'
Paul Eggert [Mon, 1 Jan 2018 00:57:25 +0000 (00:57 +0000)]
maint: Run 'make update-copyright'

7 years agomaint: fix 'make update-copyright'
Paul Eggert [Mon, 1 Jan 2018 00:43:46 +0000 (16:43 -0800)]
maint: fix 'make update-copyright'

* Makefile (update-copyright): Adjust to 2016-11-23 change
to config/srclist-update, which changed the format of srclist.txt.

7 years agoautoupdate
Paul Eggert [Mon, 1 Jan 2018 00:26:12 +0000 (16:26 -0800)]
autoupdate

7 years agoautoupdate
Karl Berry [Sun, 31 Dec 2017 16:53:16 +0000 (08:53 -0800)]
autoupdate

7 years agochdir-safer: remove this module
Paul Eggert [Sun, 31 Dec 2017 00:34:32 +0000 (16:34 -0800)]
chdir-safer: remove this module

* MODULES.html.sh (func_all_modules): Remove chdir-safer.
* NEWS: Document removal.
* lib/chdir-safer.c, lib/chdir-safer.h, m4/afs.m4, m4/chdir-safer.m4:
* modules/chdir-safer: Remove these files.

7 years agoAdd cross-compilation results for GNU/Hurd.
Samuel Thibault [Fri, 29 Dec 2017 16:30:07 +0000 (17:30 +0100)]
Add cross-compilation results for GNU/Hurd.

* m4/calloc.m4: Add GNU/Hurd guess.
* m4/cbrtl.m4: Likewise.
* m4/ceil.m4: Likewise.
* m4/ceilf.m4: Likewise.
* m4/ceill.m4: Likewise.
* m4/chown.m4: Likewise.
* m4/duplocale.m4: Likewise.
* m4/exp2l.m4: Likewise.
* m4/expm1.m4: Likewise.
* m4/fchdir.m4: Likewise.
* m4/floor.m4: Likewise.
* m4/floorf.m4: Likewise.
* m4/fmod.m4: Likewise.
* m4/fmodf.m4: Likewise.
* m4/fmodl.m4: Likewise.
* m4/getcwd.m4: Likewise.
* m4/getgroups.m4: Likewise.
* m4/gettimeofday.m4: Likewise.
* m4/hypot.m4: Likewise.
* m4/hypotf.m4: Likewise.
* m4/hypotl.m4: Likewise.
* m4/link-follow.m4: Likewise.
* m4/link.m4: Likewise.
* m4/linkat.m4: Likewise.
* m4/log.m4: Likewise.
* m4/log10.m4: Likewise.
* m4/log10f.m4: Likewise.
* m4/log1p.m4: Likewise.
* m4/log1pf.m4: Likewise.
* m4/log1pl.m4: Likewise.
* m4/log2.m4: Likewise.
* m4/log2f.m4: Likewise.
* m4/logf.m4: Likewise.
* m4/lstat.m4: Likewise.
* m4/malloc.m4: Likewise.
* m4/mbrlen.m4: Likewise.
* m4/mbrtowc.m4: Likewise.
* m4/mkdir.m4: Likewise.
* m4/mkfifo.m4: Likewise.
* m4/mknod.m4: Likewise.
* m4/mkstemp.m4: Likewise.
* m4/modf.m4: Likewise.
* m4/modff.m4: Likewise.
* m4/modfl.m4: Likewise.
* m4/printf.m4: Likewise.
* m4/pselect.m4: Likewise.
* m4/ptsname.m4: Likewise.
* m4/putenv.m4: Likewise.
* m4/readlink.m4: Likewise.
* m4/realloc.m4: Likewise.
* m4/remainder.m4: Likewise.
* m4/remainderf.m4: Likewise.
* m4/remainderl.m4: Likewise.
* m4/rmdir.m4: Likewise.
* m4/round.m4: Likewise.
* m4/roundf.m4: Likewise.
* m4/roundl.m4: Likewise.
* m4/select.m4: Likewise.
* m4/setenv.m4: Likewise.
* m4/signbit.m4: Likewise.
* m4/sleep.m4: Likewise.
* m4/stat.m4: Likewise.
* m4/strerror.m4: Likewise.
* m4/strtok_r.m4: Likewise.
* m4/symlink.m4: Likewise.
* m4/symlinkat.m4: Likewise.
* m4/trunc.m4: Likewise.
* m4/truncf.m4: Likewise.
* m4/truncl.m4: Likewise.
* m4/tzset.m4: Likewise.
* m4/ungetc.m4: Likewise.
* m4/usleep.m4: Likewise.
* m4/wcwidth.m4: Likewise.

7 years agognulib-tool: Make --conditional-dependencies work better.
Bruno Haible [Thu, 28 Dec 2017 23:29:23 +0000 (00:29 +0100)]
gnulib-tool: Make --conditional-dependencies work better.

Reported by Dmitry Selyutin <ghostman.sd@gmail.com>.

* gnulib-tool (Options): Don't reject the combination of
--conditional-dependencies with --with-tests.
(func_emit_autoconf_snippets): Add argument referenceable_modules.
Don't reference $modules.
(func_import, func_create_testdir): Pass it.

7 years agoautoupdate
Karl Berry [Thu, 28 Dec 2017 00:05:51 +0000 (16:05 -0800)]
autoupdate

7 years agoregex: use re_malloc etc. consistently
Paul Eggert [Tue, 19 Dec 2017 23:53:47 +0000 (15:53 -0800)]
regex: use re_malloc etc. consistently

Problem and original patch reported by Arnold Robbins in:
https://sourceware.org/ml/libc-alpha/2017-12/msg00241.html
* lib/regcomp.c (re_comp):
* lib/regexec.c (push_fail_stack, build_trtable, match_ctx_clean):
Use re_malloc/re_realloc/re_free instead of malloc/realloc/free.

7 years agoautoupdate
Karl Berry [Tue, 19 Dec 2017 17:05:15 +0000 (09:05 -0800)]
autoupdate

7 years agoautoupdate
Karl Berry [Sun, 17 Dec 2017 16:02:54 +0000 (08:02 -0800)]
autoupdate

7 years agoglob: Silence warning about void pointer arithmetic.
Tim Rühsen [Sat, 16 Dec 2017 03:02:01 +0000 (04:02 +0100)]
glob: Silence warning about void pointer arithmetic.

* lib/glob.c (glob): Use a 'char *', not a 'void *', in pointer
arithmetic.

7 years agoglob.c: Silence warning about void pointer arithmetic
Tim Rühsen [Sat, 16 Dec 2017 01:27:21 +0000 (17:27 -0800)]
glob.c: Silence warning about void pointer arithmetic

7 years agospawn-pipe: Silence a clang warning.
Bruno Haible [Fri, 15 Dec 2017 09:44:15 +0000 (10:44 +0100)]
spawn-pipe: Silence a clang warning.

Reported by Tim Rühsen <tim.ruehsen@gmx.de>.

* lib/spawn-pipe.c: Disable clang -Wconditional-uninitialized warnings
in this file.

7 years agoexplicit_bzero: port to macOS + Clang 9.0.0
Paul Eggert [Wed, 13 Dec 2017 00:41:21 +0000 (16:41 -0800)]
explicit_bzero: port to macOS + Clang 9.0.0

Problem reported by Marcus Johnson (Bug#29658).
* lib/explicit_bzero.c (explicit_bzero) [__clang__]:
Don’t use asm.

7 years agodoc: Improve explanation of supporting relocatable libraries.
Reuben Thomas [Mon, 11 Dec 2017 10:27:52 +0000 (10:27 +0000)]
doc: Improve explanation of supporting relocatable libraries.

* doc/relocatable-maint.texi (Supporting Relocation): Explain
properly how to build the relocatable module for
libraries. (Method and example code from Bruno Haible.)

7 years agodoc: Use better texinfo tags in a few cases.
Reuben Thomas [Mon, 11 Dec 2017 13:12:19 +0000 (14:12 +0100)]
doc: Use better texinfo tags in a few cases.

* doc/gnulib.texi (Extending Gnulib): Use @option or @command
instead of @samp in a few places.

7 years agounistr/base: Update comment.
Bruno Haible [Mon, 11 Dec 2017 13:08:40 +0000 (14:08 +0100)]
unistr/base: Update comment.

* lib/unistr.in.h: Update comment about u*_mbtouc_unsafe functions.

7 years agotest-faccessat.c: avoid test failure if prior partial run
Pádraig Brady [Mon, 11 Dec 2017 01:59:32 +0000 (17:59 -0800)]
test-faccessat.c: avoid test failure if prior partial run

* tests/test-faccessat.c: Remove the file if present
to ensure not present from a prior (partial) run.

7 years agotest-faccessat.c: unlink temp file to avoid subsequent test failure
Pádraig Brady [Mon, 11 Dec 2017 01:41:57 +0000 (17:41 -0800)]
test-faccessat.c: unlink temp file to avoid subsequent test failure

* tests/test-faccessat.c: Remove the file to avoid failure
to open the file on subsequent runs due to being created
with no permissions.

7 years agodoc: New section "Modifying the build rules of a Gnulib import directory".
Bruno Haible [Sun, 10 Dec 2017 15:28:43 +0000 (16:28 +0100)]
doc: New section "Modifying the build rules of a Gnulib import directory".

* doc/gnulib-tool.texi (Modified build rules): New node.

7 years agodoc: Tweak wording.
Bruno Haible [Sun, 10 Dec 2017 13:00:43 +0000 (14:00 +0100)]
doc: Tweak wording.

* doc/gnulib-tool.texi (Multiple instances): Talk about "programs", not
"binaries".

7 years agono-c++: Avoid "egrep: repetition-operator operand invalid" error.
Sam Steingold [Tue, 5 Dec 2017 16:02:33 +0000 (11:02 -0500)]
no-c++: Avoid "egrep: repetition-operator operand invalid" error.

* m4/no-c++.m4 (gt_NO_CXX): Don't use '+' characters nor spaces in the
AC_EGREP_CPP pattern.

7 years agoall: Replace more http URLs by https URLs.
Bruno Haible [Sun, 3 Dec 2017 22:35:26 +0000 (23:35 +0100)]
all: Replace more http URLs by https URLs.

7 years agoautoupdate
Karl Berry [Sun, 3 Dec 2017 17:18:35 +0000 (09:18 -0800)]
autoupdate

7 years agoPort better to CentOS 5
Paul Eggert [Tue, 28 Nov 2017 22:30:25 +0000 (14:30 -0800)]
Port better to CentOS 5

Problems reported by Tom G. Christensen in:
https://lists.gnu.org/r/bug-gnulib/2017-11/msg00053.html
* doc/glibc-functions/strverscmp.texi (strverscmp):
Document strverscmp bug with glibc 2.9 and earlier.
* doc/posix-functions/tzset.texi (tzset):
Document that TZ with angle brackets is POSIX-2001 and later.
* tests/test-nstrftime.c: Include unistd.h.
(TZ_ANGLE_BRACKETS_SHOULD_WORK): New macro.
(TZ): Use it to skip tests with angle brackets in TZ,
for older systems.