platform/upstream/coreutils.git
17 years agoDon't include dirname.h, since system.h does it now.
Paul Eggert [Sun, 3 Sep 2006 02:53:16 +0000 (02:53 +0000)]
Don't include dirname.h, since system.h does it now.

17 years agorm now rejects attempts to remove /, ./, and ../.
Paul Eggert [Sun, 3 Sep 2006 02:50:41 +0000 (02:50 +0000)]
rm now rejects attempts to remove /, ./, and ../.

17 years agoFix typo in previous change; an unsigned int wasn't converted to
Paul Eggert [Fri, 1 Sep 2006 22:07:18 +0000 (22:07 +0000)]
Fix typo in previous change; an unsigned int wasn't converted to
uintmax_t at the right time.  Problem reported by Bruno.

17 years agoUpdate to match current gnulib.
Paul Eggert [Fri, 1 Sep 2006 19:44:43 +0000 (19:44 +0000)]
Update to match current gnulib.

17 years ago* m4/jm-macros.m4 (gl_MACROS): Call cu_PREREQ_STAT_PROG rather
Paul Eggert [Fri, 1 Sep 2006 19:40:46 +0000 (19:40 +0000)]
* m4/jm-macros.m4 (gl_MACROS): Call cu_PREREQ_STAT_PROG rather
than AC_REQUIREing, so that sys/mount.h isn't tested for after
the test result.  I'm not sure why this fix is needed, but it
works.
* m4/stat-prog.m4 (cu_PREREQ_STAT_PROG): Revamp to reflect better
what stat.c actually needs.
* src/stat.c: Include <stddef.h>
(alignof): New macro.
(HAVE_STRUCT_STATXFS_F_FSID___VAL, HAVE_STRUCT_STATXFS_F_FSID_VAL):
Remove.
(STRUCT_STATXFS_F_FSID_IS_INTEGER): New macro.
(FSID_VAL): Remove.
(print_statfs): If f_fsid isn't an integer, grab its words one
at a time in little-endian order.  This is a bit easier to configure
and should avoid a compilation failure on MacOS reported by Bruno
Haible.

17 years ago* src/stat.c (HAVE_STRUCT_STATXFS_F_FSID_VAL, FSID_VAL): New macros, to
Paul Eggert [Tue, 29 Aug 2006 21:53:29 +0000 (21:53 +0000)]
* src/stat.c (HAVE_STRUCT_STATXFS_F_FSID_VAL, FSID_VAL): New macros, to
work around a Mac OS X porting problem reported by Bruno Haible in
<http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00308.html>.
(print_statfs): Use them.
* m4/stat-prog.m4 (cu_PREREQ_STAT_PROG): Check for __val versus val
components of fsid.  Omit some checks that stat.c doesn't care about.

17 years ago* bootstrap.conf (gnulib_modules): Add isapipe.
Paul Eggert [Tue, 29 Aug 2006 20:50:21 +0000 (20:50 +0000)]
* bootstrap.conf (gnulib_modules): Add isapipe.
* src/tail.c: Include isapipe.h.
(IS_PIPE_LIKE_FILE_TYPE): Remove.
(IS_TAILABLE_FILE_TYPE): Just list both FIFOs and sockets as
tailable, since this seems to be portable.
(main): Use isapipe, to fix a bug on MacOS X reported by Bruno Haible in
<http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00304.html>.

17 years ago* src/system.h (LOCALEDIR): Remove, since configmake.h now defines
Paul Eggert [Tue, 29 Aug 2006 14:26:52 +0000 (14:26 +0000)]
* src/system.h (LOCALEDIR): Remove, since configmake.h now defines
it for us.

17 years ago(main): Don't test whether macros like
Paul Eggert [Tue, 29 Aug 2006 00:32:33 +0000 (00:32 +0000)]
(main): Don't test whether macros like
S_ISLNK are defined, since they're always defined now.

17 years ago* src/copy.c (copy_internal): Don't test whether macros like
Paul Eggert [Mon, 28 Aug 2006 23:29:38 +0000 (23:29 +0000)]
* src/copy.c (copy_internal): Don't test whether macros like
S_ISLNK are defined, since they're always defined now.
* src/cp.c (main): Likewise.
* src/ln.c (main): Likewise.
* src/ls.c (get_link_name, make_link_name): Likewise.
* src/mkfifo.c (usage): Likewise.
* src/who.c (S_IWGRP): Likewise.

17 years agoAdjust to recent gnulib changes for the gnulib module.
Paul Eggert [Mon, 28 Aug 2006 23:05:13 +0000 (23:05 +0000)]
Adjust to recent gnulib changes for the gnulib module.
* bootstrap.conf (gnulib_modules): Add fcntl.
* src/system.h (SEEK_SET, SEEK_CUR, SEEK_END): Remove.  Other code
is already assuming these macros are defined.
(O_DIRECT, O_DIRECTORY, O_DSYNC, O_NDELAY, O_NOATIME, O_NONBLOCK):
(O_NOCTTY, O_NOFOLLOW, O_NOLINKS, O_RSYNC, O_SYNC, O_BINARY, O_TEXT):
Remove; the fcntl module now handles these.

