| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
| |
* lib/*.in.h: In the comments, mention also HAVE_RAW_DECL_*.
* Makefile (sc_check_config_h_reminder): Search also for HAVE_RAW_DECL_.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* m4/gnulib-common.m4 (gl_COMMON): In config.h, define
_GL_CONFIG_H_INCLUDED.
* lib/acl-internal.h: Test _GL_CONFIG_H_INCLUDED instead of
_GL_INLINE_HEADER_BEGIN.
* lib/alignalloc.h: Likewise.
* lib/argp-fmtstream.h: Likewise.
* lib/argp.h: Likewise.
* lib/binary-io.h: Likewise.
* lib/bitrotate.h: Likewise.
* lib/c-ctype.h: Likewise.
* lib/count-leading-zeros.h: Likewise.
* lib/count-one-bits.h: Likewise.
* lib/count-trailing-zeros.h: Likewise.
* lib/eealloc.h: Likewise.
* lib/execinfo.in.h: Likewise.
* lib/gethrxtime.h: Likewise.
* lib/gl_list.h: Likewise.
* lib/gl_map.h: Likewise.
* lib/gl_omap.h: Likewise.
* lib/gl_openssl.h: Likewise.
* lib/gl_oset.h: Likewise.
* lib/gl_set.h: Likewise.
* lib/gl_xlist.h: Likewise.
* lib/gl_xmap.h: Likewise.
* lib/gl_xomap.h: Likewise.
* lib/gl_xoset.h: Likewise.
* lib/gl_xset.h: Likewise.
* lib/gl_xsublist.h: Likewise.
* lib/glthread/cond.h: Likewise.
* lib/hamt.h: Likewise.
* lib/ialloc.h: Likewise.
* lib/math.in.h: Likewise.
* lib/mbchar.h: Likewise.
* lib/mbfile.h: Likewise.
* lib/mbiter.h: Likewise.
* lib/mbuiter.h: Likewise.
* lib/openat.h: Likewise.
* lib/pipe-filter-aux.h: Likewise.
* lib/priv-set.h: Likewise.
* lib/safe-alloc.h: Likewise.
* lib/savewd.h: Likewise.
* lib/se-context.in.h: Likewise.
* lib/se-label.in.h: Likewise.
* lib/se-selinux.in.h: Likewise.
* lib/sig-handler.h: Likewise.
* lib/stat-time.h: Likewise.
* lib/string-desc-quotearg.h: Likewise.
* lib/string-desc.h: Likewise.
* lib/sys_socket.in.h: Likewise.
* lib/timespec.h: Likewise.
* lib/u64.h: Likewise.
* lib/uchar.in.h: Likewise.
* lib/unistd.in.h: Likewise.
* lib/utimens.h: Likewise.
* lib/wctype.in.h: Likewise.
* lib/xalloc.h: Likewise.
* lib/xbinary-io.h: Likewise.
* lib/xsize.h: Likewise.
* lib/xstring-desc.h: Likewise.
* lib/xtime.h: Likewise.
* lib/acl.h: Check that config.h was already included.
* lib/alignof.h: Likewise.
* lib/argmatch.h: Likewise.
* lib/argv-iter.h: Likewise.
* lib/arpa_inet.in.h: Likewise.
* lib/attribute.h: Likewise.
* lib/backupfile.h: Likewise.
* lib/base32.h: Likewise.
* lib/base64.h: Likewise.
* lib/basename-lgpl.h: Likewise.
* lib/bitset.h: Likewise.
* lib/bitsetv.h: Likewise.
* lib/c-snprintf.h: Likewise.
* lib/c-stack.h: Likewise.
* lib/c-strcase.h: Likewise.
* lib/c-vasnprintf.h: Likewise.
* lib/c-vasprintf.h: Likewise.
* lib/c-vsnprintf.h: Likewise.
* lib/c-xvasprintf.h: Likewise.
* lib/canon-host.h: Likewise.
* lib/canonicalize.h: Likewise.
* lib/clean-temp.h: Likewise.
* lib/concat-filename.h: Likewise.
* lib/ctype.in.h: Likewise.
* lib/dfa.h: Likewise.
* lib/di-set.h: Likewise.
* lib/dirent-safer.h: Likewise.
* lib/dirent.in.h: Likewise.
* lib/dirname.h: Likewise.
* lib/eloop-threshold.h: Likewise.
* lib/error.in.h: Likewise.
* lib/exclude.h: Likewise.
* lib/fatal-signal.h: Likewise.
* lib/fcntl.in.h: Likewise.
* lib/file-type.h: Likewise.
* lib/filenamecat.h: Likewise.
* lib/filevercmp.h: Likewise.
* lib/flexmember.h: Likewise.
* lib/fnmatch.in.h: Likewise.
* lib/fpending.h: Likewise.
* lib/freadable.h: Likewise.
* lib/freadahead.h: Likewise.
* lib/freading.h: Likewise.
* lib/fts_.h: Likewise.
* lib/fwritable.h: Likewise.
* lib/fwriting.h: Likewise.
* lib/gc.h: Likewise.
* lib/get_progname_of.h: Likewise.
* lib/glob.in.h: Likewise.
* lib/glthread/thread.h: Likewise.
* lib/hash-pjw-bare.h: Likewise.
* lib/hash-pjw.h: Likewise.
* lib/hash-triple.h: Likewise.
* lib/hash.h: Likewise.
* lib/i-ring.h: Likewise.
* lib/iconv.in.h: Likewise.
* lib/ino-map.h: Likewise.
* lib/inttostr.h: Likewise.
* lib/inttypes.in.h: Likewise.
* lib/javaversion.h: Likewise.
* lib/langinfo.in.h: Likewise.
* lib/locale.in.h: Likewise.
* lib/localename.h: Likewise.
* lib/malloc.in.h: Likewise.
* lib/malloca.h: Likewise.
* lib/memcasecmp.h: Likewise.
* lib/memchr2.h: Likewise.
* lib/memcmp2.h: Likewise.
* lib/modechange.h: Likewise.
* lib/monetary.in.h: Likewise.
* lib/mountlist.h: Likewise.
* lib/netdb.in.h: Likewise.
* lib/obstack.h: Likewise.
* lib/opendirat.h: Likewise.
* lib/pagealign_alloc.h: Likewise.
* lib/pipe-filter.h: Likewise.
* lib/poll.in.h: Likewise.
* lib/pthread.in.h: Likewise.
* lib/pty.in.h: Likewise.
* lib/quotearg.h: Likewise.
* lib/read-file.h: Likewise.
* lib/readline.h: Likewise.
* lib/readutmp.h: Likewise.
* lib/regex-quote.h: Likewise.
* lib/relocatable.h: Likewise.
* lib/savedir.h: Likewise.
* lib/sched.in.h: Likewise.
* lib/search.in.h: Likewise.
* lib/sh-quote.h: Likewise.
* lib/signal.in.h: Likewise.
* lib/sigpipe-die.h: Likewise.
* lib/sockets.h: Likewise.
* lib/spawn.in.h: Likewise.
* lib/ssfmalloc.h: Likewise.
* lib/stack.h: Likewise.
* lib/stdalign.in.h: Likewise.
* lib/stdarg.in.h: Likewise.
* lib/stddef.in.h: Likewise.
* lib/stdio-safer.h: Likewise.
* lib/stdio.in.h: Likewise.
* lib/stdlib.in.h: Likewise.
* lib/stdnoreturn.in.h: Likewise.
* lib/strerror-override.h: Likewise.
* lib/striconv.h: Likewise.
* lib/striconveh.h: Likewise.
* lib/striconveha.h: Likewise.
* lib/string-buffer.h: Likewise.
* lib/string.in.h: Likewise.
* lib/strings.in.h: Likewise.
* lib/strnlen1.h: Likewise.
* lib/sys_file.in.h: Likewise.
* lib/sys_ioctl.in.h: Likewise.
* lib/sys_random.in.h: Likewise.
* lib/sys_resource.in.h: Likewise.
* lib/sys_select.in.h: Likewise.
* lib/sys_stat.in.h: Likewise.
* lib/sys_time.in.h: Likewise.
* lib/sys_times.in.h: Likewise.
* lib/sys_utsname.in.h: Likewise.
* lib/sys_wait.in.h: Likewise.
* lib/system-quote.h: Likewise.
* lib/term-style-control.h: Likewise.
* lib/termios.in.h: Likewise.
* lib/textstyle.in.h: Likewise.
* lib/threads.in.h: Likewise.
* lib/time.in.h: Likewise.
* lib/trim.h: Likewise.
* lib/utime.in.h: Likewise.
* lib/utmp.in.h: Likewise.
* lib/vasnprintf.h: Likewise.
* lib/verror.h: Likewise.
* lib/version-etc.h: Likewise.
* lib/wchar.in.h: Likewise.
* lib/windows-spawn.h: Likewise.
* lib/windows-thread.h: Likewise.
* lib/xgetcwd.h: Likewise.
* lib/xgetdomainname.h: Likewise.
* lib/xgethostname.h: Likewise.
* lib/xmalloca.h: Likewise.
* lib/xmemdup0.h: Likewise.
* lib/xprintf.h: Likewise.
* lib/xreadlink.h: Likewise.
* lib/xstriconv.h: Likewise.
* lib/xstriconveh.h: Likewise.
* lib/xstrndup.h: Likewise.
* lib/xstrtol-error.h: Likewise.
* lib/xvasprintf.h: Likewise.
* Makefile (config_h_MACROS*): New variables.
(sc_check_config_h_reminder): New rule.
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Reported by Jan Engelhardt <jengelh@inai.de>.
* lib/stdlib.in.h (_GL_ATTRIBUTE_DEALLOC, _GL_ATTRIBUTE_DEALLOC_FREE,
_GL_ATTRIBUTE_MALLOC): Add fallback definitions.
* lib/dirent.in.h (_GL_ATTRIBUTE_DEALLOC, _GL_ATTRIBUTE_MALLOC): Add
fallback definitions.
* lib/stdio.in.h (_GL_ATTRIBUTE_DEALLOC): Add fallback definition.
* lib/math.in.h (_GL_ATTRIBUTE_CONST): Add fallback definition.
* lib/pthread.in.h (_GL_ATTRIBUTE_PURE): Add fallback definition.
* lib/threads.in.h (_GL_ATTRIBUTE_PURE): Likewise.
* lib/uchar.in.h (_GL_ATTRIBUTE_PURE): Likewise.
* lib/string.in.h (_GL_ATTRIBUTE_PURE): Move definition, for consistency
with the other *.in.h files.
* lib/se-context.in.h (_GL_ATTRIBUTE_MAYBE_UNUSED): Add fallback
definition.
* lib/se-label.in.h (_GL_ATTRIBUTE_MAYBE_UNUSED): Likewise.
* lib/se-selinux.in.h (_GL_ATTRIBUTE_MAYBE_UNUSED): Likewise.
* lib/textstyle.in.h: Use _GL_ATTRIBUTE_MAYBE_UNUSED instead of
_GL_UNUSED.
(_GL_ATTRIBUTE_SPEC_PRINTF_STANDARD, _GL_ATTRIBUTE_MAYBE_UNUSED): Add
fallback definitions.
|
|
|
|
|
|
|
|
| |
* lib/dirent.in.h (opendir): For GCC >= 11: Declare also when the
platform already declares the function or when the module 'opendir' is
not in use.
(fdopendir): For GCC >= 11: Declare also when the platform already
declares the function or when the module 'fdopendir' is not in use.
|
|
|
|
|
|
|
|
| |
* lib/dirent.in.h (closedir): Move declaration up.
(opendir, fdopendir): Declare that that deallocation must happen through
'closedir'.
* lib/dirent-safer.h (opendir_safer): Likewise.
* lib/opendirat.h (opendirat): Likewise.
|
|
|
|
|
| |
* lib/**.{h,c,gperf}: Use LGPLv2+ notice whenever the module description
says so.
|
|
|
|
|
| |
* lib/dirent.in.h (dirfd): Redefine dirfd macro as a rpl function
always.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* m4/gnulib-common.m4 (_Noreturn): Use __attribute__ __noreturn__ also
on clang.
* lib/cdefs.h (__glibc_clang_has_attribute, __glibc_clang_has_builtin):
New macros.
(__THROW, __THROWNL, __NTH, __NTHNL): Use __attribute__ __nothrow__ also
on clang.
(__warndecl, __warnattr, __errordecl): Use __attribute__ __diagnose_if__
also on older clang versions.
(__attribute__): Don't define to empty on clang.
(__attribute_malloc__): Use __attribute__ __malloc__ also on clang.
(__attribute_pure__): Use __attribute__ __pure__ also on clang.
(__attribute_const__): Use __attribute__ __const__ also on clang.
(__attribute_used__): Use __attribute__ __used__ also on clang.
(__attribute_noinline__): Use __attribute__ __noinline__ also on clang.
(__attribute_deprecated__): Use __attribute__ __deprecated__ also on
clang.
(__attribute_format_arg__): Use __attribute__ __format_arg__ also on
clang.
(__attribute_format_strfmon__): Use __attribute__ __format__ __strfmon__
also on clang.
(__nonnull): Use __attribute__ __nonnull__ also on clang.
(__attribute_warn_unused_result__): Use __attribute__
__warn_unused_result__ also on clang.
(__always_inline): Use __attribute__ __always_inline__ also on clang.
(__attribute_artificial__): Use __attribute__ __artificial__ also on
clang >= 7.
(__glibc_unlikely, __glibc_likely): Use __builtin_expect also on older
clang versions.
(_Noreturn): Don't redefine on clang >= 3.5.
* lib/arg-nonnull.h (_GL_ARG_NONNULL): Use __attribute__ __nonnull__
also on clang.
* lib/dirent.in.h (_GL_ATTRIBUTE_PURE): Use __attribute__ __pure__ also
on clang.
* lib/stdlib.in.h (_GL_ATTRIBUTE_PURE): Likewise.
* lib/string.in.h (_GL_ATTRIBUTE_PURE): Likewise.
* lib/wchar.in.h (_GL_ATTRIBUTE_PURE): Likewise.
* lib/stdio.in.h (_GL_ATTRIBUTE_FORMAT): Use __attribute__ __format__
also on clang.
* lib/monetary.in.h (_GL_ATTRIBUTE_FORMAT): Likewise.
* lib/textstyle.in.h (ostream_printf, ostream_vprintf): Likewise.
* lib/unitypes.in.h (_UC_ATTRIBUTE_CONST): Use __attribute__ __const__
also on clang.
(_UC_ATTRIBUTE_PURE): Use __attribute__ __pure__ also on clang.
* lib/noreturn.h (_GL_NORETURN_FUNC, _GL_NORETURN_FUNCPTR): Use
__attribute__ __noreturn__ also on clang.
* lib/obstack.h (__attribute_noreturn__): Likewise.
* lib/file-set.h (record_file): Use __attribute__ __nonnull__ also on
clang.
* lib/argp-help.c (hol_entry_long_iterate): Use __attribute__
always_inline also on clang.
* tests/test-printf-posix.c (func1, func2, func3, func4): Test also on
clang.
|
|
|
|
|
|
|
|
| |
* lib/dirent.in.h (_GL_ATTRIBUTE_PURE): Don't override the definition
that usually comes from m4/gnulib-common.m4.
* lib/stdlib.in.h (_GL_ATTRIBUTE_PURE): Likewise.
* lib/string.in.h (_GL_ATTRIBUTE_PURE): Likewise.
* lib/wchar.in.h (_GL_ATTRIBUTE_PURE): Likewise.
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
| |
* 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.
* all files: Run 'make update-copyright'.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* lib/closedir.c (closedir): Unregister fd if closedir() succeeds.
* lib/dirent.in.h (_gl_register_dirp_fd, _gl_unregister_dirp_fd):
Declare on kLIBC.
* lib/dirfd.c (struct dirp_fd_list): New. Structures to keep track of
fd associated with dirp.
(_gl_register_dirp_fd): New. Register fd associated with dirp to
dirp_fd_list.
(_gl_unregister_dirp_fd): New. Unregister fd with closing it.
(dirfd): Implemented for kLIBC.
* lib/fdopendir.c (fdopendir): Implemented for kLIBC.
* lib/opendir.c (opendir): New. Register fd and dirp pair if open()
succeeds.
* m4/closedir.m4 (gl_FUNC_CLOSEDIR): Replace if OS/2.
* m4/dirfd.m4 (gl_FUNC_DIRFD): Likewise.
(REPLACE_DIRFD): Define to 1 if replaced.
* m4/opendir.m4 (gl_FUNC_OPENDIR): Likewise.
* modules/closedir (Depends-on): Add dirfd.
* modules/dirfd (Depends-on): Add 'test $REPLACE_DIRFD = 1' to errno
condition.
(configure.ac): Add dirfd to LIBOBJS if $REPLACE_DIRFD = 1 as well.
* modules/opendir (Depends-on): Add dirfd.
|
|
|
|
|
|
|
|
|
|
| |
* 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.
* all files: Run 'make update-copyright'.
|
|
|
|
|
|
|
|
| |
* lib/dirent--.h (GNULIB_defined_opendir):
* lib/dirent.in.h (GNULIB_defined_opendir)
(GNULIB_defined_closedir):
* lib/getcwd.c, lib/glob.c, lib/mountlist.c (opendir, closedir):
#undef only if Gnulib defined it.
|
|
|
|
|
|
| |
* doc/gnulib.texi:
* lib/version-etc.c (COPYRIGHT_YEAR): Update copyright date.
* all files: Run 'make update-copyright'.
|
|
|
|
|
|
| |
I ran 'make update-copyright'.
Signed-off-by: Eric Blake <eblake@redhat.com>
|
|
|
|
|
|
| |
Run "make update-copyright". Compare to commit 1602f0a from last year.
Signed-off-by: Eric Blake <eblake@redhat.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* lib/dirent.in.h (_GL_ATTRIBUTE_PURE): Define, like in string.in.h.
(alphasort): Declare with GCC attribute 'pure'.
* lib/stdlib.in.h (_GL_ATTRIBUTE_PURE): Define, like in string.in.h.
(atoll): Declare with GCC attribute 'pure'.
* lib/string.in.h (mbslen, mbsnlen, mbschr, mbsrchr, mbsstr,
mbscasecmp, mbsncasecmp, mbspcasecmp, mbscasestr, mbscspn, mbspbrk,
mbsspn, strverscmp): Declare with GCC attribute 'pure'.
* lib/wchar.in.h (_GL_ATTRIBUTE_PURE): Define, like in string.in.h.
(btowc, wctob, wcwidth, wmemchr, wmemcmp, wcslen, wcsnlen, wcscmp,
wcsncmp, wcscasecmp, wcsncasecmp, wcschr, wcsrchr, wcscspn, wcsspn,
wcspbrk, wcsstr, wcswidth): Declare with GCC attribute 'pure'.
|
|
|
|
| |
Run "make update-copyright".
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* lib/dirent.in.h (struct dirent): New type.
(DT_UNKNOWN, DT_FIFO, DT_CHR, DT_DIR, DT_BLK, DT_REG, DT_LNK, DT_SOCK,
DT_WHT): New macros.
(DIR): New type.
(opendir, closedir): Declare only if the module 'opendir' is enabled.
(readdir, rewinddir): New declarations.
* lib/dirent-private.h: New file.
* lib/opendir.c: New file.
* lib/readdir.c: New file.
* lib/rewinddir.c: New file.
* lib/closedir.c: New file.
* lib/fchdir.c (rpl_closedir, rpl_opendir): Remove functions.
* m4/opendir.m4: New file.
* m4/readdir.m4: New file.
* m4/rewinddir.m4: New file.
* m4/closedir.m4: New file.
* m4/fchdir.m4 (gl_FUNC_FCHDIR): Don't set REPLACE_OPENDIR,
REPLACE_CLOSEDIR here.
* m4/dirent_h.m4 (gl_DIRENT_H): Also check whether closedir, opendir,
readdir, rewinddir are declared.
(gl_DIRENT_H_DEFAULTS): Initialize GNULIB_OPENDIR, GNULIB_READDIR,
GNULIB_REWINDDIR, GNULIB_CLOSEDIR, HAVE_OPENDIR, HAVE_READDIR,
HAVE_REWINDDIR, HAVE_CLOSEDIR.
* modules/dirent (Makefile.am): Substitute GNULIB_OPENDIR,
GNULIB_READDIR, GNULIB_REWINDDIR, GNULIB_CLOSEDIR, HAVE_OPENDIR,
HAVE_READDIR, HAVE_REWINDDIR, HAVE_CLOSEDIR.
* modules/opendir: New file.
* modules/readdir: New file.
* modules/rewinddir: New file.
* modules/closedir: New file.
* doc/posix-functions/opendir.texi: Mention the 'opendir' module.
* doc/posix-functions/readdir.texi: Mention the 'readdir' module.
* doc/posix-functions/rewinddir.texi: Mention the 'rewinddir' module.
* doc/posix-functions/closedir.texi: Mention the 'closedir' module.
* NEWS: Mention the 'fchdir' change.
|
|
|
|
|
|
|
| |
* lib/dirent.in.h: Include <dirent.h> only if HAVE_DIRENT_H is 1.
* m4/dirent_h.m4 (gl_DIRENT_H): Set HAVE_DIRENT_H.
* modules/dirent (Makefile.am): Substitute HAVE_DIRENT_H.
* doc/posix-headers/dirent.texi: Mention the MSVC problem.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* gnulib-tool (func_compute_include_guard_prefix): New function.
(func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Resolve also
${gl_include_guard_prefix} references.
(func_import, func_create_testdir): Invoke
func_compute_include_guard_prefix.
* lib/arpa_inet.in.h: Use the @GUARD_PREFIX@ placeholder.
* lib/ctype.in.h: Likewise.
* lib/dirent.in.h: Likewise.
* lib/errno.in.h: Likewise.
* lib/fcntl.in.h: Likewise.
* lib/float.in.h: Likewise.
* lib/getopt.in.h: Likewise.
* lib/iconv.in.h: Likewise.
* lib/langinfo.in.h: Likewise.
* lib/locale.in.h: Likewise.
* lib/math.in.h: Likewise.
* lib/netdb.in.h: Likewise.
* lib/netinet_in.in.h: Likewise.
* lib/poll.in.h: Likewise.
* lib/pthread.in.h: Likewise.
* lib/pty.in.h: Likewise.
* lib/sched.in.h: Likewise.
* lib/se-selinux.in.h: Likewise.
* lib/search.in.h: Likewise.
* lib/signal.in.h: Likewise.
* lib/spawn.in.h: Likewise.
* lib/stdarg.in.h: Likewise.
* lib/stddef.in.h: Likewise.
* lib/stdint.in.h: Likewise.
* lib/stdio.in.h: Likewise.
* lib/stdlib.in.h: Likewise.
* lib/string.in.h: Likewise.
* lib/strings.in.h: Likewise.
* lib/sys_file.in.h: Likewise.
* lib/sys_ioctl.in.h: Likewise.
* lib/sys_select.in.h: Likewise.
* lib/sys_socket.in.h: Likewise.
* lib/sys_stat.in.h: Likewise.
* lib/sys_time.in.h: Likewise.
* lib/sys_times.in.h: Likewise.
* lib/sys_uio.in.h: Likewise.
* lib/sys_utsname.in.h: Likewise.
* lib/sys_wait.in.h: Likewise.
* lib/sysexits.in.h: Likewise.
* lib/termios.in.h: Likewise.
* lib/time.in.h: Likewise.
* lib/unistd.in.h: Likewise.
* lib/wchar.in.h: Likewise.
* lib/wctype.in.h: Likewise.
* modules/arpa_inet (Makefile.am): Substitute @GUARD_PREFIX@.
* modules/ctype (Makefile.am): Likewise.
* modules/dirent (Makefile.am): Likewise.
* modules/errno (Makefile.am): Likewise.
* modules/fcntl-h (Makefile.am): Likewise.
* modules/float (Makefile.am): Likewise.
* modules/getopt-posix (Makefile.am): Likewise.
* modules/iconv-h (Makefile.am): Likewise.
* modules/langinfo (Makefile.am): Likewise.
* modules/locale (Makefile.am): Likewise.
* modules/math (Makefile.am): Likewise.
* modules/netdb (Makefile.am): Likewise.
* modules/netinet_in (Makefile.am): Likewise.
* modules/poll-h (Makefile.am): Likewise.
* modules/pthread (Makefile.am): Likewise.
* modules/pty (Makefile.am): Likewise.
* modules/sched (Makefile.am): Likewise.
* modules/search (Makefile.am): Likewise.
* modules/selinux-h (Makefile.am): Likewise.
* modules/signal (Makefile.am): Likewise.
* modules/spawn (Makefile.am): Likewise.
* modules/stdarg (Makefile.am): Likewise.
* modules/stddef (Makefile.am): Likewise.
* modules/stdint (Makefile.am): Likewise.
* modules/stdio (Makefile.am): Likewise.
* modules/stdlib (Makefile.am): Likewise.
* modules/string (Makefile.am): Likewise.
* modules/strings (Makefile.am): Likewise.
* modules/sys_file (Makefile.am): Likewise.
* modules/sys_ioctl (Makefile.am): Likewise.
* modules/sys_select (Makefile.am): Likewise.
* modules/sys_socket (Makefile.am): Likewise.
* modules/sys_stat (Makefile.am): Likewise.
* modules/sys_time (Makefile.am): Likewise.
* modules/sys_times (Makefile.am): Likewise.
* modules/sys_uio (Makefile.am): Likewise.
* modules/sys_utsname (Makefile.am): Likewise.
* modules/sys_wait (Makefile.am): Likewise.
* modules/sysexits (Makefile.am): Likewise.
* modules/termios (Makefile.am): Likewise.
* modules/time (Makefile.am): Likewise.
* modules/unistd (Makefile.am): Likewise.
* modules/wchar (Makefile.am): Likewise.
* modules/wctype-h (Makefile.am): Likewise.
* modules/assert-h (Makefile.am): Replace _GL_VERIFY_H specially.
|
|
|
|
| |
Run the new "make update-copyright" rule.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* m4/include_next.m4 (gl_INCLUDE_NEXT): Define also PRAGMA_COLUMNS.
* lib/arpa_inet.in.h: Use PRAGMA_COLUMNS.
* lib/ctype.in.h: Likewise.
* lib/dirent.in.h: Likewise.
* lib/errno.in.h: Likewise.
* lib/fcntl.in.h: Likewise.
* lib/float.in.h: Likewise.
* lib/getopt.in.h: Likewise.
* lib/iconv.in.h: Likewise.
* lib/inttypes.in.h: Likewise.
* lib/langinfo.in.h: Likewise.
* lib/locale.in.h: Likewise.
* lib/math.in.h: Likewise.
* lib/netdb.in.h: Likewise.
* lib/netinet_in.in.h: Likewise.
* lib/poll.in.h: Likewise.
* lib/pthread.in.h: Likewise.
* lib/pty.in.h: Likewise.
* lib/sched.in.h: Likewise.
* lib/se-selinux.in.h: Likewise.
* lib/search.in.h: Likewise.
* lib/signal.in.h: Likewise.
* lib/spawn.in.h: Likewise.
* lib/stdarg.in.h: Likewise.
* lib/stddef.in.h: Likewise.
* lib/stdint.in.h: Likewise.
* lib/stdio.in.h: Likewise.
* lib/stdlib.in.h: Likewise.
* lib/string.in.h: Likewise.
* lib/strings.in.h: Likewise.
* lib/sys_file.in.h: Likewise.
* lib/sys_ioctl.in.h: Likewise.
* lib/sys_select.in.h: Likewise.
* lib/sys_socket.in.h: Likewise.
* lib/sys_stat.in.h: Likewise.
* lib/sys_time.in.h: Likewise.
* lib/sys_times.in.h: Likewise.
* lib/sys_utsname.in.h: Likewise.
* lib/sys_wait.in.h: Likewise.
* lib/sysexits.in.h: Likewise.
* lib/termios.in.h: Likewise.
* lib/time.in.h: Likewise.
* lib/unistd.in.h: Likewise.
* lib/wchar.in.h: Likewise.
* lib/wctype.in.h: Likewise.
* modules/arpa_inet (Makefile.am): Substitute PRAGMA_COLUMNS.
* modules/ctype (Makefile.am): Likewise.
* modules/dirent (Makefile.am): Likewise.
* modules/errno (Makefile.am): Likewise.
* modules/fcntl-h (Makefile.am): Likewise.
* modules/float (Makefile.am): Likewise.
* modules/getopt-posix (Makefile.am): Likewise.
* modules/iconv-h (Makefile.am): Likewise.
* modules/inttypes (Makefile.am): Likewise.
* modules/langinfo (Makefile.am): Likewise.
* modules/locale (Makefile.am): Likewise.
* modules/math (Makefile.am): Likewise.
* modules/netdb (Makefile.am): Likewise.
* modules/netinet_in (Makefile.am): Likewise.
* modules/poll-h (Makefile.am): Likewise.
* modules/pthread (Makefile.am): Likewise.
* modules/pty (Makefile.am): Likewise.
* modules/sched (Makefile.am): Likewise.
* modules/search (Makefile.am): Likewise.
* modules/selinux-h (Makefile.am): Likewise.
* modules/signal (Makefile.am): Likewise.
* modules/spawn (Makefile.am): Likewise.
* modules/stdarg (Makefile.am): Likewise.
* modules/stddef (Makefile.am): Likewise.
* modules/stdint (Makefile.am): Likewise.
* modules/stdio (Makefile.am): Likewise.
* modules/stdlib (Makefile.am): Likewise.
* modules/string (Makefile.am): Likewise.
* modules/strings (Makefile.am): Likewise.
* modules/sys_file (Makefile.am): Likewise.
* modules/sys_ioctl (Makefile.am): Likewise.
* modules/sys_select (Makefile.am): Likewise.
* modules/sys_socket (Makefile.am): Likewise.
* modules/sys_stat (Makefile.am): Likewise.
* modules/sys_time (Makefile.am): Likewise.
* modules/sys_times (Makefile.am): Likewise.
* modules/sys_utsname (Makefile.am): Likewise.
* modules/sys_wait (Makefile.am): Likewise.
* modules/sysexits (Makefile.am): Likewise.
* modules/termios (Makefile.am): Likewise.
* modules/time (Makefile.am): Likewise.
* modules/unistd (Makefile.am): Likewise.
* modules/wchar (Makefile.am): Likewise.
* modules/wctype (Makefile.am): Likewise.
|
|
|
|
|
|
| |
* lib/dirent.in.h (dirfd): In C++ mode with GNULIB_NAMESPACE, turn the
macro into a function.
Reported by Jarno Rajahalme <jarno.rajahalme@nsn.com>.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Without a declaration, at least tar would core dump on 64-bit
FreeBSD because gcc only used 32 bits of the resulting pointer.
* m4/dirent_h.m4 (gl_DIRENT_H_DEFAULTS): New witness.
* m4/fdopendir.m4 (gl_FUNC_FDOPENDIR): Set it.
* modules/dirent (Makefile.am): Substitute it.
* lib/dirent.in.h (fdopendir): Supply missing FreeBSD
declaration.
* doc/posix-functions/fdopendir.texi (fdopendir): Document the
fix.
Reported by Christian Weisgerber <naddy@mips.inka.de>.
Signed-off-by: Eric Blake <eblake@redhat.com>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Several headers set #pragma GCC system_header prior to checking
any multiple inclusion guards; maintenance is easiest if all
replacement headers follow the same paradigm.
* lib/ctype.in.h (system_header): Hoist for consistent placement.
* lib/dirent.in.h (system_header): Likewise.
* lib/errno.in.h (system_header): Likewise.
* lib/float.in.h (system_header): Likewise.
* lib/getopt.in.h (system_header): Likewise.
* lib/iconv.in.h (system_header): Likewise.
* lib/inttypes.in.h (system_header): Likewise.
* lib/langinfo.in.h (system_header): Likewise.
* lib/locale.in.h (system_header): Likewise.
* lib/math.in.h (system_header): Likewise.
* lib/netdb.in.h (system_header): Likewise.
* lib/netinet_in.in.h (system_header): Likewise.
* lib/pty.in.h (system_header): Likewise.
* lib/sched.in.h (system_header): Likewise.
* lib/se-selinux.in.h (system_header): Likewise.
* lib/search.in.h (system_header): Likewise.
* lib/spawn.in.h (system_header): Likewise.
* lib/stdarg.in.h (system_header): Likewise.
* lib/stdint.in.h (system_header): Likewise.
* lib/string.in.h (system_header): Likewise.
* lib/strings.in.h (system_header): Likewise.
* lib/sys_file.in.h (system_header): Likewise.
* lib/sys_ioctl.in.h (system_header): Likewise.
* lib/sys_socket.in.h (system_header): Likewise.
* lib/sys_times.in.h (system_header): Likewise.
* lib/sys_utsname.in.h (system_header): Likewise.
* lib/sys_wait.in.h (system_header): Likewise.
* lib/sysexits.in.h (system_header): Likewise.
* lib/unistd.in.h (system_header): Likewise.
* lib/wctype.in.h (system_header): Likewise.
Signed-off-by: Eric Blake <eblake@redhat.com>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Each *.in.h file serves two purposes - provide enough self-contained
content to serve as a replacement for the system header regardless of
the user's compiler, and offer the developer the ability to detect any
gnulib modules that might have been inadvertantly excluded. The
former requires independence from config.h, and routes everything
through a Makefile.am snippet that uses @@ substitution specific to
the modules that were in use, with details learned at configure time.
The latter works by poisoning anything that gnulib did not replace,
but which the developer had natively available, explaining why their
tests passed during development. Poisoning relies on gcc features,
and requires manual triggering by adding -DGNULIB_POSIXCHECK to
CFLAGS; it assumes that <config.h> is properly included. In fact, we
do not want to use @@ substitution for HAVE_DECL_* during poisoning,
because the warning is only relevant for the gnulib modules which were
not included, and thus where the m4 macros to set proper @@ values
have not been run. Furthermore, we only need to poison interfaces
that already have a declaration; if something is not declared, then
the developer wouldn't have been able to link, so their code won't be
using the problematic interface in the first place.
* modules/stdio (Depends-on, Makefile.am): Drop link-warning.
* modules/unistd (Depends-on, Makefile.am): Likewise.
* modules/arpa_inet (Depends-on): Replace link-warning with
warn-on-use.
(Makefile.am): Update rules accordingly.
* modules/ctype (Depends-on, Makefile.am): Likewise.
* modules/dirent (Depends-on, Makefile.am): Likewise.
* modules/fcntl-h (Depends-on, Makefile.am): Likewise.
* modules/inttypes (Depends-on, Makefile.am): Likewise.
* modules/langinfo (Depends-on, Makefile.am): Likewise.
* modules/locale (Depends-on, Makefile.am): Likewise.
* modules/math (Depends-on, Makefile.am): Likewise.
* modules/search (Depends-on, Makefile.am): Likewise.
* modules/signal (Depends-on, Makefile.am): Likewise.
* modules/spawn (Depends-on, Makefile.am): Likewise.
* modules/stdlib (Depends-on, Makefile.am): Likewise.
* modules/string (Depends-on, Makefile.am): Likewise.
* modules/strings (Depends-on, Makefile.am): Likewise.
* modules/sys_file (Depends-on, Makefile.am): Likewise.
* modules/sys_ioctl (Depends-on, Makefile.am): Likewise.
* modules/sys_select (Depends-on, Makefile.am): Likewise.
* modules/sys_socket (Depends-on, Makefile.am): Likewise.
* modules/sys_stat (Depends-on, Makefile.am): Likewise.
* modules/sys_times (Depends-on, Makefile.am): Likewise.
* modules/sys_utsname (Depends-on, Makefile.am): Likewise.
* modules/wchar (Depends-on, Makefile.am): Likewise.
* m4/arpa_inet_h.m4 (gl_HEADER_ARPA_INET): Check which functions
should be poisoned.
* m4/ctype.m4 (gl_CTYPE_H): Likewise.
* m4/dirent_h.m4 (gl_DIRENT_H): Likewise.
* m4/fcntl_h.m4 (gl_FCNTL_H): Likewise.
* m4/inttypes.m4 (gl_INTTYPES_H): Likewise.
* m4/langinfo_h.m4 (gl_LANGINFO_H): Likewise.
* m4/locale_h.m4 (gl_LOCALE_H): Likewise.
* m4/math_h.m4 (gl_MATH_H): Likewise.
* m4/search_h.m4 (gl_SEARCH_H): Likewise.
* m4/signal_h.m4 (gl_SIGNAL_H): Likewise.
* m4/spawn_h.m4 (gl_SPAWN_H): Likewise.
* m4/stdio_h.m4 (gl_STDIO_H): Likewise.
* m4/stdlib_h.m4 (gl_STDLIB_H): Likewise.
* m4/string_h.m4 (gl_HEADER_STRING_H_BODY): Likewise.
* m4/strings_h.m4 (gl_HEADER_STRINGS_H_BODY): Likewise.
* m4/sys_file_h.m4 (gl_HEADER_SYS_FILE_H_DEFAULTS): Likewise.
* m4/sys_ioctl_h.m4 (gl_SYS_IOCTL_H): Likewise.
* m4/sys_select_h.m4 (gl_HEADER_SYS_SELECT): Likewise.
* m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Likewise.
* m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Likewise.
* m4/sys_times_h.m4 (gl_SYS_TIMES_H): Likewise.
* m4/sys_utsname_h.m4 (gl_SYS_UTSNAME_H): Likewise.
* m4/unistd_h.m4 (gl_UNISTD_H): Likewise.
* m4/wchar.m4 (gl_WCHAR_H): Likewise.
* lib/arpa_inet.in.h: Use _GL_WARN_ON_USE instead of
GL_LINK_WARNING.
* lib/ctype.in.h: Likewise.
* lib/dirent.in.h: Likewise.
* lib/fcntl.in.h: Likewise.
* lib/inttypes.in.h: Likewise.
* lib/langinfo.in.h: Likewise.
* lib/locale.in.h: Likewise.
* lib/math.in.h: Likewise.
* lib/search.in.h: Likewise.
* lib/signal.in.h: Likewise.
* lib/spawn.in.h: Likewise.
* lib/stdio.in.h: Likewise.
* lib/stdlib.in.h: Likewise.
* lib/string.in.h: Likewise.
* lib/strings.in.h: Likewise.
* lib/sys_file.in.h: Likewise.
* lib/sys_ioctl.in.h: Likewise.
* lib/sys_select.in.h: Likewise.
* lib/sys_socket.in.h: Likewise.
* lib/sys_stat.in.h: Likewise.
* lib/sys_times.in.h: Likewise.
* lib/sys_utsname.in.h: Likewise.
* lib/unistd.in.h: Likewise.
* lib/wchar.in.h: Likewise.
Signed-off-by: Eric Blake <ebb9@byu.net>
|
| |
|
|
|
|
|
|
|
|
|
|
| |
POSIX 2008 XSI requires ino_t. But it is easier if gnulib
guarantees it always, rather than just on XSI systems.
* lib/dirent.in.h (includes): Guarantee ino_t.
Reported by Ralf Wildenhues.
Signed-off-by: Eric Blake <ebb9@byu.net>
|
|
|
|
|
| |
Use the same procedure as for 2009, outlined in
http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/20081
|
|
|
|
|
|
|
|
|
| |
Fix prototype to match POSIX.
* lib/dirent.in.h (dirfd): Argument is not const, per POSIX.
* lib/dirfd.c (dirfd): Likewise.
Signed-off-by: Eric Blake <ebb9@byu.net>
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
fdopendir(open("file",O_RDONLY)) mistakenly succeeded, with
subsequent readdir() failing with ENOTDIR.
* m4/fdopendir.m4 (gl_FUNC_FDOPENDIR): Check for Hurd bug in
allowing non-directory fds.
* lib/fdopendir.c (rpl_fdopendir): Work around it.
* m4/dirent_h.m4 (gl_DIRENT_H_DEFAULTS): New witness.
* modules/dirent (Makefile.am): Substitute it.
* lib/dirent.in.h (fdopendir): Declare replacement.
* doc/posix-functions/fdopendir.texi (fdopendir): Document this.
* tests/test-fdopendir.c (main): Test something other than
/dev/null, since on Hurd that behaves like a directory.
Signed-off-by: Eric Blake <ebb9@byu.net>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* m4/fchdir.m4 (gl_FUNC_FCHDIR): Set appropriate witnesses.
* m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Add REPLACE_FSTAT.
* m4/dirent_h.m4 (gl_DIRENT_H_DEFAULTS): Add REPLACE_OPENDIR,
REPLACE_CLOSEDIR.
* m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add REPLACE_DUP.
* modules/sys_stat (Makefile.am): Substitute correct witness.
* modules/dirent (Makefile.am): Likewise.
* modules/unistd (Makefile.am): Likewise.
* lib/dirent.in.h (opendir, closedir): Use better witnesses.
* lib/unistd.in.h (dup): Likewise.
* lib/sys_stat.in.h (fstat): Likewise.
Signed-off-by: Eric Blake <ebb9@byu.net>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* lib/openat.c (fdopendir): Move...
* lib/fdopendir.c: ...into new file.
* modules/fdopendir: New module.
* m4/fdopendir.m4 (gl_FUNC_FDOPENDIR): New file.
* modules/openat (Depends-on): Add fdopendir.
* m4/openat.m4 (gl_FUNC_OPENAT): No longer need to check for
fdopendir here.
* modules/savedir (Depends-on): Only need fdopendir, not full
openat.
* lib/savedir.c (include): Use <dirent.h>, not "openat.h".
* lib/openat.h (fdopendir): Drop prototype.
* lib/dirent.in.h (fdopendir): Provide prototype.
* m4/dirent_h.m4 (gl_DIRENT_H_DEFAULTS): Add replacements.
* modules/dirent (Makefile.am): Substitute them.
* MODULES.html.sh (File system functions): Mention it.
* doc/posix-functions/fdopendir.texi (fdopendir): Likewise.
* modules/fdopendir-tests: New file.
* tests/test-fdopendir.c: Likewise.
Signed-off-by: Eric Blake <ebb9@byu.net>
|
| |
|
| |
|
| |
|
| |
|