| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
| |
* modules/canonicalize-lgpl (Depends-on): Remove free-posix,
malloc-posix. Add unistd.
* modules/canonicalize (Depends-on): Remove free-posix, xalloc.
Add unistd.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Problem reported by Adhemerval Zanella in:
https://sourceware.org/pipermail/libc-alpha/2020-December/121182.html
* lib/canonicalize-lgpl.c, lib/canonicalize.c:
Include intprops.h.
(NARROW_ADDRESSES): New constant.
* lib/canonicalize-lgpl.c (realpath_stk):m
* lib/canonicalize.c (canonicalize_filename_mode_stk):
Work even if strlen (END) does not fit in idx_t, or if adding
N to it overflows.
* modules/canonicalize, modules/canonicalize-lgpl (Depends-on):
Add intprops.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
I misunderstood the glibc source code. Deduced from
Adhemerval Zanella’s proposed glibc patch in:
https://sourceware.org/pipermail/libc-alpha/2020-December/121131.html
* doc/posix-functions/faccessat.texi: It is not a problem.
* lib/canonicalize-lgpl.c, lib/canonicalize.c, lib/faccessat.c:
(FACCESSAT_NEVER_OVERFLOWS): Remove. All uses removed.
* lib/faccessat.c: Revert to simpler version now that
LSTAT_FOLLOWS_SLASHED_SYMLINK must be false.
* m4/faccessat.m4 (gl_FUNC_FACCESSAT_EOVERFLOW):
Remove. All uses removed.
* modules/canonicalize, modules/canonicalize-lgpl (Files):
Remove m4/faccessat.m4.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
A proper faccessat doesn't have the EOVERFLOW problem, and can be
more efficient as it needn't gather data from the filesystem to
fill in struct stat. So use stat only if faccessat is absent,
or when checking for symlink loops in canonicalize.c.
* lib/canonicalize-lgpl.c, lib/canonicalize.c:
Include fcntl.h, for AT_EACCESS.
(FACCESSAT_NEVER_EOVERFLOWS): Default to false.
(file_accessible): New function, based on faccessat but with
a fallback to stat and with an EOVERFLOW workaround.
(dir_check): Use it.
(dir_suffix): New static constant.
* lib/canonicalize-lgpl.c (FACCESSAT_NEVER_EOVERFLOWS) [_LIBC]:
Use __ASSUME_FACCESSAT2 to set FACCESSAT_NEVER_EOVERFLOWS
(__faccessat) [!_LIBC]: Define.
(realpath_stk): Use dir_suffix now.
* lib/canonicalize.c (canonicalize_filename_mode_stk):
If logical, don't check each component's existence; just check
at the end, as that's enough.
* m4/canonicalize.m4 (gl_FUNC_CANONICALIZE_FILENAME_MODE)
(gl_CANONICALIZE_LGPL_SEPARATE):
Require gl_FUNC_FACCESSAT_EOVERFLOW,
gl_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK, and check for faccessat.
(gl_CANONICALIZE_LGPL_SEPARATE): Do not check for readlink,
as the code does not use HAVE_READLINK.
* modules/canonicalize, modules/canonicalize-lgpl (Files):
Add m4/faccessat.m4, m4/lstat.m4.
(Depends-on): Add fcntl-lh.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* modules/free-posix: Renamed from modules/free.
(configure.ac): Update gl_STDLIB_MODULE_INDICATOR invocation.
* m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_FREE_POSIX,
not GNULIB_FREE.
* modules/stdlib (Makefile.am): Substitute GNULIB_FREE_POSIX, not
GNULIB_FREE.
* lib/stdlib.in.h (free): Test GNULIB_FREE_POSIX, not GNULIB_FREE.
* doc/posix-functions/free.texi: Mention the module 'free-posix' and
what it does.
* NEWS: Mention that module 'free' no longer exists.
* modules/canonicalize (Depends-on): Add free-posix. Remove free.
* modules/canonicalize-lgpl (Depends-on): Likewise.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Remove canonicalize.c’s arbitrary 8192-byte limit on platforms
like GNU Hurd that do not define the PATH_MAX macro, and similarly
for canonicalize-lgpl.c’s arbitrary 1024-byte limit. Do this by
using scratch buffers. Lessen the number of differences between
the two source files, to simplify this and future maintenance.
* lib/canonicalize-lgpl.c (__realpath):
* lib/canonicalize.c (canonicalize_filename_mode_stk):
Use scratch buffers instead of malloc and malloca. This avoids
the need for alloca, and avoids the need for malloc in most cases.
* lib/canonicalize-lgpl.c, lib/canonicalize.c: Make these files
easier to compare, e.g., by sorting include files and by switching
to the GNU convention of calling file names "file names", not
"path names". Include stdbool.h, scratch_buffer.h.
* lib/canonicalize-lgpl.c (IDX_MAX) [_LIBC]: New macro.
(malloca) [_LIBC]: Remove.
[!_LIBC]: Do not include malloca.h.
(get_path_max): New function, so that pathconf is called only in
the rare and dubious case when when RESOLVED is not null and
PATH_MAX is not defined. Invoke pathconf on "/" not the input
file name, as we care about the longest file name starting from
"/" (not from the input file name), and POSIX does not specify
what pathconf does on a non-directory file anyway. If PATH_MAX is
not defined, do not worry about overriding a path_max of 0, and do
not let path_max exceed IDX_MAX.
(__realpath): Remove an assumption that file name components
cannot exceed 1024 bytes when PATH_MAX is not defined (wrong for
the Hurd, presumably).
When allocating the result, allocate it to just the right size;
this costs nothing when the result is smaller than 1023 bytes,
and for larger results it's probably worth the CPU to call realloc,
as canonicalize.c already does.
* lib/canonicalize.c: Include attribute.h.
Do not include pathmax.h or xgetcwd.h.
(PATH_MAX): Do not define, so file names longer than 8192 bytes
work on platforms with no fixed limit.
(canonicalize_filename_mode_stk): New function, with
the content of the old canonicalize_filename_mode.
Use getcwd instead of xgetcwd, and readlink instead of areadlink,
since the scratch buffers now do memory management for us.
Use rawmemchr instead of adding strlen.
Use mempcpy instead of mempcpy + size.
Assume free preserves errno.
(canonicalize_filename_mode): Use it.
* modules/canonicalize (Depends-on): Remove areadlink, pathmax,
xgetcwd. Add attribute, free, getcwd, mempcpy, rawmemchr,
scratch_buffer, stdbool, xalloc-die.
* modules/canonicalize-lgpl (Depends-on): Remove alloca-opt,
malloca, realloc-posix. Add scratch_buffer, stdbool.
|
|
|
|
|
|
|
|
|
|
| |
Problem reported by Bruno Haible in:
https://lists.gnu.org/r/bug-gnulib/2020-12/msg00109.html
* lib/canonicalize.c (canonicalize_filename_mode):
When testing a file name ending in '/', use stat rather than
readlink, so that it does the right thing on AIX.
* modules/canonicalize (Depends-on): Add readlink, to pull in the
recent changes in the Gnulib readlink module.
|
|
|
|
|
|
|
|
|
|
| |
* lib/idx.h: New file.
* modules/idx: New file.
* lib/canonicalize-lgpl.c: Include idx.h. Use idx_t instead of
ptrdiff_t.
* lib/canonicalize.c: Likewise.
* modules/canonicalize-lgpl (Depends-on): Add idx.
* modules/canonicalize (Depends-on): Likewise.
|
|
|
|
|
|
|
|
|
|
| |
* lib/canonicalize.c (canonicalize_filename_mode):
When checking for loops, use st_dev and st_ino from the parent
directory not from the symlink, as pre-2017 POSIX says these
members are not reliable for symlinks. Couple this with START
(the remaining file name to be resolved), not NAME (the whole file
name with START as its suffix).
* modules/canonicalize (Depends-on): Depend on stat, not lstat.
|
|
|
|
|
|
|
|
|
|
| |
* lib/canonicalize.c (canonicalize_filename_mode):
When testing whether a directory entry is a symbolic link, or a
directory or other, do not use lstat or stat or
areadlink_with_size. Just use areadlink, as this suffices and it
avoids the EOVERFLOW problem that lstat and stat have.
* modules/canonicalize (Depends-on): Depend on areadlink instead
of areadlink-with-size and stat.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* lib/hash-triple.h: Group declarations.
* lib/hash-triple-simple.c: New file, extracted from lib/hash-triple.c.
* lib/hash-triple.c: Don't include <stdlib.h>, <string.h>, hash-pjw.h.
(STREQ): Remove macro.
(triple_hash, triple_compare_ino_str, triple_free): Remove functions.
* modules/hash-triple-simple: New file, based on modules/hash-triple.
* modules/hash-triple (Files): Remove lib/hash-triple.h.
(Depends-on): Add hash-triple-simple. Remove hash-pjw.
* modules/canonicalize (Depends-on): Remove hash-triple. Add
hash-triple-simple.
* modules/file-set (Depends-on): Likewise.
|
|
|
|
|
|
|
| |
* modules/canonicalize (Files): Remove m4/double-slash-root.m4.
(Depends-on): Add double-slash-root.
* modules/canonicalize-lgpl (Depends-on): Add double-slash-root.
* modules/dirname-lgpl (Depends-on): Add double-slash-root.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* lib/at-func.c: Include filename.h instead of dosname.h.
* lib/unlinkat.c: Likewise.
* modules/areadlinkat (Depends-on): Add filename. Remove dosname.
* modules/areadlinkat-with-size (Depends-on): Likewise.
* modules/faccessat (Depends-on): Likewise.
* modules/fchmodat (Depends-on): Likewise.
* modules/fchownat (Depends-on): Likewise.
* modules/fstatat (Depends-on): Likewise.
* modules/mkdirat (Depends-on): Likewise.
* modules/mkfifoat (Depends-on): Likewise.
* modules/readlinkat (Depends-on): Likewise.
* modules/selinux-at (Depends-on): Likewise.
* modules/symlinkat (Depends-on): Likewise.
* modules/unlinkat (Depends-on): Likewise.
* modules/utimensat (Depends-on): Likewise.
* lib/at-func2.c: Include filename.h instead of dosname.h.
* modules/linkat (Depends-on): Add filename. Remove dosname.
* modules/renameatu (Depends-on): Likewise.
* lib/canonicalize.c: Include filename.h instead of dosname.h.
* lib/canonicalize-lgpl.c: Likewise.
* modules/canonicalize (Depends-on): Add filename.
* modules/canonicalize-lgpl (Depends-on): Likewise.
* lib/dirname.h: Include filename.h instead of dosname.h.
* modules/dirname-lgpl (Depends-on): Add filename. Remove dosname.
* lib/fchdir.c: Include filename.h instead of dosname.h.
* modules/fchdir (Depends-on): Add filename. Remove dosname.
* lib/openat.c: Include filename.h instead of dosname.h.
* modules/openat (Depends-on): Add filename. Remove dosname.
* lib/rmdir.c: Include filename.h instead of dosname.h.
* modules/rmdir (Depends-on): Add filename. Remove dosname.
* lib/savewd.c: Include filename.h instead of dosname.h.
* modules/savewd (Depends-on): Add filename. Remove dosname.
* lib/unlink.c: Include filename.h instead of dosname.h.
* modules/unlink (Depends-on): Add filename. Remove dosname.
* modules/relocatable-prog-wrapper (Depends-on): Add filename.
* lib/relocwrapper.c: Update comments.
* modules/lstat (Depends-on): Remove dosname.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* modules/acl-permissions (Depends-on): Add stat.
* modules/canonicalize (Depends-on): Likewise.
* modules/file-has-acl (Depends-on): Likewise.
* modules/fstat (Depends-on): Likewise.
* modules/fstatat (Depends-on): Likewise.
* modules/glob (Depends-on): Likewise.
* modules/javacomp (Depends-on): Likewise.
* modules/linkat (Depends-on): Likewise.
* modules/mkdir (Depends-on): Likewise.
* modules/pt_chown (Depends-on): Likewise.
* modules/ptsname_r (Depends-on): Likewise.
* modules/readlinkat (Depends-on): Likewise.
* modules/rename (Depends-on): Likewise.
* modules/renameatu (Depends-on): Likewise.
* modules/tmpdir (Depends-on): Likewise.
* modules/utimens (Depends-on): Likewise.
* modules/relocatable-prog-wrapper (Depends-on): Add largefile.
* modules/same (Depends-on): Remove stat.
|
|
|
|
|
|
| |
* m4/canonicalize.m4 (gl_FUNC_CANONICALIZE_FILENAME_MODE): Remove
AC_LIBOBJ invocation.
* modules/canonicalize (Makefile.am): Augment lib_SOURCES.
|
|
|
|
|
|
|
|
| |
* m4/canonicalize.m4 (gl_FUNC_REALPATH_WORKS): Add GL_NOCRASH code.
* modules/canonicalize (Depends-on): Add 'nocrash'.
* modules/canonicalize-lgpl (Depends-on): Likewise.
* doc/posix-functions/realpath.texi: Update platforms list.
Reported by Ryan Schmidt <ryandesign@macports.org>.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* modules/canonicalize (Files): Add double-slash-root.m4.
* modules/canonicalize-lgpl (Files): Likewise.
* m4/canonicalize.m4 (gl_FUNC_CANONICALIZE_FILENAME_MODE)
(gl_CANONICALIZE_LGPL_SEPARATE): Add dependency.
* lib/canonicalize.c (DOUBLE_SLASH_IS_DISTINCT_ROOT): Provide
fallback definition.
(canonicalize_filename_mode): Use it to protect //.
* lib/canonicalize-lgpl.c (DOUBLE_SLASH_IS_DISTINCT_ROOT)
(__realpath): Likewise.
* tests/test-canonicalize.c (main): Test this.
* tests/test-canonicalize-lgpl.c (main): Likewise.
* modules/canonicalize-tests (Depends-on): Add same-inode.
* modules/canonicalize-lgpl-tests (Depends-on): Likewise.
Signed-off-by: Eric Blake <ebb9@byu.net>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Match current gnulib conventions of glibc functions being declared in
the same header as glibc. This makes it easier to replace broken
canonicalize_file_name. canonicalize still requires "canonicalize.h"
because canonicalize_filename_mode is not in glibc. With this patch,
canonicalize-lgpl always provides realpath and canonicalize_file_name,
while canonicalize can provide canonicalize_file_name but not
realpath; if both modules are in use, canonicalize_file_name comes
from the LGPLv2+ sources, but the testing comes from canonicalize.
* modules/canonicalize-lgpl (Files): Drop canonicalize.h.
(Include): Mention <stdlib.h>.
(configure.ac): Mention functions we provide.
* modules/canonicalize (configure.ac): Likewise.
* m4/canonicalize-lgpl.m4 (gl_CANONICALIZE_LGPL): Always replace
realpath if canonicalize_file_name is missing.
* m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Provide defaults.
* modules/stdlib (Makefile.am): Substitute witnesses.
* lib/stdlib.in.h (canonicalize_file_name, realpath): Declare.
* lib/canonicalize-lgpl.c (includes): Adjust accordingly.
* lib/canonicalize.h (canonicalize_file_name): Drop declaration.
* NEWS: Document this.
* doc/glibc-functions/canonicalize_file_name.texi
(canonicalize_file_name): Likewise.
* doc/posix-functions/realpath.texi (realpath): Likewise.
* tests/test-canonicalize-lgpl.c (includes): Use <stdlib.h>.
Signed-off-by: Eric Blake <ebb9@byu.net>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Back when canonicalize merely provided canonicalize_file_name,
resolvepath was more efficient than implementing a complete
realpath. But since resolvepath can't implement other modes for
canonicalize_filename_mode, using it is now just bulk on Solaris.
* m4/canonicalize.m4 (gl_FUNC_CANONICALIZE_FILENAME_MODE): Delete
unnecessary checks.
* lib/canonicalize.c (includes): Simplify.
(canonicalize_file_name): Drop resolvepath implementation.
* modules/canonicalize (Depends-on): Drop filenamecat.
Signed-off-by: Eric Blake <ebb9@byu.net>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The m4 files were checking whether canonicalize_file_name was
declared, but without enabling extensions, this would never
succeed. Also, mingw failed to compile the module combination of
canonicalize-lgpl and sys_stat, due to a link error on lstat.
* modules/canonicalize (Depends-on): Add extensions, lstat,
pathmax, stdlib.
(Files): Drop pathmax.h.
(configure.ac): Adjust macro name.
* modules/canonicalize-lgpl (Depends-on): Add errno, extensions,
lstat, stdlib, sys_stat.
* m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Rename...
(gl_FUNC_CANONICALIZE_FILENAME_MODE): ...to this, and require
extensions.
* m4/canonicalize-lgpl.m4 (gl_CANONICALIZE_LGPL)
(gl_CANONICALIZE_LGPL_SEPARATE): Require extensions.
(gl_PREREQ_CANONICALIZE_LGPL): Assume unistd.h.
* lib/canonicalize.h (canonicalize_file_name): Use <stdlib.h>
declaration, if available.
* lib/canonicalize-lgpl.c [HAVE_READLINK]: Delete this condition;
we can rely on the readlink module.
(MAXSYMLINKS): Also consult SYMLOOP_MAX.
(includes): Use <unistd.h> unconditionally.
Signed-off-by: Eric Blake <ebb9@byu.net>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* lib/c-stack.c (ENOTSUP): <errno.h> guarantees a definition.
* lib/canonicalize-lgpl.c (ENAMETOOLONG): Likewise.
* lib/canonicalize.c (ELOOP): Likewise.
* lib/inet_ntop.c (EAFNOSUPPORT): Likewise.
* lib/inet_pton.c (EAFNOSUPPORT): Likewise.
* lib/lchown.c (EOPNOTSUPP): Likewise.
* lib/openat-priv.h (ENOSYS, EOPNOTSUPP): Likewise.
* lib/savewd.c (ESTALE): Likewise.
* lib/settime.c (ENOSYS): Likewise.
* lib/utimens.c (ENOSYS): Likewise.
* lib/xgethostname.c (ENAMETOOLONG): Likewise.
* lib/chdir-safer.c (ELOOP): Likewise.
(chdir_no_follow): Use HAVE_READLINK, not ELOOP, as witness.
* modules/c-stack (Depends-on): Add errno.
* modules/canonicalize (Depends-on): Likewise.
* modules/chdir-safer (Depends-on): Likewise.
* modules/fdopendir (Depends-on): Likewise.
* modules/inet_ntop (Depends-on): Likewise.
* modules/inet_pton (Depends-on): Likewise.
* modules/lchown (Depends-on): Likewise.
* modules/openat (Depends-on): Likewise.
* modules/savewd (Depends-on): Likewise.
* modules/settime (Depends-on): Likewise.
* m4/chdir-safer.m4 (gl_CHDIR_SAFER): Check for readlink.
Signed-off-by: Eric Blake <ebb9@byu.net>
|
| |
|
|
|
|
|
|
|
|
|
|
| |
* modules/canonicalize (Depends-on): Add file-set and hash-triple. Sort.
Remove cycle-check.
* lib/canonicalize.c: Include file-set.h and hash-triple.h, not cycle-check.h.
(seen_triple): New function.
(canonicalize_filename_mode): Use it instead of cycle-check.
* tests/test-canonicalize.c: Add a test for this bug.
* tests/test-canonicalize.sh: Set up and run the test.
|
|
|
|
|
|
|
|
|
|
|
|
| |
* NEWS: Document the change.
* lib/mreadlink-with-size.c (mreadlink_with_size): Rename this to...
* lib/areadlink-with-size.c (areadlink_with_size): ...this.
* lib/mreadlink.h: Rename this to...
* lib/areadlink.h: ...this.
* modules/mreadlink-with-size: Rename this to...
* modules/areadlink-with-size: ...this.
* lib/canonicalize.c: Reflect the renaming.
* modules/canonicalize: Likewise.
|
|
|
|
|
|
|
|
| |
* MODULES.html.sh: Add mreadlink-with-size.
* modules/mreadlink-with-size: New module
* modules/canonicalize (Depends-on): Depend on mreadlink-with-size,
not xreadlink-with-size.
* lib/mreadlink-with-size.c, lib/mreadlink.h: New files.
|
| |
|
|
|
|
|
|
|
|
| |
* m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Remove
PROVIDE_CANONICALIZE_FILENAME_MODE macro definition.
* lib/canonicalize.h: Test GNULIB_CANONICALIZE instead of
PROVIDE_CANONICALIZE_FILENAME_MODE.
* modules/canonicalize (configure.ac): Use gl_MODULE_INDICATOR.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
stat-macros.h is now for our own macros, whereas stat_h is for
macros in the <sys/stat.h> name space.
* lib/stat-macros.h: Remove copyright notice, as this file is now tiny.
(STAT_MACROS_H): Remove.
(S_IFMT, S_ISBLK, S_ISCHR, S_ISDIR, S_ISFIFO, S_ISLNK, S_ISNAM):
(S_ISMPB, S_ISMPC, S_ISNWK, S_ISREG, S_ISSOCK, S_ISDOOR, S_ISPORT):
(S_TYPEISMQ, S_TYPEISTMO, S_TYPEISSEM, S_TYPEISSHM, S_ISCTG, S_ISOFD):
(S_ISOFL, S_ISWHT, S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IRGRP):
(S_IROTH, S_IWUSR, S_IWGRP, S_IWOTH, S_IXUSR, S_IXGRP, S_IXOTH):
(S_IRWXU, S_IRWXG, S_IRWXO, S_IXUGO, S_IRWXUGO):
Move these macros to ...
* lib/stat_.h: here. Don't include stat-macros.h.
* lib/canonicalize.c: Don't include stat-macros.h.
* lib/chown.c: Likewise.
* lib/euidaccess.c: Likewise.
* lib/file-type.c: Likewise.
* lib/filemode.c: Likewise.
* lib/glob.c: Likewise.
* lib/isapipe.c: Likewise.
* lib/lchown.c: Likewise.
* lib/lstat.c: Likewise.
* lib/mkdir-p.c: Likewise.
* lib/rmdir.c: Likewise.
* m4/lchown.m4 (gl_FUNC_LCHOWN): Don't require gl_STAT_MACROS.
* m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Don't check for io.h
unless mkdir isn't declared, to speed up 'configure'.
Always create sys/stat.h, since it's unlikely any real sys/stat.h
would define all the S_* symbols.
* modules/canonicalize (Depends-on):
Depend on sys_stat, not stat-macros.
* modules/chown: Likewise.
* modules/euidaccess: Likewise.
* modules/filemode: Likewise.
* modules/file-type: Likewise.
* modules/glob: Likewise.
* modules/isapipe: Likewise.
* modules/lchown: Likewise.
* modules/lstat: Likewise.
* modules/mkancesdirs: Likewise.
* modules/rmdir: Likewise.
* modules/mkdir-p (Depends-on): Also depend on sys_stat.
* modules/modechange: Likewise.
* modules/stat-macros (Files): Remove m4/stat-macros.m4.
(configure.ac): Remove gl_STAT_MACROS.
* modules/sys_stat (Depends-on): Remove stat-macros.
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* modules/acl (EXTRA_DIST): Add acl.h.
* modules/argmatch (Files): Add m4/argmatch.m4.
(configure.ac): Add gl_ARGMATCH.
(EXTRA_DIST): Renamed from lib_SOURCES, for
consistency with the other modules. Remove argmatch.c.
* modules/backupfile (EXTRA_DIST): Add backupfile.h.
* modules/c-strtod (EXTRA_DIST): Add c-strtod.h.
* modules/c-strtold (EXTRA_DIST): Add c-strtod.c, c-strtod.h.
* modules/canonhost (EXTRA_DIST): Add c-canonhost.h.
* modules/canonicalize (EXTRA_DIST): Add canonicalize.h.
* modules/chdir-long (EXTRA_DIST): Add chdir-long.h.
* modules/chdir-safer (EXTRA_DIST): Add chdir-safer.h.
* modules/cloexec (EXTRA_DIST): Add cloexec.h.
* modules/close-stream (EXTRA_DIST): Add close-stream.h.
* modules/closeout (EXTRA_DIST): Add closeout.h.
* modules/cycle-check (EXTRA_DIST): Add cycle-check.h.
* modules/dev-ino (EXTRA_DIST): Add dev-ino.h.
* modules/dirfd (EXTRA_DIST): Add dirfd.h.
* modules/dirname (EXTRA_DIST): Renamed from lib_SOURCES. Add
dirname.h; remove basename.c and stripslash.c.
* modules/exclude (EXTRA_DIST): Add exclude.h.
* modules/exitfail (EXTRA_DIST): Add exitfail.h.
* modules/fcntl-safer (EXTRA_DIST): Add fcntl-safer.h fcntl--.h.
* modules/file-type (EXTRA_DIST): Add file-type.h.
* modules/filemode (EXTRA_DIST): Add filemode.h.
* modules/filenamecat (EXTRA_DIST): Add filenamecat.h.
* modules/fopen-safer (EXTRA_DIST): Add stdio-safer.h stdio--.h.
* modules/fpending (EXTRA_DIST): Add __fpending.h.
* modules/fprintftime (EXTRA_DIST): Add fprintftime.h.
* modules/fsusage (EXTRA_DIST): Add fsusage.h.
* modules/fts (EXTRA_DIST): Add fts_.h fts-cycle.c.
* modules/getcwd (EXTRA_DIST): Add getcwd.h.
* modules/getdate (EXTRA_DIST): Add getdate.c.
* modules/gethrxtime (EXTRA_DIST): Add gethrxtime.h xtime.h.
* modules/getpagesize (EXTRA_DIST): Add getpagesize.h.
* modules/getpass (EXTRA_DIST): Add getpass.h.
* modules/glob (EXTRA_DIST): Add glob_.h glob-libc.h.
* modules/group-member (EXTRA_DIST): Add group-member.h.
* modules/hard-locale (EXTRA_DIST): Add hard-locale.h.
* modules/hash (EXTRA_DIST): Add hash.h.
* modules/human (EXTRA_DIST): Add human.h.
* modules/inttypes (EXTRA_DIST): Add inttypes.h.
* modules/lchmod (EXTRA_DIST): Add lchmod.h.
* modules/lchown (EXTRA_DIST): Add lchown.h.
* modules/long-options (EXTRA_DIST): Add long-options.h.
* modules/lstat (EXTRA_DIST): Add lstat.h.
* modules/md5 (EXTRA_DIST): Add memcasecmp.h.
* modules/memcoll (EXTRA_DIST): Add memcoll.h.
* modules/mempcpy (EXTRA_DIST): Add mempcpy.h.
* modules/memrchr (EXTRA_DIST): Add memrchr.h.
* modules/memxor (EXTRA_DIST): Add memxor.h.
* modules/mkancesdirs (EXTRA_DIST): Add mkancesdirs.h.
* modules/mkdir-p (EXTRA_DIST): Add modechange.h.
* modules/mountlist (EXTRA_DIST): Add mountlist.h.
* modules/openat (EXTRA_DIST): Add at-func.c openat.h openat-priv.h.
* modules/pathmax (EXTRA_DIST): Add pathmax.h.
* modules/physmem (EXTRA_DIST): Add physmem.h.
* modules/posixtm (EXTRA_DIST): Add posixtm.h.
* modules/posixver (EXTRA_DIST): Add posixver.h.
* modules/quote (EXTRA_DIST): Add quote.h.
* modules/quotearg (EXTRA_DIST): Add quotearg.h.
* modules/readtokens (EXTRA_DIST): Add readtokens.h.
* modules/readutmp (EXTRA_DIST): Add readutmp.h.
* modules/regex (EXTRA_DIST): Add regcomp.c regex.h regex_internal.c regex_internal.h regexec.c.
* modules/safe-read (EXTRA_DIST): Add safe-read.h.
* modules/safe-write (EXTRA_DIST): Add safe-write.h.
* modules/same (EXTRA_DIST): Add same.h.
* modules/same-inode (EXTRA_DIST): Add same-inode.h.
* modules/save-cwd (EXTRA_DIST): Add save-cwd.h.
* modules/savedir (EXTRA_DIST): Add savedir.h.
* modules/sha1 (EXTRA_DIST): Add sha1.h.
* modules/sig2str (EXTRA_DIST): Add sig2str.h.
* modules/stat-macros (EXTRA_DIST): Add stat-macros.h.
* modules/stat-time (EXTRA_DIST): Add stat-time.h.
* modules/stdlib-safer (EXTRA_DIST): Add stdlib-safer.h stdlib--.h.
* modules/strdup (EXTRA_DIST): Add strdup.h.
* modules/strftime (EXTRA_DIST): Add strftime.h.
* modules/strndup (EXTRA_DIST): Add strndup.h.
* modules/strnlen (EXTRA_DIST): Add strnlen.h.
* modules/strverscmp (EXTRA_DIST): Add strverscmp.h.
* modules/time_r (EXTRA_DIST): Add time_r.h.
* modules/timespec (EXTRA_DIST): Add timespec.h.
* modules/tmpfile-safer (EXTRA_DIST): Add stdio-safer.h stdio--.h.
* modules/unistd-safer (EXTRA_DIST): Add unistd-safer.h unistd--.h.
* modules/unlinkdir (EXTRA_DIST): Add unlinkdir.h.
* modules/unlocked-io (EXTRA_DIST): Add unlocked-io.h.
* modules/userspec (EXTRA_DIST): Add userspec.h.
* modules/utimecmp (EXTRA_DIST): Add utimecmp.h.
* modules/utimens (EXTRA_DIST): Add utimens.h.
* modules/xalloc (EXTRA_DIST): Add xalloc.h.
* modules/xgetcwd (EXTRA_DIST): Add xgetcwd.h.
* modules/xnanosleep (EXTRA_DIST): Add xnanosleep.h.
* modules/xreadlink (EXTRA_DIST): Add xreadlink.h.
* modules/xstrtod (EXTRA_DIST): Add xstrtod.h.
* modules/xstrtol (EXTRA_DIST): Add xstrtol.h.
* modules/xstrtold (EXTRA_DIST): Add xstrtod.c xstrtod.h.
* modules/yesno (EXTRA_DIST): Add yesno.h.
+
* m4/argmatch.m4: New file, from coreutils with AC_LIBSOURCES removed.
* m4/dev-ino.m4, same-inode.m4: Remove.
+
* m4/_inttypes_h.m4 (gl_INTTYPES_H):
* m4/acl.m4 (AC_FUNC_ACL):
* m4/backupfile.m4 (gl_BACKUPFILE):
* m4/c-strtod.m4 (gl_C99_STRTOLD):
* m4/canon-host.m4 (gl_CANON_HOST):
* m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME):
* m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG):
* m4/chdir-safer.m4 (gl_CHDIR_SAFER):
* m4/cloexec.m4 (gl_CLOEXEC):
* m4/close-stream.m4 (gl_CLOSE_STREAM):
* m4/closeout.m4 (gl_CLOSEOUT):
* m4/dirfd.m4 (gl_FUNC_DIRFD):
* m4/dirname.m4 (gl_DIRNAME):
* m4/exclude.m4 (gl_EXCLUDE):
* m4/exitfail.m4 (gl_EXITFAIL):
* m4/fcntl-safer.m4 (gl_FCNTL_SAFER):
* m4/file-type.m4 (gl_FILE_TYPE):
* m4/filemode.m4 (gl_FILEMODE):
* m4/filenamecat.m4 (gl_FILE_NAME_CONCAT):
* m4/fpending.m4 (gl_FUNC_FPENDING):
* m4/fprintftime.m4 (gl_FPRINTFTIME):
* m4/fts.m4 (gl_FUNC_FTS):
* m4/getcwd.m4 (gl_FUNC_GETCWD_NULL):
* m4/getdate.m4 (gl_GETDATE):
* m4/gethrxtime.m4 (gl_GETHRXTIME):
* m4/getpagesize.m4 (gl_GETPAGESIZE):
* m4/getpass.m4 (gl_FUNC_GETPASS):
* m4/gettime.m4 (gl_GETTIME):
* m4/getugroups.m4 (gl_GETUGROUPS):
* m4/glob.m4 (gl_GLOB_SUBSTITUTE):
* m4/group-member.m4 (gl_FUNC_GROUP_MEMBER):
* m4/hard-locale.m4 (gl_HARD_LOCALE):
* m4/hash.m4 (gl_HASH):
* m4/idcache.m4 (gl_IDCACHE):
* m4/lchmod.m4 (gl_FUNC_LCHMOD):
* m4/lchown.m4 (gl_FUNC_LCHOWN):
* m4/long-options.m4 (gl_LONG_OPTIONS):
* m4/lstat.m4 (gl_FUNC_LSTAT):
* m4/md5.m4 (gl_MD5):
* m4/memcasecmp.m4 (gl_MEMCASECMP):
* m4/memcoll.m4 (gl_MEMCOLL):
* m4/mempcpy.m4 (gl_FUNC_MEMPCPY):
* m4/memrchr.m4 (gl_FUNC_MEMRCHR):
* m4/memxor.m4 (gl_MEMXOR):
* m4/mkancesdirs.m4 (gl_MKANCESDIRS):
* m4/mkdir-p.m4 (gl_MKDIR_PARENTS):
* m4/modechange.m4 (gl_MODECHANGE):
* m4/mountlist.m4 (gl_MOUNTLIST):
* m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
* m4/openat.m4 (gl_FUNC_OPENAT):
* m4/pathmax.m4 (gl_PATHMAX):
* m4/physmem.m4 (gl_PHYSMEM):
* m4/posixtm.m4 (gl_POSIXTM):
* m4/posixver.m4 (gl_POSIXVER):
* m4/quote.m4 (gl_QUOTE):
* m4/quotearg.m4 (gl_QUOTEARG):
* m4/readtokens.m4 (gl_READTOKENS):
* m4/readutmp.m4 (gl_READUTMP):
* m4/regex.m4 (gl_REGEX):
* m4/safe-read.m4 (gl_SAFE_READ):
* m4/safe-write.m4 (gl_SAFE_WRITE):
* m4/same.m4 (gl_SAME):
* m4/save-cwd.m4 (gl_SAVE_CWD):
* m4/savedir.m4 (gl_SAVEDIR):
* m4/settime.m4 (gl_SETTIME):
* m4/sha1.m4 (gl_SHA1):
* m4/sig2str.m4 (gl_FUNC_SIG2STR):
* m4/stat-macros.m4 (gl_STAT_MACROS):
* m4/stat-time.m4 (gl_STAT_TIME):
* m4/stdio-safer.m4 (gl_FOPEN_SAFER):
* m4/stdlib-safer.m4 (gl_STDLIB_SAFER):
* m4/strdup.m4 (gl_FUNC_STRDUP):
* m4/strftime.m4 (gl_FUNC_GNU_STRFTIME):
* m4/strndup.m4 (gl_FUNC_STRNDUP):
* m4/strnlen.m4 (gl_FUNC_STRNLEN):
* m4/strverscmp.m4 (gl_FUNC_STRVERSCMP):
* m4/time_r.m4 (gl_TIME_R):
* m4/timespec.m4 (gl_TIMESPEC):
* m4/unistd-safer.m4 (gl_UNISTD_SAFER):
* m4/unlinkdir.m4 (gl_UNLINKDIR):
* m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO):
* m4/userspec.m4 (gl_USERSPEC):
* m4/utimecmp.m4 (gl_UTIMECMP):
* m4/utimens.m4 (gl_UTIMENS):
* m4/xalloc.m4 (gl_XALLOC):
* m4/xgetcwd.m4 (gl_XGETCWD):
* m4/xnanosleep.m4 (gl_XNANOSLEEP):
* m4/xreadlink.m4 (gl_XREADLINK):
* m4/xstrtod.m4 (gl_XSTRTOD):
* m2/yesno.m4 (gl_YESNO):
Don't use AC_LIBSOURCES; instead, rely on the files in ../modules/
to get the necessary .h files and whatnot.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Use "file name" when talking about file names, instead of "filename"
or "path", as per the GNU coding standards.
* MODULES.html.sh: mkdir-p renamed from makepath.
filenamecat renamed from path-concat.
* modules/filenamecat: Renamed from modules/path-concat.
(Files): filenamecat.h and filenamecat.c renamed from
path-concat.h and path-concat.c.
(configure.ac): gl_FILE_NAME_CONCAT, not gl_PATH_CONCAT.
(Include): filenamecat.h, not path-concat.h.
* modules/mkdir-p: Renamed from modules/makepath.
(Files): mkdir-p.h and mkdir-p.c renamed from makepath.h and makepath.c.
(configure.ac): gl_MKDIR_PARENTS, not gl_MAKEPATH.
(Include): mkdir-p.h, not makepath.h.
* lib/mkdir-p.c: Renamed from makepath.c.
(make_dir_parents): Renamed from make_path. All callers changed.
* lib/mkdir-p.h: Likewise. All includers changed.
* lib/filenamecat.c: Renamed from path-concat.c.
(file_name_concat): Renamed from path_concat. All callers changed.
[TEST_FILE_NAME_CONCAT]: Renamed from TEST_PATH_CONCAT.
* lib/filenamecat.h: Likewise. All includers changed.
* lib/acl.c: Don't use "path" or "filename" to mean "file name"
in comments or local variable names.
* lib/basename.c: Likewise.
* lib/canonicalize.c, canonicalize.h: Likewise.
* lib/dirname.c, dirname.h: Likewise.
* lib/euidaccess.c: Likewise.
* lib/exclude.c: Likewise
* lib/fnmatch_.h, fnmatch_loop.c: Likewise.
* lib/fsusage.c, fsuage.h: Likewise.
* lib/fts.c, fts_.h: Likewise.
* lib/getcwd.c: Likewise.
* lib/getloadavg.c: Likewise.
* lib/mkstemp.c: Likewise.
* lib/mountlist.c, mountlist.h: Likewise.
* lib/openat.c, openat.h: Likewise.
* lib/readlink-stub.c: Likewise.
* lib/readutmp.c, readutmp.h: Likewise.
* lib/rename.c: Likewise.
* lib/rmdir.c: Likewise.
* lib/same.c: Likewise.
* lib/savedir.c: Likewise.
* lib/stripslash.c: Likewise.
* lib/tempname.c: Likewise.
* lib/xreadlink.c: Likewise.
* lib/exclude.c (excluded_file_name): Renamed from excluded_filename.
All uses changed.
* lib/exclude.h: Likewise.
* m4/mkdir-p.m4: Renamed from makepath.m4.
(gl_MKDIR_PARENTS): Renamed from gl_MAKEPATH. All uses changed.
Rename files from makepath.c to mkdir-p.c, and from
makepath.h to mkdir-p.h.
* m4/filenamecat.m4: Renamed from path-concat.m4.
(gl_FILE_NAME_CONCAT): Renamed from gl_PATH_CONCAT. All uses changed.
Rename files from path-concat.c to filenamecat.c,
and from path-concat.h to filenamecat.h.
* m4/getcwd-path-max.m4: Don't use "path" or "filename" to mean
"file name" in local variables or comments.
* rename.m4: Likewise.
* lib/euidaccess.c (getuid, getgid, getuid, getegid)
[!defined _POSIX_VERSION]: Remove decls; not needed these days.
* lib/idcache.c (getpwuid, getpwnam, getgrgid, getgrnam)
[!defined _POSIX_VERSION]: Remove decls; not needed these days.
* lib/pathmax.h: Include <limits.h> unconditionally, since other
files have been getting away with it for years (MORE/BSD 4.3
is extinct now).
* lib/userspec.c (getpwnam, getgrnam, getgrgid)
[!defined _POSIX_VERSION]: Remove decls; not needed these days.
* lib/pathmax.h (_POSIX_PATH_MAX) [!defined _POSIX_PATH_MAX]:
Define to 256, not 255, as per modern POSIX.
|
|
|
|
|
| |
rather than listing lib/stat-macros.h manually.
Don't add stat-macros.h to lib_SOURCES or list it in Files: section.
|
|
|
|
| |
is now done automatically by the corresponding Autoconf macro.
|
| |
|
| |
|
| |
|
|
|