17 years agoAdjust to recent gnulib changes for the inttypes module.
Paul Eggert [Mon, 28 Aug 2006 20:51:56 +0000 (20:51 +0000)]
Adjust to recent gnulib changes for the inttypes module.
* bootstrap.conf (gnulib_modules): Remove stdint; add inttypes.
(excluded_files): Don't exclude m4/inttypes-h.m4 or m4/inttypes-pri.m4.
* src/system.h: Don't bother to include <stdint.h>, since we can
now assume inttypes.h does the equivalent of including stdint.h.

17 years agoUse http://, not https:// for savannah.gnu.org bug URLs.
Jim Meyering [Sun, 27 Aug 2006 19:59:15 +0000 (19:59 +0000)]
Use , not https:// for savannah.gnu.org bug URLs.

17 years ago* NEWS: Mention this.
Jim Meyering [Sun, 27 Aug 2006 19:46:26 +0000 (19:46 +0000)]
* NEWS: Mention this.

17 years ago* src/copy.c (copy_internal): Don't make a backup if the last
Jim Meyering [Sun, 27 Aug 2006 19:41:04 +0000 (19:41 +0000)]
* src/copy.c (copy_internal): Don't make a backup if the last
component of the source name is "." or "..".
Reported by Andreas Schwab in https://savannah.gnu.org/bugs/?17540.
* tests/cp/src-base-dot: New file.  Test for the above fix.
* tests/cp/Makefile.am (TESTS): Add src-base-dot.

17 years ago* src/system.h (DOT_OR_DOTDOT): Remove macro. Rewrite as a...
Jim Meyering [Sun, 27 Aug 2006 19:34:28 +0000 (19:34 +0000)]
* src/system.h (DOT_OR_DOTDOT): Remove macro.  Rewrite as a...
(dot_or_dotdot): ...new static inline function.
* src/remove.c (rm_1): Reflect this renaming.
* src/ls.c (basename_is_dot_or_dotdot): Likewise.

17 years agoTwo of those comments apply only when "moving" (not when copying).
Jim Meyering [Sun, 27 Aug 2006 16:29:11 +0000 (16:29 +0000)]
Two of those comments apply only when "moving" (not when copying).
Correct them.

17 years ago* src/copy.c (copy_internal): Add comments.
Jim Meyering [Sun, 27 Aug 2006 16:20:52 +0000 (16:20 +0000)]
* src/copy.c (copy_internal): Add comments.

17 years ago(AM_CPPFLAGS): Remove -I$(srcdir) and -I../lib,
Paul Eggert [Sun, 27 Aug 2006 06:03:02 +0000 (06:03 +0000)]
(AM_CPPFLAGS): Remove -I$(srcdir) and -I../lib,
since Automake supplies them for us.  It always did -I$(srcdir),
and with the recent change to AC_CONFIG_HEADERS in configure.ac it
is now also doing -I../lib.

17 years agoFix typo in previous bootstrap change; WGET_COMMAND is needed by sh.
Paul Eggert [Sun, 27 Aug 2006 03:35:09 +0000 (03:35 +0000)]
Fix typo in previous bootstrap change; WGET_COMMAND is needed by sh.

17 years ago.cvsignore: Add config-h.m4.
Paul Eggert [Sun, 27 Aug 2006 03:34:42 +0000 (03:34 +0000)]
.cvsignore: Add config-h.m4.

17 years agoThis test was failing in some environments.
Jim Meyering [Sat, 26 Aug 2006 18:44:52 +0000 (18:44 +0000)]
This test was failing in some environments.
* tests/ls/color-dtype-dir: Don't rely on eval "`dircolors -b`"
to set LS_COLORS in the environment.
* tests/envvar-check: Instead, ensure that LS_COLORS is not set.
Reported by Bob Proulx.

17 years ago* bootstrap (get_translations): Skip this if WGET_COMMAND is empty.
Paul Eggert [Sat, 26 Aug 2006 18:33:08 +0000 (18:33 +0000)]
* bootstrap (get_translations): Skip this if WGET_COMMAND is empty.
Fail if the first "echo" fails.  Suppress diagnostics from "ls po/*.po"
since there might not be any .po files.
(WGET_COMMAND): Set to empty if wget doesn't
seem to be available.  Don't export; shouldn't be needed.

17 years ago* tests/mv/Makefile.am (TESTS): Add backup-dir.
Jim Meyering [Sat, 26 Aug 2006 17:13:49 +0000 (17:13 +0000)]
* tests/mv/Makefile.am (TESTS): Add backup-dir.

17 years ago* src/c99-to-c89.diff: Remove hunk for copy.c; no longer needed.
Jim Meyering [Sat, 26 Aug 2006 16:21:15 +0000 (16:21 +0000)]
* src/c99-to-c89.diff: Remove hunk for copy.c; no longer needed.

17 years agos/c98/c89/ in file name.
Jim Meyering [Sat, 26 Aug 2006 16:20:59 +0000 (16:20 +0000)]
s/c98/c89/ in file name.

17 years ago* Makefile.am (EXTRA_DIST): Remove these files here, too:
Jim Meyering [Sat, 26 Aug 2006 16:18:04 +0000 (16:18 +0000)]
* Makefile.am (EXTRA_DIST): Remove these files here, too:
.x-sc_no_if_have_config_h, .x-sc_prohibit_assert_without_use,
.x-sc_two_space_separator_in_usage.

