Lasse Collin [Fri, 9 Nov 2007 23:07:37 +0000 (01:07 +0200)]
"cp -p" tries to preserve GID even if preserving the UID fails.
* NEWS: Mention this new feature.
* src/copy.c (set_owner): Try to preserve just the GID,
when initial fchown/lchown fails.
* src/cp.c (re_protect): Likewise.
Jim Meyering [Fri, 23 Nov 2007 08:03:23 +0000 (09:03 +0100)]
* src/runcon.c (main): Remove unused parameter, "envp".
Jim Meyering [Thu, 22 Nov 2007 21:44:51 +0000 (22:44 +0100)]
Add tests to show new class of strings accepted by date -d.
* tests/misc/date (rel-1day, rel-plus1): New tests for the recent
change in gnulib's getdate.y.
* NEWS: Mention the fix.
Jim Meyering [Thu, 22 Nov 2007 08:24:17 +0000 (09:24 +0100)]
Quiet warnings about unused parameters.
* src/copy.c (set_author) [!HAVE_STRUCT_STAT_ST_AUTHOR]:
"Use" each of the parameters.
Jim Meyering [Thu, 22 Nov 2007 07:44:38 +0000 (08:44 +0100)]
* GNUmakefile: Correct the "rerunning..." diagnostic.
Jim Meyering [Thu, 22 Nov 2007 07:42:32 +0000 (08:42 +0100)]
Make it easier to diagnose PATH-induced "make distcheck" failures.
* Makefile.maint (write_loser): Define.
(my-distcheck): Use an always-failing wrapper script, that gives
a diagnostic, not "false".
Run only "make -C tests check" with the restrictive PATH.
Run the new gnulib-tests/ with the usual PATH.
Jim Meyering [Fri, 16 Nov 2007 08:31:15 +0000 (09:31 +0100)]
cp: by default, refuse to copy through a dangling destination symlink
* NEWS: Mention this change.
* doc/coreutils.texi (cp invocation): Describe the new behavior.
* src/copy.c: No longer include "canonicalize.h".
(copy_reg): Upon failure to open a dangling destination symlink, don't
canonicalize the name, but rather fail (default) or, with POSIXLY_CORRECT,
repeat the open call without O_EXCL (potentially dangerous).
* src/copy.h (struct cp_options) [open_dangling_dest_symlink]:
New member. Reorder the others, grouping "bool" and "enum"
members together.
* tests/cp/thru-dangling: Test for changed and new behavior.
* src/cp.c (cp_option_init): Initialize new member.
* src/install.c (cp_option_init): Likewise.
* src/mv.c (cp_option_init): Likewise.
Signed-off-by: Jim Meyering <meyering@redhat.com>
Jim Meyering [Wed, 21 Nov 2007 21:13:17 +0000 (22:13 +0100)]
Fix Pádraig's name in ChangeLog.
Pádraig Brady [Wed, 21 Nov 2007 19:45:51 +0000 (20:45 +0100)]
Improve the descriptions of the split command options.
* doc/coreutils.texi (split invocation):
Jim Meyering [Wed, 21 Nov 2007 17:41:06 +0000 (18:41 +0100)]
* src/c99-to-c89.diff: Adjust seq.c offsets.
Paul Eggert [Wed, 21 Nov 2007 17:37:08 +0000 (18:37 +0100)]
* src/seq.c (print_numbers): Rewrite in an attempt to avoid the
more-general rounding issues exposed by the previous patch.
Jim Meyering [Sun, 18 Nov 2007 20:20:37 +0000 (21:20 +0100)]
* src/c99-to-c89.diff: Adjust seq.c offsets.
Jim Meyering [Sun, 18 Nov 2007 20:19:33 +0000 (21:19 +0100)]
Remove unused parameter in remove.c.
* src/remove.c (fd_to_subdirp): Remove unused parameter.
(remove_cwd_entries, remove_dir): Update callers.
Jim Meyering [Sun, 18 Nov 2007 10:55:45 +0000 (11:55 +0100)]
bootstrap: work also with 4-argument variant of AC_INIT (from gnulib)
2007-11-18 Sergey Poznyakoff <gray@gnu.org.ua>
* bootstrap (gnulib_extra_files): Adjust sed command.
Jim Meyering [Sat, 17 Nov 2007 09:04:07 +0000 (10:04 +0100)]
Correct preceding patch.
* src/seq.c (print_numbers): Also handle first < last && step < 0.
* tests/misc/seq [empty-rev]: New test for this case.
Jim Meyering [Sat, 17 Nov 2007 08:39:42 +0000 (09:39 +0100)]
"seq .1 .1" would mistakenly generate no output on some systems
* NEWS: Say this.
* src/seq.c (print_numbers): Handle another floating point corner case.
This avoids failure of seq's eq-wid-7 test on FreeBSD 6.1.
Paul Eggert [Fri, 16 Nov 2007 23:04:08 +0000 (00:04 +0100)]
Port tests/rmdir/ignore away from GNU/Linux.
* tests/rmdir/ignore: Don't assume that rmdir($PWD) will fail
with errno==ENOTEMPTY when $PWD is not empty; Posix also allows
rmdir to fail with errno==EBUSY.
Jim Meyering [Fri, 16 Nov 2007 10:08:19 +0000 (11:08 +0100)]
Avoid an obscure new "make distcheck" failure.
* Makefile.maint (my-distcheck): Also allow 'mv', for its use
in gnulib-tests/Makefile.
Paul Eggert [Fri, 16 Nov 2007 10:04:31 +0000 (11:04 +0100)]
Port readlink-fp-loop to Solaris.
* tests/misc/readlink-fp-loop (symlink_loop_msg): New var,
which records the symlink-loop message, whose wording is
not standardized by Posix. Do not rely on "echo x > p/1"
to work when p/1 has a lot of indirect symlinks. (I'm surprised
that it works on Linux. Perhaps a Linux bug?)
Jim Meyering [Fri, 16 Nov 2007 10:03:03 +0000 (11:03 +0100)]
Port to Solaris 'make' and use a Posixish shell on Solaris.
* bootstrap.conf (gnulib_modules): Add gnu-make, posix-shell.
* build-aux/check.mk (SHELL): Set to $(PREFERABLY_POSIX_SHELL),
so that commands can assume Posix syntax.
(ENABLE_HARD_ERRORS, TEST_LOGS): Don't use GNU Make's "?=" syntax.
(SH_E_WORKAROUND): New macro.
(am__check_pre, $(TEST_SUITE_LOG)): Use it.
(am__check_pre): Fail if "mkdir" fails. Use $(SHELL)
rather than relying on the "#!/bin/sh" in the file, so that tests
can use Posix syntax.
(am__check_pre, am__tty_colors): Use $$src rather than $$<, to
support the Posix-make $(TEST_LOGS) rule.
(%.log: %.test, %.log: %$(EXEEXT)): Remove unused inference rules
that rely on a GNU Make extension and cause Solaris 'make' to fail.
(SUFFIXES): New macro, so that we can use Posix style inference rules.
(%.log: %): Use this rule only if GNU_MAKE.
Set $$src so that macros can use $$src rather than $$<.
(CHECK-FORCE, DEPENDENCY, $(TEST_LOGS)): New macros and rules,
which rely only on Posix 'make' semantics, and are used only with
non-GNU 'make' implementations. $(TEST_LOGS) invokes 'make'
recursively (and a bit inefficiently) to simulate the GNU 'make'
rules.
(.log.html): Renamed from "%.html: %.log", so that it relies only
on Posix 'make' semantics.
(check-clean, .PHONY): Do not depend on check-clean-local, since
Solaris 'make' complains about nonexistent rules like that.
* src/Makefile.am (SUFFIXES): Remove; no longer needed.
(groups): Use a specific rule rather than an inference rule that
is only instantiated once. The inference-rule approach does not
work with Solaris 'make', which gets confused by the "groups:
Makefile" line. It's not clear from the Posix spec that Solaris
'make' is buggy here, so instead of worrying about it, rewrite
the makefile so that it clearly conforms to Posix.
* tests/check.mk (TESTS_ENVIRONMENT): Export PACKAGE_BUGREPORT.
GNU 'make' does this automatically for us, but Solaris 'make'
doesn't.
2007-11-15 Paul Eggert <eggert@cs.ucla.edu>
Paul Eggert [Fri, 16 Nov 2007 08:35:54 +0000 (09:35 +0100)]
Port to Solaris 8 perl, which does not support "use warnings;".
* tests/dd/skip-seek: Skip test if "use warnings;" fails.
* tests/du/files0-from: Likewise.
* tests/misc/base64: Likewise.
* tests/misc/basename: Likewise.
* tests/misc/cut: Likewise.
* tests/misc/date: Likewise.
* tests/misc/dircolors: Likewise.
* tests/misc/dirname: Likewise.
* tests/misc/expand: Likewise.
* tests/misc/expr: Likewise.
* tests/misc/factor: Likewise.
* tests/misc/fmt: Likewise.
* tests/misc/fold: Likewise.
* tests/misc/head-elide-tail: Likewise.
* tests/misc/ls-misc: Likewise.
* tests/misc/md5sum: Likewise.
* tests/misc/md5sum-newline: Likewise.
* tests/misc/mktemp: Likewise.
* tests/misc/od: Likewise.
* tests/misc/paste-no-nl: Likewise.
* tests/misc/pr: Likewise.
* tests/misc/seq: Likewise.
* tests/misc/sha1sum: Likewise.
* tests/misc/sha1sum-vec: Likewise.
* tests/misc/sha224sum: Likewise.
* tests/misc/sha256sum: Likewise.
* tests/misc/sha384sum: Likewise.
* tests/misc/sha512sum: Likewise.
* tests/misc/sort-merge: Likewise.
* tests/misc/stat-printf: Likewise.
* tests/misc/sum: Likewise.
* tests/misc/test-diag: Likewise.
* tests/misc/tsort: Likewise.
* tests/misc/unexpand: Likewise.
* tests/misc/wc-files0-from: Likewise.
* tests/misc/xstrtol: Likewise.
* tests/mv/i-1: Likewise.
* tests/rm/empty-name: Likewise.
* tests/rm/unreadable: Likewise.
Andreas Schwab [Thu, 15 Nov 2007 13:06:12 +0000 (14:06 +0100)]
* m4/include-exclude-prog.m4 (gl_REMOVE_PROG): Fix syntax error.
Remove trailing space from result.
Jim Meyering [Thu, 15 Nov 2007 12:04:13 +0000 (13:04 +0100)]
Avoid misbehavior of a cross-device "mv" or "install".
Those programs must not dereference a destination symlink.
* src/copy.c (copy_reg): Don't treat a dangling destination symlink
differently in move mode. In move mode, the only way the added
O_EXCL can cause failure is when some other process has recreated
the file this code unlinked a few instructions before.
Jim Meyering [Wed, 14 Nov 2007 22:52:42 +0000 (23:52 +0100)]
Another bootstrap kludge.
* bootstrap: Ensure gnulib-tests/test-*.sh are executable
Jim Meyering [Wed, 14 Nov 2007 22:34:19 +0000 (23:34 +0100)]
src/install.c (setdefaultfilecon): Stub-out the entire function.
Jim Meyering [Wed, 14 Nov 2007 21:36:10 +0000 (22:36 +0100)]
#ifdef-out matchpathcon-related code, for now.
* src/install.c (setdefaultfilecon): #ifdef-out all of the
matchpathcon-related code, until it's more efficient.
Jim Meyering [Wed, 14 Nov 2007 19:37:06 +0000 (20:37 +0100)]
Use gnulib's stpncpy module, now required by install.c
* bootstrap.conf (gnulib_modules): Add stpncpy.
Jim Meyering [Sat, 10 Nov 2007 17:33:07 +0000 (18:33 +0100)]
Enable gnulib-tool's --with-tests option.
* bootstrap: After all is done, transform the generated gnulib-tests/gnulib.mk.
* bootstrap.conf (gnulib_tool_option_extras): Set it here.
* gnulib-tests/Makefile.am: New file.
* Makefile.am (SUBDIRS): Add gnulib-tests.
* configure.ac (AC_CONFIG_FILES): Add gnulib-tests/Makefile.
* m4/jm-macros.m4 (coreutils_MACROS) [ARGMATCH_DIE_DECL]: Omit the
"extern " prefix to "void usage ()", so that the macro string value can
be used to construct a function definition in gnulib's test-argmatch.c.
Benno Schulenberg [Mon, 12 Nov 2007 23:00:53 +0000 (00:00 +0100)]
Likewise for description of cp -a in doc/coreutils.texi: s/-dpPR/-dpR/.
Benno Schulenberg [Mon, 12 Nov 2007 18:13:32 +0000 (19:13 +0100)]
Clarify description of cp's -a option.
* src/cp.c (usage) [-a]: Remove unnecessary 'P'.
Since option -d of 'cp' includes the function of -P, mentioning the
latter in the description of option -a is redundant and therefore
slightly confusing, as the reader tries to figure out what it adds.
Jim Meyering [Sat, 10 Nov 2007 16:36:55 +0000 (17:36 +0100)]
bootstrap: fix typo to enable use of $gnulib_tool_option_extras.
* bootstrap (gnulib_tool_options): Add a space before the use
of $gnulib_tool_option_extras, so that it's separated from the
preceding argument.
Signed-off-by: Jim Meyering <meyering@redhat.com>
Jim Meyering [Sat, 10 Nov 2007 16:31:31 +0000 (17:31 +0100)]
install+SELinux: reduce a 12x performance hit to ~1.5x
* src/install.c (setdefaultfilecon): Call matchpathcon_init_prefix,
to mitigate what would otherwise be a large performance hit due to
the use of matchpathcon.
Dan Walsh suggested the use of matchpathcon_init_prefix.
* gl/lib/se-selinux.in.h (matchpathcon_init_prefix): Define.
Signed-off-by: Jim Meyering <meyering@redhat.com>
Jim Meyering [Thu, 1 Nov 2007 17:35:04 +0000 (18:35 +0100)]
Adapt to gnulib's s/jm_/gl_/ cache variable renaming.
* configure.ac: Change the cache variable name prefix "jm_" to "gl_",
to match today's change in gnulib.
Jim Meyering [Mon, 5 Nov 2007 17:06:38 +0000 (18:06 +0100)]
Fix bootstrap failure to handle files like lib/uniwidth/cjk.h.
* bootstrap (cp_mark_as_generated): Create any required parent
destination directories before copying a file into place.
Jim Meyering [Mon, 5 Nov 2007 13:57:09 +0000 (14:57 +0100)]
* src/c99-to-c89.diff: Adjust offsets.
Jim Meyering [Mon, 5 Nov 2007 11:03:08 +0000 (12:03 +0100)]
Don't use GNU-sed-specific \< \> operators here, either.
* m4/include-exclude-prog.m4 (gl_REMOVE_PROG): Use a loop, as below.
Jim Meyering [Mon, 5 Nov 2007 10:05:55 +0000 (11:05 +0100)]
Use tighter regexps when performing name substitution.
* man/Makefile.am (mapped_name): Add ^ and $$ anchors.
Signed-off-by: Jim Meyering <meyering@redhat.com>
Jim Meyering [Mon, 5 Nov 2007 10:03:55 +0000 (11:03 +0100)]
Don't use GNU-sed-specific \< \> operators.
* configure.ac (MAN): Transform ginstall.1 to install.1 using
a loop, rather than sed with \<...\>.
Problem reported by Bruno Haible.
Andreas Schwab reminded me that \< and \> are not portable.
Jim Meyering [Mon, 5 Nov 2007 07:31:51 +0000 (08:31 +0100)]
Get git-version-gen from gnulib.
* build-aux/git-version-gen: Remove file.
* build-aux/.gitignore: Add git-version-gen.
* bootstrap.conf (gnulib_modules): Add git-version-gen.
Jim Meyering [Sat, 3 Nov 2007 21:52:33 +0000 (22:52 +0100)]
git-version-gen: Sync from autoconf's version.
* build-aux/git-version-gen: Run git-status
Jim Meyering [Sat, 3 Nov 2007 17:04:40 +0000 (18:04 +0100)]
Sync copyright and scriptversion bits from gnulib.
* build-aux/git-version-gen: No semantic change.
Jim Meyering [Sat, 3 Nov 2007 16:46:42 +0000 (17:46 +0100)]
Change the first '-' to '.' in the snapshot version string,
e.g., 6.9-377-08144 -> 6.9.377-08144
* build-aux/git-version-gen: ... and add comments.
Jim Meyering [Sat, 3 Nov 2007 09:10:38 +0000 (10:10 +0100)]
seq: add another test for the %% bug
* tests/misc/seq (fmt-c): Test the other fixed case, too.
Paul Eggert [Sat, 3 Nov 2007 08:10:59 +0000 (01:10 -0700)]
Fix bug with "seq 10.8 0.1 10.95", plus another bug with %% in format.
* NEWS: Mention the %%-in-format bug fix.
* src/seq.c (struct layout): New type.
(long_double_format): New arg LAYOUT. Fill it in. Fix mishandling
of %% in formats.
(print_numbers): New arg LAYOUT. Don't convert LAST to output format
when deciding whether to go slightly past LAST. Instead, convert
X to output format and back. This fixes a bug reported by
Andreas Schwab in
<http://lists.gnu.org/archive/html/bug-coreutils/2007-10/msg00237.html>
where "seq 10.8 0.1 10.95" would output 11.0 on platforms where
10.95 rounds to a value that prints as 11.0 when only one digit
past the decimal point is asked for.
(main): Compute layout, for benefit of print_numbers.
* tests/misc/seq (float-3): Undo previous change, since the bug
should be fixed now.
(fmt-b): New test, for the %% bug.
Jim Meyering [Thu, 1 Nov 2007 22:39:41 +0000 (23:39 +0100)]
tests/misc/printf-surprise: Correct sed transform.
Reported by Bob Proulx.
Jim Meyering [Thu, 1 Nov 2007 21:34:36 +0000 (22:34 +0100)]
Add example inspired by "make dist" running gzip and lzma in sequence.
* doc/coreutils.texi (tee invocation): Show how to run tar just
once, compressing the tee'd output streams in parallel.
Jim Meyering [Thu, 1 Nov 2007 20:25:28 +0000 (21:25 +0100)]
Say that the first process substitution example is contrived.
* doc/coreutils.texi (tee invocation): ... and show how to do
it properly. Pointed out by James Antill.
Jim Meyering [Thu, 1 Nov 2007 17:58:17 +0000 (18:58 +0100)]
Use mktemp, not mkdtemp, to create test directories.
* tests/test-lib.sh: Use the mktemp binary we've just built,
not the mkdtemp script.
* tests/mkdtemp: Remove file.
* tests/Makefile.am (EXTRA_DIST): Remove mkdtemp.
Jim Meyering [Thu, 1 Nov 2007 11:10:06 +0000 (12:10 +0100)]
Adjust a seq subtest not to depend on the vagaries of floating point.
* tests/misc/seq (float-3): Use 10.94 as the endpoint, not 10.95,
since 10.95 was precisely in the middle of the interval, and with
a %.1f format could map to either 10.9 or 11.0.
Reported by Mike Frysinger
Jim Meyering [Thu, 1 Nov 2007 11:06:11 +0000 (12:06 +0100)]
Make the new printf-surprise test more precise.
* tests/test-lib.sh (require_ulimit_): New function.
* tests/misc/printf-surprise: Use ulimit -v to trigger the fixed bug,
and rather than checking printf's exit status (which would go wrong
on FreeBSD 6.1, since their printf(3) function doesn't require
lots of memory in this case) simply test whether it outputs
the first 10 bytes.
Jim Meyering [Thu, 1 Nov 2007 10:59:08 +0000 (11:59 +0100)]
Accommodate FreeBSD 6.1 hard-link-to-symlink differences.
* tests/cp/same-file: Detect when linking to a symlink links to
the target of the symlink (FreeBSD 6.1 does this, Linux does not),
and skip the few tests that would otherwise fail.
Redirect output of final comparison to stderr, since all stdout
is already redirected.
Jim Meyering [Wed, 31 Oct 2007 07:42:17 +0000 (08:42 +0100)]
Fix a "make distcheck" failure.
* Makefile.maint (my-distcheck): Don't stub-out dirname,
since build-aux/check.mk now uses it.
Jim Meyering [Wed, 31 Oct 2007 07:40:51 +0000 (08:40 +0100)]
* bootstrap.conf (gnulib_modules): Add xprintf-posix.
Jim Meyering [Tue, 30 Oct 2007 10:17:59 +0000 (11:17 +0100)]
Avoid seq floating-point test failure on FreeBSD 6.1.
* tests/misc/seq (float-4): Also accept -0.0.
Jim Meyering [Mon, 29 Oct 2007 11:24:39 +0000 (12:24 +0100)]
Change a "make dist" diagnostic.
* GNUmakefile: Don't imply that $(_curr-ver) is the new version string.
Bob Proulx [Mon, 29 Oct 2007 11:10:23 +0000 (05:10 -0600)]
Improve color terminal escape usage.
* build-aux/check.mk (am__tty_colors): Use 'tput' to deduce
terminal color capabilities.
Jim Meyering [Mon, 29 Oct 2007 09:37:09 +0000 (10:37 +0100)]
Don't try to colorize a dumb terminal.
* build-aux/check.mk (am__tty_colors): Skip colors if $TERM is "dumb".
Thanks to Bob Proulx.
Jim Meyering [Mon, 29 Oct 2007 09:14:58 +0000 (10:14 +0100)]
Remove gnulib's printf-posix module, for now.
* bootstrap.conf (gnulib_modules): It caused too many test failures.
Jim Meyering [Mon, 29 Oct 2007 09:01:25 +0000 (10:01 +0100)]
Remove spurious semicolon after "else".
* build-aux/check.mk (am__tty_colors): Fix syntax error.
Jim Meyering [Mon, 29 Oct 2007 08:49:50 +0000 (09:49 +0100)]
Attribute suggestion for last change.
Jim Meyering [Mon, 29 Oct 2007 08:47:52 +0000 (09:47 +0100)]
If $TERM is empty, don't use colors. This helps the buildbot,
since it produces its result in an environment with a tty, but
we don't want color codes in that case.
* build-aux/check.mk (am__tty_colors): Test for nonempty $TERM.
Jim Meyering [Mon, 29 Oct 2007 07:41:08 +0000 (08:41 +0100)]
Always initialize terminal colorization string variables.
* build-aux/check.mk (am__tty_colors): Always initialize red, grn, etc.,
In case they're defined in the environment.
Jim Meyering [Mon, 29 Oct 2007 06:47:21 +0000 (07:47 +0100)]
Avoid test failure in non-srcdir build vs. the git tree.
* tests/check.mk (vc_exe_in_TESTS): Run this test only in a
srcdir build directory. Reported by Andreas Schwab.
Jim Meyering [Sun, 28 Oct 2007 18:04:59 +0000 (19:04 +0100)]
Define ENOTSUP, not ENOSYS. Needed on OpenBSD 3.9.
* gl/lib/se-context.in.h (ENOTSUP): Define if missing.
* gl/lib/se-selinux.in.h: Likewise.
Jim Meyering [Sun, 28 Oct 2007 17:16:54 +0000 (18:16 +0100)]
Define ENODATA, for FreeBSD 5.0 and 6.1.
* src/system.h (ENODATA): Define, if missing.
Jim Meyering [Sun, 28 Oct 2007 14:53:59 +0000 (15:53 +0100)]
Run autoreconf, not just autoconf, to avoid warnings.
* GNUmakefile (dummy): Otherwise, we'd sometimes get a warning
about autoconf version mismatch between what was used to generate
aclocal.m4 and the currently-running autoconf.
Jim Meyering [Sun, 28 Oct 2007 14:38:17 +0000 (15:38 +0100)]
Require gnulib's printf-posix module, to support Interix.
* bootstrap.conf (gnulib_modules): Add printf-posix.
Jim Meyering [Sun, 28 Oct 2007 14:37:56 +0000 (15:37 +0100)]
Help xgettext recognize more printf-style format strings.
* bootstrap.conf (XGETTEXT_OPTIONS): Add directives for
error, error_at_line, xasprintf, xfprintf and xprintf.
Jim Meyering [Sat, 27 Oct 2007 07:42:27 +0000 (09:42 +0200)]
Adjust format string so msgfmt doesn't object.
* src/df.c (main): Use "%s%s" (not %smsg) to print "msg" with or
without a "Warning: " prefix. Reported by Clytie Siddall.
Jim Meyering [Sat, 27 Oct 2007 07:06:11 +0000 (09:06 +0200)]
Clean up tests/Makefile.am.
* tests/Makefile.am (EXTRA_DIST): Remove $(TESTS). No longer defined.
(TESTS_ENVIRONMENT): Remove definition.
Jim Meyering [Sat, 27 Oct 2007 07:04:47 +0000 (09:04 +0200)]
* build-aux/check.mk: Merge with latest from Akim.
Jim Meyering [Fri, 26 Oct 2007 21:59:43 +0000 (23:59 +0200)]
Add a test for the printf fix of 2007-10-21.
* tests/misc/printf-surprise: New file. Test for 2007-10-21's fix.
* tests/misc/Makefile.am (TESTS): Add printf-surprise.
Jim Meyering [Thu, 25 Oct 2007 07:20:44 +0000 (09:20 +0200)]
Add attribution for the expr.c-vs-xgettext report.
Jim Meyering [Thu, 25 Oct 2007 07:06:29 +0000 (09:06 +0200)]
Remove vestiges of cvs-gnulib-checkout process. Now we use git.
* bootstrap: Remove support for now-unnecessary option, --cvs-user,
and envvars CVS_USER, CVS_RSH.
2007-10-24 Micah Cowan <micah@cowan.name>
Micah Cowan [Thu, 25 Oct 2007 06:59:30 +0000 (08:59 +0200)]
Tell xgettext that "ARG1 % ARG2" is not a C format string.
* src/expr.c (usage): Add a comment to override xgettext's default
behavior, which would classify "ARG1 % ARG2" as a fprintf-style
format string.
Jim Meyering [Wed, 24 Oct 2007 20:31:35 +0000 (22:31 +0200)]
Avoid diagnostics from sha1sum when there is no cached checksum.
* bootstrap (update_po_files): Skip the sha1sum check if the po.s1
file hasn't been created yet.
Jim Meyering [Wed, 24 Oct 2007 20:09:57 +0000 (22:09 +0200)]
Get gnulib from the git repository, not from an obsolete cvs one.
* bootstrap: Suggestion from Micah Cowan.
Jim Meyering [Wed, 24 Oct 2007 07:13:59 +0000 (09:13 +0200)]
Doc improvements.
* README-hacking: Prefer the no-hyphen variant of git commands,
e.g., use "git pull" not "git-pull".
Don't presume that the only way to read this document is via a
prior git clone: provide instructions for cloning coreutils, too.
* README-hacking: Add "cd automake" in build instructions.
From Bob Proulx.
Jim Meyering [Wed, 24 Oct 2007 06:50:09 +0000 (08:50 +0200)]
Don't fail part 2 of tests/rm/unreadable when run as root.
* tests/rm/unreadable: With UID == 0, expect different results.
Reported by Mike Frysinger.
Jim Meyering [Tue, 23 Oct 2007 13:44:58 +0000 (15:44 +0200)]
* README-hacking: Refer to LZMA Utils <tukaani.org/lzma/>.
Paul Eggert [Mon, 22 Oct 2007 21:29:40 +0000 (23:29 +0200)]
* README-hacking: Describe how to build with LZMA.
Jim Meyering [Mon, 22 Oct 2007 19:43:12 +0000 (21:43 +0200)]
Remove git-version-gen's first parameter.
* build-aux/git-version-gen: Add comments.
Remove first command-line parameter.
* configure.ac: Remove corresponding first argument.
* GNUmakefile (_curr-ver): Likewise.
Jim Meyering [Sun, 21 Oct 2007 16:19:54 +0000 (18:19 +0200)]
Attribute the printf bug report.
Jim Meyering [Sun, 21 Oct 2007 16:17:30 +0000 (18:17 +0200)]
* NEWS: Mention the printf fix.
Jim Meyering [Sun, 21 Oct 2007 10:44:32 +0000 (12:44 +0200)]
Reorder tests to run more basic ones earlier.
* tests/misc/Makefile.am (TESTS): Reorder.
* tests/Makefile.am (SUBDIRS): Reorder.
Signed-off-by: Jim Meyering <meyering@redhat.com>
Jim Meyering [Sun, 21 Oct 2007 10:38:33 +0000 (12:38 +0200)]
tr: do not reject an unmatched [:lower:] or [:upper:] in SET1.
* NEWS: Mention this.
* src/tr.c (get_next) [RE_CHAR_CLASS]: Don't skip the loop when
processing [:lower:] and [:upper:].
(main): Require [:lower:] or [:upper:] in SET1 only when
when one of those is specified in SET2.
* tests/tr/Test.pm: Add tests for this fix.
Reported by Per Starbäck.
Signed-off-by: Jim Meyering <meyering@redhat.com>
Jim Meyering [Sat, 20 Oct 2007 19:50:43 +0000 (21:50 +0200)]
* tests/misc/help-version: Add a comment.
Signed-off-by: Jim Meyering <meyering@redhat.com>
Jim Meyering [Sat, 20 Oct 2007 12:48:29 +0000 (14:48 +0200)]
Detect printf(3) failure due to ENOMEM.
* src/printf.c: Include "xprintf.h"
(print_direc): Use xprintf, rather than printf.
* bootstrap.conf (gnulib_modules): Add xprintf.
* po/POTFILES.in: Add lib/xprintf.c.
Signed-off-by: Jim Meyering <meyering@redhat.com>
Jim Meyering [Sat, 20 Oct 2007 12:41:50 +0000 (14:41 +0200)]
Put always-failing programs first in PATH, so tests cannot mistakenly run installed versions.
* Makefile.maint (my-distcheck): Set up a bogus bin/ dir, to be used
for "make check".
Signed-off-by: Jim Meyering <meyering@redhat.com>
Jim Meyering [Sat, 20 Oct 2007 11:53:45 +0000 (13:53 +0200)]
* doc/coreutils.texi: Add a cross-reference to bashref's Process Substitution node.
Jim Meyering [Sat, 20 Oct 2007 10:00:54 +0000 (12:00 +0200)]
* doc/coreutils.texi (tee invocation): Fix typo. Add a little.
Jim Meyering [Sat, 20 Oct 2007 08:07:12 +0000 (10:07 +0200)]
Adjust tests to pass, now that Test.pm ones use check.mk.
* tests/check.mk (vc_exe_in_TESTS): Adjust regexp not to match the
"TESTS = $x-tests" line in each Test.pm-derived Makefile.am file.
* tests/sort/main: Remove this unused file.
Jim Meyering [Sat, 20 Oct 2007 07:06:39 +0000 (09:06 +0200)]
Ensure that Test.pm-derived tests use the right $PATH.
* tests/Makefile.am.in: Include $(top_srcdir)/tests/check.mk.
Bob Proulx [Sat, 20 Oct 2007 06:26:57 +0000 (08:26 +0200)]
Prevent "make check" from leaving mktemp /tmp/tmp.* files behind.
* tests/misc/help-version (mktemp_args): Tell mktemp to create
its temporary file in the current directory.
Jim Meyering [Tue, 9 Oct 2007 10:24:14 +0000 (12:24 +0200)]
Show how to make tee redirect to multiple processes.
Jim Meyering [Sun, 14 Oct 2007 19:47:08 +0000 (21:47 +0200)]
Pull all TESTS_ENVIRONMENT settings "up" into tests/check.mk.
* tests/Makefile.am.in (TESTS_ENVIRONMENT): Remove definition.
* tests/chgrp/Makefile.am: Likewise.
* tests/chmod/Makefile.am: Likewise.
* tests/chown/Makefile.am: Likewise.
* tests/cp/Makefile.am: Likewise.
* tests/dd/Makefile.am: Likewise.
* tests/du/Makefile.am: Likewise.
* tests/install/Makefile.am: Likewise.
* tests/ln/Makefile.am: Likewise.
* tests/ls/Makefile.am: Likewise.
* tests/misc/Makefile.am: Likewise.
* tests/mkdir/Makefile.am: Likewise.
* tests/mv/Makefile.am: Likewise.
* tests/readlink/Makefile.am: Likewise.
* tests/rm/Makefile.am: Likewise.
* tests/rmdir/Makefile.am: Likewise.
* tests/tail-2/Makefile.am: Likewise.
* tests/touch/Makefile.am: Likewise.
* tests/check.mk (TESTS_ENVIRONMENT) [EXEEXT, EGREP, MAKE, PERL]:
[CONFIG_HEADER, build_programs, host_os, host_triplet, PATH]:
[REPLACE_GETCWD, CU_TEST_NAME]: Add definitions here.
* tests/misc/pwd-long: Use $abs_top_builddir/src, not $BUILD_SRC_DIR.
* tests/dd/skip-seek: Don't use $ENV{PROG}.
* tests/rm/empty-name: Likewise.
* tests/rm/unreadable: Likewise.
* tests/mv/i-1: Likewise.
Jim Meyering [Sun, 14 Oct 2007 11:35:34 +0000 (13:35 +0200)]
Fix a minor typo.
* configure.ac (AC_INIT): Fix a typo (s/9.6/6.9/) that makes a
difference only when running "make dist" without a .git/ subdir.
Jim Meyering [Tue, 9 Oct 2007 15:12:45 +0000 (17:12 +0200)]
Move the help-version test into misc/.
* tests/help-version: Move to...
* tests/misc/help-version: ...here.
Source test-lib.sh, as usual.
Use $abs_top_builddir, rather than ".." and "../..".
Jim Meyering [Tue, 9 Oct 2007 13:48:51 +0000 (15:48 +0200)]
Make the runcon-no-reorder test slightly more general.
* tests/misc/runcon-no-reorder: Don't hard-code "unconstrained_t".
Use slightly more general "runcon $(id -Z)".
Suggestion from Stephen Smalley.
Jim Meyering [Tue, 9 Oct 2007 07:58:27 +0000 (09:58 +0200)]
Skip the chcon test on a system with no SELinux support.
* tests/test-lib.sh (require_selinux_): New function.
* tests/misc/chcon: Use it.
* tests/misc/selinux: Use it here, too.
* tests/cp/cp-a-selinux: and here.
* tests/selinux: Remove file.
* tests/Makefile.am (EXTRA_DIST): Remove selinux.
Reported by Mike Frysinger and Bauke Jan Douma.