17 years agoFix "mv --verbose --backup" so its output includes the
Jim Meyering [Sat, 26 Aug 2006 15:53:24 +0000 (15:53 +0000)]
Fix "mv --verbose --backup" so its output includes the
" (backup: foo.~1~)" suffix also when backing up a directory.
* NEWS: Report this bug fix.
* src/copy.c (emit_verbose): New function, factored out of...
(copy_internal): ...here.  Use the new function.
* tests/mv/backup-dir: Test for the above fix.

17 years agoInclude <config.h> unconditionally, since we now assume config.h exists.
Paul Eggert [Sat, 26 Aug 2006 06:55:57 +0000 (06:55 +0000)]
Include <config.h> unconditionally, since we now assume config.h exists.

17 years ago"ls --color" would highlight other-writable and sticky directories
Jim Meyering [Sat, 26 Aug 2006 06:46:17 +0000 (06:46 +0000)]
"ls --color" would highlight other-writable and sticky directories
no differently than regular directories on a file system with
dirent.d_type support.
* NEWS: Say the above.
* src/ls.c (gobble_file): With --color, also stat the file when
we know it is a directory.
Derived from an anonymous one-line fix and bug report:
<https://savannah.gnu.org/bugs/?15043>.
* tests/ls/color-dtype-dir: New file.  Test for the above fix.
* tests/ls/Makefile.am (TESTS): Add color-dtype-dir.

17 years ago* .cvsignore: Remove stamp-h1. Add coreutils-*, to ignore
Paul Eggert [Fri, 25 Aug 2006 23:30:57 +0000 (23:30 +0000)]
* .cvsignore: Remove stamp-h1.  Add coreutils-*, to ignore
tarballs.
* bootstrap.conf: Add configmake, verify.
* lib/.cvsignore: Add configmake.h, stamp-h1.
* src/.cvsignore: Remove localedir.h.
* src/Makefile.am (localedir, DISTCLEANFILES, localedir.h): Remove;
subsumed by configmake.
* src/system.h: Include configmake.h rather than localedir.h
(LOCALEDIR): New macro.

17 years agoFix typo in previous checkin; a "&" went missing.
Paul Eggert [Fri, 25 Aug 2006 23:12:01 +0000 (23:12 +0000)]
Fix typo in previous checkin; a "&" went missing.

17 years agoRewrite to avoid some unnecessary casts, macros, literals.
Paul Eggert [Fri, 25 Aug 2006 23:08:58 +0000 (23:08 +0000)]
Rewrite to avoid some unnecessary casts, macros, literals.
(DEFAULT_PASSES, VERBOSE_UPDATE): Now constants, not macros.
(SECTOR_SIZE, SECTOR_MASK): New constants.
(fillpattern, dopass, do_wipefd, main): Remove unnecessary casts,
and use the SECTOR_* constants when applicable.  Check for size <
0 rather than size == -1, since negative-size files are a sign of
trouble anyway.

(dopass): Assume a continuable error if EIO even if the current
position is not a multiple of 512.

17 years ago* src/stat.c (print_statfs): Fix typo: remove extra "sizeof".
Jim Meyering [Thu, 24 Aug 2006 21:47:37 +0000 (21:47 +0000)]
* src/stat.c (print_statfs): Fix typo: remove extra "sizeof".

17 years ago* src/stat.c (HAVE_STRUCT_STATXFS_F_FSID___VAL): Define. This
Paul Eggert [Wed, 23 Aug 2006 23:40:21 +0000 (23:40 +0000)]
* src/stat.c (HAVE_STRUCT_STATXFS_F_FSID___VAL): Define.  This
macro was being used without being defined.
(SB_F_NAMEMAX): Remove cast.
(f_fsid) [BeOS]: Likewise.
(OUT_NAMEMAX): Renamed from NAMEMAX_FORMAT, with a new meaning.
All uses changed.
(out_string, out_int, out_uint, out_uint_o, out_uint_x): New
functions.
(xstrcat): Remove.  All uses changed to use the above functions.
(print_statfs, print_stat): 2nd arg is now the prefix len, not the
buffer len.  All uses changed.  Output '?', not '*', for unknown
data or errors.  Do not assume signed values can be interchanged
with unsigned when printing.
(print_statfs): For %i, print the fsid as a single int, not as a
pair.
(print_it): Quote invalid format better.
(STRUCT_STATVFS, statfs, f_fsid, f_blocks, f_bfree) [BeOS]:
(f_bavail, f_bsize, STATFS_FRSIZE, f_files, f_ffree) [BeOS]:
(STATXFS_FILE_SYSTEM_TYPE_MEMBER_NAME) [BeOS]: Define.

17 years ago* NEWS: printf supports the I flag.
Paul Eggert [Wed, 23 Aug 2006 23:38:27 +0000 (23:38 +0000)]
* NEWS: printf supports the I flag.
* src/printf.c (print_formatted) [glibc 2.2 or later]: Likewise.

17 years ago(SA_RESTART): Fallback define.
Paul Eggert [Wed, 23 Aug 2006 19:19:01 +0000 (19:19 +0000)]
(SA_RESTART): Fallback define.

17 years ago* src/system.h (EDQUOT): Define if not already defined.
Paul Eggert [Wed, 23 Aug 2006 19:14:25 +0000 (19:14 +0000)]
* src/system.h (EDQUOT): Define if not already defined.

17 years ago* .cvsignore: Remove config.h, config.hin, as they are now
Paul Eggert [Wed, 23 Aug 2006 18:37:27 +0000 (18:37 +0000)]
* .cvsignore: Remove config.h, config.hin, as they are now
in lib.
* configure.ac (AC_CONFIG_HEADERS): Move config.h and config.hin
to lib.
* lib/.cvsignore: Add config.h, config.hin.
* lib/Makefile.am (AM_CPPFLAGS): Remove; we no longer need '-I..'.
* src/Makefile.am (AM_CPPFLAGS): Remove '-I..'; no longer needed.

17 years agoNo need to define gl_LOCK.
Paul Eggert [Wed, 23 Aug 2006 18:09:40 +0000 (18:09 +0000)]
No need to define gl_LOCK.

17 years ago* bootstrap (slurp): Also put in a dummy definition for
Paul Eggert [Wed, 23 Aug 2006 18:06:48 +0000 (18:06 +0000)]
* bootstrap (slurp): Also put in a dummy definition for
gl_LOCK_EARLY, introduced recently into gnulib.

17 years agoAdd gnupload.
Paul Eggert [Wed, 23 Aug 2006 17:08:09 +0000 (17:08 +0000)]
Add gnupload.

17 years ago* NEWS: Mention the sweeping infrastructure changes.
Jim Meyering [Wed, 23 Aug 2006 09:17:14 +0000 (09:17 +0000)]
* NEWS: Mention the sweeping infrastructure changes.

17 years ago* bootstrap.conf (gnulib_modules): Add gnupload.
Paul Eggert [Tue, 22 Aug 2006 19:36:22 +0000 (19:36 +0000)]
* bootstrap.conf (gnulib_modules): Add gnupload.
* Makefile.maint (emit_upload_commands): gnupload is now
in build-aux.
* gnupload: Remove from CVS, since it's now a gnulib module.

17 years ago* bootstrap (bootstrap_conf_cleanup): Remove.
Paul Eggert [Tue, 22 Aug 2006 19:19:57 +0000 (19:19 +0000)]
* bootstrap (bootstrap_conf_cleanup): Remove.
(excluded_files): New var.
* bootstrap.conf: Likewise.
* bootstrap (slurp): Exclude files early if they're in the
excluded_files list.  That way, their names don't get put into
.cvsignore.

17 years agoAdd aclocal.m4, config.hin, configure to .cvsignore.
Paul Eggert [Tue, 22 Aug 2006 18:59:02 +0000 (18:59 +0000)]
Add aclocal.m4, config.hin, configure to .cvsignore.

17 years ago* aclocal.m4, config.hin, configure:
Paul Eggert [Tue, 22 Aug 2006 18:50:24 +0000 (18:50 +0000)]
* aclocal.m4, config.hin, configure:
Remove from CVS, since ./bootstrap generates them automatically.
* .cvsignore: Add INSTALL, Makefile.in, *.cache, *.lineno, *.log.
Remove more-specific entries.  This catches files like configure.lineno.
* man/.cvsignore: Add Makefile.in.
* src/.cvsignore: Add Makefile.in.
Remove .version, dir.c, install, mvdir, stamp-v, vdir.c, version.c.

For .cvsignore file under the tests directory:
Add Makefile.in.  Sort entries if necessary.  Remove *.I, *.E,
*.X, *.O, *-tests, build-script, mk-script if they're never
created in this directory.

* build-aux/.cvsignore: New file.
* doc/.cvsignore: Add Makefile.in, coreutils.html, coreutils.pdf,
coreutils.ps, coreutils.tps.  Remove coreutils.cm (dunno what it
is, but the makefile doesn't mention it).  Remove coreutils.info
as it is subsumed by coreutils.info*.
* lib/.cvsignore: Add Makefile.in, getdate.tab.h.
Remove stat.c, sysexit.h.
* m4/.cvsignore: Remove Makefile, dev-ino.m4, glibc2.m4, intdiv0.m4,
inttypes-h.m4, inttypes-pri.m4, jm-glibc-io.m4, lcmessage.m4,
lock.m4, printf-posix.m4, same-inode.m4, size_max.m4,
uintmax_t.m4, ulonglong.m4, visibility.m4, xsize.m4.  Many of
these are put in automatically by ../bootstrap, but that's a
bootstrap bug that I plan to fix shortly.
* po/.cvsignore: More ../bootstrap-related fixes, plus remove old
cruft.  Add *.po, LINGUAS, Makevars.  Remove *.cat, *.msg,
cat-id-dbl.c, messages.mo, stamp-cat-id.

17 years agoBeOS portability.
Paul Eggert [Tue, 22 Aug 2006 17:42:21 +0000 (17:42 +0000)]
BeOS portability.
* src/uptime.c: Include OS.h if it exists.
(print_uptime): On BeOS, use the get_system_info function (actually a
macro). Loop through utmp entries only if utmp.h or utmpx.h exists.
(uptime): Call read_utmp only if utmp.h or utmpx.h exists.
* m4/boottime.m4 (GNULIB_BOOT_TIME): Test also for utmp.h, utmpx.h,
OS.h. Don't require to have utmp.h or utmpx.h. Enable boottime
support if <OS.h> is found.

17 years ago* .cvsignore: Add files that are now generated by ../bootstrap.
Jim Meyering [Tue, 22 Aug 2006 11:01:23 +0000 (11:01 +0000)]
* .cvsignore: Add files that are now generated by ../bootstrap.

17 years ago[ChangeLog]
Jim Meyering [Tue, 22 Aug 2006 10:44:40 +0000 (10:44 +0000)]
[ChangeLog]
* .cvsignore: Add ABOUT-NLS.
[lib/ChangeLog]
* .cvsignore: Add files that are now generated by ../bootstrap.
[m4/ChangeLog]
* .cvsignore: Add files that are now generated by ../bootstrap.
[po/ChangeLog]
* .cvsignore: Add files that are now generated by ../bootstrap.

17 years agoMove the check-AUTHORS rule to be run as part of "make distcheck",
Jim Meyering [Tue, 22 Aug 2006 10:13:37 +0000 (10:13 +0000)]
Move the check-AUTHORS rule to be run as part of "make distcheck",
rather than "make check".
* src/Makefile.am (check): Don't depend on check-AUTHORS; it would
cause "make check" to fail on systems unable to build all binaries.
* Makefile.maint (check-AUTHORS): New rule.
(local-checks-available): Add it here.
Reported by Bruno Haible.  Needed for BeOS.

17 years ago(LDADD): Restore this line; it is still needed for
Paul Eggert [Tue, 22 Aug 2006 07:00:51 +0000 (07:00 +0000)]
(LDADD): Restore this line; it is still needed for
t-fpending on platforms without __fpending.

17 years agoRemove df -mP.
Paul Eggert [Tue, 22 Aug 2006 04:00:01 +0000 (04:00 +0000)]
Remove df -mP.

17 years ago(print_header, show_dev): Use a column width that
Paul Eggert [Tue, 22 Aug 2006 03:59:14 +0000 (03:59 +0000)]
(print_header, show_dev): Use a column width that
depends on the block size of -P is specified and not autoscaling.

17 years agoRemove argmatch.m4 from CVS, since ../bootstrap generates it automatically.
Paul Eggert [Mon, 21 Aug 2006 22:09:48 +0000 (22:09 +0000)]
Remove argmatch.m4 from CVS, since ../bootstrap generates it automatically.

17 years ago* tests/dircolors/simple (a): Don't fail with an unexpected diagnostic
Jim Meyering [Mon, 21 Aug 2006 17:28:09 +0000 (17:28 +0000)]
* tests/dircolors/simple (a): Don't fail with an unexpected diagnostic
when the shell variable, SHELL, is not set.
Trigger the failure with "(unset SHELL; make check TESTS=simple)".
Reported by Sven Joachim in <http://bugs.debian.org/355368>.

17 years ago* src/od.c: Now that HAVE_UNSIGNED_LONG_LONG is no longer defined
Jim Meyering [Mon, 21 Aug 2006 13:54:04 +0000 (13:54 +0000)]
* src/od.c: Now that HAVE_UNSIGNED_LONG_LONG is no longer defined
in config.h, change the uses to HAVE_UNSIGNED_LONG_LONG_INT.
Otherwise, on a system with 4-byte longs, "od -t u8" fails with this:
od: invalid type string `u8';
this system doesn't provide a 8-byte integral type
FIXME: add a test for this, but skip it when sizeof uintmax < 8.

17 years agoDone: convert to use gnulib-tool
Jim Meyering [Mon, 21 Aug 2006 08:11:55 +0000 (08:11 +0000)]
Done: convert to use gnulib-tool

17 years agoAdd a bootstrap procedure, so that the CVS version contains fewer
Paul Eggert [Mon, 21 Aug 2006 07:30:45 +0000 (07:30 +0000)]
Add a bootstrap procedure, so that the CVS version contains fewer
files and we bootstrap the rest from gnulib, gettext, etc.
* README-cvs: New file.
* bootstrap: New file.
* bootstrap.conf: New file.
* .x-sc_trailing_blank: Remove config-log, .gdb-history.  Add .po.
* configure.ac (AC_PREREQ): Move here from m4/*.m4, for benefit
of gnulib-tool.
(gl_DEFAULT_POSIX2_VERSION, gl_USE_SYSTEM_EXTENSIONS, gl_PERL):
(gl_IGNORE_UNUSED_LIBRARIES): Remove; now done by gnulib.
(gl_EARLY): Add.
(gl_MACROS): Call just after gl_EARLY, just for clarity.
* src/c99-to-c98.diff: Remove patch to ls.c; no longer needed.
* src/kill.c (strtoimax): Remove decl.
* src/ls.c: Include "wcwidth.h" instead of rolling it ourselves.
* src/wc.c: Likewise.
* src/ls.c (sort_files): Rewrite to avoid need for C99-style
declaration, so that we don't need to patch this file.
* src/printf.c (strtoimax, strtoumax): Remove decls.
* src/su.c: Include getpass.h.
(getpass): remove.
* src/system.h: Include mempcpy.h, stpcpy.h, strpbrk.h.
Include inttypes.h unconditionally; remove decls it handles.
* lib/Makefile.am: include gnulib.mk, so that we can remove most of
this file.
(AM_CPPFLAGS): Don't mention -I$(srcdir), since that's now done
for us.
(noinst_LIBRARIES, LDDADD, DEFS): Remove.
(libcoreutils_a_SOURCES): Trim down greatly, just to the files
that aren't in gnulib.
Remove defns gnulib does for us.
* m4/check-decl.m4 (gl_CHECK_DECLS):
Don't include stdio.h, string.h, stdlib.h, unistd.h, sys/time.h,
time.h.  Use AC_CHECK_DECLS_ONCE for free, getenv, geteuid, getlogin,
getuid, lseek, malloc, memchr, realloc.  Don't check for getutent,
memrchr, nanosleep, stpcpy, strndup, strnlen, strstr, strtoul,
strtoull.
(_gl_DECL_HEADERS): Remove; all uses removed.
* m4/jm-macros.m4 (gl_MACROS): Move AC_PREREQ into configure.ac
for the benefit of gnulib-tool.  Call gl_INIT.
Do not call or require macros that gnulib will handle for us.
Don't check for fchmod, hasmntopt, isascii, lchown, listmntent,
mempcpy, realpath, wcrtomb, tzset.
(gl_CHECK_ALL_HEADERS): Don't check for sys/statvfs.h, sys/vfs.h,
sys/mount.h.
(gl_CHECK_ALL_TYPES): Require AC_TYPE_UNSIGNED_LONG_LONG_INT.
Don't check for struct stat.st_blksize.
Don't require AC_STRUCT_ST_DM_MODE, gt_TYPE_SSIZE_T,
gl_AC_TYPE_UINT32_T, gl_AC_TYPE_UINTMAX_T, gl_AC_TYPE_UINTPTR_T,
gl_AC_TYPE_UNSIGNED_LONG_LONG.
* m4/prereq.m4 (gl_PREREQ): Require gl_FUNC_XFTS, gl_ROOT_DEV_INO.
Don't require macros that gnulib does for us.
* m4/stat-prog.m4 (cu_PREREQ_STAT_PROG): Don't check for
sys/sysmacros.h.  Don't check for statvfs.  Use AC_CHECK_HEADERS_ONCE
for netinet/in.h, nfs/nfs_clnt.h, nfs/vfs.h.
Don't require gl_AC_TYPE_LONG_LONG, gt_HEADER_INTTYPES_H.

17 years agoRemove from CVS, since the bootstrap script generates them automatically.
Paul Eggert [Mon, 21 Aug 2006 07:26:38 +0000 (07:26 +0000)]
Remove from CVS, since the bootstrap script generates them automatically.

17 years agoadd -cvs suffix
Jim Meyering [Sun, 20 Aug 2006 15:53:11 +0000 (15:53 +0000)]
add -cvs suffix

17 years agothe patch from 2006-08-18 broke on cygwin.
Paul Eggert [Sun, 20 Aug 2006 15:17:27 +0000 (15:17 +0000)]
the patch from 2006-08-18 broke on cygwin.

17 years ago* NEWS: Add a line for 6.2-cvs.
Jim Meyering [Sun, 20 Aug 2006 14:23:38 +0000 (14:23 +0000)]
* NEWS: Add a line for 6.2-cvs.
* configure.ac (AC_INIT): Bump to 6.2 and add "-cvs" suffix.

17 years ago.
Jim Meyering [Sat, 19 Aug 2006 21:03:14 +0000 (21:03 +0000)]
.

17 years ago. COREUTILS-6_1 v6.1
Jim Meyering [Sat, 19 Aug 2006 20:49:45 +0000 (20:49 +0000)]
.

17 years ago* tests/Makefile.am (EXTRA_DIST): Add sparse-file.
Jim Meyering [Sat, 19 Aug 2006 20:34:57 +0000 (20:34 +0000)]
* tests/Makefile.am (EXTRA_DIST): Add sparse-file.

17 years ago.
Jim Meyering [Sat, 19 Aug 2006 20:34:31 +0000 (20:34 +0000)]
.

17 years ago.
Jim Meyering [Sat, 19 Aug 2006 20:17:21 +0000 (20:17 +0000)]
.

17 years agoremove trailing blanks, again
Jim Meyering [Sat, 19 Aug 2006 19:36:44 +0000 (19:36 +0000)]
remove trailing blanks, again

17 years agoremove -cvs suffix, too
Jim Meyering [Sat, 19 Aug 2006 19:35:28 +0000 (19:35 +0000)]
remove -cvs suffix, too

17 years ago.
Jim Meyering [Sat, 19 Aug 2006 19:34:16 +0000 (19:34 +0000)]
.

17 years agoImport from Translation Project, with obvious corrections for plural forms.
Paul Eggert [Sat, 19 Aug 2006 19:00:41 +0000 (19:00 +0000)]
Import from Translation Project, with obvious corrections for plural forms.

17 years ago* Version 6.1.
Jim Meyering [Sat, 19 Aug 2006 18:33:50 +0000 (18:33 +0000)]
* Version 6.1.
* NEWS: Record the 6.1 release date.
* configure.ac (AC_INIT): Remove "-cvs" suffix from version string.

17 years agoAvoid test failure when `make check' is run through debuild.
Jim Meyering [Sat, 19 Aug 2006 18:30:04 +0000 (18:30 +0000)]
Avoid test failure when `make check' is run through debuild.
* tests/help-version: Ensure that $SHELL is set to some value
and exported.  Patch from Sven Joachim.  For details, see
<http://bugs.debian.org/355368>.

17 years ago*** empty log message ***
Jim Meyering [Sat, 19 Aug 2006 17:37:28 +0000 (17:37 +0000)]
*** empty log message ***

17 years ago* tests/ls/stat-dtype: Test for the 2006-08-17 `ls -CF' fix.
Jim Meyering [Sat, 19 Aug 2006 17:19:12 +0000 (17:19 +0000)]
* tests/ls/stat-dtype: Test for the 2006-08-17 `ls -CF' fix.

17 years agoChange FIXME comment to fwd ref.
Jim Meyering [Sat, 19 Aug 2006 17:17:49 +0000 (17:17 +0000)]
Change FIXME comment to fwd ref.

17 years agoCapitalize the P in Pre-C99.
Jim Meyering [Sat, 19 Aug 2006 16:52:41 +0000 (16:52 +0000)]
Capitalize the P in Pre-C99.

17 years ago* README: Describe potential "pre-C99 build failure", and work-around.
Jim Meyering [Sat, 19 Aug 2006 16:23:17 +0000 (16:23 +0000)]
* README: Describe potential "pre-C99 build failure", and work-around.

17 years agoSome of my 2006-07-03 changes to tests/*/Makefile.am were being
Jim Meyering [Sat, 19 Aug 2006 16:02:11 +0000 (16:02 +0000)]
Some of my 2006-07-03 changes to tests/*/Makefile.am were being
backed out due to updates provoked by the copyright changes.
* tests/Makefile.am.in (PATH): Prepend $(VG_PATH_PREFIX), so that
it propagates to the derived Makefile.am files.
($(srcdir)/Makefile.am): Mark generated .am files as read-only,
so we don't mistakenly edit them again.
* tests/cut/Makefile.am: Regenerate.
* tests/head/Makefile.am: Likewise.
* tests/join/Makefile.am: Likewise.
* tests/pr/Makefile.am: Likewise.
* tests/sort/Makefile.am: Likewise.
* tests/tac/Makefile.am: Likewise.
* tests/tail/Makefile.am: Likewise.
* tests/test/Makefile.am: Likewise.
* tests/tr/Makefile.am: Likewise.
* tests/uniq/Makefile.am: Likewise.
* tests/wc/Makefile.am: Likewise.

17 years ago* NEWS: Fix cp --sparse so that it preserves tail-end sparseness, even
Jim Meyering [Sat, 19 Aug 2006 14:01:29 +0000 (14:01 +0000)]
* NEWS: Fix cp --sparse so that it preserves tail-end sparseness, even
when the file's apparent size is not a multiple of its block size.
* src/copy.c (copy_reg): Don't write a NUL before calling ftruncate.
For some file sizes, writing that single byte would unnecessarily
waste a few file blocks.  That write may have been necessary in the
early days of Linux, but now, removing it should be safe.
Based on a patch by Alan Curry: <http://bugs.debian.org/370792>
* tests/cp/sparse: New test for the above.
* tests/cp/Makefile.am (TESTS): Add sparse.

* tests/sparse-file: New file, essence factored out of...
* tests/du/8gb: ... here.  Use the new script.

17 years agoAdd support for NetBSD 3.0.
Paul Eggert [Fri, 18 Aug 2006 18:36:04 +0000 (18:36 +0000)]
Add support for NetBSD 3.0.
* src/stat.c (USE_STATVFS): Set to 1 if 'struct statvfs' has a field
f_fstypename.
(STATXFS_FILE_SYSTEM_TYPE_MEMBER_NAME): Define also if 'struct statvfs'
has a field f_fstypename.
This undoes the 2006-08-15 to src/stat.c.
* lib/mountlist.c [MOUNTED_GETMNTINFO2]: Include sys/statvfs.h.
(ME_DUMMY): Treat "kernfs" as a dummy.
(read_file_system_list) [MOUNTED_GETMNTINFO2]: Implement.
* m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Also check for
sys/statvfs.h. When getmntinfo was found, check its declaration and
set either MOUNTED_GETMNTINFO or MOUNTED_GETMNTINFO2 depending on it.
* m4/stat-prog.m4 (cu_PREREQ_STAT_PROG): Test also for f_fstypename
in struct statvfs.

17 years ago* src/system.h (select_plural): Reduce by 1000000, not 1000, since
Paul Eggert [Fri, 18 Aug 2006 18:12:47 +0000 (18:12 +0000)]
* src/system.h (select_plural): Reduce by 1000000, not 1000, since
the CVS gettext manual now suggests 1000000.

17 years ago* gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Also check for CLOCK_REALTIME,
Jim Meyering [Fri, 18 Aug 2006 09:04:12 +0000 (09:04 +0000)]
* gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Also check for CLOCK_REALTIME,
since gethrxtime may revert to using clock_gettime via gettime.c.
Gabor Z. Papp reported that gethrxtime-using programs failed to
link due to unresolved clock_gettime on a linux-2.4.x system.

17 years agoback out last patch
Jim Meyering [Fri, 18 Aug 2006 08:24:46 +0000 (08:24 +0000)]
back out last patch

17 years ago* gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Reverse sense of test for
Jim Meyering [Fri, 18 Aug 2006 07:34:06 +0000 (07:34 +0000)]
* gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Reverse sense of test for
CLOCK_MONOTONIC.  Otherwise, linking a gethrxtime-using program
with $(LIB_GETHRXTIME) could fail due to unresolved clock_gettime.
Reported by Gabor Z. Papp.

17 years ago* Makefile.am (EXTRA_DIST): Reflect doclicense.texi->fdl.texi renaming.
Jim Meyering [Thu, 17 Aug 2006 20:55:32 +0000 (20:55 +0000)]
* Makefile.am (EXTRA_DIST): Reflect doclicense.texi->fdl.texi renaming.

17 years agoRemove; no longer needed.
Paul Eggert [Thu, 17 Aug 2006 20:09:22 +0000 (20:09 +0000)]
Remove; no longer needed.

17 years agoAdd/fix copyright notices and adjust to latest GNU FDL.
Paul Eggert [Thu, 17 Aug 2006 19:58:17 +0000 (19:58 +0000)]
Add/fix copyright notices and adjust to latest GNU FDL.

17 years agols -CF would misalign columns in some cases.
Jim Meyering [Thu, 17 Aug 2006 15:46:56 +0000 (15:46 +0000)]
ls -CF would misalign columns in some cases.
* src/ls.c (get_type_indicator): New function.  extracted from...
(print_type_indicator): ...here.  Use it.
(length_of_file_name_and_frills): Use it here, too, rather than
assuming stat.st_mode is valid.
Reported by Andreas Schwab, here:
<http://article.gmane.org/gmane.comp.gnu.core-utils.bugs/7774>
FIXME: add a test for this: FYI, I did ls -CF /proc and visually
inspected the result.

17 years ago* src/copy.c (copy_internal, same_file_ok): Adjust comments not
Jim Meyering [Thu, 17 Aug 2006 15:34:59 +0000 (15:34 +0000)]
* src/copy.c (copy_internal, same_file_ok): Adjust comments not
to mention the now-removed cp_options.xstat member.

17 years agoregenerate
Jim Meyering [Thu, 17 Aug 2006 11:49:08 +0000 (11:49 +0000)]
regenerate

17 years ago(AC_INIT): Bump to 6.1 and add "-cvs" suffix.
Jim Meyering [Thu, 17 Aug 2006 11:47:53 +0000 (11:47 +0000)]
(AC_INIT): Bump to 6.1 and add "-cvs" suffix.

17 years ago* Makefile.maint (patch-check): Adapt to work now that the patch
Jim Meyering [Thu, 17 Aug 2006 10:03:05 +0000 (10:03 +0000)]
* Makefile.maint (patch-check): Adapt to work now that the patch
modifies more than one file in src/.

17 years agoWith this patch, permit building with Solaris cc on Solaris 7.
Jim Meyering [Thu, 17 Aug 2006 09:50:24 +0000 (09:50 +0000)]
With this patch, permit building with Solaris cc on Solaris 7.
* src/c99-to-c89.diff: Add diffs to convert more c99-isms.
This integrates patches from Bruno Haible.

17 years ago* tests/chmod/setgid (abs_srcdir): Remove; not used or needed.
Paul Eggert [Wed, 16 Aug 2006 21:58:48 +0000 (21:58 +0000)]
* tests/chmod/setgid (abs_srcdir): Remove; not used or needed.
Skip this test if "chmod g+s d" silently does nothing.

17 years ago* tests/cp/Makefile.am: Don't mark "acl" as XFAIL.
Jim Meyering [Wed, 16 Aug 2006 21:53:56 +0000 (21:53 +0000)]
* tests/cp/Makefile.am: Don't mark "acl" as XFAIL.
* tests/cp/acl: Instead, skip the test if either setfacl
or getfacl fails.

17 years agoSkip this test suite if we can't set up files
Paul Eggert [Wed, 16 Aug 2006 21:46:36 +0000 (21:46 +0000)]
Skip this test suite if we can't set up files
properly for the setuid-etc test.

17 years ago* tests/lang-default (LC_ALL): Set to "C", so we get
Paul Eggert [Wed, 16 Aug 2006 20:11:42 +0000 (20:11 +0000)]
* tests/lang-default (LC_ALL): Set to "C", so we get
English-language diagnostics.  Unset the other variables.

17 years agoFix bugs when printing plurals of numbers that are not
Paul Eggert [Wed, 16 Aug 2006 19:36:46 +0000 (19:36 +0000)]
Fix bugs when printing plurals of numbers that are not
unsigned long int values.
* src/system.h (select_plural): New function.
* src/md5sum.c (digest_check): Use select_plural to avoid bug.
* src/uptime.c (print_uptime): Likewise.
* src/dd.c (print_stats): Likewise.  Also, don't use ngettext to
print a floating point number, as reducing to 0 or 1 doesn't work
for some languages.  Instead, just use "s" for seconds since it
doesn't need a plural form.