12007-12-31 Jim Meyering <jim@meyering.net> 2 3 * doc/coreutils.texi (Block size): Put braces around multi-digit 4 exponents. Reported by Darrel Francis. 5 6 Add a syntax check, so this doesn't recur. Reorganize existing checks. 7 * doc/Makefile.am (sc-exponent-grouping): 8 (syntax_checks): New variable. 9 (sc-avoid-io, sc-avoid-non-zero, sc-avoid-timezone): 10 (sc-avoid-zeroes, sc-use-small-caps-NUL): New rules, extracted 11 from check-texinfo. 12 (check-texinfo): Depend on $(syntax_checks). 13 142007-12-30 Mike Frysinger <vapier@gentoo.org> 15 16 * src/dircolors.hin (TERM): Add gnome-256color. 17 182007-12-21 Ralf Wildenhues <Ralf.Wildenhues@gmx.de> 19 20 * doc/coreutils.texi: Fix a typo. Avoid the term `relationals'. 21 222007-12-20 Jim Meyering <meyering@redhat.com> 23 24 Use comma-separated list in ./configure --help output. 25 * configure.ac: Map commas to spaces in excluded-program list. 26 Use a comma-separated list, not a space-separated one. 27 * m4/include-exclude-prog.m4 (gl_INCLUDE_EXCLUDE_PROG): 28 Expect list of program names to be comma-separated. 29 Reported by Jan Bauke Douma. 30 31 Avoid another "make check" failure due to omitted programs. 32 * tests/test-lib.sh (require_built_): New function. 33 * tests/misc/groups-version: Use it to skip this test if 34 either groups or id is not built. 35 36 Avoid spurious "make check" failures due to omitted programs. 37 * man/Makefile.am (distcheck-hook): Make check rules dependents of 38 this target, not of check-local, so that people aren't distracted by 39 failures due to programs omitted via --enable-no-install-program=... 40 412007-12-19 Paul Eggert <eggert@cs.ucla.edu> 42 43 * src/uniq.c (usage): Improve wording in --help "Note". 44 452007-12-18 Jim Meyering <meyering@redhat.com> 46 47 * src/uniq.c (usage): Note that sorting uniq's input is often useful. 48 Suggested by Eric Blake. 49 (usage): Say "key-selection", not "field-selection". 50 Quote example commands consistently. 51 522007-12-15 Jim Meyering <meyering@redhat.com> 53 54 Version 6.9.91. 55 56 * Makefile.cfg (gpg_key_ID): Use new, longer signing subkey. 57 582007-12-12 Jim Meyering <meyering@redhat.com> 59 60 * tests/mv/part-symlink: Redirect diff output to stderr. 61 622007-12-11 Jim Meyering <meyering@redhat.com> 63 64 Add a test to exercise today's bug fix. 65 * tests/misc/selinux: Test for today's bug fix. 66 * NEWS: Mention the SELinux "ls -l" fix. 67 682007-12-11 Paul Eggert <eggert@cs.ucla.edu> 69 70 "ls -l" wouldn't output "+" on SELinux hosts unless -Z was also given. 71 * src/ls.c (gobble_file): Also get the file context if -l is specified. 72 Treat getfilecon failures like file_has_acl failures. 73 (UNKNOWN_SECURITY_CONTEXT): New constant. 74 (clear_files): Don't free it. 75 (gobble_file): Set unknown security contexts to it; that way, we 76 don't have to have special cases for unknown contexts. 77 (print_long_format, print_file_name_and_frills): Don't worry 78 about scontext being null, since it's always some string now. 79 802007-12-11 Jim Meyering <meyering@redhat.com> 81 82 * NEWS: Add the "Bug fixes" heading. 83 842007-12-09 Jim Meyering <meyering@redhat.com> 85 86 "rm" as root would fail to unlink a non-directory on OS X 10.4.x 87 * src/remove.c (remove_entry) ["can unlink directories"]: Fix a 88 mistakenly reversed condition. 89 * NEWS: Mention this bug fix. 90 Reported by Pieter Bowman. 91 922007-12-08 Jim Meyering <meyering@redhat.com> 93 94 * src/c99-to-c89.diff: Adjust shred.c offsets. 95 962007-12-04 Jim Meyering <meyering@rho.meyering.net> 97 98 Reflect change in gnulib: don't include getpagesize.h, 99 now that it's provided by unistd.h. 100 * src/cat.c: Don't include getpagesize.h. 101 * src/copy.c: Likewise. 102 * src/dd.c: Likewise. 103 * src/shred.c: Likewise. 104 * src/split.c: Likewise. 105 1062007-12-02 Jim Meyering <meyering@redhat.com> 107 108 Copy a .po file into place also when the target doesn't exist. 109 * bootstrap (gnulib_tool): ... not just when the checksum differs. 110 So now, if I manually remove po/xx.po, rerunning bootstrap will 111 copy the latest into place. 112 113 Make my-distcheck depend on "check". 114 * Makefile.maint (my-distcheck): Also depend on "check", so I can't tag 115 and release something that fails "make check" (however harmless) when 116 run in a checked-out-from-git dir, but not in the distributed tarball. 117 118 * NEWS: Add the usual "Noteworthy changes in release 6.9.91..." line. 119 120 Remove just-installed su, if unable to make it set-UID root. 121 Normally, su isn't even installed. However, if you configure with 122 --enable-install-program=su, and then install with insufficient 123 privileges, we now make sure to remove the just-installed binary. 124 * src/Makefile.am (install-exec-hook): Rename from install-exec-local, 125 so that this rule is guaranteed to be run *after* installation. 126 If unable to chown and chmod the installed "su" program, remove it. 127 Reported by Greg Schaefer. 128 1292007-12-01 Bob Proulx <bob@proulx.com> 130 131 Make existing-perm-race executable. 132 * tests/cp/existing-perm-race: Update file mode. 133 1342007-12-01 Jim Meyering <meyering@redhat.com> 135 136 Version 6.9.90. 137 138 * NEWS: Remove the now-untrue statement about cp vs. dangling symlinks 139 140 Change release procedure: tag *before* running e.g., "make stable". 141 * Makefile.maint (vc-dist): Don't tag. Now, you must apply the tag 142 before running "make beta", "make stable", etc. 143 (vc-tag-check): Remove rule. No longer makes sense. 144 145 * Makefile.maint (vc-tag-check): Correct check for existing git tag. 146 147 Defer NEWS and ChangeLog checks until after the version-changing tag. 148 * Makefile.maint (alpha beta major): Don't depend on the 149 news-date-check changelog-check targets. They must fail before 150 applying the version-changing tag. Instead, run them after "vc-dist". 151 152 * NEWS: Record release date and new version number. 153 Mention some of the SELinux changes. 154 * src/stat.c (main): Adjust a comment. 155 156 * TODO: Add some entries (documentation needed), 157 and remove the one for mktemp. 158 159 Add "extern" keyword to declaration of cp_options_default. 160 * src/copy.c (cp_options_default): Mark as "extern", so the 161 "sc_tight_scope" part of "make distcheck" passes. 162 1632007-12-01 Jim Meyering <meyering@redhat.com> 164 165 Change comments: say bug present up to coreutils-6.9, not fixed in 6.10. 166 * tests/cut/Test.pm: Adjust comment. 167 * tests/misc/cut: Likewise. 168 * tests/misc/ls-misc: Likewise. 169 * tests/misc/od: Likewise. 170 * tests/misc/stty-invalid: Likewise. 171 * tests/tr/Test.pm: Likewise. 172 1732007-11-29 Paul Eggert <eggert@cs.ucla.edu> 174 175 Add a test for cp -p and existing file permissions. 176 * tests/cp/Makefile.am (TESTS): Add existing-perm-race. 177 * tests/cp/existing-perm-race: New test. It isn't much of a 178 test yet, since it's hard to catch the race, but it has a FIXME 179 that will let us do a better test later. 180 1812007-11-28 Paul Eggert <eggert@cs.ucla.edu> 182 183 Fix a security race with "cp -p A B" when B already exists. 184 * src/copy.h (struct cp_options): New member owner_privileges. 185 * src/copy.c (USE_ACL): Define to 0 if not defined, for convenience. 186 (owner_failure_ok): New function. 187 (set_owner): Avoid a security-related race by doing an extra chmod 188 first if it looks like there might be trouble right after a chown. 189 Accept a source struct stat rather than a uid and gid, and 190 accept a boolean NEW_DST and destination struct stat. 191 All callers changed. 192 * src/copy.h (cp_options_default): New function, replacing the 193 old chown_privileges. 194 * src/copy.c (cp_options_default): Likewise. 195 * src/cp.c (cp_option_init): Use it. 196 * src/install.c (cp_option_init): Likewise. 197 * src/mv.c (cp_option_init): Likewise. 198 1992007-11-30 Jim Meyering <meyering@redhat.com> 200 201 Move the very-expensive file into test-lib.sh. 202 * tests/very-expensive: Remove file. 203 * tests/test-lib.sh (very_expensive_): New function. 204 * tests/Makefile.am (EXTRA_DIST): Remove very-expensive. 205 * tests/cp/perm: Call the new function, rather than sourcing the file. 206 * tests/tail-2/assert: Likewise. 207 * tests/tail-2/assert-2: Likewise. 208 * tests/du/2g: Likewise. 209 210 Avoid a spurious test failure when build directory is set-GID. 211 * tests/cp/fail-perm: Ensure that '.'s set-GID bit is off. 212 213 Be extra careful to quote $abs_top_builddir-derived names. 214 * tests/misc/ls-misc (shell_quote): New function. 215 Use it to quote file names derived from $abs_top_builddir, 216 in case it contains shell meta-characters. This is not currently 217 needed, since CuTmpdir detects the fishy name and skips the test. 218 But it's important enough to add the extra protection. 219 Reported by Ralf Wildenhues. 220 221 Include test name in the "unsafe working directory name" diagnostic. 222 * tests/CuTmpdir.pm (import): If $ME is '-', use $prefix. 223 2242007-11-30 Ralf Wildenhues <Ralf.Wildenhues@gmx.de> 225 226 Add quotes to protect against white space in build dir name. 227 * tests/check.mk (TESTS_ENVIRONMENT): Quote $(abs_srcdir). 228 * tests/chmod/setgid: Quote absolute names. 229 * tests/misc/help-version: Likewise. 230 * tests/misc/pwd-unreadable-parent: Likewise. 231 * tests/rmdir/ignore: Likewise. 232 * tests/test-lib.sh: Likewise. 233 234 Define `tst', for CU_TEST_NAME. 235 * build-aux/check.mk (am__check_pre): Set `tst', for 236 CU_TEST_NAME in tests/check.mk. 237 238 * tests/CuTmpdir.pm (END): Do not do the cleanup if $dir is not 239 defined, because it then goes wild and changes the mode of all 240 directories below $HOME. Undefined $dir can happen if the test 241 is to be skipped because of an unsafe working directory name. 242 2432007-11-28 Paul Eggert <eggert@cs.ucla.edu> 244 245 Close a file descriptor leak when cp --preserve=context fails. 246 * src/copy.c (copy_reg): Close dest_desc too, if getfscreatecon 247 or fsetfilecon fail. 248 2492007-11-28 Jim Meyering <meyering@redhat.com> 250 251 * README: Document the known problem with gettext <= 0.17. 252 2532007-11-28 Paul Eggert <eggert@cs.ucla.edu> 254 255 * gl/modules/randread (Depends-on): Remove nonexistent rand-isaac. 256 2572007-11-27 Jim Meyering <meyering@redhat.com> 258 259 Don't block use of 'cat' or 'wc' in "make check". 260 * Makefile.maint (my-distcheck): Add "cat" and "wc" to the list 261 of programs that we can't blacklist. 262 263 Fix md5sum+sha*sum on sparc: regenerate files with latest autoconf. 264 * configure et al: Regenerate with very latest version of autoconf 265 (v2.61a-312-gb524b0f), to fix md5sum and sha*sum miscompilation 266 on big-endian systems (like sparc) due to lack of the required 267 definition in of WORDS_BIGENDIAN in lib/config.h. 268 2692007-11-26 Jim Meyering <meyering@redhat.com> 270 271 setuidgid.c: more cleanup 272 * src/setuidgid.c: Include "mgetgroups.h". 273 (main): Don't presume there's a fixed limit on the maximum number 274 of group IDs. Don't use NGROUPS; it's artificially low. 275 Change the name of a local: s/gids_count/n_gids/. 276 Remove non-portable "const": s/const int tmp =.../int tmp =.../ 277 2782007-11-25 Jim Meyering <meyering@redhat.com> 279 280 Document install's -D option. 281 * doc/coreutils.texi (install invocation): Document -D. 282 Reported by Akim Demialle. 283 284 setuidgid: Update --help output. 285 * src/setuidgid.c (usage): Describe -g GID[,GID1...] option. 286 Mention that USER may be a numeric ID or a user name. 287 2882007-11-24 Jim Meyering <meyering@redhat.com> 289 290 Tweak new test. 291 * tests/cp/preserve-gid: Split some long lines. 292 Prepend "+" to numeric uid and gid chown arguments, on principle. 293 Use skip_test_. 294 295 setuidgid: minor clean-up. 296 * setuidgid.c: Include "xstrtoul.h". 297 (main): Detect overflow in string-to-gid_t and -to-uid_t conversions. 298 Improve diagnostics. 299 300 * src/setuidgid.c: Normalize leading white space: no more TABs. 301 302 Test the new feature: cp -p preserves the GID whenever possible. 303 * tests/cp/preserve-gid: New file. Test for today's change. 304 * tests/cp/Makefile.am (TESTS): Add preserve-gid. 305 * tests/Makefile.am (all_t): Add tc. 306 (tc): New target. 307 308 setuidgid: accept numeric UID, and new option -g GID,GID1,GID2,... 309 * src/setuidgid.c: Add functionality for the new test above. 310 311 "cp -p" tries to preserve GID even if preserving the UID fails. 312 * NEWS: Mention this new feature. 313 * src/copy.c (set_owner): Try to preserve just the GID, 314 when initial fchown/lchown fails. 315 * src/cp.c (re_protect): Likewise. 316 3172007-11-23 Jim Meyering <meyering@redhat.com> 318 319 * src/runcon.c (main): Remove unused parameter, "envp". 320 321 Add tests to show new class of strings accepted by date -d. 322 * tests/misc/date (rel-1day, rel-plus1): New tests for the recent 323 change in gnulib's getdate.y. 324 * NEWS: Mention the fix. 325 3262007-11-22 Jim Meyering <meyering@redhat.com> 327 328 Quiet warnings about unused parameters. 329 * src/copy.c (set_author) [!HAVE_STRUCT_STAT_ST_AUTHOR]: 330 "Use" each of the parameters. 331 332 * GNUmakefile: Correct the "rerunning..." diagnostic. 333 334 Make it easier to diagnose PATH-induced "make distcheck" failures. 335 * Makefile.maint (write_loser): Define. 336 (my-distcheck): Use an always-failing wrapper script, that gives 337 a diagnostic, not "false". 338 Run only "make -C tests check" with the restrictive PATH. 339 Run the new gnulib-tests/ with the usual PATH. 340 341 cp: by default, refuse to copy through a dangling destination symlink 342 * NEWS: Mention this change. 343 * doc/coreutils.texi (cp invocation): Describe the new behavior. 344 * src/copy.c: No longer include "canonicalize.h". 345 (copy_reg): Upon failure to open a dangling destination symlink, 346 don't canonicalize the name, but rather fail (default) or, with 347 POSIXLY_CORRECT, repeat the open call without O_EXCL (potentially 348 dangerous). 349 * src/copy.h (struct cp_options) [open_dangling_dest_symlink]: 350 New member. Reorder the others, grouping "bool" and "enum" 351 members together. 352 * tests/cp/thru-dangling: Test for changed and new behavior. 353 * src/cp.c (cp_option_init): Initialize new member. 354 * src/install.c (cp_option_init): Likewise. 355 * src/mv.c (cp_option_init): Likewise. 356 3572007-11-21 P��draig Brady <P@draigBrady.com> 358 359 * doc/coreutils.texi (split invocation): Improve the 360 descriptions of the split command options. 361 3622007-11-21 Jim Meyering <meyering@redhat.com> 363 364 * src/c99-to-c89.diff: Adjust seq.c offsets. 365 3662007-11-18 Paul Eggert <eggert@cs.ucla.edu> 367 368 * src/seq.c (print_numbers): Rewrite in an attempt to avoid the 369 more-general rounding issues exposed by the previous patch. 370 3712007-11-18 Jim Meyering <meyering@redhat.com> 372 373 * src/c99-to-c89.diff: Adjust seq.c offsets. 374 375 Remove unused parameter in remove.c. 376 * src/remove.c (fd_to_subdirp): Remove unused parameter. 377 (remove_cwd_entries, remove_dir): Update callers. 378 379 bootstrap: work also with 4-argument variant of AC_INIT (from gnulib) 380 2007-11-18 Sergey Poznyakoff <gray@gnu.org.ua> 381 * bootstrap (gnulib_extra_files): Adjust sed command. 382 3832007-11-17 Jim Meyering <meyering@redhat.com> 384 385 Correct preceding patch. 386 * src/seq.c (print_numbers): Also handle first < last && step < 0. 387 * tests/misc/seq [empty-rev]: New test for this case. 388 389 "seq .1 .1" would mistakenly generate no output on some systems 390 * NEWS: Say this. 391 * src/seq.c (print_numbers): Handle another floating point corner case. 392 This avoids failure of seq's eq-wid-7 test on FreeBSD 6.1. 393 3942007-11-16 Paul Eggert <eggert@cs.ucla.edu> 395 396 Port tests/rmdir/ignore away from GNU/Linux. 397 * tests/rmdir/ignore: Don't assume that rmdir($PWD) will fail 398 with errno==ENOTEMPTY when $PWD is not empty; Posix also allows 399 rmdir to fail with errno==EBUSY. 400 4012007-11-16 Jim Meyering <meyering@redhat.com> 402 403 Avoid an obscure new "make distcheck" failure. 404 * Makefile.maint (my-distcheck): Also allow 'mv', for its use 405 in gnulib-tests/Makefile. 406 4072007-11-16 Paul Eggert <eggert@cs.ucla.edu> 408 409 Port readlink-fp-loop to Solaris. 410 * tests/misc/readlink-fp-loop (symlink_loop_msg): New var, 411 which records the symlink-loop message, whose wording is 412 not standardized by Posix. Do not rely on "echo x > p/1" 413 to work when p/1 has a lot of indirect symlinks. (I'm surprised 414 that it works on Linux. Perhaps a Linux bug?) 415 4162007-11-15 Paul Eggert <eggert@cs.ucla.edu> 417 418 Port to Solaris 'make' and use a Posixish shell on Solaris. 419 * bootstrap.conf (gnulib_modules): Add gnu-make, posix-shell. 420 * build-aux/check.mk (SHELL): Set to $(PREFERABLY_POSIX_SHELL), 421 so that commands can assume Posix syntax. 422 (ENABLE_HARD_ERRORS, TEST_LOGS): Don't use GNU Make's "?=" syntax. 423 (SH_E_WORKAROUND): New macro. 424 (am__check_pre, $(TEST_SUITE_LOG)): Use it. 425 (am__check_pre): Fail if "mkdir" fails. Use $(SHELL) 426 rather than relying on the "#!/bin/sh" in the file, so that tests 427 can use Posix syntax. 428 (am__check_pre, am__tty_colors): Use $$src rather than $$<, to 429 support the Posix-make $(TEST_LOGS) rule. 430 (%.log: %.test, %.log: %$(EXEEXT)): Remove unused inference rules 431 that rely on a GNU Make extension and cause Solaris 'make' to fail. 432 (SUFFIXES): New macro, so that we can use Posix style inference rules. 433 (%.log: %): Use this rule only if GNU_MAKE. 434 Set $$src so that macros can use $$src rather than $$<. 435 (CHECK-FORCE, DEPENDENCY, $(TEST_LOGS)): New macros and rules, 436 which rely only on Posix 'make' semantics, and are used only with 437 non-GNU 'make' implementations. $(TEST_LOGS) invokes 'make' 438 recursively (and a bit inefficiently) to simulate the GNU 'make' 439 rules. 440 (.log.html): Renamed from "%.html: %.log", so that it relies only 441 on Posix 'make' semantics. 442 (check-clean, .PHONY): Do not depend on check-clean-local, since 443 Solaris 'make' complains about nonexistent rules like that. 444 * src/Makefile.am (SUFFIXES): Remove; no longer needed. 445 (groups): Use a specific rule rather than an inference rule that 446 is only instantiated once. The inference-rule approach does not 447 work with Solaris 'make', which gets confused by the "groups: 448 Makefile" line. It's not clear from the Posix spec that Solaris 449 'make' is buggy here, so instead of worrying about it, rewrite 450 the makefile so that it clearly conforms to Posix. 451 * tests/check.mk (TESTS_ENVIRONMENT): Export PACKAGE_BUGREPORT. 452 GNU 'make' does this automatically for us, but Solaris 'make' 453 doesn't. 454 4552007-11-15 Paul Eggert <eggert@cs.ucla.edu> 456 457 Port to Solaris 8 perl, which does not support "use warnings;". 458 * tests/dd/skip-seek: Skip test if "use warnings;" fails. 459 * tests/du/files0-from: Likewise. 460 * tests/misc/base64: Likewise. 461 * tests/misc/basename: Likewise. 462 * tests/misc/cut: Likewise. 463 * tests/misc/date: Likewise. 464 * tests/misc/dircolors: Likewise. 465 * tests/misc/dirname: Likewise. 466 * tests/misc/expand: Likewise. 467 * tests/misc/expr: Likewise. 468 * tests/misc/factor: Likewise. 469 * tests/misc/fmt: Likewise. 470 * tests/misc/fold: Likewise. 471 * tests/misc/head-elide-tail: Likewise. 472 * tests/misc/ls-misc: Likewise. 473 * tests/misc/md5sum: Likewise. 474 * tests/misc/md5sum-newline: Likewise. 475 * tests/misc/mktemp: Likewise. 476 * tests/misc/od: Likewise. 477 * tests/misc/paste-no-nl: Likewise. 478 * tests/misc/pr: Likewise. 479 * tests/misc/seq: Likewise. 480 * tests/misc/sha1sum: Likewise. 481 * tests/misc/sha1sum-vec: Likewise. 482 * tests/misc/sha224sum: Likewise. 483 * tests/misc/sha256sum: Likewise. 484 * tests/misc/sha384sum: Likewise. 485 * tests/misc/sha512sum: Likewise. 486 * tests/misc/sort-merge: Likewise. 487 * tests/misc/stat-printf: Likewise. 488 * tests/misc/sum: Likewise. 489 * tests/misc/test-diag: Likewise. 490 * tests/misc/tsort: Likewise. 491 * tests/misc/unexpand: Likewise. 492 * tests/misc/wc-files0-from: Likewise. 493 * tests/misc/xstrtol: Likewise. 494 * tests/mv/i-1: Likewise. 495 * tests/rm/empty-name: Likewise. 496 * tests/rm/unreadable: Likewise. 497 4982007-11-15 Andreas Schwab <schwab@suse.de> 499 500 * m4/include-exclude-prog.m4 (gl_REMOVE_PROG): Fix syntax error. 501 Remove trailing space from result. 502 5032007-11-15 Jim Meyering <meyering@redhat.com> 504 505 Avoid misbehavior of a cross-device "mv" or "install". 506 Those programs must not dereference a destination symlink. 507 * src/copy.c (copy_reg): Don't treat a dangling destination symlink 508 differently in move mode. In move mode, the only way the added 509 O_EXCL can cause failure is when some other process has recreated 510 the file this code unlinked a few instructions before. 511 5122007-11-14 Jim Meyering <meyering@redhat.com> 513 514 Another bootstrap kludge. 515 * bootstrap: Ensure gnulib-tests/test-*.sh are executable 516 517 #ifdef-out matchpathcon-related code, for now. 518 * src/install.c (setdefaultfilecon): #ifdef-out all of the 519 matchpathcon-related code, until it's more efficient. 520 (setdefaultfilecon): Instead of the above, stub-out the entire function. 521 522 Use gnulib's stpncpy module, now required by install.c 523 * bootstrap.conf (gnulib_modules): Add stpncpy. 524 525 Enable gnulib-tool's --with-tests option. 526 * bootstrap: After all is done, transform the generated 527 gnulib-tests/gnulib.mk. 528 * bootstrap.conf (gnulib_tool_option_extras): Set it here. 529 * gnulib-tests/Makefile.am: New file. 530 * Makefile.am (SUBDIRS): Add gnulib-tests. 531 * configure.ac (AC_CONFIG_FILES): Add gnulib-tests/Makefile. 532 * m4/jm-macros.m4 (coreutils_MACROS) [ARGMATCH_DIE_DECL]: Omit the 533 "extern " prefix to "void usage ()", so that the macro string value can 534 be used to construct a function definition in gnulib's test-argmatch.c. 535 5362007-11-12 Benno Schulenberg <bensberg@justemail.net> 537 538 Clarify description of cp's -a option. 539 * src/cp.c (usage) [-a]: Remove unnecessary 'P'. 540 Since option -d of 'cp' includes the function of -P, mentioning the 541 latter in the description of option -a is redundant and therefore 542 slightly confusing, as the reader tries to figure out what it adds. 543 * doc/coreutils.texi (cp invocation): Likewise: s/-dpPR/-dpR/. 544 5452007-11-09 Jim Meyering <meyering@redhat.com> 546 547 bootstrap: fix typo to enable use of $gnulib_tool_option_extras. 548 * bootstrap (gnulib_tool_options): Add a space before the use 549 of $gnulib_tool_option_extras, so that it's separated from the 550 preceding argument. 551 552 install+SELinux: reduce a 12x performance hit to ~1.5x 553 * src/install.c (setdefaultfilecon): Call matchpathcon_init_prefix, 554 to mitigate what would otherwise be a large performance hit due to 555 the use of matchpathcon. 556 Dan Walsh suggested the use of matchpathcon_init_prefix. 557 * gl/lib/se-selinux.in.h (matchpathcon_init_prefix): Define. 558 5592007-11-08 Jim Meyering <meyering@redhat.com> 560 561 Adapt to gnulib's s/jm_/gl_/ cache variable renaming. 562 * configure.ac: Change the cache variable name prefix "jm_" to "gl_", 563 to match today's change in gnulib. 564 5652007-11-05 Jim Meyering <meyering@redhat.com> 566 567 Fix bootstrap failure to handle files like lib/uniwidth/cjk.h. 568 * bootstrap (cp_mark_as_generated): Create any required parent 569 destination directories before copying a file into place. 570 571 * src/c99-to-c89.diff: Adjust offsets. 572 573 Don't use GNU-sed-specific \< \> operators here, either. 574 * m4/include-exclude-prog.m4 (gl_REMOVE_PROG): Use a loop, as below. 575 576 Use tighter regexps when performing name substitution. 577 * man/Makefile.am (mapped_name): Add ^ and $$ anchors. 578 579 Don't use GNU-sed-specific \< \> operators. 580 * configure.ac (MAN): Transform ginstall.1 to install.1 using 581 a loop, rather than sed with \<...\>. 582 Problem reported by Bruno Haible. 583 Andreas Schwab reminded me that \< and \> are not portable. 584 585 Get git-version-gen from gnulib. 586 * build-aux/git-version-gen: Remove file. 587 * build-aux/.gitignore: Add git-version-gen. 588 * bootstrap.conf (gnulib_modules): Add git-version-gen. 589 5902007-11-03 Jim Meyering <meyering@redhat.com> 591 592 git-version-gen: Sync from autoconf's version. 593 * build-aux/git-version-gen: Run git-status 594 595 Sync copyright and scriptversion bits from gnulib. 596 * build-aux/git-version-gen: No semantic change. 597 598 Change the first '-' to '.' in the snapshot version string, 599 e.g., 6.9-377-08144 -> 6.9.377-08144 600 * build-aux/git-version-gen: ... and add comments. 601 602 seq: add another test for the %% bug. 603 * tests/misc/seq (fmt-c): Test the other fixed case, too. 604 6052007-11-03 Paul Eggert <eggert@cs.ucla.edu> 606 607 Fix bug with "seq 10.8 0.1 10.95", plus another bug with %% in format. 608 609 * NEWS: Mention the %%-in-format bug fix. 610 * src/seq.c (struct layout): New type. 611 (long_double_format): New arg LAYOUT. Fill it in. Fix mishandling 612 of %% in formats. 613 (print_numbers): New arg LAYOUT. Don't convert LAST to output format 614 when deciding whether to go slightly past LAST. Instead, convert 615 X to output format and back. This fixes a bug reported by 616 Andreas Schwab in 617 <http://lists.gnu.org/archive/html/bug-coreutils/2007-10/msg00237.html> 618 where "seq 10.8 0.1 10.95" would output 11.0 on platforms where 619 10.95 rounds to a value that prints as 11.0 when only one digit 620 past the decimal point is asked for. 621 (main): Compute layout, for benefit of print_numbers. 622 * tests/misc/seq (float-3): Undo previous change, since the bug 623 should be fixed now. 624 (fmt-b): New test, for the %% bug. 625 6262007-11-01 Jim Meyering <meyering@redhat.com> 627 628 * tests/misc/printf-surprise: Correct sed transform. 629 Reported by Bob Proulx. 630 631 Add example inspired by "make dist" running gzip and lzma in sequence. 632 * doc/coreutils.texi (tee invocation): Show how to run tar just 633 once, compressing the tee'd output streams in parallel. 634 635 Say that the first process substitution example is contrived. 636 * doc/coreutils.texi (tee invocation): ... and show how to do 637 it properly. Pointed out by James Antill. 638 639 Use mktemp, not mkdtemp, to create test directories. 640 * tests/test-lib.sh: Use the mktemp binary we've just built, 641 not the mkdtemp script. 642 * tests/mkdtemp: Remove file. 643 * tests/Makefile.am (EXTRA_DIST): Remove mkdtemp. 644 645 Adjust a seq subtest not to depend on the vagaries of floating point. 646 * tests/misc/seq (float-3): Use 10.94 as the endpoint, not 10.95, 647 since 10.95 was precisely in the middle of the interval, and with 648 a %.1f format could map to either 10.9 or 11.0. 649 Reported by Mike Frysinger 650 651 Make the new printf-surprise test more precise. 652 * tests/test-lib.sh (require_ulimit_): New function. 653 * tests/misc/printf-surprise: Use ulimit -v to trigger the fixed bug, 654 and rather than checking printf's exit status (which would go wrong 655 on FreeBSD 6.1, since their printf(3) function doesn't require 656 lots of memory in this case) simply test whether it outputs 657 the first 10 bytes. 658 659 Accommodate FreeBSD 6.1 hard-link-to-symlink differences. 660 * tests/cp/same-file: Detect when linking to a symlink links to 661 the target of the symlink (FreeBSD 6.1 does this, Linux does not), 662 and skip the few tests that would otherwise fail. 663 Redirect output of final comparison to stderr, since all stdout 664 is already redirected. 665 6662007-10-31 Jim Meyering <meyering@redhat.com> 667 668 Fix a "make distcheck" failure. 669 * Makefile.maint (my-distcheck): Don't stub-out dirname, 670 since build-aux/check.mk now uses it. 671 672 * bootstrap.conf (gnulib_modules): Add xprintf-posix. 673 6742007-10-30 Jim Meyering <meyering@redhat.com> 675 676 Avoid seq floating-point test failure on FreeBSD 6.1. 677 * tests/misc/seq (float-4): Also accept -0.0. 678 6792007-10-29 Jim Meyering <meyering@redhat.com> 680 681 Change a "make dist" diagnostic. 682 * GNUmakefile: Don't imply that $(_curr-ver) is the new version string. 683 6842007-10-29 Bob Proulx <bob@proulx.com> 685 686 Improve color terminal escape usage. 687 * build-aux/check.mk (am__tty_colors): Use 'tput' to deduce 688 terminal color capabilities. 689 6902007-10-29 Jim Meyering <meyering@redhat.com> 691 692 Don't try to colorize a dumb terminal. 693 * build-aux/check.mk (am__tty_colors): Skip colors if $TERM is "dumb". 694 Thanks to Bob Proulx. 695 696 Remove gnulib's printf-posix module, for now. 697 * bootstrap.conf (gnulib_modules): It caused too many test failures. 698 699 Remove spurious semicolon after "else". 700 * build-aux/check.mk (am__tty_colors): Fix syntax error. 701 702 If $TERM is empty, don't use colors. This helps the buildbot, 703 since it produces its result in an environment with a tty, but 704 we don't want color codes in that case. 705 * build-aux/check.mk (am__tty_colors): Test for nonempty $TERM. 706 Suggestion from Bob Proulx. 707 708 Always initialize terminal colorization string variables. 709 * build-aux/check.mk (am__tty_colors): Always initialize red, grn, etc., 710 In case they're defined in the environment. 711 712 Avoid test failure in non-srcdir build vs. the git tree. 713 * tests/check.mk (vc_exe_in_TESTS): Run this test only in a 714 srcdir build directory. Reported by Andreas Schwab. 715 7162007-10-28 Jim Meyering <meyering@redhat.com> 717 718 Define ENOTSUP, not ENOSYS. Needed on OpenBSD 3.9. 719 * gl/lib/se-context.in.h (ENOTSUP): Define if missing. 720 * gl/lib/se-selinux.in.h: Likewise. 721 722 Define ENODATA, for FreeBSD 5.0 and 6.1. 723 * src/system.h (ENODATA): Define, if missing. 724 725 Run autoreconf, not just autoconf, to avoid warnings. 726 * GNUmakefile (dummy): Otherwise, we'd sometimes get a warning 727 about autoconf version mismatch between what was used to generate 728 aclocal.m4 and the currently-running autoconf. 729 730 Require gnulib's printf-posix module, to support Interix. 731 * bootstrap.conf (gnulib_modules): Add printf-posix. 732 733 Help xgettext recognize more printf-style format strings. 734 * bootstrap.conf (XGETTEXT_OPTIONS): Add directives for 735 error, error_at_line, xasprintf, xfprintf and xprintf. 736 7372007-10-27 Jim Meyering <meyering@redhat.com> 738 739 Adjust format string so msgfmt doesn't object. 740 * src/df.c (main): Use "%s%s" (not %smsg) to print "msg" with or 741 without a "Warning: " prefix. Reported by Clytie Siddall. 742 743 Clean up tests/Makefile.am. 744 * tests/Makefile.am (EXTRA_DIST): Remove $(TESTS). No longer defined. 745 (TESTS_ENVIRONMENT): Remove definition. 746 7472007-10-26 Jim Meyering <meyering@redhat.com> 748 749 * build-aux/check.mk: Merge with latest from Akim. 750 751 Add a test for the printf fix of 2007-10-21. 752 * tests/misc/printf-surprise: New file. Test for 2007-10-21's fix. 753 * tests/misc/Makefile.am (TESTS): Add printf-surprise. 754 7552007-10-24 Micah Cowan <micah@cowan.name> 756 757 Remove vestiges of cvs-gnulib-checkout process. Now we use git. 758 * bootstrap: Remove support for now-unnecessary option, --cvs-user, 759 and envvars CVS_USER, CVS_RSH. 760 7612007-10-24 Micah Cowan <micah@cowan.name> 762 763 Tell xgettext that "ARG1 % ARG2" is not a C format string. 764 * src/expr.c (usage): Add a comment to override xgettext's default 765 behavior, which would classify "ARG1 % ARG2" as a fprintf-style 766 format string. Reported by Clytie Siddall. 767 7682007-10-24 Jim Meyering <meyering@redhat.com> 769 770 Avoid diagnostics from sha1sum when there is no cached checksum. 771 * bootstrap (update_po_files): Skip the sha1sum check if the po.s1 772 file hasn't been created yet. 773 774 Get gnulib from the git repository, not from an obsolete cvs one. 775 * bootstrap: Suggestion from Micah Cowan. 776 777 Doc improvements. 778 * README-hacking: Prefer the no-hyphen variant of git commands, 779 e.g., use "git pull" not "git-pull". 780 Don't presume that the only way to read this document is via a 781 prior git clone: provide instructions for cloning coreutils, too. 782 783 * README-hacking: Add "cd automake" in build instructions. 784 From Bob Proulx. 785 786 Don't fail part 2 of tests/rm/unreadable when run as root. 787 * tests/rm/unreadable: With UID == 0, expect different results. 788 Reported by Mike Frysinger. 789 7902007-10-23 Jim Meyering <meyering@redhat.com> 791 792 * README-hacking: Refer to LZMA Utils <http://tukaani.org/lzma/>. 793 7942007-10-22 Paul Eggert <eggert@cs.ucla.edu> 795 796 * README-hacking: Describe how to build with LZMA. 797 7982007-10-22 Jim Meyering <meyering@redhat.com> 799 800 Remove git-version-gen's first parameter. 801 * build-aux/git-version-gen: Add comments. 802 Remove first command-line parameter. 803 * configure.ac: Remove corresponding first argument. 804 * GNUmakefile (_curr-ver): Likewise. 805 8062007-10-21 Jim Meyering <meyering@redhat.com> 807 808 * NEWS: Mention the printf fix. 809 810 Reorder tests to run more basic ones earlier. 811 * tests/misc/Makefile.am (TESTS): Reorder. 812 * tests/Makefile.am (SUBDIRS): Reorder. 813 814 tr: do not reject an unmatched [:lower:] or [:upper:] in SET1. 815 * NEWS: Mention this. 816 * src/tr.c (get_next) [RE_CHAR_CLASS]: Don't skip the loop when 817 processing [:lower:] and [:upper:]. 818 (main): Require [:lower:] or [:upper:] in SET1 only when 819 when one of those is specified in SET2. 820 * tests/tr/Test.pm: Add tests for this fix. 821 Reported by Per Starb��ck. 822 8232007-10-20 Jim Meyering <meyering@redhat.com> 824 825 * tests/misc/help-version: Add a comment. 826 827 Detect printf(3) failure due to ENOMEM. 828 * src/printf.c: Include "xprintf.h" 829 (print_direc): Use xprintf, rather than printf. 830 * bootstrap.conf (gnulib_modules): Add xprintf. 831 * po/POTFILES.in: Add lib/xprintf.c. 832 Reported by Bruno Haible. 833 834 Put always-failing programs first in PATH, so tests cannot mistakenly 835 run installed versions. 836 * Makefile.maint (my-distcheck): Set up a bogus bin/ dir, to be used 837 for "make check". 838 839 * doc/coreutils.texi (tee invocation): Fix typo. Add a little. 840 Add a cross-reference to bashref's Process Substitution node. 841 842 Adjust tests to pass, now that Test.pm ones use check.mk. 843 * tests/check.mk (vc_exe_in_TESTS): Adjust regexp not to match the 844 "TESTS = $x-tests" line in each Test.pm-derived Makefile.am file. 845 * tests/sort/main: Remove this unused file. 846 847 Ensure that Test.pm-derived tests use the right $PATH. 848 * tests/Makefile.am.in: Include $(top_srcdir)/tests/check.mk. 849 8502007-10-20 Bob Proulx <bob@proulx.com> 851 852 Prevent "make check" from leaving mktemp /tmp/tmp.* files behind. 853 * tests/misc/help-version (mktemp_args): Tell mktemp to create 854 its temporary file in the current directory. 855 8562007-10-16 Jim Meyering <meyering@redhat.com> 857 858 Show how to make tee redirect to multiple processes. 859 * doc/coreutils.texi (tee invocation): Tee can redirect output 860 to multiple _processes_, too. 861 8622007-10-14 Jim Meyering <meyering@redhat.com> 863 864 Pull all TESTS_ENVIRONMENT settings "up" into tests/check.mk. 865 * tests/Makefile.am.in (TESTS_ENVIRONMENT): Remove definition. 866 * tests/chgrp/Makefile.am: Likewise. 867 * tests/chmod/Makefile.am: Likewise. 868 * tests/chown/Makefile.am: Likewise. 869 * tests/cp/Makefile.am: Likewise. 870 * tests/dd/Makefile.am: Likewise. 871 * tests/du/Makefile.am: Likewise. 872 * tests/install/Makefile.am: Likewise. 873 * tests/ln/Makefile.am: Likewise. 874 * tests/ls/Makefile.am: Likewise. 875 * tests/misc/Makefile.am: Likewise. 876 * tests/mkdir/Makefile.am: Likewise. 877 * tests/mv/Makefile.am: Likewise. 878 * tests/readlink/Makefile.am: Likewise. 879 * tests/rm/Makefile.am: Likewise. 880 * tests/rmdir/Makefile.am: Likewise. 881 * tests/tail-2/Makefile.am: Likewise. 882 * tests/touch/Makefile.am: Likewise. 883 * tests/check.mk (TESTS_ENVIRONMENT) [EXEEXT, EGREP, MAKE, PERL]: 884 [CONFIG_HEADER, build_programs, host_os, host_triplet, PATH]: 885 [REPLACE_GETCWD, CU_TEST_NAME]: Add definitions here. 886 * tests/misc/pwd-long: Use $abs_top_builddir/src, not $BUILD_SRC_DIR. 887 * tests/dd/skip-seek: Don't use $ENV{PROG}. 888 * tests/rm/empty-name: Likewise. 889 * tests/rm/unreadable: Likewise. 890 * tests/mv/i-1: Likewise. 891 892 Fix a minor typo. 893 * configure.ac (AC_INIT): Fix a typo (s/9.6/6.9/) that makes a 894 difference only when running "make dist" without a .git/ subdir. 895 8962007-10-09 Jim Meyering <meyering@redhat.com> 897 898 Move the help-version test into misc/. 899 * tests/help-version: Move to... 900 * tests/misc/help-version: ...here. 901 Source test-lib.sh, as usual. 902 Use $abs_top_builddir, rather than ".." and "../..". 903 904 Make the runcon-no-reorder test slightly more general. 905 * tests/misc/runcon-no-reorder: Don't hard-code "unconstrained_t". 906 Use slightly more general "runcon $(id -Z)". 907 Suggestion from Stephen Smalley. 908 909 Skip the chcon test on a system with no SELinux support. 910 * tests/test-lib.sh (require_selinux_): New function. 911 * tests/misc/chcon: Use it. 912 * tests/misc/selinux: Use it here, too. 913 * tests/cp/cp-a-selinux: and here. 914 * tests/selinux: Remove file. 915 * tests/Makefile.am (EXTRA_DIST): Remove selinux. 916 Reported by Mike Frysinger and Bauke Jan Douma. 917 918 * src/dircolors.hin: Recognize .lzma as a compressed-file suffix. 919 920 * configure.ac (AM_INIT_AUTOMAKE): Use dist-lzma, rather than dist-bzip2. 921 922 Now that we don't install su, don't make misleading suggestions. 923 * src/Makefile.am (install-exec-local) [$(INSTALL_SU) != yes]: 924 Don't suggest running "make install-root". 925 (uninstall-local) [$(INSTALL_SU) != yes]: Don't even check 926 the installed binary. 927 9282007-10-08 Jim Meyering <meyering@redhat.com> 929 930 When forming a truncated name, use the "[...]" prefix even for 931 an extremely long name in the current directory 932 * src/remove.c (full_filename_): Rename a local variable. 933 Use two separate "truncated" variables, in case the second 934 call to right_justify does not indicate any truncation -- which 935 would happen only if the single component FILENAME were longer 936 than 511 bytes and DIR_NAME were empty. 937 938 rm could malfunction under unusual circumstances: 939 When operating on a relative name longer than 511 bytes, 940 and (when either processing a directory that is neither writable 941 nor readable (but still searchable) or when determining whether 942 to prompt), and encountering an ENOMEM error while forming the 943 file name, rm would operate on a truncated-to-511-byte name 944 starting with "[...]" rather than the intended one. 945 * NEWS: Describe the bugs. 946 * src/remove.c: Correct two misuses of full_filename: 947 (full_filename0, xfull_filename): New functions. 948 (full_filename_): Rewrite to use full_filename0. 949 (AD_pop_and_chdir): Use xfull_filename, not full_filename. 950 (write_protected_non_symlink): Likewise. 951 9522007-10-07 Jim Meyering <meyering@redhat.com> 953 954 Don't let a helper function modify errno. 955 * src/remove.c (full_filename_): Save and restore errno. 956 Spotted by Bruno Haible. 957 958 Reflect 2->3 GPL copyright version update in gnulib. 959 * gl/lib/tempname.h: Update copyright from gnulib. 960 * gl/lib/tempname.c: Likewise. 961 * .x-sc_GPL_version: Don't make an exception for those two files. 962 963 * configure.ac (AM_INIT_AUTOMAKE): Don't use dist-lzma just yet. 964 965 New program: mktemp. 966 * NEWS: Mention this. 967 * README: Add mktemp to the list. 968 * AUTHORS: Add this: mktemp: Jim Meyering 969 * src/mktemp.c: New file. 970 * src/Makefile.am (bin_PROGRAMS): Add mktemp. 971 (mktemp_LDADD): Add $(LIB_GETHRXTIME). 972 * man/mktemp.x: New file. 973 * man/Makefile.am (dist_man_MANS): Add mktemp.1. 974 (mktemp.1): New dependency. 975 * man/.cvsignore: Add mktemp.1. 976 * man/.gitignore: New file. 977 * src/.cvsignore, src/.gitignore: Add mktemp. 978 * tests/misc/mktemp: New file. 979 * tests/misc/Makefile.am (TESTS): Add mktemp. 980 * tests/Coreutils.pm (run_tests): Give the POST-test function 981 access to stdout and stderr contents, so it can verify that 982 the named-on-stdout file/dir does indeed exist and has proper 983 permissions, etc. 984 [po/ChangeLog] 985 * POTFILES.in: Add src/mktemp.c. 986 987 Make tempname more random, via the randint module. 988 * gl/modules/tempname (Depends-on): Add randint and stdbool. 989 * gl/lib/tempname.c: Include randint.h and stdbool.h. 990 (uint64_t): Remove definition. Not needed. 991 [_LIBC] (RANDOM_BITS): Remove this block, now that we have proper 992 random bits. 993 (check_x_suffix): New function. 994 (gen_tempname_len): Rename from __gen_tempname. 995 Add a parameter, x_suffix_len, telling how many X's there must be at 996 the end of the template. 997 Use pseudo-random numbers all the way, rather than adding 7777 998 from one iteration to the next. 999 (__gen_tempname): New function, to call gen_tempname_len, requiring a 1000 suffix length of 6. 1001 * gl/lib/tempname.h: Add prototype for gen_tempname_len. 1002 1003 Convert coreutils' rand*.{c,h,m4} into modules. 1004 First step: move these files to gl/lib: 1005 * lib/rand-isaac.c, lib/rand-isaac.h 1006 * lib/randint.c, lib/randint.h 1007 * lib/randperm.c, lib/randperm.h 1008 * lib/randread.c, lib/randread.h 1009 Step 2: add modules/rand* and remove now-unneeded .m4 files. 1010 * gl/modules/randint: New file. 1011 * gl/modules/randperm: New file. 1012 * gl/modules/randread: New file. 1013 * m4/randint.m4: Remove file. 1014 * m4/randperm.m4: Remove file. 1015 * m4/randread.m4: Remove file. 1016 Step 3: use the new modules 1017 * bootstrap.conf (gnulib_modules): Add randint and randperm. 1018 * m4/prereq.m4 (gl_RANDINT, gl_RANDREAD, gl_RANDPERM): Don't require; 1019 These have been removed. 1020 (gl_ROOT_DEV_INO): Don't require; already handled via bootstrap.conf. 1021 1022 Copy from gnulib the parts of tempname that we'll modify. 1023 * gl/lib/tempname.c: Copy from gnulib. 1024 * gl/lib/tempname.h: Likewise. 1025 * gl/modules/tempname: Likewise. 1026 Allow GPLv2 on temporarily(?)-imported file from gnulib/libc. 1027 * .x-sc_GPL_version: New file. 1028 * Makefile.am (EXTRA_DIST): Add .x-sc_GPL_version 1029 10302007-10-07 Jim Meyering <meyering@redhat.com> 1031 1032 Avoid a pseudo-leak in sort. 1033 * src/sort.c (main) [lint]: Avoid a nominal leak. 1034 1035 Use puts, rather than printf ("%s\n". Slightly cleaner. 1036 * src/tsort.c (tsort): ...and more efficient. 1037 1038 Avoid seq malfunction on non-POSIX systems: mingw, BeOS, Interix. 1039 * bootstrap.conf (gnulib_modules): Add vasprintf-posix. 1040 Suggestion from Bruno Haible. 1041 1042 Avoid a used-uninitialized error. 1043 * src/copy.c (copy_internal): Don't overload "use_stat". 1044 10452007-10-05 Jim Meyering <meyering@redhat.com> 1046 1047 Make a failing cross-partition mv give a sensible diagnostic. 1048 A cross-partition move of a file in a sticky tmpdir and owned by 1049 another user would evoke an invalid diagnostic after copying it: 1050 mv: cannot remove `x': Operation not permitted 1051 Either of the following (mv.c, remove.c) changes would fix the bug by 1052 itself. I think it's slightly better to use both; the added cost is 1053 minimal: mv: an extra lstat-per-mv-cmdline-arg-that-goes-cross-partition, 1054 rm: an extra lstat-per-unlink-that-fails-w/EPERM. 1055 * src/remove.c (remove_entry): Also lstat the file upon EPERM. 1056 * src/mv.c (rm_option_init): Initialize root_dev_ino just as is done 1057 in rm, so that a cross-partition invoked remove.c:rm call works the 1058 same way as one invoked from the command-line use of "rm". That 1059 setting of root_dev_ino makes rm() do the equivalent of an additional 1060 lstat for each argument, which in turn gives rm enough information to 1061 issue the right diagnostic. 1062 * tests/mv/sticky-to-xpart (version): New file. Test for the above. 1063 * tests/mv/Makefile.am (TESTS): Add sticky-to-xpart. 1064 Arrange for "make check-root" to run the new root-only test. 1065 * tests/Makefile.am (tb): New target, to run the new root-only test. 1066 (all_t): Add tb. 1067 * src/c99-to-c89.diff: Adjust offsets. 1068 1069 Add PACKAGE_VERSION to TESTS_ENVIRONMENT via check.mk. 1070 * tests/check.mk (TESTS_ENVIRONMENT): Add PACKAGE_VERSION here, 1071 rather than in every Makefile.am that needs it. 1072 * tests/rm/Makefile.am (TESTS_ENVIRONMENT): Remove PACKAGE_VERSION. 1073 * tests/misc/Makefile.am (TESTS_ENVIRONMENT): Likewise. 1074 10752007-10-04 Jim Meyering <jim@meyering.net> 1076 1077 Adapt to new gnulib naming scheme. 1078 * gl/lib/se-context.in.h: Rename from gl/lib/se-context_.h. 1079 * gl/lib/se-selinux.in.h: Rename from gl/lib/se-selinux_.h. 1080 * gl/m4/selinux-context-h.m4: Remove use of AC_LIBSOURCES. 1081 * gl/m4/selinux-selinux-h.m4: Likewise. 1082 * gl/modules/selinux-h (Files, Makefile.am): Reflect renaming. 1083 (Makefile.am) [lib_SOURCES]: Add se-context.in.h and se-selinux.in.h. 1084 1085 * lib/search_.h: Remove unused file. 1086 1087 * bootstrap (slurp): Adapt to _.h -> .in.h name change. 1088 (update_po_files): Work also when there are no .po files in po/. 1089 1090 Remove test program: lib/t-fpending.c. 1091 * lib/t-fpending.c: Remove file. Now, this test is in gnulib. 1092 * lib/Makefile.am: Remove associated rules. 1093 * .gitignore: Remove lib/t-fpending. 1094 10952007-10-03 Jim Meyering <jim@meyering.net> 1096 1097 * tests/misc/selinux: Skip this test if the initial chcon fails. 1098 10992007-10-02 Jim Meyering <jim@meyering.net> 1100 1101 Never copy through a symlink that cp has just created. 1102 * src/copy.c (copy_internal): When same-file detection requires 1103 'stat'ing the destination file, also 'lstat' it and ensure that 1104 it wasn't the destination of a preceding copy operation. 1105 This bug was introduced on 2007-06-18. 1106 * tests/cp/abuse: New test for the above. 1107 * tests/cp/Makefile.am (TESTS): Add abuse. 1108 11092007-09-30 Jim Meyering <jim@meyering.net> 1110 1111 cp: do not abbreviate in --help output. 1112 * src/cp.c (usage): Don't abbreviate: s/=link/=links/. 1113 Reported by G��raud Meyer in <http://bugs.debian.org/444137>. 1114 11152007-09-29 Eric Blake <ebb9@byu.net> 1116 1117 Test previous patch. 1118 * tests/misc/groups-dash: New test. 1119 * tests/misc/Makefile.am (TESTS): Add it. 1120 11212007-09-28 Eric Blake <ebb9@byu.net> 1122 1123 * src/groups.sh: Don't ignore first argument if later argument is --. 1124 11252007-09-27 Jim Meyering <jim@meyering.net> 1126 1127 Avoid spurious test failure when SELinux stats "selinux/class". 1128 * tests/ls/stat-free-symlinks: Grep for more precise /^stat("x"/. 1129 1130 Move file-set and hash-triple modules to gnulib. 1131 * bootstrap.conf (gnulib_modules): Remove file-set, now that 1132 it's in gnulib, and the canonicalize module requires it there. 1133 * gl/lib/file-set.c, gl/lib/file-set.h, gl/modules/hash-triple: Remove. 1134 * gl/lib/hash-triple.c, gl/lib/hash-triple.h, gl/modules/file-set: 1135 Remove. 1136 1137 Add a test to exercise a readlink bug. 1138 * tests/misc/readlink-fp-loop: New file. Test for the readlink bug 1139 fixed through today's change to Gnulib's canonicalize module. 1140 * tests/misc/Makefile.am (TESTS): Add readlink-fp-loop. 1141 Bug report and a test case from mpb.mail@gmail.com. 1142 11432007-09-25 P��draig Brady <P@draigBrady.com> 1144 1145 * doc/coreutils.texi (date invocation): 1146 Make "Date input formats" easier to navigate to. 1147 11482007-09-25 Jim Meyering <jim@meyering.net> 1149 1150 Use XOR, not OR to combine bits. 1151 * gl/lib/hash-triple.c (triple_hash): Use XOR (^), not OR (|), to 1152 combine the bits from hashing the name and those of the inode number. 1153 Add a few comments and remove out-of-context ones. 1154 11552007-09-24 Jim Meyering <jim@meyering.net> 1156 1157 * NEWS: The recent rm-diagnostic fix also affects cross-partition "mv". 1158 1159 copy.c: Remove definitions of factored-out functions. 1160 * src/copy.c: Include "file-set.h". 1161 (seen_file, record_file): Remove functions that I factored 1162 out on 2007-08-23. 1163 11642007-09-22 Jim Meyering <jim@meyering.net> 1165 1166 Don't print the commands of a 10-line script that's run in each subdir. 1167 * tests/check.mk (vc_exe_in_TESTS): Add a leading "@", to reduce noise. 1168 1169 rm: give a sensible diagnostic when failing to remove a symlink 1170 On some systems (those with openat et al), when rm would fail to 1171 remove a symlink, it would fail with the misleading diagnostic, 1172 "Too many levels of symbolic links". 1173 * NEWS: Mention the bug fix. 1174 * src/remove.c (is_nondir_lstat): New function. 1175 (remove_entry): Use it to catch failed-to-remove symlink (and any 1176 other non-dir) here so that we don't fall through and try to treat 1177 it as directory, which -- with a symlink -- would provoke the bogus 1178 ELOOP failure. 1179 * tests/rm/fail-eacces: Add a test for the above. 1180 * src/c99-to-c89.diff: Adjust offsets. 1181 1182 rm: fix a tiny, nearly inconsequential bug. 1183 Don't perform a "."-relative lstat, when the file in question 1184 may well not be in ".". Although this is a bug, a few attempts 1185 to exercise it on a linux-2.6.22 system failed. You probably need 1186 a pre-openat system to trigger the failure. The consequence of this 1187 bug would be a lower-quality diagnostic upon failed dir removal. 1188 * src/remove.c (is_dir_lstat): Add a parameter, fd_cwd. 1189 Use it instead of hard-coding AT_FDCWD. 1190 (remove_entry): Call is_dir_lstat with fd_cwd. 1191 11922007-09-22 Karl Berry <karl@freefriends.org> 1193 1194 * TODO: It'd be nice to add renice. 1195 11962007-09-21 Jim Meyering <jim@meyering.net> 1197 1198 Avoid test failure due to now-parallelized tests. 1199 * tests/du/two-args: Run "du .." from a sub-directory one level deeper. 1200 12012007-09-16 Jim Meyering <jim@meyering.net> 1202 1203 * tests/misc/tac-continue: Arrange to remove a temporary file. 1204 1205 * tests/check.mk (vc_exe_in_TESTS): Don't rely on the value of 1206 $(TESTS), so that "make check TESTS=test-name" works once again. 1207 1208 * tests/CuTmpdir.pm: Use File::Find + chmod syscall, not chmod -R. 1209 1210 Revamp most test scripts. 1211 1212 * tests/rm/v-slash: Avoid test failure with non-C locale. 1213 Reported by Michael Stone. 1214 1215 Enable some previously omitted test scripts. Add a test cross-check. 1216 * tests/rm/Makefile.am (TESTS): Add empty-name and unreadable. 1217 * tests/rm/empty-name: Likewise. 1218 * tests/rm/unreadable: Reenable this test. Adjust for new rm. 1219 * tests/mkdir/Makefile.am: Add writable-under-readonly. 1220 * tests/mkdir/writable-under-readonly: Add some comments. 1221 This test is always skipped, for now. 1222 * tests/Makefile.am (ta): Hook up the new root-only script. 1223 * tests/tail-2/infloop-1: Make this test pass. 1224 * tests/tail-2/Makefile.am (TESTS): Add infloop-1. 1225 * tests/tail-2/fflush: Remove unused file. 1226 * tests/check.mk (vc_executable_is_in_TESTS): More portable. 1227 * tests/check.mk (check): Depend on the above. 1228 * build-aux/check.mk: Remove comment mentioning AUTHORS file. 1229 1230 Factor out definitions in TESTS_ENVIRONMENT of srcdir, top_srcdir, etc. 1231 tests/check.mk (top_srcdir): Define. 1232 tests/*/Makefile.am: Remove definitions of $(srcdir), $(top_srcdir), 1233 $(abs_top_srcdir), and $(abs_top_builddir), since they're 1234 defined via the included tests/check.mk. 1235 1236 tests/general: Remove from VC, this long-unused directory and contents. 1237 1238 Adapt tests/tail-2/ to use test-lib.sh. 1239 Adapt tests/readlink/ to use test-lib.sh. 1240 1241 Move the sole test in tests/ls-2/ to tests/misc/. 1242 * tests/ls-2/basic-1: Move this file to ... 1243 * tests/misc/ls-misc: ...here. Don't rely on $PROG in env. 1244 * tests/misc/Makefile.am (TESTS): Add ls-misc. 1245 * tests/Makefile.am (SUBDIRS): Remove ls-2. 1246 * tests/ls-2: Remove the directory. 1247 * configure.ac (AC_CONFIG_FILES): Remove tests/ls-2/Makefile. 1248 1249 More misc, test-related changes. (some to allow running tests as root) 1250 1251 Move all tests from test/{od,sha1sum,shred,stty} to tests/misc/. 1252 Reflect these renamings: 1253 od/od-N misc/od-N 1254 od/x8 misc/od-x8 1255 sha1sum/basic-1 misc/sha1sum 1256 sha1sum/sample-vec misc/sha1sum-vec 1257 shred/exact misc/shred-exact 1258 shred/remove misc/shred-remove 1259 stty/basic-1 misc/stty 1260 stty/invalid misc/stty-invalid 1261 stty/row-col-1 misc/stty-row-col 1262 * tests/misc/Makefile.am (TESTS): Add the new files. 1263 * tests/Makefile.am (SUBDIRS): Remove the dir names. 1264 * tests/od, tests/sha1sum, tests/shred, tests/stty: Remove the 1265 directories. 1266 * configure.ac (AC_CONFIG_FILES): Remove the corresponding Makefile 1267 names. 1268 1269 Move the two tests in tests/tee to tests/misc/. 1270 * tests/tee/basic: Move this file to ... 1271 * tests/misc/tee: ...here. Don't rely on $PROG in env. 1272 * tests/tee/dash: Move this file to ... 1273 * tests/misc/tee-dash: ...here. Don't rely on $PROG in env. 1274 * tests/misc/Makefile.am (TESTS): Add tee. 1275 * tests/Makefile.am (SUBDIRS): Remove tee. 1276 * tests/tee: Remove the directory. 1277 * configure.ac (AC_CONFIG_FILES): Remove tests/tee/Makefile 1278 1279 Move the two tests in tests/sum/ to tests/misc/. 1280 * tests/sum/basic-1: Move this file to ... 1281 * tests/misc/sum: ...here. Don't rely on $PROG in env. 1282 * tests/sum/sysv: Move this file to ... 1283 * tests/misc/sum-sysv: ...here. Adapt it to use test-lib.sh. 1284 * tests/misc/Makefile.am (TESTS): Add sum and sum-sysv. 1285 * tests/Makefile.am (SUBDIRS): Remove sum. 1286 * tests/sum: Remove the directory. 1287 * configure.ac (AC_CONFIG_FILES): Remove tests/sum/Makefile. 1288 1289 Move the sole test in tests/tsort/ to tests/misc/tsort. 1290 * tests/tsort/basic-1: Move this file to ... 1291 * tests/misc/tsort: ...here. Don't rely on $PROG in env. 1292 * tests/misc/Makefile.am (TESTS): Add tsort. 1293 * tests/Makefile.am (SUBDIRS): Remove tsort. 1294 * tests/tsort: Remove the directory. 1295 * configure.ac (AC_CONFIG_FILES): Remove tests/tsort/Makefile. 1296 1297 Move the sole test in tests/unexpand to tests/misc/unexpand. 1298 * tests/unexpand/basic-1: Move this file to ... 1299 * tests/misc/unexpand: ...here. Don't rely on $PROG in env. 1300 * tests/misc/Makefile.am (TESTS): Add unexpand. 1301 * tests/Makefile.am (SUBDIRS): Remove unexpand. 1302 * tests/unexpand: Remove the directory. 1303 * configure.ac (AC_CONFIG_FILES): Remove tests/unexpand/Makefile. 1304 1305 Move the sole test in tests/seq to tests/misc/seq. 1306 * tests/seq/basic: Move this file to ... 1307 * tests/misc/seq: ...here. Don't rely on $PROG in env. 1308 * tests/misc/Makefile.am (TESTS): Add seq. 1309 * tests/Makefile.am (SUBDIRS): Remove seq. 1310 * tests/seq: Remove the directory. 1311 * configure.ac (AC_CONFIG_FILES): Remove tests/seq/Makefile 1312 1313 Convert tests/mkdir/ to use test-lib.sh. 1314 1315 Move the two tests in tests/md5sum to tests/misc/md5sum. 1316 * tests/md5sum/basic-1: Move this file to ... 1317 * tests/misc/md5sum: ...here. Don't rely on $PROG in env. 1318 * tests/md5sum/newline-1: Move this file to ... 1319 * tests/misc/md5sum-newline: ...here. Don't rely on $PROG in env. 1320 * tests/misc/Makefile.am (TESTS): Add md5sum. 1321 * tests/Makefile.am (SUBDIRS): Remove md5sum. 1322 * tests/md5sum: Remove the directory. 1323 * configure.ac (AC_CONFIG_FILES): Remove tests/md5sum/Makefile 1324 1325 tests/sample-test: Update to use test-lib.sh. 1326 1327 Convert tests/misc/ to use test-lib.sh, too. 1328 Convert tests/ls/, too. 1329 Convert tests/ln/, too. 1330 Convert tests/install/, too. 1331 1332 Move the two tests in tests/fmt to tests/misc/fmt. 1333 * tests/fmt/basic: Move this file to ... 1334 * tests/misc/fmt: ...here. Don't rely on $PROG in env. 1335 * tests/fmt/long-line: Move this file to ... 1336 * tests/misc/fmt-long-line: ...here. 1337 * tests/misc/Makefile.am (TESTS): Add fmt. 1338 * tests/Makefile.am (SUBDIRS): Remove fmt. 1339 * tests/fmt: Remove the directory. 1340 * configure.ac (AC_CONFIG_FILES): Remove tests/fmt/Makefile 1341 1342 Move the sole test in tests/factor to tests/misc/factor. 1343 * tests/factor/basic: Move this file to ... 1344 * tests/misc/factor: ...here. Don't rely on $PROG in env. 1345 * tests/misc/Makefile.am (TESTS): Add factor. 1346 * tests/Makefile.am (SUBDIRS): Remove factor. 1347 * tests/factor: Remove the directory. 1348 * configure.ac (AC_CONFIG_FILES): Remove tests/factor/Makefile 1349 1350 Move the sole test in tests/expr to tests/misc/expr. 1351 * tests/expr/basic: Move this file to ... 1352 * tests/misc/expr: ...here. Don't rely on $PROG in env. 1353 * tests/misc/Makefile.am (TESTS): Add expr. 1354 * tests/Makefile.am (SUBDIRS): Remove expr. 1355 * tests/expr: Remove the directory. 1356 * configure.ac (AC_CONFIG_FILES): Remove tests/expr/Makefile 1357 1358 Convert tests/du/*, too. 1359 1360 Move the sole test in tests/dircolors to tests/misc/dircolors. 1361 * tests/dircolors/simple: Move this file to... 1362 * tests/misc/dircolors: ...here. Don't rely on $PROG in env. 1363 * tests/misc/Makefile.am (TESTS): Add dircolors. 1364 * tests/Makefile.am (SUBDIRS): Remove dircolors. 1365 * tests/dircolors: Remove the directory. 1366 * configure.ac (AC_CONFIG_FILES): Remove tests/dircolors/Makefile 1367 1368 Convert tests/dd/*, too. 1369 1370 Convert tests/mv, too. 1371 * tests/other-fs-tmpdir: Before, all callers would exit 77 upon 1372 failure to find the required dir. Now, exit 77 in this script so 1373 callers don't have to. Adjust callers. 1374 1375 Adjust chgrp, chmod, chown, cp tests to use test-lib.sh. 1376 * tests/check.mk: Also define abs_top_builddir. 1377 1378 Parallel "make check" support. 1379 * build-aux/check.mk: New file, from The Vaucanson Group. 1380 * .x-sc_GPL_version: New file, to allow "version 2 or later" 1381 in build-aux/check.mk. 1382 * Makefile.am (EXTRA_DIST): Add .x-sc_GPL_version. 1383 * tests/check.mk: New file. 1384 * tests/Makefile.am (EXTRA_DIST): Add check.mk, mkdtemp and test-lib.sh. 1385 1386 Begin factoring "sample-test" out of test scripts. 1387 * tests/test-lib.sh: New file, to be sourced by all tests that 1388 were previously derived from the "sample-test" template. 1389 * tests/mkdtemp: New file. 1390 * tests/touch/dir-1: Use test-lib.sh. 1391 * tests/touch/empty-file: Likewise. 1392 * tests/touch/fail-diag: Likewise. 1393 * tests/touch/fifo: Likewise. 1394 * tests/touch/no-create-missing: Likewise. 1395 * tests/touch/no-rights: Likewise. Also, don't sleep. 1396 * tests/touch/not-owner: Likewise. 1397 * tests/touch/obsolescent: Likewise. 1398 * tests/touch/read-only: Likewise. 1399 * tests/touch/relative: Likewise. 1400 * tests/touch/Makefile.am: Include $(top_srcdir)/tests/check.mk, 1401 to get the parallel-"make check" bits. 1402 1403 Move a slow test into tests/misc. 1404 * tests/check.mk: Wrapper. 1405 * tests/ls/time-1: Move this file to tests/misc/ls-time. 1406 * tests/misc/ls-time: New file. From tests/ls/time-1. 1407 * tests/ls/Makefile.am (TESTS): Remove time-1. 1408 * tests/misc/Makefile.am (TESTS): Add ls-time. 1409 1410 Add support for parallel "make check" (in tests/misc, for now) 1411 14122007-09-08 Jim Meyering <jim@meyering.net> 1413 1414 Accommodate gnulib's renaming: __fpending.h -> fpending.h. 1415 * lib/t-fpending.c: Include "fpending.h", not "__fpending.h". 1416 14172007-09-07 Jim Meyering <jim@meyering.net> 1418 1419 chmod: don't ignore a dangling symlink 1420 * NEWS: Mention the bug fix. 1421 * src/chmod.c (process_file): Handle the case of FTS_SLNONE, 1422 i.e., give a diagnostic saying we cannot operate on such a file. 1423 * tests/chmod/thru-dangling: Compare new stderr output with expected. 1424 14252007-09-07 Bob Proulx <bob@proulx.com> 1426 1427 Add a test: demonstrate that chmod ignores a dangling symlink 1428 * tests/chmod/thru-dangling: New test. Fails. 1429 * tests/chmod/Makefile.am (TESTS): Add thru-dangling. 1430 14312007-09-05 Jim Meyering <jim@meyering.net> 1432 1433 Adapt to new SELinux behavior: "?" vs. new "unlabeled" 1434 * src/ls.c (gobble_file): Interpret the new "unlabeled" indicator 1435 from getfilecon/lgetfilecon the same way we interpret a negative 1436 return value: no security context. So we don't print the "+". 1437 * tests/selinux: Recognize that "unlabeled" means insufficient 1438 support for SELinux, just like "?". 1439 14402007-09-03 Jim Meyering <jim@meyering.net> 1441 1442 Invoke $(AUTOCONF) manually, if needed to get an updated version string. 1443 * GNUmakefile: Don't actually touch configure.ac. 1444 That would make git-version-gen always print "...-dirty". 1445 1446 Don't change '-'s to '.'s in the string from git-describe. 1447 * build-aux/git-version-gen: Leave '-'s in the string from git-describe. 1448 Otherwise, s/-/./g would make it too hard to distinguish the base 1449 version number from the appended .DD suffixes. 1450 14512007-09-03 Jim Meyering <jim@meyering.net> 1452 1453 * README-hacking: Require rsync, rather than wget. 1454 14552007-09-02 Jim Meyering <jim@meyering.net> 1456 1457 * bootstrap (WGET_COMMAND): Remove code to set this variable. 1458 1459 Ensure that $(VERSION) is up to date for dist-related targets. 1460 * GNUmakefile: Arrange to rerun autoconf, if the version reported by 1461 git-version-gen doesn't match $(VERSION), but only for dist targets. 1462 1463 bootstrap: uses rsync to download the .po files 1464 * bootstrap (po_download_command_format): New global. 1465 (download_po_files): Use rsync. 1466 (update_po_files): Don't remove .po files after download, 1467 so future rsync runs can take advantage of the copies. 1468 14692007-09-01 Jim Meyering <jim@meyering.net> 1470 1471 * bootstrap (gnulib_tool): Make sha1sum check quietly. 1472 1473 Ensure that snapshot version changes make it to groups, too. 1474 * src/Makefile.am (groups): Depend on Makefile. 1475 1476 Make groups-version executable, 1477 * tests/misc/groups-version: ... as it was in the patch. 1478 14792007-08-31 Eric Blake <ebb9@byu.net> 1480 1481 Test yesterday's change to groups. 1482 * tests/misc/groups-version: New test. 1483 * tests/misc/Makefile.am (TESTS): Add groups-version. 1484 14852007-08-31 Jim Meyering <jim@meyering.net> 1486 1487 Solve the unnecessary-.po-file-regeneration problem once and for all. 1488 * bootstrap (download_po_files): New function, renamed from 1489 get_translations. Now, downloads, but doesn't update LINGUAS. 1490 (update_po_files): New function. 1491 14922007-08-30 Jim Meyering <jim@meyering.net> 1493 1494 Shorten the snapshot version string by removing the "g". 1495 * build-aux/git-version-gen: Remove git-describe's "g" that would 1496 always precede the abbreviated SHA1. Suggestion from Dmitry V. Levin. 1497 1498 Perform the s,rm,/bin/rm, fix-up properly. No more kludge. 1499 * Makefile.am (EXTRA_DIST): Remove .kludge-stamp. 1500 (.kludge-stamp): Remove rule. Instead, ... 1501 (dist-hook): Do the job here, operating on the file in $(distdir). 1502 (rm_subst): Adjust regexp to match "rm -f rm$(EXEEXT)", not "rm -f rm". 1503 (MAINTAINERCLEANFILES): s/+=/=/, now that this is the sole use. 1504 (dist-hook): Remove the legacy-from-cvs install-sh is-executable check. 1505 * .gitignore: Remove .kludge-stamp. 1506 1507 Make inter-release --version output more useful. 1508 Now, each snapshot has a version "number" like 6.9-219-g58ddd, 1509 which indicates that it is built using the 219th change set 1510 (in _some_ repository) following the "v6.9" tag, and that 58ddd 1511 is a prefix of the commit SHA1. 1512 * build-aux/git-version-gen: New file. 1513 * configure.ac: Run it to set the version. 1514 * Makefile.am (dist-hook): Arrange so that .version appears only 1515 in distribution tarballs, never in a checked-out repository. 1516 * .gitignore: Add .version here, too. Just in case. 1517 15182007-08-30 Eric Blake <ebb9@byu.net> 1519 1520 * src/.gitignore: Ignore *.exe for platforms with non-empty $(EXEEXT). 1521 15222007-08-30 Eric Blake <ebb9@byu.net> 1523 1524 Use PACKAGE_NAME instead of GNU_PACKAGE. 1525 * src/Makefile.am (.sh, uninstall-local): Adjust all users of 1526 hand-rolled GNU_PACKAGE to instead use autoconf-provided 1527 PACKAGE_NAME. 1528 * src/basename.c (main): Likewise. 1529 * src/chroot.c (main): Likewise. 1530 * src/dirname.c (main): Likewise. 1531 * src/echo.c (main): Likewise. 1532 * src/expr.c (main): Likewise. 1533 * src/factor.c (main): Likewise. 1534 * src/groups.sh (version): Likewise. Also, reflect change in 1535 --version output due to GPLv3. 1536 * src/hostid.c (main): Likewise. 1537 * src/hostname.c (main): Likewise. 1538 * src/link.c (main): Likewise. 1539 * src/logname.c (main): Likewise. 1540 * src/nice.c (main): Likewise. 1541 * src/nohup.c (main): Likewise. 1542 * src/printenv.c (main): Likewise. 1543 * src/printf.c (main): Likewise. 1544 * src/pwd.c (main): Likewise. 1545 * src/setuidgid.c (main): Likewise. 1546 * src/sleep.c (main): Likewise. 1547 * src/system.h (case_GETOPT_VERSION_CHAR): Likewise. 1548 * src/test.c (main): Likewise. 1549 * src/true.c (main): Likewise. 1550 * src/unlink.c (main): Likewise. 1551 * src/uptime.c (main): Likewise. 1552 * src/users.c (main): Likewise. 1553 * src/whoami.c (main): Likewise. 1554 * src/yes.c (main): Likewise. 1555 * configure.ac (AC_CHECK_DECLS): No need to check strtoimax, 1556 strtoumax, since gnulib does this. 1557 15582007-08-30 Jim Meyering <jim@meyering.net> 1559 1560 Ensure that TMPDIR is valid. Otherwise, it would cause test failures. 1561 * tests/misc/tty-eof: Set TMPDIR=. 1562 * tests/misc/sort-compress: Likewise. 1563 1564 Use EXIT_FAILURE, not EXIT_FAIL, now that EXIT_FAILURE is always 1. 1565 * src/system.h (EXIT_FAIL): Remove definition. 1566 * src/chroot.c (main): EXIT_FAIL -> EXIT_FAILURE. 1567 * src/env.c (main): Likewise. 1568 * src/nice.c (main): Likewise. 1569 * src/su.c (change_identity, main): Likewise. 1570 * src/tty.c (main): Likewise. 1571 Suggestion from Eric Blake. 1572 15732007-08-28 Jim Meyering <jim@meyering.net> 1574 1575 * src/test.c (usage): Note that [ honors --help and --version, 1576 but that test does not. Suggestion from Dan Jacobson. 1577 1578 By default, do not install hostname anymore; no kidding, this time. 1579 * src/Makefile.am (EXTRA_PROGRAMS): Remove hostname from this list, 1580 now that it's no longer being installed by default. This should 1581 have been part of the 2007-08-21 change. 1582 (check-duplicate-no-install): New rule to ensure this doesn't 1583 happen again. 1584 (check): Depend on it. 1585 1586 Reflect renaming: mreadlink-with-size -> areadlink-with-size. 1587 * bootstrap.conf: Update module name. 1588 * src/copy.c (copy_internal): Update header and function names. 1589 * src/ls.c (get_link_name): Likewise. 1590 * src/readlink.c (main): Likewise. 1591 * src/stat.c (print_stat): Likewise. 1592 1593 Add file system type names and magic numbers from "man 2 statfs". 1594 * src/stat.c (human_fstype): Also handle BEFS, BFS, BINFMT_MISC, 1595 FUSECTL, HUGETLBFS, NFSD and OPENPROM. 1596 15972007-08-27 Jim Meyering <jim@meyering.net> 1598 1599 Add some file system type names and magic numbers from glibc. 1600 * src/stat.c (human_fstype): Add any file system names and values 1601 present in glibc's linux_fsinfo.h but not in this list. 1602 Alphabetize the S_* names and capitalize the hexadecimal constants. 1603 16042007-08-26 Jim Meyering <jim@meyering.net> 1605 1606 * tests/misc/fold: Fix a typo: missing \ in a diagnostic 1607 no one is likely ever to see. 1608 16092007-08-25 Jim Meyering <jim@meyering.net> 1610 1611 * src/dircolors.hin: Add .dz and .svgz as archive suffixes. 1612 1613 Remove all .cvsignore files from version control. 1614 16152007-08-24 Jim Meyering <jim@meyering.net> 1616 1617 bootstrap: Ignore more. 1618 * bootstrap (symlink_to_dir): Add a directory name like 1619 uniwidth to e.g., lib/.gitignore. 1620 (slurp): Handle the sys_stat_.h -> sys mapping, too. 1621 * .hgignore: Remove this file, too. 1622 * Makefile.am (EXTRA_DIST): Remove .gitignore and .hgignore. 1623 1624 No longer version-control .???ignore files in lib/, m4/, and po/. 1625 * .gitignore: Ignore a few files in lib/, m4/, and po/ that are not 1626 picked up automatically. 1627 * lib/.gitignore, lib/.cvsignore: Remove files. 1628 * m4/.gitignore, m4/.cvsignore: Remove files. 1629 * po/.gitignore, po/.cvsignore: Remove files. 1630 1631 bootstrap: when fetching .po files, do not remove .gmo files. 1632 * bootstrap (get_translations): Don't remove *.gmo files! 1633 They can be expensive to regenerate. 1634 1635 Create .gitignore and/or .cvsignore from scratch, if absent. 1636 This is in preparation for my removing those files from version 1637 control in the directories managed by gnulib-tool. 1638 * bootstrap: New setting: vc_ignore. 1639 (insert_sorted_if_absent): Create $file if absent. 1640 Adapt to new, possibly empty, list: $vc_ignore. 1641 1642 * src/system.h (fseeko, ftello): Remove now-unneeded definitions. 1643 * src/od.c (LDBL_DIG): Remove now-unneeded definition. 1644 1645 Arrange to use tag names like vM.N, rather than COREUTILS-M_N. 1646 * Makefile.maint (this-vc-tag) [git]: Simply use v$(VERSION). 1647 (this-vc-tag-regexp): New variable. 1648 (vc-tag-check): Use it, rather than $(this-vc-tag). 1649 16502007-08-23 Jim Meyering <jim@meyering.net> 1651 1652 * src/dircolors.hin: Add xterm-16color, xterm-88color and eterm-color. 1653 Suggestion from Dan Nicolaescu. 1654 1655 Don't let ln be a party to destroying user data. 1656 * src/ln.c: Include "file-set.h", "hash.h" and "hash-triple.h". 1657 (dest_set, DEST_INFO_INITIAL_CAPACITY): New globals. 1658 (do_link): Refuse to remove a just-created link. 1659 Record a name,dev,ino triple for each link we create. 1660 (main): Initialize dest_set, if needed. 1661 * tests/mv/childproof: Test for the above fix. 1662 * NEWS: Document this. 1663 Reported by Eric Blake. 1664 1665 Move functions from copy.c into new modules, since ln needs them, too. 1666 * bootstrap.conf (gnulib_modules): Add file-set. 1667 * gl/lib/file-set.c (record_file, seen_file): Functions from copy.c. 1668 * gl/lib/file-set.h: Add prototypes. 1669 * gl/lib/hash-triple.c (triple_hash, triple_hash_no_name): 1670 (triple_compare, triple_free): Functions from copy.c. 1671 * gl/lib/hash-triple.h (struct F_triple): Define. From copy.c. 1672 Add prototypes. 1673 * gl/modules/file-set: New module. 1674 * gl/modules/hash-triple: New module. 1675 * src/Makefile.am (copy_sources): New variable. 1676 (ginstall_SOURCES, cp_SOURCES, mv_SOURCES): Use it. 1677 * src/copy.c: Include hash-triple.h. 1678 No longer include hash-pjw.h. 1679 (copy_internal): Don't pass a NULL third argument to record_file, 1680 since that function no longer accepts that. 1681 (record_file): Move this function to file-set.c. 1682 Along the way, remove the code to allow a NULL stat-buffer pointer. 1683 Adjust sole caller. 1684 (seen_file): Move this function to file-set.c. 1685 (struct F_triple): Move declaration to hash-triple.h. 1686 (triple_compare, triple_free, triple_hash, triple_hash_no_name): 1687 Move these functions to hash-triple.c. 1688 1689 bootstrap: generate more ignorable names 1690 * bootstrap (slurp): When generating ignorable names, also map 1691 .sin to .sed, .gperf to .c, and .y to .c. 1692 1693 * Makefile.maint (patch-check): Don't remove temporaries upon failure. 1694 16952007-08-22 Jim Meyering <jim@meyering.net> 1696 1697 * src/c99-to-c89.diff: Adjust offsets. 1698 1699 Change "rm --verbose -r a//" not to print extra slashes in a///b 1700 * src/remove.c (push_dir): Don't copy trailing slashes onto the stack. 1701 Reported by Fran��ois Pinard. 1702 * tests/rm/v-slash: New file. Test for the above change. 1703 * tests/rm/Makefile.am (TESTS): Add v-slash. 1704 1705 * src/date.c: Don't include "getline.h", now removed from gnulib; 1706 its declarations are now in <stdio.h>. 1707 * src/md5sum.c: Likewise. 1708 * src/dircolors.c: Likewise. 1709 1710 * src/copy.c (DEST_INFO_INITIAL_CAPACITY): Correct a comment. 1711 17122007-08-21 Jim Meyering <jim@meyering.net> 1713 1714 By default, do not install hostname anymore. 1715 * configure.ac: Add "hostname" to the list of not-installed programs. 1716 * src/Makefile.am (no_install__progs): Add "hostname" here, too. 1717 * NEWS: Mention this. 1718 17192007-08-20 Bob Proulx <bob@proulx.com> 1720 1721 Clarify touch documentation of file arguments. 1722 * src/touch.c (usage): Improve wording of documentation regarding 1723 file argument handling and special handling of - argument. 1724 * doc/coreutils.texi (touch invocation): Likewise. 1725 Documentation problem reported by Vincent Lefevre. 1726 17272007-08-20 Paul Eggert <eggert@cs.ucla.edu> 1728 1729 * NEWS: The old cp -p bug affected coreutils releases before 6.0. 1730 Problem reported by Soren Spies in 1731 <http://lists.gnu.org/archive/html/bug-coreutils/2007-08/msg00106.html>. 1732 To be conservative, just say the bug was in all versions through 6.6. 1733 17342007-08-19 Eric Blake <ebb9@byu.net> 1735 1736 Avoid consuming too much seekable input when yesno is used. 1737 * bootstrap.conf (gnulib_modules): Add closein. 1738 * src/system.h (includes): Also include closein.h. 1739 * src/mv.c (main): Use close_stdin, not close_stdout. 1740 * src/cp.c (main): Likewise. 1741 * src/ln.c (main): Likewise. 1742 * src/rm.c (main): Likewise. 1743 * src/install.c (main): Likewise. 1744 * NEWS: Document the fix. 1745 17462007-08-20 Jim Meyering <jim@meyering.net> 1747 1748 Parallel "make check" support. 1749 * build-aux/check.mk: New file, from The Vaucanson Group. 1750 * .x-sc_GPL_version: New file, to allow "version 2 or later" 1751 in build-aux/check.mk. 1752 * Makefile.am (EXTRA_DIST): Add .x-sc_GPL_version. 1753 * tests/check.mk: New file. 1754 * tests/Makefile.am (EXTRA_DIST): Add check.mk, mkdtemp and test-lib.sh. 1755 1756 Begin factoring "sample-test" out of test scripts. 1757 * tests/test-lib.sh: New file, to be sourced by all tests that 1758 were previously derived from the "sample-test" template. 1759 * tests/mkdtemp: New file. 1760 * tests/touch/dir-1: Use test-lib.sh. 1761 * tests/touch/empty-file: Likewise. 1762 * tests/touch/fail-diag: Likewise. 1763 * tests/touch/fifo: Likewise. 1764 * tests/touch/no-create-missing: Likewise. 1765 * tests/touch/no-rights: Likewise. Also, don't sleep. 1766 * tests/touch/not-owner: Likewise. 1767 * tests/touch/obsolescent: Likewise. 1768 * tests/touch/read-only: Likewise. 1769 * tests/touch/relative: Likewise. 1770 * tests/touch/Makefile.am: Include $(top_srcdir)/tests/check.mk, 1771 to get the parallel-"make check" bits. 1772 17732007-08-18 Jim Meyering <jim@meyering.net> 1774 1775 Use new "idcache.h" header. 1776 * src/ls.c: Remove ancient declarations of getuser and getgroup. 1777 Include "idcache.h", instead. 1778 1779 Run each Coreutils.pm-based test in its own subdirectory. 1780 * tests/CuTmpdir.pm: New file. 1781 * tests/Makefile.am (EXTRA_DIST): Add CuTmpdir.pm. 1782 * tests/misc/od, tests/misc/base64, tests/misc/basename: 1783 * tests/misc/cut, tests/misc/date, tests/misc/dirname: 1784 * tests/misc/expand, tests/misc/fold, tests/misc/head-elide-tail: 1785 * tests/misc/paste-no-nl, tests/misc/pr, tests/misc/sha224sum: 1786 * tests/misc/sha256sum, tests/misc/sha384sum, tests/misc/sha512sum: 1787 * tests/misc/sort-merge, tests/misc/stat-printf, tests/misc/test-diag: 1788 * tests/misc/wc-files0-from, tests/misc/xstrtol: 1789 * tests/dd/skip-seek, tests/dircolors/simple, tests/du/files0-from: 1790 * tests/expr/basic, tests/factor/basic, tests/fmt/basic: 1791 * tests/ls-2/tests, tests/md5sum/basic-1, tests/md5sum/newline-1: 1792 * tests/seq/basic, tests/sha1sum/basic-1, tests/sha1sum/sample-vec: 1793 * tests/sum/basic-1, tests/tsort/basic-1, tests/unexpand/basic-1: 1794 * tests/mv/i-1, tests/rm/empty-name, tests/rm/unreadable: Use it. 1795 * tests/misc/test-diag: Use "$ENV{abs_top_builddir}/src/test", 1796 not "../../src/test", so it works when run from a subdirectory. 1797 * tests/ls-2/tests: Create temp files and dirs from within the perl 1798 script, so that they're removed, when run from a subdirectory. 1799 * tests/ls-2/Makefile.am (TESTS_ENVIRONMENT): Define abs_top_builddir, 1800 so we can use "$ENV{abs_top_builddir}/src/test" in a test script. 1801 18022007-08-16 Jim Meyering <jim@meyering.net> 1803 1804 Consolidate od tests. 1805 * tests/misc/od: Perform od-zero-len's test here. 1806 Include boilerplate code, so tests run in a subdirectory. 1807 * tests/misc/od-zero-len: Remove this file. 1808 1809 * tests/ls/time-1: Include sample-test boilerplate code. 1810 Remove the then-unnecessary, hard-coded envvar "unset" commands. 1811 18122007-08-15 Jim Meyering <jim@meyering.net> 1813 1814 Move a slow test into tests/misc. 1815 * tests/ls/time-1: Move this file to tests/misc/ls-time. 1816 * tests/misc/ls-time: New file. From tests/ls/time-1. 1817 * tests/ls/Makefile.am (TESTS): Remove time-1. 1818 * tests/misc/Makefile.am (TESTS): Add ls-time. 1819 1820 od --skip (-j) works even on files in /proc, when the kernel lies 1821 * src/od.c (skip): Don't let kernel misinformation (nonempty files 1822 in /proc with stat.st_size == 0) make "od -j N" misbehave. 1823 Patch by Paul Eggert. 1824 * NEWS: Document this work-around. 1825 * tests/misc/od-zero-len: New file, test for the above. 1826 1827 * src/printf.c (usage): Adjust summary to also mention OPTIONs. 1828 From Karl Berry. 1829 18302007-08-14 Jim Meyering <jim@meyering.net> 1831 1832 od: fix a bug that arises when skipping exact length of file 1833 * NEWS: Document the bug fix. 1834 * src/od.c (skip): Call fseek even when n_skip is exactly the 1835 same as the length of the current file. Otherwise, the next 1836 iteration would use unadjusted input stream pointer, thus ignoring 1837 the desired "skip". Report and patch by Paul GHALEB. 1838 1839 * tests/misc/od: New file, test for the above. 1840 * tests/misc/Makefile.am (TESTS): Add od. 1841 18422007-08-10 Paul Eggert <eggert@cs.ucla.edu> 1843 1844 Accommodate more xstrtol changes. 1845 * src/df.c (long_options): Don't bother prepending "--" to long 1846 options that OPT_STR might decode, as that hack is no longer needed. 1847 (main): Invoke xstrtol_fatal rather than STRTOL_FATAL_ERROR. 1848 * src/du.c (long_options, main): Likewise. 1849 * src/ls.c (decode_switches): Likewise. 1850 * src/od.c (long_options, main): Likewise. 1851 * src/pr.c (first_last_page, main): Likewise. 1852 * src/sort.c (long_options, specify_sort_size): Likewise. 1853 * src/pr.c (first_last_page): Accept option index and option char 1854 instead of an assembled option string. All callers changed. 1855 * src/sort.c (specify_sort_size): Likewise. 1856 * src/system.h (OPT_STR, LONG_OPT_STR, short_opt_str, OPT_STR_INIT): 1857 Remove. 1858 18592007-08-05 Jim Meyering <jim@meyering.net> 1860 1861 Encapsulate a static variable. 1862 * src/system.h (opt_str_storage): Move static var into... 1863 (short_opt_str): ... new static inline function. 1864 (OPT_STR): Use the new function. 1865 18662007-08-04 Jim Meyering <jim@meyering.net> 1867 1868 Exercise xstrtol's diagnostics via pr's --pages option. 1869 * tests/misc/xstrtol: New file. 1870 * tests/misc/Makefile.am (TESTS): Add xstrtol. 1871 18722007-08-04 Paul Eggert <eggert@cs.ucla.edu> 1873 1874 Adapt to new human and xstrtol API. 1875 * src/df.c (long_options): Prepend "--" to long options that 1876 OPT_STR might decode. 1877 * src/du.c (long_options): Likewise. 1878 * src/od.c (long_options): Likewise. 1879 * src/sort.c (long_options): Likewise. 1880 * src/df.c (main): Adjust to new human and xstrtol API. 1881 * src/du.c (main): Likewise. 1882 * src/ls.c (decode_switches): Likewise. 1883 * src/od.c (main): Likewise. 1884 * src/pr.c (first_last_page): Likewise. New argument OPTION. 1885 All callers changed. 1886 * src/sort.c (specify_sort_size): New arg OPTION. All callers 1887 changed. Adjust to new xstrtol API. 1888 * src/system.h (opt_str_storage): New static var. 1889 (OPT_STR, LONG_OPT_STR, OPT_STR_INIT): New macros. 1890 18912007-08-02 Jim Meyering <jim@meyering.net> 1892 1893 Adjust one more test to accommodate the recent fts change. 1894 This matters only on systems with insufficient openat support. 1895 * tests/du/inacc-dest: Adjust expected diagnostic. 1896 1897 Adjust the other two "no-x" tests and unify all three. 1898 * tests/du/no-x: Factor out du-specific bits. 1899 * tests/chmod/no-x: Use the same code. 1900 * tests/chgrp/no-x: Use the same code. 1901 1902 Adapt du's no-x test not to fail on older Linux systems. 1903 * tests/du/no-x: Accept a third variant of the diagnostic. 1904 19052007-07-31 Jim Meyering <jim@meyering.net> 1906 1907 du: print size (probably incomplete) of each inaccessible directory 1908 * src/du.c (process_file): Print what we know of the size of a 1909 directory even when it is inaccessible. What we print is just the 1910 size of the directory itself, not counting any of its contents. 1911 * tests/du/inacc-dir: Test for this. 1912 * NEWS: Mention this change. 1913 1914 Add a test for du not counting size of inaccessible directories. 1915 * tests/du/inacc-dir: New file. Test for fts.c bug fixed yesterday. 1916 * tests/du/Makefile.am (TESTS): Add inacc-dir. 1917 * NEWS: Mention the bug fix. 1918 19192007-07-28 Jim Meyering <jim@meyering.net> 1920 1921 Attempt to copy a regular file, even if stat says it is empty. 1922 * NEWS: Document this bug fix. 1923 * src/copy.c (copy_reg): Read from a regular file, even if it 1924 appears (stat.st_size == 0) to be empty. This reverts an 1925 optimization introduced on 2005-11-23 for coreutils-6.0. 1926 Otherwise, "cp /proc/cpuinfo /tmp" creates an empty file, 1927 on e.g., linux-2.6.20. 1928 * tests/cp/proc-zero-len: New file. Test for the above. 1929 * tests/cp/Makefile.am (TESTS): Add proc-zero-len. 1930 Reported by Dan Berrang��. 1931 19322007-07-26 Bob Proulx <bob@proulx.com> 1933 1934 sort: Improve sort --random-sort test. 1935 * tests/misc/sort-rand: If "locale" is available pick a random 1936 non-C locale and check "sort --random-sort" behavior using it. 1937 19382007-07-24 Jim Meyering <jim@meyering.net> 1939 1940 sort: add a test to exercise the affected code. 1941 * tests/sort/Test.pm (realloc-buf): Exercise the code that changed 1942 yesterday. No other test in all of "make check" does this. 1943 * NEWS: Mention the fix. 1944 19452007-07-23 Paul Eggert <eggert@cs.ucla.edu> 1946 1947 sort: avoid unaligned access. 1948 * src/sort.c (fillbuf): When enlarging the line buffer, ensure that 1949 the new size is a multiple of "sizeof (struct line)". This avoids 1950 alignment problems when indexing from the end of the buffer. 1951 Problem reported by Andreas Schwab in 1952 <http://lists.gnu.org/archive/html/bug-coreutils/2007-07/msg00158.html>. 1953 19542007-07-23 Jim Meyering <jim@meyering.net> 1955 1956 Update all copyright notices to use the newer form (e.g., remove 1957 the postal address, and add the 'licenses' URL). 1958 1959 * COPYING: Update to Version 3. 1960 1961 Update c99/c89 patch for new, copyright-change-induced offsets. 1962 * Makefile.maint (patch-check): Filter out '^Only in...' lines. 1963 * src/c99-to-c89.diff: Handle new c99'isms in seq.c. 1964 19652007-07-22 Jim Meyering <jim@meyering.net> 1966 1967 * configure.ac: Arrange to rerun configure whenever src/Makefile.am 1968 changes. That file contains the list of program names that must be 1969 substituted into files like man/Makefile. 1970 Add quotes around AC_SUBST arguments. 1971 19722007-07-21 Paul Eggert <eggert@cs.ucla.edu> 1973 1974 * bootstrap (slurp): Work even in environments where "ls" defaults 1975 to "ls -A". Put in a FIXME, though, since the current code does 1976 not slurp files whose names start with ".", and this looks like 1977 it might be a troublesome area. 1978 19792007-07-20 Jim Meyering <jim@meyering.net> 1980 1981 Document and add a test for today's sort bug fix. 1982 * NEWS: Describe the bug fix. 1983 * tests/sort/Test.pm (obs-inval): Add a test for today's fix. 1984 19852007-07-20 Andreas Schwab <schwab@suse.de> 1986 1987 * src/sort.c (main): Don't free a pointer to non-malloc'd memory. 1988 19892007-07-19 Jim Meyering <jim@meyering.net> 1990 1991 Fix a portability bug in the new ls-color test. 1992 * tests/ls/stat-free-symlinks: Don't rely on the ability of 1993 a built-in printf to interpolate '\e'. Use '\033' instead. 1994 19952007-07-18 Jim Meyering <jim@meyering.net> 1996 1997 "cp -i --update older newer" no longer prompts; same for mv 1998 * src/copy.c (copy_internal): Perform "update" check before the 1999 possible interactive prompt. Reported by zeno_AT_biyg_DOT_org 2000 in <http://bugzilla.redhat.com/248591> 2001 * tests/mv/update: Add tests for the above. 2002 * NEWS: Mention the bug fix. 2003 20042007-07-15 Jim Meyering <jim@meyering.net> 2005 2006 ls --color: Don't stat symlinks when neither ORPHAN nor MISSING 2007 attribute has a color. 2008 * src/ls.c (main): Don't set check_symlink_color when C_EXEC is 2009 colored, unless ln=target (aka color_symlink_as_referent) is set. 2010 (gobble_file): Set f->linkok = true also when !check_symlink_color. 2011 http://thread.gmane.org/gmane.comp.gnu.coreutils.bugs/10608/focus=10927 2012 Reported by Jeremy Maitin-Shepard. 2013 * tests/strace: New file, contents extracted from... 2014 * tests/mv/atomic: ...here. Source strace. 2015 * tests/ls/stat-free-symlinks: New file. Test for the above. 2016 Use strace to ensure that in this corner case, ls does not call stat. 2017 * tests/ls/Makefile.am (TESTS): Add stat-free-symlinks. 2018 * tests/Makefile.am (EXTRA_DIST): Add strace. 2019 20202007-07-14 Jim Meyering <jim@meyering.net> 2021 2022 Remove long-deprecated options. 2023 * NEWS: Mention this. 2024 * src/df.c, src/ls.c: Remove --kilobytes option. 2025 * src/du.c: Remove --kilobytes and --megabytes options. 2026 * src/who.c: Remove -i and --idle options. 2027 * src/ptx.c: Remove --copyright option. 2028 2029 Change interface: make 2nd param _space_-separated, not comma-separated 2030 * m4/include-exclude-prog.m4 (gl_INCLUDE_EXCLUDE_PROG): Remove now- 2031 unnecessary use of tr. 2032 Improve comments. 2033 * configure.ac: Adjust caller, as well as the code that ensures the 2034 2nd parameter stays in sync with the list in src/Makefile.am. 2035 20362007-07-14 Karel Zak <kzak@redhat.com> 2037 2038 * m4/include-exclude-prog.m4 (gl_REMOVE_PROG): Fix typo: s/$2/$1/. 2039 (gl_INCLUDE_EXCLUDE_PROG): Quote first use of $2 parameter. 2040 Don't mix comma- and space-separated lists. 2041 Patch from Karel Zak. 2042 20432007-07-13 Jim Meyering <jim@meyering.net> 2044 2045 Warn about non-portable use of unescaped backslash at end of string, 2046 and treat it as if it were escaped. 2047 * src/tr.c (unquote): Considering that such usage would make GNU tr 2048 from coreutils-5.2.1 and earlier *fail*, the least we can do now is 2049 to warn about it. Solaris' tr ignores it. 2050 * NEWS: Mention this. 2051 2052 Use proper backslash-quoting inside backticks. 2053 * configure.ac: Otherwise we run afoul of strict GNU tr: 2054 a string ending in a lone backslash would provoke a failure. 2055 20562007-07-12 Jim Meyering <jim@meyering.net> 2057 2058 Expand default-no-install prog list in ./configure --help output, 2059 and fix some []-quoting bugs in sed expressions. 2060 * configure.ac: Hard-code the list, "arch,su" here as well 2061 as in src/Makefile.am, and ensure the two stay in sync. 2062 * m4/include-exclude-prog.m4 (gl_INCLUDE_EXCLUDE_PROG): Use $2, 2063 rather than the nearly-equivalent shell variable. 2064 Karel Zak reported that ./configure --help's output included 2065 the literal string, $gl_no_install_progs_default. 2066 2067 Clean up include-exclude-prog.m4. 2068 * m4/include-exclude-prog.m4 (gl_ADD_PROG): Don't modify MAN. 2069 (gl_REMOVE_PROG): Likewise. 2070 Add omitted "\>" in sed regexp. 2071 Remove any leading or trailing spaces. 2072 (gl_ADD_PROG): Remove any leading space. 2073 * configure.ac: Instead, derive $MAN from $optional_bin_progs. 2074 Append $(EXEEXT) to *all* names, not just the first one. 2075 20762007-07-11 Jim Meyering <jim@meyering.net> 2077 2078 If there's a GPL vN copyright comment, require that N == 3. 2079 * Makefile.maint (sc_GPL_version): New rule. 2080 * tests/misc/arch: Fix the sole violation. 2081 20822007-07-10 Jim Meyering <jim@meyering.net> 2083 2084 Skip "arch" test if it's not built. 2085 * tests/misc/Makefile.am (built_programs): Define. 2086 (TESTS_ENVIRONMENT): Add $(built_programs), for... 2087 * tests/misc/arch: ...this: skip the test if arch is not built. 2088 * src/Makefile.am (built_programs.list): New rule. 2089 * tests/Makefile.am (built_programs): Rename from all_programs. 2090 (TESTS_ENVIRONMENT): Use built_programs, not all_programs. 2091 * tests/help-version: Likewise. 2092 * NEWS: Mention that using --enable-no-install-program=X may 2093 cause "make check" to fail. 2094 2095 Add support for enabling/disabling installation of specified programs. 2096 * NEWS: Mention new configure-time options. 2097 Mention that neither arch nor su is built/installed, by default. 2098 * m4/include-exclude-prog.m4: New file. 2099 * configure.ac: Use new macro, gl_ADD_PROG, rather than 2100 manually appending to OPTIONAL_BIN_PROGS and MAN. 2101 Move the code that adds "df" to the list of programs to build from 2102 m4/jm-macros into this file. 2103 Use gl_INCLUDE_EXCLUDE_PROG, then handle special cases: ginstall, [. 2104 (NO_INSTALL_PROGS_DEFAULT): AC_SUBST it. Used by man/Makefile.am. 2105 * man/Makefile.am (dist_man_MANS): Remove from this list all man pages 2106 corresponding to "bin" programs. Add $(MAN) instead. 2107 (optional_mans): Remove all uses. 2108 (check-x-vs-1): Adapt to work even though arch and su are typically 2109 no longer built (and neither are their .1 files). 2110 * src/Makefile.am (install_su): Rename from INSTALL_SU, now that 2111 INSTALL_SU has a different meaning. Use the new $(INSTALL_SU) value. 2112 21132007-07-10 Karel Zak <kzak@redhat.com> 2114 2115 New program: arch 2116 * NEWS: Mention arch. 2117 * README: Add arch to the list of programs. 2118 * AUTHORS: Add arch. 2119 * src/uname.c: Include "uname.h". 2120 (PROGRAM_NAME): Handle arch, too. 2121 (ARCH_AUTHORS): Define. 2122 (uname_long_options, arch_long_options): Renamed and new globals. 2123 (usage): Handle arch-mode as well as uname-mode. 2124 (decode_switches): New function, extracted from main, 2125 to handle arch-mode as well as uname-mode. 2126 (main): Handle both modes. 2127 * src/uname-arch.c: New program, alias for "uname -m". 2128 * src/uname-uname.c: New file, default uname mode. 2129 * src/uname.h: New file, uname modes. 2130 * src/Makefile.am (EXTRA_PROGRAMS): Add arch. 2131 (uname_SOURCES, arch_SOURCES): Define. 2132 * man/arch.x: New file. 2133 * man/Makefile.am (dist_man_MANS): Add arch.1. 2134 (arch.1): New dependency. 2135 * tests/misc/arch: New test, compare "arch" with "uname -m" 2136 * configure.ac (OPTIONAL_BIN_PROGS): Add arch. 2137 (MAN): Add arch.1. 2138 * .x-sc_require_config_h: Exempt uname-arch.c and uname-uname.c 2139 from the always-include-<config.h> rule. 2140 21412007-07-10 Jim Meyering <jim@meyering.net> 2142 2143 Change "version 2" to "version 3" in all copyright notices. 2144 21452007-07-09 Jim Meyering <jim@meyering.net> 2146 2147 Compensate for new c99'isms in seq.c. 2148 * Makefile.maint (patch-check): Use -p1, not -p2, so a patch 2149 generated via "make patch-check REGEN=1" actually works. 2150 * src/c99-to-c89.diff: Handle new c99'isms in seq.c. 2151 21522007-07-09 P��draig Brady <P@draigBrady.com> 2153 2154 Fix the automatic number width formatting in seq. 2155 * src/seq.c: Fix the -w logic. Ignore spaces and '+' 2156 characters of input numbers when determining width. 2157 Set format correctly for input numbers in scientific notation. 2158 * tests/seq/basic: Add various number width tests. 2159 Details: <http://thread.gmane.org/gmane.comp.gnu.coreutils.bugs/10903> 2160 21612007-07-08 Jim Meyering <jim@meyering.net> 2162 2163 Run the coreutils-specific code only if tests/Makefile.am.in exists. 2164 * bootstrap (mam_template): Move definition out of loop. 2165 2166 Create symlinks for gl/{lib,m4}/*, just as for gnulib/{lib,m4}/*. 2167 * bootstrap (symlink_to_dir): Rename function from symlink_to_gnulib. 2168 Add a directory parameter. Update all callers. 2169 (cp_mark_as_generated): Also check for -- and link to -- files in gl/. 2170 2171 * THANKS: Add P��draig Brady. 2172 21732007-07-08 Jim Meyering <jim@meyering.net> 2174 2175 Adapt to deeper hierarchy in gnulib. 2176 * bootstrap (symlink_to_dir): If the destination directory doesn't 2177 exist, create it. This is required at least for "lib/uniwidth/cjk.h". 2178 2179 Use <wchar.h>, not "wcwidth.h". 2180 * src/wc.c: Now that gnulib provides the POSIX-specified <wchar.h>, 2181 include it and <wctype.h>, rather than "wcwidth.h". 2182 * src/ls.c: Include <wchar.h>, rather than "wcwidth.h". 2183 21842007-07-05 Jim Meyering <jim@meyering.net> 2185 2186 setuidgid: set all groups, not just the primary one. 2187 I wanted to use the xgetgroups function from id.c, so factored 2188 it out and made it into a non-exiting function (hence the "m" 2189 prefix rather than "x"). 2190 * src/setuidgid.c (main): Use mgetgroups. 2191 Include "mgetgroups.h". 2192 2193 * src/id.c (xgetgroups): Remove function. 2194 Include "mgetgroups.h". 2195 (print_group_list): Use mgetgroups, not xgetgroups. 2196 2197 * gl/modules/mgetgroups: New module. 2198 * gl/lib/mgetgroups.c: New file. mgetgroups is derived from 2199 id.c's xgetgroups function. 2200 * bootstrap.conf (gnulib_modules): Add mgetgroups. 2201 * gl/m4/mgetgroups.m4: New file. 2202 * gl/lib/mgetgroups.h: New file. 2203 2204 * bootstrap: Merge in changes from gnulib. 2205 2206 * src/id.c: Include "getugroups.h" rather than declaring manually. 2207 22082007-07-04 Paul Eggert <eggert@cs.ucla.edu> 2209 2210 * NEWS: pr -F no longer suppresses the footer or the first two blank 2211 lines in the header. 2212 * doc/coreutils.texi (pr invocation): Likewise. Also, a too-short 2213 page length implies -t, not -T. 2214 * src/pr.c (lines_per_header, lines_per_footer): Now constants. 2215 (init_parameters): Don't try to change them. 2216 (print_header): Use the same header and footer format regardless of 2217 wither form feeds are being used. 2218 (usage): Adjust to above change when describing too-short page length. 2219 Too-short page length impliesy -t, not -T. 2220 * tests/pr/2-S_f-t_notab: Adjust to the fact that -F now affects 2221 only formfeed handling; it does not change the header. 2222 * tests/pr/2-Sf-t_notab: Likewise. 2223 * tests/pr/2f-t_notab: Likewise. 2224 * tests/pr/2s_f-t_notab: Likewise. 2225 * tests/pr/2s_w60f-t_nota: Likewise. 2226 * tests/pr/2sf-t_notab: Likewise. 2227 * tests/pr/2sw60f-t_notab: Likewise. 2228 * tests/pr/2w60f-t_notab: Likewise. 2229 * tests/pr/3a3f-0F: Likewise. 2230 * tests/pr/3b3f-0F: Likewise. 2231 * tests/pr/3b3f-0FF: Likewise. 2232 * tests/pr/3b3f-FF: Likewise. 2233 * tests/pr/3f-0F: Likewise. 2234 * tests/pr/3f-FF: Likewise. 2235 * tests/pr/Test.pm: Likewise. 2236 * tests/pr/a3f-0F: Likewise. 2237 * tests/pr/a3f-0FF: Likewise. 2238 * tests/pr/a3f-FF: Likewise. 2239 * tests/pr/b3f-0F: Likewise. 2240 * tests/pr/b3f-0FF: Likewise. 2241 * tests/pr/b3f-FF: Likewise. 2242 * tests/pr/3-5l17f-t: Remove, since it's been renamed to another 2243 file whose name has a line count 7 larger, 2244 reflecting the new line count needed for this behavior. 2245 * tests/pr/3a3l8f-t: Likewise. 2246 * tests/pr/3b3l8f-t: Likewise. 2247 * tests/pr/3l17f-t: Likewise. 2248 * tests/pr/3ml17f-t: Likewise. 2249 * tests/pr/Ja3l17f-lm: Likewise. 2250 * tests/pr/Jb3l17f-lm: Likewise. 2251 * tests/pr/Jml17f-lm-lo: Likewise. 2252 * tests/pr/W-72l17f-ll: Likewise. 2253 * tests/pr/W20l17f-ll: Likewise. 2254 * tests/pr/W26l17f-ll: Likewise. 2255 * tests/pr/W27l17f-ll: Likewise. 2256 * tests/pr/W28l17f-ll: Likewise. 2257 * tests/pr/W35Ja3l17f-lm: Likewise. 2258 * tests/pr/W35Jb3l17f-lm: Likewise. 2259 * tests/pr/W35Jml17f-lmlo: Likewise. 2260 * tests/pr/W35a3l17f-lm: Likewise. 2261 * tests/pr/W35b3l17f-lm: Likewise. 2262 * tests/pr/W35ml17f-lm-lo: Likewise. 2263 * tests/pr/W72Jl17f-ll: Likewise. 2264 * tests/pr/a3l17f-lm: Likewise. 2265 * tests/pr/a3l8f-t: Likewise. 2266 * tests/pr/b3l17f-lm: Likewise. 2267 * tests/pr/b3l8f-t: Likewise. 2268 * tests/pr/l17f-t: Likewise. 2269 * tests/pr/ml17f-0F: Likewise. 2270 * tests/pr/ml17f-lm-lo: Likewise. 2271 * tests/pr/ml17f-t: Likewise. 2272 * tests/pr/ml17f-t-0F: Likewise. 2273 * tests/pr/n+2-5l17f-0FF: Likewise. 2274 * tests/pr/n+2l17f-0FF: Likewise. 2275 * tests/pr/n+2l17f-bl: Likewise. 2276 * tests/pr/n+3l17f-0FF: Likewise. 2277 * tests/pr/n+3l17f-bl: Likewise. 2278 * tests/pr/n+3ml13f-bl-FF: Likewise. 2279 * tests/pr/n+3ml17f-bl-tn: Likewise. 2280 * tests/pr/n+3ml17f-tn-bl: Likewise. 2281 * tests/pr/n+4b2l10f-0FF: Likewise. 2282 * tests/pr/n+5-8b3l10f-FF: Likewise. 2283 * tests/pr/n+5a3l6f-0FF: Likewise. 2284 * tests/pr/n+6b3l6f-FF: Likewise. 2285 * tests/pr/nJml17f-lmlmlo: Likewise. 2286 * tests/pr/nJml17f-lmlolm: Likewise. 2287 * tests/pr/nN1+3l17f-bl: Likewise. 2288 * tests/pr/nN15l17f-bl: Likewise. 2289 * tests/pr/nSml13-bl-FF: Likewise. 2290 * tests/pr/nSml13-t-t-FF: Likewise. 2291 * tests/pr/nSml13-t-tFFFF: Likewise. 2292 * tests/pr/nSml17-bl-FF: Likewise. 2293 * tests/pr/nSml17-t-t-FF: Likewise. 2294 * tests/pr/nSml17-t-tFFFF: Likewise. 2295 * tests/pr/nl17f-bl: Likewise. 2296 * tests/pr/o3Jml17f-lm-lo: Likewise. 2297 * tests/pr/o3a3Sl17f-tn: Likewise. 2298 * tests/pr/o3a3Snl17f-tn: Likewise. 2299 * tests/pr/o3a3l17f-tn: Likewise. 2300 * tests/pr/o3b3Sl17f-tn: Likewise. 2301 * tests/pr/o3b3Snl17f-tn: Likewise. 2302 * tests/pr/o3b3l17f-tn: Likewise. 2303 * tests/pr/o3mSl17f-bl-tn: Likewise. 2304 * tests/pr/o3mSnl17fbltn: Likewise. 2305 * tests/pr/o3ml17f-bl-tn: Likewise. 2306 * tests/pr/w72l17f-ll: Likewise. 2307 * tests/pr/3-5l24f-t: New file, containing the contents of the 2308 file with the same name but with the line count smaller by 7, 2309 reflecting the new behavior with -F. 2310 * tests/pr/3a3l15f-t: Likewise. 2311 * tests/pr/3b3l15f-t: Likewise. 2312 * tests/pr/3l24f-t: Likewise. 2313 * tests/pr/3ml24f-t: Likewise. 2314 * tests/pr/Ja3l24f-lm: Likewise. 2315 * tests/pr/Jb3l24f-lm: Likewise. 2316 * tests/pr/Jml24f-lm-lo: Likewise. 2317 * tests/pr/W-72l24f-ll: Likewise. 2318 * tests/pr/W20l24f-ll: Likewise. 2319 * tests/pr/W26l24f-ll: Likewise. 2320 * tests/pr/W27l24f-ll: Likewise. 2321 * tests/pr/W28l24f-ll: Likewise. 2322 * tests/pr/W35Ja3l24f-lm: Likewise. 2323 * tests/pr/W35Jb3l24f-lm: Likewise. 2324 * tests/pr/W35Jml24f-lmlo: Likewise. 2325 * tests/pr/W35a3l24f-lm: Likewise. 2326 * tests/pr/W35b3l24f-lm: Likewise. 2327 * tests/pr/W35ml24f-lm-lo: Likewise. 2328 * tests/pr/W72Jl24f-ll: Likewise. 2329 * tests/pr/a3l15f-t: Likewise. 2330 * tests/pr/a3l24f-lm: Likewise. 2331 * tests/pr/b3l15f-t: Likewise. 2332 * tests/pr/b3l24f-lm: Likewise. 2333 * tests/pr/l24f-t: Likewise. 2334 * tests/pr/ml24f-0F: Likewise. 2335 * tests/pr/ml24f-lm-lo: Likewise. 2336 * tests/pr/ml24f-t: Likewise. 2337 * tests/pr/ml24f-t-0F: Likewise. 2338 * tests/pr/n+2-5l24f-0FF: Likewise. 2339 * tests/pr/n+2l24f-0FF: Likewise. 2340 * tests/pr/n+2l24f-bl: Likewise. 2341 * tests/pr/n+3l24f-0FF: Likewise. 2342 * tests/pr/n+3l24f-bl: Likewise. 2343 * tests/pr/n+3ml20f-bl-FF: Likewise. 2344 * tests/pr/n+3ml24f-bl-tn: Likewise. 2345 * tests/pr/n+3ml24f-tn-bl: Likewise. 2346 * tests/pr/n+4b2l17f-0FF: Likewise. 2347 * tests/pr/n+5-8b3l17f-FF: Likewise. 2348 * tests/pr/n+5a3l13f-0FF: Likewise. 2349 * tests/pr/n+6b3l13f-FF: Likewise. 2350 * tests/pr/nJml24f-lmlmlo: Likewise. 2351 * tests/pr/nJml24f-lmlolm: Likewise. 2352 * tests/pr/nN1+3l24f-bl: Likewise. 2353 * tests/pr/nN15l24f-bl: Likewise. 2354 * tests/pr/nSml20-bl-FF: Likewise. 2355 * tests/pr/nSml20-t-t-FF: Likewise. 2356 * tests/pr/nSml20-t-tFFFF: Likewise. 2357 * tests/pr/nSml24-bl-FF: Likewise. 2358 * tests/pr/nSml24-t-t-FF: Likewise. 2359 * tests/pr/nSml24-t-tFFFF: Likewise. 2360 * tests/pr/nl24f-bl: Likewise. 2361 * tests/pr/o3Jml24f-lm-lo: Likewise. 2362 * tests/pr/o3a3Sl24f-tn: Likewise. 2363 * tests/pr/o3a3Snl24f-tn: Likewise. 2364 * tests/pr/o3a3l24f-tn: Likewise. 2365 * tests/pr/o3b3Sl24f-tn: Likewise. 2366 * tests/pr/o3b3Snl24f-tn: Likewise. 2367 * tests/pr/o3b3l24f-tn: Likewise. 2368 * tests/pr/o3mSl24f-bl-tn: Likewise. 2369 * tests/pr/o3mSnl24fbltn: Likewise. 2370 * tests/pr/o3ml24f-bl-tn: Likewise. 2371 * tests/pr/w72l24f-ll: Likewise. 2372 23732007-06-23 Jim Meyering <jim@meyering.net> 2374 2375 Prefer "STREQ (a, b)" over "strcmp (a, b) == 0"; similar for != 0. 2376 * src/base64.c (main): Likewise. 2377 * src/install.c (setdefaultfilecon): Likewise. 2378 * src/sort.c (main): Likewise. 2379 * Makefile.maint (sc_prohibit_strcmp): New rule. 2380 * .x-sc_prohibit_strcmp: New file, to list the few exceptions. 2381 * Makefile.am (EXTRA_DIST): Add .x-sc_prohibit_strcmp. 2382 23832007-06-22 Paul Eggert <eggert@cs.ucla.edu> 2384 2385 * NEWS: seq no longer mishandles obvious cases like 2386 "seq 0 0.000001 0.000003" by omitting the last output number. 2387 * doc/coreutils.texi (seq invocation): Remove advice about workaround 2388 for seq off-by-one problem, since the bug is fixed now. Replace 2389 it with more-generic advice about rounding errors. 2390 * src/seq.c (long_double_format, print_numbers): 2391 New arg NUMERIC_FORMAT. All uses changed. 2392 23932007-06-22 P��draig Brady <P@draigBrady.com> (trivial change) 2394 2395 * tests/seq/basic: Add test cases for seq off-by-one problem. 2396 23972007-06-22 Jim Meyering <jim@meyering.net> 2398 2399 * src/stat.c (long_options): Add a FIXME comment to help ensure 2400 that the deprecated and undocumented "--filesystem" option is 2401 removed someday. 2402 24032007-06-18 Paul Eggert <eggert@cs.ucla.edu> 2404 2405 A few more symlink-related fixes. Fix a bug triggered by cp 2406 --parents and symlinks. Close some race conditions possible when 2407 the destination replaces a newly-created file with a symlink. 2408 * NEWS: Document that 'cp --parents' no longer mishandles 2409 symlinks in file name components of source. 2410 * src/copy.c (HAVE_LCHOWN): Default to false. 2411 (lchown) [!defined HAVE_LCHOWN]: Define to chown, for convenience. 2412 * src/cp.c (lchown) [!HAVE_LCHOWN]: Likewise. 2413 * src/install.c (lchown [!HAVE_LCHOWN]: Likewise. 2414 * src/copy.c (set_owner): Use lchown instead of chown, for safety 2415 in case the file got replaced by a symlink in the meantime. 2416 * src/cp.c (re_protect): Likewise. 2417 * src/install.c (change_attributes): Likewise. 2418 * src/copy.c (copy_internal): Use ordinary C rather than an #if. 2419 * src/cp.c (lchown) [!HAVE_LCHOWN]: Define to chown, for convenience. 2420 (struct dir_attr): Cache the entire struct stat of the directory, 2421 rather than just its mode, so that we needn't stat the directory 2422 twice (which can lead to races). 2423 (re_protect): Don't use XSTAT as that's not appropriate in 2424 this context (symlinks should be followed here). Instead, use 2425 the cached stat value. 2426 (make_dir_parents_private): Save dir's entire struct stat, not 2427 just its mode. 2428 * tests/cp/cp-parents: Add test to check against bug with 2429 cp --parents and symlinks. 2430 24312007-06-18 Jim Meyering <jim@meyering.net> 2432 2433 Use mreadlink_with_size (doesn't exit), not xreadlink_with_size. 2434 * bootstrap.conf (gnulib_modules): Add readlink-with-size. 2435 Remove xreadlink and xreadlink-with-size. 2436 * src/copy.c (copy_internal): Use mreadlink_with_size, 2437 not xreadlink_with_size. 2438 * src/ls.c (get_link_name): Likewise. 2439 * src/readlink.c (main): Likewise. 2440 * src/stat.c (print_stat): Likewise. 2441 2442 * README-hacking: Don't mention Gzip 1.2.4, now that 1.3.12 is out. 2443 24442007-06-16 Jim Meyering <jim@meyering.net> 2445 2446 Make chgrp and chown diagnostics consistent. 2447 * src/chown.c (main): Emit the diagnostic before the file name, 2448 not after it, to be consistent with chgrp's diagnostic. 2449 * src/chgrp.c (parse_group): Emit a ":" between the diagnostic 2450 and the file name. 2451 Reported by Egmont Koblinger. 2452 * THANKS: Add Egmont Koblinger. 2453 24542007-06-15 Paul Eggert <eggert@cs.ucla.edu> 2455 2456 Correct cp's handling of destination symlinks in some cases. 2457 * NEWS: "cp" no longer considers a destination symlink to be the 2458 same as the referenced file when copying links or making backups. 2459 * src/copy.c (copy_reg): When following a symlink, use the 2460 followed name in later chown etc. requests, so that the created 2461 file is affected, rather than the symlink. Use O_NOFOLLOW on 2462 source when not dereferencing symlinks; this avoids a race. 2463 Preserve errno correctly when doing multiple open attempts on the 2464 destination. 2465 (copy_internal): Follow destination symlinks only when copying a 2466 regular file and only when we don't intend to remove or rename the 2467 destination first, regardless of whether following source 2468 symlinks; this is because since POSIX and tradition (e.g., 2469 FreeBSD) say we should ordinarily follow destination symlinks if 2470 the system calls would ordinarily do so. 2471 * src/copy.h (struct cp_options): Add comment that 'dereference' 2472 is only for source files. 2473 * src/cp.c (usage): Note that --derereference etc. are only for 2474 source files. 2475 (make_dir_parents_private): Follow symlinks, regardless of whether 2476 --dereference is specified, because these are destination symlinks. 2477 * tests/cp/same-file: Adjust tests to match revised behavior. 2478 Filter out perror output since it might vary from host to host. 2479 Use sed alone instead of also using echo. 2480 2481 * doc/coreutils.texi (cp invocation): Document the behavior better when 2482 the destination is a symlink. Clarify source versus destination 2483 symlinks. Describe the new behavior for destination symlinks. 2484 24852007-06-15 Jim Meyering <jim@meyering.net> 2486 2487 * src/copy.c: Include "canonicalize.h". 2488 (copy_reg): Use canonicalize_filename_mode to follow the symlink, 2489 so that we can always open with O_EXCL and avoid a race. 2490 24912007-06-15 Jim Meyering <jim@meyering.net> 2492 2493 Don't include "quote.h" when it is not used. 2494 * src/md5sum.c: Remove unnecessary inclusion of "quote.h". 2495 * src/expr.c: Likewise. 2496 * src/shred.c: Likewise. 2497 * Makefile.maint (sc_prohibit_quote_without_use): New rule. 2498 * src/c99-to-c89.diff: Adjust offsets. 2499 25002007-06-14 Paul Eggert <eggert@cs.ucla.edu> 2501 2502 Clarify what "cat" documentation means by "blank" lines. 2503 * doc/coreutils.texi (cat invocation): "Blank" lines actually mean 2504 empty lines. 2505 * src/cat.c (usage): Say that "nonblank" means nonempty. Clarify 2506 --squeeze-blank. 2507 25082007-06-13 Jim Meyering <jim@meyering.net> 2509 2510 rmdir: give better diagnostics 2511 * src/rmdir.c (remove_parents): Give a more descriptive/consistent 2512 diagnostic upon failure. 2513 (main): Likewise. 2514 Suggestion from Joey Hess. 2515 * THANKS: Add Joey Hess. 2516 2517 Don't include "quotearg.h" when it is not used. 2518 * Makefile.maint (sc_prohibit_quotearg_without_use): New rule. 2519 * src/cp.c: Don't include "quotearg.h". It wasn't used. 2520 2521 * README-hacking: List Gperf as a build-requirement, too. 2522 Reported by Steve Ward. 2523 25242007-06-11 Jim Meyering <jim@meyering.net> 2525 2526 * README: Mention README-hacking, for whose who start from 2527 cloned/checked-out sources rather than from a distribution tarball. 2528 Reported by Steve Ward. 2529 * THANKS: Add Steve Ward. 2530 25312007-06-10 Jim Meyering <jim@meyering.net> 2532 2533 bug-fix: cp would fail to write through a dangling symlink 2534 * NEWS: Mention the bug fix. 2535 * src/copy.c (copy_reg): When open fails with EEXIST, the destination 2536 is lstat'able, and a symlink, call open again, but now without O_EXCL. 2537 * tests/cp/thru-dangling: New file, to test for the above fix. 2538 * tests/cp/Makefile.am (TESTS): Add thru-dangling. 2539 * THANKS: Add Michael McLagan. 2540 Bug report from Michael McLagan in <http://bugzilla.redhat.com/243588>. 2541 25422007-06-04 Paul Eggert <eggert@cs.ucla.edu> 2543 2544 * doc/coreutils.texi (Common options): Mention that -h and 2545 --human-readable are equivalent to --block-size=human-readable. 2546 Documentation problem reported by Steve Ward in 2547 <http://lists.gnu.org/archive/html/bug-coreutils/2007-06/msg00007.html>. 2548 (du invocation): Use optSi rather than duplicating the macro's 2549 contents (incorrectly, since we claimed a "B" was output). 2550 25512007-05-31 Jim Meyering <jim@meyering.net> 2552 2553 Pull printf-related code from gnulib, rather than using forked copy. 2554 * bootstrap.conf (gnulib_modules): Don't avoid size_max and xsize 2555 modules. While I dislike xsize-style overflow avoidance, maintaining 2556 a forked version of e.g., vasnprintf.c was too much work. 2557 25582007-05-29 Jim Meyering <jim@meyering.net> 2559 2560 * src/dircolors.hin: Add screen-256color. 2561 Suggested by sdl.web@gmail.com in <http://bugzilla.redhat.com/239266>. 2562 25632007-05-26 Jim Meyering <jim@meyering.net> 2564 2565 * TODO: Add an entry for comm --output-delimiter=STR 2566 25672007-05-25 James Youngman <jay@gnu.org> 2568 2569 wc: ignore multibyte-character decoding errors 2570 * src/wc.c (wc): Don't issue an error message when mbrtowc 2571 indicates that we have seen an invalid byte sequence. This 2572 makes "wc /bin/sh" bearable (though the word and line counts 2573 are likely not to be useful). 2574 * NEWS: Mention the change. 2575 25762007-05-22 Jim Meyering <jim@meyering.net> 2577 2578 Check for an up-to-date copyright year in coreutils.texi. 2579 * Makefile.maint (copyright-check): Also check for an up-to-date 2580 copyright year in doc/$().texi, if that file exists. 2581 * doc/coreutils.texi: Add 2007 to list of Copyright years. 2582 Reported by Karl Berry. 2583 2584 cut: diagnose a range starting with 0 (-f 0-2) as invalid, and 2585 give a better diagnostic for a field-number/offset of 0. 2586 * NEWS: Mention the fix. 2587 * src/cut.c (ADD_RANGE_PAIR): Add an explicit check. 2588 Based on a patch from James Youngman. 2589 * tests/misc/cut: Add tests for the above. 2590 2591 "cut -f 2-0" now fails; before, it was equivalent to "cut -f 2-" 2592 Also, diagnose the '-' in "cut -f -" as an invalid range, rather 2593 than interpreting it as the unlimited range, "1-". 2594 * NEWS: Mention these changes. 2595 * src/cut.c (set_fields): Don't interpret an accumulator "value" 2596 of 0 as an unspecified range endpoint. 2597 Give better diagnostics. 2598 Adjust a comment so that it is true also for 64-bit size_t. 2599 2600 * tests/cut/Test.pm: Add tests for the above. 2601 2602 stty: fix a harmless syntax nit 2603 * src/stty.c (visible): Use ";" as the statement terminator 2604 between two assignments, not ",". 2605 (integer_arg): Join an unnecessarily wrapped line. 2606 26072007-05-20 Jim Meyering <jim@meyering.net> 2608 2609 stty: diagnose an invalid hex value in 35-colon command-line argument 2610 * NEWS: Mention this. 2611 * src/stty.c (strtoul_tcflag_t, strtoul_cc_t): New functions. 2612 (recover_mode): Use those functions (not sscanf), to parse the 2613 string robustly. 2614 * tests/stty/invalid: New file. Test for the above. 2615 * tests/stty/Makefile.am (TESTS): Add invalid. 2616 * .x-sc_prohibit_atoi_atof: Don't exempt stty.c from this check. 2617 Add tests/stty/invalid so we don't have to obfuscate the comment 2618 about sscanf therein. 2619 * Makefile.maint (sc_prohibit_atoi_atof): Mention sscanf in the 2620 diagnostic, too. 2621 2622 * TODO: Remove some now-completed or no longer relevant items. 2623 26242007-05-19 Jim Meyering <jim@meyering.net> 2625 2626 Rename uses of futimens -> gl_futimens; glibc now declares the former. 2627 * src/copy.c (copy_reg): Reflect renaming: futimens -> gl_futimens. 2628 * src/touch.c (touch): Likewise. 2629 26302007-05-18 Jim Meyering <jim@meyering.net> 2631 2632 * Makefile.maint (my-distcheck): Remove -pedantic from $(CFLAGS) 2633 for now, to avoid c89-check failure due to use of #include_next. 2634 26352007-05-15 Jim Meyering <jim@meyering.net> 2636 2637 Generate a dozen test-related Makefile.am files at bootstrap-time. 2638 * README-hacking: Build-from-checkout now require Perl, too. 2639 * bootstrap: Now that these generated Makefile.am files are no longer 2640 under version control, they must be created at bootstrap time. 2641 26422007-05-14 Paul Eggert <eggert@cs.ucla.edu> 2643 2644 * man/chmod.x: Document chmod's behavior with setuid and setgid bits. 2645 Remove misleading implication about leading zero. Problem 2646 reported by Jan Engelhardt in 2647 <http://lists.gnu.org/archive/html/bug-coreutils/2007-05/msg00134.html>. 2648 26492007-05-13 Jim Meyering <jim@meyering.net> 2650 2651 Remove the generated tests/*/Makefile.am files from version control. 2652 * tests/cut/Makefile.am: git-remove this generated file. 2653 * tests/head/Makefile.am: Likewise. 2654 * tests/join/Makefile.am: Likewise. 2655 * tests/pr/Makefile.am: Likewise. 2656 * tests/sort/Makefile.am: Likewise. 2657 * tests/tac/Makefile.am: Likewise. 2658 * tests/tail/Makefile.am: Likewise. 2659 * tests/test/Makefile.am: Likewise. 2660 * tests/tr/Makefile.am: Likewise. 2661 * tests/uniq/Makefile.am: Likewise. 2662 * tests/wc/Makefile.am: Likewise. 2663 * .cvsignore, .gitignore: Ignore these generated files. 2664 2665 * src/.cvsignore, src/.gitignore: Add chcon here, ... 2666 * .cvsignore, .gitignore: ... not here. 2667 2668 Test uniq's new --zero-terminated (-z) option. 2669 * tests/uniq/Test.pm: When possible, create a "-z"-testing variant 2670 of each existing test. 2671 (2z, 3z, 4z, 5z, 20z, 122, 123): New tests from James Youngman. 2672 26732007-05-12 James Youngman <jay@gnu.org> 2674 2675 Add -z option to uniq. Originally proposed by Egmont Koblinger. 2676 * NEWS: Mention uniq's new option: --zero-terminated (-z). 2677 * src/uniq.c: Add new option, --zero-terminated (-z), to make 2678 uniq use the NUL byte as separator/delimiter rather than newline. 2679 (check_file): Add a parameter: delimiter. Update caller. 2680 Use readlinebuffer_delim in place of readlinebuffer everywhere. 2681 (main): Handle the new option. 2682 (usage): Describe new option the same way sort does. 2683 * doc/coreutils.texi (uniq invocation): Describe the new option. 2684 26852007-05-07 Jim Meyering <jim@meyering.net> 2686 2687 * NEWS: Mention that last week's tr bug dates back to 1992. 2688 26892007-05-04 Jim Meyering <jim@meyering.net> 2690 2691 Avoid test failure when run with an unusual umask. 2692 * tests/ls/color-dtype-dir: Set umask to 022. 2693 Suggestion from AIDA Shinra. 2694 2695 Avoid failure of root-only test when run with a restrictive umask. 2696 * tests/rm/no-give-up: Ensure that non-root can access "d/" through 2697 root-owned ".". Reported by AIDA Shinra. 2698 2699 tr -c: don't abort when translating with S2 larger than complement of S1 2700 * src/tr.c (main): Remove invalid assertion triggered by e.g., 2701 tr -c a '[b*256]'. There's nothing wrong with having Set2 larger 2702 than Set1. Reported by Guntram Blohm. 2703 * tests/tr/Test.pm (no-abort-1): Test for the above. 2704 * NEWS: Mention this bug fix. 2705 * THANKS: Add Guntram Blohm. 2706 27072007-05-03 Jim Meyering <jim@meyering.net> 2708 2709 Avoid test failure when run with a permissive umask. 2710 * tests/rm/no-give-up: Set permissions of test directory properly, 2711 i.e., not depending on umask prohibiting go=w. 2712 Reported by AIDA Shinra. 2713 27142007-05-02 Paul Eggert <eggert@cs.ucla.edu> 2715 2716 The following commands and options now support the standard size 2717 suffixes kB, M, MB, G, GB, and so on for T, P, Y, Z, and Y: 2718 head -c, head -n, od -j, od -N, od -S, split -b, split -C, 2719 tail -c, tail -n. 2720 * doc/coreutils.texi (od invocation, head invocation, tail invocation): 2721 Document support for new size suffixes. 2722 (head invocation, tail invocation): 2723 Document that -n uses the same suffixes as -c. 2724 (tail invocation): More-clearly document what leading "+" does. 2725 * src/head.c (usage, string_to_integer): Support new suffixes. 2726 * src/od.c (usage, main): Likewise. 2727 * src/split.c (usage, main): Likewise. 2728 * src/tail.c (usage, parse_options): Likewise. 2729 Prompted by a patch from Evan Hunt. 2730 27312007-05-02 Jim Meyering <jim@meyering.net> 2732 2733 * src/du.c (usage): Tweak description of --dereference-args (-D) again. 2734 Prompted by another request for clarification from Justin Pryzby. 2735 2736 Invoke rm via 'setuidgid ... env PATH="$PATH" ...', as in fail-eperm. 2737 * tests/rm/fail-2eperm: Patch from AIDA Shinra. 2738 Reported by Peter Dyballa. 2739 * THANKS: Add AIDA Shinra and Peter Dyballa. 2740 27412007-04-28 Paul Eggert <eggert@cs.ucla.edu> 2742 2743 * src/nohup.c (usage): Describe how standard input and output 2744 are redirected. 2745 27462007-04-25 Jim Meyering <jim@meyering.net> 2747 2748 * src/du.c (usage): Clarify description of --dereference-args (-D). 2749 Prompted by a report from Justin Pryzby. 2750 2751 * bootstrap.conf (gnulib_modules): Add fseeko and ftello. 2752 (gnulib_modules): Add autobuild. 2753 27542007-04-24 Jim Meyering <jim@meyering.net> 2755 2756 * THANKS: Add Andreas Frische. 2757 * NEWS: Mention today's ls --color fix. 2758 * tests/ls-2/tests (sl-dangle): Add a test for today's fix. 2759 27602007-04-24 Eric Blake <ebb9@byu.net> 2761 2762 ls --color once again colors dangling symlinks correctly 2763 * src/ls.c (gobble_file): Much like the 2007-04-07 fix, 2764 add a term to the expression that decides whether we need 2765 stat and/or lstat calls. Reported by Andreas Frische. 2766 27672007-04-16 Jim Meyering <jim@meyering.net> 2768 2769 * src/cut.c (usage): Adjust synopsis to show that an OPTION is required. 2770 Reported by Rudolf Kastl. 2771 * THANKS: Add Rudolf Kastl. 2772 27732007-04-11 Paul Eggert <eggert@cs.ucla.edu> 2774 2775 split --line-bytes=N (-C N): don't create an empty file. 2776 * src/split.c (line_bytes_split): Don't create an empty line 2777 afterwards if the last buffer happens to be exactly full. 2778 * tests/misc/split-fail: Add a test case for this. 2779 * NEWS: mention this. 2780 27812007-04-10 Jim Meyering <jim@meyering.net> 2782 2783 ls: don't form or compute the length of strings that won't be used. 2784 * src/ls.c (gobble_file): Form and compute length of strings for 2785 block size, owner, group, author, major+minor numbers and file size 2786 only if they'll actually be used. I.e., don't form most of them 2787 when not producing long format output. 2788 27892007-04-07 Jim Meyering <jim@meyering.net> 2790 2791 Add a test for, and document, today's fix. 2792 * NEWS: Mention today's ls --color fix. 2793 * tests/ls-2/tests (sl-target): Add a test for today's fix. 2794 * THANKS: Add Kirk Kelsey. 2795 27962007-04-07 Eric Blake <ebb9@byu.net> 2797 2798 Fix a bug in how the LS_COLORS ln=target attribute is handled. 2799 * src/ls.c (gobble_file): Use "stat" (not lstat) also when the 2800 ln=target attribute applies. Reported by Kirk Kelsey. 2801 28022007-04-02 Jim Meyering <jim@meyering.net> 2803 2804 * src/copy.c (copy_reg): Initialize local "con", before calling 2805 getfscreatecon, in case that function (or its inline stub) does 2806 not set it. 2807 28082007-04-01 Paul Eggert <eggert@cs.ucla.edu> 2809 2810 * src/ls.c (print_horizontal): Fix bug reported by Mike Frysinger: 2811 ls -x DIR would sometimes output the wrong string in place of the 2812 first entry. 2813 * NEWS: Mention the bug fix. 2814 * tests/ls/x-option: New file. 2815 * tests/ls/Makefile.am (TESTS): Add x-option. 2816 2817 gnulib moved md5 and sha1 modules into a new crypt/ directory; adapt 2818 * bootstrap.conf (gnulib_modules): Adjust to gnulib's renaming of 2819 md5 to crypt/md5 and sha1 to crypt/sha1. 2820 28212007-03-30 Jim Meyering <jim@meyering.net> 2822 2823 * NEWS: Mention these SELinux changes. 2824 2825 * ChangeLog-selinux: Remove file. 2826 Move its contents into this file, removing old dates. 2827 2828 * src/runcon.c (main): Don't reorder arguments. Reported by 2829 Ulrich Drepper in <http://bugzilla.redhat.com/232652>. 2830 * tests/misc/runcon-no-reorder: New file. Test for the above. 2831 * tests/misc/Makefile.am (TESTS): Add runcon-no-reorder. 2832 2833 * src/runcon.c (main): Remove "." at end of a diagnostic. 2834 2835 * src/runcon.c: New program. 2836 * src/Makefile.am (bin_PROGRAMS): Add runcon. 2837 (runcon_LDADD): Define. 2838 * README: Add runcon to the list of programs. 2839 * AUTHORS: Add this: runcon: Russell Coker 2840 * tests/help-version: Add runcon as an exception. 2841 * man/Makefile.am (dist_man_MANS): Add runcon.1. 2842 (runcon.1): New dependency. 2843 2844 mkfifo, mknod: Accept new "-Z, --context=C" option. 2845 * src/mkfifo.c, src/mknod.c: Include <selinux/selinux.h>. 2846 (main): Honor it. 2847 * src/Makefile.am (mkfifo_LDADD, mknod_LDADD): Use $(LIB_SELINUX). 2848 2849 mkdir: Accept new "-Z, --context=C" option. 2850 * src/mkdir.c: Include <selinux/selinux.h>. 2851 (main): Honor it. 2852 * src/Makefile.am (mkdir_LDADD): Use $(LIB_SELINUX). 2853 2854 * tests/cp/cp-a-selinux: New file. Test for the bug reported in 2855 <http://bugzilla.redhat.com/219900>. 2856 * tests/cp/Makefile.am (TESTS): Add cp-a-selinux. 2857 2858 * tests/selinux: New file. 2859 * tests/Makefile.am (EXTRA_DIST): Add selinux. 2860 * tests/misc/selinux: Source the new script, rather than open coding it. 2861 2862 Change how "cp -a" and "cp --preserve=context" work with SELinux. 2863 Now, cp -a attempts to preserve context, but failure to do so does 2864 not change cp's exit status. However "cp --preserve=context" is 2865 similar, but failure *does* cause cp to exit with nonzero status. 2866 * src/copy.h (struct cp_options) [require_preserve_context]: New member. 2867 * src/copy.c (copy_reg, copy_internal): Implement the above. 2868 * src/mv.c (cp_option_init): Initialize the new member. 2869 * src/install.c (cp_option_init): Likewise. 2870 * src/cp.c (cp_option_init): Likewise. 2871 (decode_preserve_arg): Set it or reset it. 2872 2873 cp, mv, install: add SELinux support, but unlike with the Red Hat 2874 patch, mv and cp do not provide the "-Z context" option. 2875 * src/copy.c: Include <selinux/selinux.h>. 2876 (restore_default_fscreatecon): New function. 2877 (copy_reg): Make cp --preserve=context work for existing destination. 2878 (copy_internal): Likewise for new destinations. 2879 * src/copy.h (cp_options) [preserve_security_context]: New member. 2880 * src/cp.c: Include <selinux/selinux.h>. 2881 (selinux_enabled): New global. 2882 (usage): Mention new --preserve=context option. 2883 (PRESERVE_CONTEXT): Define/use. 2884 (decode_preserve_arg): Handle PRESERVE_CONTEXT. 2885 (main): Remove an obsolete comment. 2886 If --preserve=context is specified on a system without SELinux 2887 enabled, give a diagnostic and fail. 2888 * src/mv.c: Include <selinux/selinux.h>. 2889 Set x->preserve_security_context if SELinux is enabled. 2890 * src/install.c: Accept new "-Z, --context=C" option. 2891 Accept --preserve-context option (but not -P option). 2892 Accept alternate spelling: --preserve_context, for now. 2893 Include <selinux/selinux.h> and "quotearg.h". 2894 (selinux_enabled, use_default_selinux_context): New globals. 2895 (PRESERVE_CONTEXT_OPTION): Define. 2896 (cp_option_init): Default: do not preserve security context. 2897 (setdefaultfilecon): New function. 2898 (main): Honor new options. 2899 * src/Makefile.am (mv_LDADD, cp_LDADD, ginstall_LDADD): 2900 Add $(LIB_SELINUX). 2901 * src/system.h (GETOPT_SELINUX_CONTEXT_OPTION_DECL): Define. 2902 2903 * tests/misc/selinux [VERBOSE]: Print version info for each 2904 of the tested tools, not just ls. 2905 2906 * src/c99-to-c89.diff: Remove the ls.c patch, now that I've 2907 temporarily removed the offending c99'ism. 2908 2909 * src/chcon.c (usage): Split a string literal that was longer than 509. 2910 2911 * src/ls.c (gobble_file): Don't call getfilecon unless print_scontext. 2912 Upon failed getfilecon, accept not just ENOTSUP, but also ENODATA. 2913 2914 * src/c99-to-c89.diff: Adjust offsets. 2915 2916 * AUTHORS: Add chcon. 2917 2918 * src/c99-to-c89.diff: Remove trailing blanks. 2919 2920 * src/chcon.c: Don't include "dirname.h". system.h already includes it. 2921 2922 * gl/lib/selinux-at.c: Remove a use of HAVE_CONFIG_H. 2923 2924 * src/c99-to-c89.diff: Handle a new c99'ism in ls.c. 2925 2926 * src/id.c (main): Tweak id -Z diagnostic. 2927 2928 id: Add SELinux support: -Z option. 2929 * src/id.c (main): Apply patches from Fedora, with these changes: 2930 Remove #ifdef WITH_SELINUX. 2931 Use error (EXIT_FAILURE, not fprintf+exit(1). 2932 * src/Makefile.am (id_LDADD): Define, so as to add $(LIB_SELINUX). 2933 2934 stat: Add support for SELinux in the form of a %C format directive. 2935 * src/stat.c (follow_links): Make this variable file-global. 2936 (out_file_context): New function. 2937 (print_statfs): Honor %C. 2938 (print_stat): Honor %C. 2939 (do_stat): Remove follow_links parameter. 2940 (usage): Document the two %C directives. 2941 (main): Accept -Z (though it's a no-op). 2942 * src/Makefile.am (stat_LDADD): Define. 2943 2944 ls: Add support for SELinux and a slightly modified -Z option. 2945 I started with the patches from Red Hat. 2946 The entries below tell how the code evolved. 2947 2948 * src/ls.c (print_long_format, print_file_name_and_frills): When 2949 there is no security context (due to getfilecon/lgetfilecon failing 2950 with e.g. ENOTSUP), print it as "?", not "". 2951 * src/ls.c (print_file_name_and_frills): Make -Z work without -l. 2952 (length_of_file_name_and_frills): Likewise. 2953 2954 * src/ls.c: Remove the --lcontext and --scontext options. 2955 Change the way -Z, --context work so that it no longer implies -l. 2956 Thus, -Z -l will work like -lcontext and -Z without -l will work 2957 like --scontext. 2958 2959 Adjust tests to reflect new 'ls -l' syntax -- affects only 2960 systems with SELinux when operating on a file with no ACL. 2961 These tests assumed that everything before the first space on 2962 each line is the 10-byte mode string. But there may also be a "+" 2963 in the 11th column, just before the space. However, note that this 2964 is not new. The same thing would have happened even without the 2965 change below, when listing a file with an ACL. 2966 * tests/chmod/equals, tests/cp/cp-parents, tests/cp/fail-perm: 2967 * tests/cp/link-preserve, tests/install/basic-1, tests/misc/mknod: 2968 * tests/mkdir/parents, tests/mkdir/special-1, tests/mv/partition-perm: 2969 2970 Don't make compilation depend on USE_ACL. An SELinux security 2971 context counts as an "alternate access control method", so ls 2972 must output a "+" for each file with a security context. 2973 * src/ls.c [struct fileinfo] (have_acl): Declare unconditionally. 2974 (FILE_HAS_ACL): Remove macro definition. Use f->have_acl directly. 2975 (gobble_file): Record whether a file has a security context, and 2976 update the condition used to determine whether to print the "+". 2977 (gobble_file): Call getfilecon/lgetfilecon also when 2978 format == long_format, so that we get the "+". 2979 2980 * src/ls.c (gobble_file): Add a comment explaining why (with a 2981 security context option) ls doesn't exit nonzero due to e.g., 2982 getfilecon failing with errno == ENOTSUP. 2983 2984 * src/ls.c (gobble_file): Ignore failure of getfilecon if it's due 2985 to ENOTSUP. 2986 2987 * src/ls.c (gobble_file): Factor out three small blocks using 2988 getfilecon and lgetfilecon. 2989 Don't ignore return value from getfilecon and lgetfilecon. 2990 2991 * src/ls.c (print_long_format): Don't use ?: (empty 2nd arg with C 2992 ternary operator). 2993 (print_scontext_format): Likewise. 2994 (print_scontext): Declare to be "bool", not int. Adjust uses. 2995 2996 * src/Makefile.am (dir_LDADD, ls_LDADD, vdir_LDADD): Add $(LIB_SELINUX). 2997 2998 * tests/misc/chcon: New file. 2999 * tests/misc/chcon-fail: New file. 3000 * tests/Makefile.am (check-root): Run new, root-only misc/chcon test. 3001 * tests/misc/Makefile.am (TESTS): Add chcon and chcon-fail. 3002 3003 * tests/misc/Makefile.am (TESTS): Add selinux. 3004 * tests/misc/selinux: New file. 3005 * tests/help-version: Skip chcon. 3006 * man/chcon.x: New file. 3007 * man/Makefile.am: Build chcon.1. 3008 3009 New program: chcon 3010 * gl/modules/selinux-at: New module. Check for libselinux and set 3011 LIB_SELINUX here, unconditionally, rather than depending on 3012 the configure-time --enable-selinux option. 3013 * gl/modules/selinux-h: New module. 3014 * bootstrap.conf (gnulib_modules): Add selinux-at. 3015 * gl/lib/selinux-at.c, gl/lib/selinux-at.h: New files. 3016 * gl/lib/se-selinux_.h: New file. 3017 * gl/lib/se-context_.h: New file. 3018 * gl/m4/selinux-selinux-h.m4: New file. 3019 * gl/m4/selinux-context-h.m4: New file. 3020 * src/Makefile.am (bin_PROGRAMS): Add chcon. 3021 (chcon_LDADD): Define. 3022 * README: Add chcon to the list of programs. 3023 * src/chcon.c: Rewrite the original (Red Hat) chcon to use fts. 3024 30252007-03-29 Jim Meyering <jim@meyering.net> 3026 3027 * .vg-suppressions: Add libc-getpwuid-leak. 3028 30292007-03-28 Jim Meyering <jim@meyering.net> 3030 3031 Help translators include translation team's web or email address. 3032 * src/system.h (emit_bug_reporting_address): New function. 3033 * src/base64.c: Use it rather than a literal printf. 3034 * src/basename.c, src/cat.c, src/chgrp.c, src/chmod.c: 3035 * src/chown.c, src/chroot.c, src/cksum.c, src/comm.c, src/cp.c: 3036 * src/csplit.c, src/cut.c, src/date.c, src/dd.c, src/df.c: 3037 * src/dircolors.c, src/dirname.c, src/du.c, src/echo.c, src/env.c: 3038 * src/expand.c, src/expr.c, src/factor.c, src/fmt.c, src/fold.c: 3039 * src/head.c, src/hostid.c, src/hostname.c, src/id.c, src/install.c: 3040 * src/join.c, src/kill.c, src/link.c, src/ln.c, src/logname.c: 3041 * src/ls.c, src/md5sum.c, src/mkdir.c, src/mkfifo.c, src/mknod.c: 3042 * src/mv.c, src/nice.c, src/nl.c, src/nohup.c, src/od.c: 3043 * src/paste.c, src/pathchk.c, src/pinky.c, src/pr.c, src/printenv.c: 3044 * src/printf.c, src/ptx.c, src/pwd.c, src/readlink.c, src/rm.c: 3045 * src/rmdir.c, src/seq.c, src/setuidgid.c, src/shred.c, src/shuf.c: 3046 * src/sleep.c, src/sort.c, src/split.c, src/stat.c, src/stty.c: 3047 * src/su.c, src/sum.c, src/sync.c, src/system.h, src/tac.c: 3048 * src/tail.c, src/tee.c, src/test.c, src/touch.c, src/tr.c: 3049 * src/true.c, src/tsort.c, src/tty.c, src/uname.c, src/unexpand.c: 3050 * src/uniq.c, src/unlink.c, src/uptime.c, src/users.c, src/wc.c: 3051 * src/who.c, src/whoami.c, src/yes.c: Likewise. 3052 3053 * src/stty.c: Don't include "vasprintf.h", now that its 3054 declarations are guaranteed to be in gnulib's stdio.h. 3055 * src/who.c: Likewise. 3056 30572007-03-27 Jim Meyering <jim@meyering.net> 3058 3059 * README: Use "install", not "ginstall" in the list of program names. 3060 * src/Makefile.am (check-README): Substitute s/ginstall/install/. 3061 30622007-03-25 Jim Meyering <jim@meyering.net> 3063 3064 * src/c99-to-c89.diff: Regenerate. 3065 30662007-03-25 Paul Eggert <eggert@cs.ucla.edu> 3067 3068 Avoid the need for euidaccess and/or lstat on every directory entry 3069 with 'rm -r dir' (without -f), if we are root, or if we are removing 3070 a directory tree that is full of symbolic links. 3071 * bootstrap.conf (gnulib_modules): Add write-any-file. 3072 * src/copy.c: Include write-any-file.h. 3073 (UNWRITABLE): Remove macro, replacing with.... 3074 (writable_destination): New function, which uses can_write_any_file 3075 to avoid the need for euidaccess when we are privileged. 3076 (overwrite_prompt, abandon_move): Use it. 3077 * src/remove.c: Include write-any-file.h. 3078 (D_TYPE): New macro. 3079 (DT_UNKNOWN, DT_DIR, DT_LNK) [!HAVE_STRUCT_DIRENT_D_TYPE]: New macros. 3080 (write_protected_non_symlink): Don't bother to stat if we can write 3081 any file. 3082 (prompt): New arg PDIRENT_TYPE. All callers changed. 3083 Use readdir dirent type to avoid the need for 'lstat' on each directory 3084 entry in cases like 'rm -r dir', if we are root, or if the tree is 3085 full of symbolic links. 3086 (DT_IS_KNOWN, DT_MUST_BE): Remove. 3087 (remove_entry): New arg DIRENT_TYPE_ARG. All callers changed. 3088 30892007-03-24 Jim Meyering <jim@meyering.net> 3090 3091 If strace malfunctions, skip the test rather than failing it. 3092 * tests/mv/atomic: Required on a mips-unknown-linux-gnu system 3093 running the aging linux-2.4.27-mipscvs-20040814. 3094 30952007-03-23 Paul Eggert <eggert@cs.ucla.edu> 3096 3097 * src/pathchk.c: Don't include euidaccess.h, as we don't call 3098 euidaccess. 3099 31002007-03-23 Jim Meyering <jim@meyering.net> 3101 3102 * README-package-renamed-to-coreutils: Add a URL for the FAQ, 3103 and a couple more archive links. 3104 31052007-03-22 Jim Meyering <jim@meyering.net> 3106 3107 Post-release version change. 3108 * NEWS: Add a line for 6.9+. 3109 * configure.ac (AC_INIT): Set new version string. 3110 3111 Version 6.9. 3112 * NEWS: Record release date and new version number. 3113 * configure.ac (AC_INIT): New version number. 3114 3115 * tests/mv/hard-3: Correct the preceding change: $3 -> $2. 3116 31172007-03-22 Paul Eggert <eggert@cs.ucla.edu> 3118 3119 Improve a test script. 3120 * tests/mv/hard-3: Check for 'ls' failure, too. 3121 Generate more-useful debugging output when 'ls' fails. 3122 31232007-03-21 Jim Meyering <jim@meyering.net> 3124 3125 Fix a test script not to claim an ext2 file system is of type xfs. 3126 * tests/du/slink: When using df --local and df --type=TYPE, 3127 test only the exit code. Don't bother with stdout. 3128 Prompted by a report by Thomas Schwinge of an inaccurate diagnostic. 3129 3130 * gl/lib/savewd.c: Remove this file, since the savewd_save change 3131 is now in gnulib. The other wasn't useful. 3132 31332007-03-20 Jim Meyering <jim@meyering.net> 3134 3135 * gl/lib/acl.c: Remove this file, now that gnulib's version subsumes it. 3136 3137 Skip part of this test when "." is not a local file system. 3138 * tests/install/basic-1: Otherwise, it would fail on some NFS 3139 file systems. 3140 * tests/mkdir/p-3: Likewise. 3141 31422007-03-19 Paul Eggert <eggert@cs.ucla.edu> 3143 3144 * src/Makefile.am (dir_LDADD, ls_LDADD, vdir_LDADD): 3145 Add $(LIB_ACL_TRIVIAL). 3146 31472007-03-18 Jim Meyering <jim@meyering.net> 3148 3149 Fix a generic NFS-related test failure. 3150 * tests/mkdir/p-3: When setting up an unreadable "." in an 3151 inaccessible parent, make the parent inaccessible *after* making "." 3152 unreadable. Otherwise, running "chmod a-r ." in an already- 3153 inaccessible parent would fail on NFS with "Stale NFS file handle". 3154 3155 Fix a bug in how pr -m -s works. 3156 * NEWS: Describe how the fix affects pr. 3157 * src/pr.c (init_parameters): The --merge (-m) option does 3158 not imply --expand-tabs (-e), so don't set "untabify_input". 3159 Reported by Wis Macomson. 3160 * tests/misc/pr: New file. Test for the above fix. 3161 * tests/misc/Makefile.am (TESTS): Add pr. 3162 * THANKS: Update. 3163 31642007-03-17 Jim Meyering <jim@meyering.net> 3165 3166 Detect use of AC_CONFIG_AUX_DIR also when its argument is quoted. 3167 * bootstrap: Put ""s around use of $build_aux, in case 3168 someone uses a name containing shell meta-characters. 3169 Reported by Alfred M. Szmidt. 3170 * tests/misc/tty-eof: Add shuf to the list of tested commands. 3171 3172 Avoid test failure on NFS-mounted Solaris ZFS file system. 3173 * tests/du/basic: Skip a test if "." is on a non-local file system. 3174 3175 Avoid an obscure build failure, prefer waitpid over wait. 3176 * src/install.c (strip): Use waitpid, not wait. It's equivalent, 3177 but feels less obsolescent. 3178 3179 * bootstrap: Don't use \> in grep regexp. For HP-UX. 3180 31812007-03-16 Jim Meyering <jim@meyering.net> 3182 3183 Begin adding support for Solaris ZFS (4 entries per trivial ACL) 3184 * gl/lib/acl.c (ACL_NOT_WELL_SUPPORTED): New macro. 3185 (file_has_acl, copy_acl): Use it, rather than enumerating errno values. 3186 (is_trivial_acl): New function. Incomplete, for now. 3187 (file_has_acl, copy_acl): Use the new function, rather than 3188 counting the number of entries in an ACL. 3189 3190 * bootstrap: Update from gnulib. 3191 3192 * .x-sc_prohibit_atoi_atof: Add TODO here, too. 3193 31942007-03-16 Paul Eggert <eggert@cs.ucla.edu> 3195 3196 * src/copy.c: Include filemode.h. 3197 (overwrite_prompt): Say "try to overwrite", not "overwrite", to 3198 make it clearer that the attempt may fail. Problem reported by 3199 Dan Jacobson in: 3200 http://lists.gnu.org/archive/html/bug-coreutils/2007-03/msg00130.html 3201 Output symbolic mode as well as numeric. 3202 * tests/mv/i-2 (fail): Adjust to new prompt format. 3203 32042007-03-15 Jim Meyering <jim@meyering.net> 3205 3206 Enforce policy: don't use *scanf functions. 3207 * Makefile.maint (sc_prohibit_atoi_atof): Add to regexp and diagnostic. 3208 * .x-sc_prohibit_atoi_atof: Give stty a temporary pass. 3209 * TODO: note that stty.c needs this small clean-up. 3210 32112007-03-13 Jim Meyering <jim@meyering.net> 3212 3213 Prepare to work on ACL-related failure when using Solaris ZFS. 3214 * gl/lib/acl.c: New file, copied from gnulib. 3215 3216 Work around a failing test due to an NFS-based race condition. 3217 * tests/cp/sparse: Accept a report that the copy is *smaller*. 3218 32192007-03-12 Jim Meyering <jim@meyering.net> 3220 3221 Make bootstrap.conf a tiny bit more generic. 3222 * bootstrap.conf (XGETTEXT_OPTIONS): Exclude gettext-related .m4 3223 files when e.g., AM_GNU_GETTEXT([external] appears in configure.ac. 3224 32252007-03-10 Jim Meyering <jim@meyering.net> 3226 3227 Try to fix today's NFS-related failure: Treat ESTALE like EACCES. 3228 * gl/lib/savewd.c: Copy this file from gnulib, then change 3229 "errno != EACCES" to (errno != EACCES && errno != ESTALE). 3230 The symptom was this failure in tests/install/basic-1: 3231 ginstall: cannot create directory `rel/a': Stale NFS file handle 3232 3233 The preceding change solved part of the problem. Now ginstall fails. 3234 * tests/install/basic-1: Temporarily, don't redirect ginstall's 3235 stderr to /dev/null, so I can see why the NFS autobuilder's NFS test 3236 is failing. 3237 3238 * tests/install/basic-1: When setting up an unreadable "." in an 3239 inaccessible parent, make the parent inaccessible *after* making "." 3240 unreadable. Otherwise, running "chmod a-r ." in an already- 3241 inaccessible parent would fail on NFS with "Stale NFS file handle". 3242 Reported by Bob Proulx. 3243 3244 * Makefile.maint (po-check): Exclude c99-to-c89.diff. 3245 32462007-03-09 Jim Meyering <jim@meyering.net> 3247 3248 Avoid test failures on Darwin 7.9.0 (MacOS X 10.3.9) 3249 * tests/chgrp/basic: Don't let failure by chgrp to set the 3250 group of a symlink make this test fail. Do give a diagnostic. 3251 In the chgrp-no-change-ctime test, add darwin7.9.0 as another 3252 known-failing system. 3253 When failing on some other system, print $host_triplet, too. 3254 Also avoid test failures on Darwin 8.8.x (MacOS X 10.4). 3255 Reported by Peter Fales. 3256 32572007-03-08 Jim Meyering <jim@meyering.net> 3258 3259 * src/c99-to-c89.diff: Reflect the new c99'ism, update offsets. 3260 32612007-03-08 Paul Eggert <eggert@cs.ucla.edu> 3262 3263 rm without -f: give a better diagnostic when euidaccess fails. 3264 * src/remove.c (write_protected_non_symlink): Return int, not bool, 3265 so that we can indicate failure too (as a postive error number). 3266 (prompt): If write_protected_non_symlink fails, report that error 3267 number and fail rather than charging ahead and removing the dubious 3268 entry. Redo the logic of printing a diagnostic so that we need to 3269 invoke quote (full_filename (...)) only once. More details at: 3270 <http://thread.gmane.org/gmane.comp.gnu.coreutils.bugs/9952/focus=9996> 3271 32722007-03-08 Jim Meyering <jim@meyering.net> 3273 3274 Generalize a few more cvs-isms. 3275 * bootstrap (checkout_only_file): Rename from CVS_only_file. 3276 Change comments and diagnostics not to say "CVS". 3277 3278 * bootstrap: Run libtool, if necessary. 3279 3280 Make bootstrap a little more general. 3281 * bootstrap (build_aux): Factor out/use this definition. 3282 Formally require a "AC_CONFIG_AUX_DIR($build_aux)" line in configure.ac. 3283 (insert_sorted_if_absent): Move function definition "up", to 3284 precede new first use. 3285 If $build_aux/ doesn't exist initially, create it, and 3286 mark it as ignored. 3287 32882007-03-03 Andrew Church <achurch@achurch.org> (tiny change) 3289 Paul Eggert <eggert@cs.ucla.edu> 3290 3291 Fix a bug: cp -x would fail to set mount point permissions. 3292 * NEWS: mention cp -x bug fix 3293 * src/copy.c (copy_internal): Don't return immediately after 3294 copying a mount point that we do not intend to recurse under. 3295 Based on a patch by Andrew Church. 3296 32972007-03-03 Jim Meyering <jim@meyering.net> 3298 3299 pwd-unreadable-parent: Skip test on ia64/Linux, too. 3300 * tests/misc/pwd-unreadable-parent: Also skip when $REPLACE_GETCWD. 3301 Reported by Bob Proulx. 3302 33032007-03-02 Jim Meyering <jim@meyering.net> 3304 3305 pwd-unreadable-parent: Skip test on non-Linux/GNU systems. 3306 * tests/misc/pwd-unreadable-parent: Rather than trying to decide 3307 whether this test has a chance of succeeding, run it only when 3308 $(host_os) is linux-gnu. It was failing on powerpc-apple-darwin8.8.0 3309 * tests/misc/Makefile.am (TESTS_ENVIRONMENT): Add host_os=$(host_os). 3310 3311 * tests/misc/pwd-long: Also allow "+" in $PWD. 3312 3313 Remove another coreutils-ism. Formatting cleanup. 3314 * Makefile.maint (my-distcheck): Update an outdated comment. 3315 (emit_upload_commands): Use $(PACKAGE) rather than "coreutils". 3316 (my-distcheck): Skip the c99/c89 check if there's no such .diff file. 3317 33182007-03-01 Jim Meyering <jim@meyering.net> 3319 3320 * Makefile.maint (warn_cflags): Hoist, adding "-Dlint -O". 3321 (my-distcheck): Use the new variable, instead of too-long literal. 3322 3323 Make "make syntax-check" rules less coreutils-specific. 3324 * Makefile.maint (sc_cast_of_x_alloc_return_value): Use CVS_LIST_EXCEPT. 3325 (sc_cast_of_alloca_return_value): Likewise. 3326 (sc_root_tests): Do nothing if there is no check-root target 3327 in tests/Makefile.am. 3328 3329 Run the writable-files check only for release-building targets. 3330 * Makefile.maint (local-checks-available): Remove writable-files. 3331 (alpha beta major): Put it here, instead. 3332 3333 "make syntax-check" now runs only Makefile.cfg-selected tests 3334 * Makefile.maint (syntax-check-rules): Hoist this definition so that 3335 it precedes the indirect use in the definition of $(local-check). 3336 (local-check): Use :=, not just "=". 3337 (syntax-check): Depend on $(local-check), not $(syntax-check-rules). 3338 33392007-02-28 Bruno Haible <bruno@clisp.org> 3340 3341 * bootstrap.conf (gnulib_modules): Replace xreadlink with 3342 xreadlink-with-size. Add xreadlink. 3343 * src/copy.c (copy_internal): Update. 3344 * src/ls.c (is_directory): Update. 3345 * src/stat.c (print_stat): Update. 3346 * src/readlink.c (main): Use the one-argument xreadlink function. 3347 33482007-02-28 Paul Eggert <eggert@cs.ucla.edu> 3349 3350 * doc/coreutils.texi (Common options): --si outputs "M", not "MB". 3351 Problem reported by Philip Rowlands in 3352 <http://lists.gnu.org/archive/html/bug-coreutils/2007-02/msg00283.html>. 3353 33542007-02-28 Jim Meyering <jim@meyering.net> 3355 3356 * .x-sc_file_system: Add the new test, tests/misc/df-P, to this 3357 list of exceptions, for the "make distcheck" sc_file_system rule. 3358 3359 * Makefile.maint (gnulib_snapshot_date): Remove now-unused definition. 3360 33612007-02-27 Paul Eggert <eggert@cs.ucla.edu> 3362 3363 Make df -P immune to effects of e.g., the BLOCK_SIZE envvar. 3364 * NEWS: With -P, the default block size and output format is not 3365 affected by DF_BLOCK_SIZE, BLOCK_SIZE, or BLOCKSIZE. 3366 * src/df.c (main): Implement this. 3367 33682007-02-27 Jim Meyering <jim@meyering.net> 3369 3370 Add a test for the above. 3371 * tests/misc/df-P: New file. 3372 * tests/misc/Makefile.am (TESTS): Add df-P. 3373 33742007-02-25 Jim Meyering <jim@meyering.net> 3375 3376 * Makefile.maint (announcement): Adjust so that it works with 3377 announce-gen's --gnulib-snapshot-time-stamp option. 3378 Indent one of the command lines using TAB, not 8 spaces. 3379 3380 Post-release version change. 3381 * NEWS: Add a line for 6.8+. 3382 * configure.ac (AC_INIT): Set new version string. 3383 33842007-02-24 Jim Meyering <jim@meyering.net> 3385 3386 Version 6.8. 3387 * NEWS: Record release date and new version number. 3388 * configure.ac (AC_INIT): New version number. 3389 3390 Don't skip this test on new-enough Linux/GNU systems. 3391 * tests/misc/pwd-unreadable-parent: Test $REPLACE_GETCWD = 0, 3392 rather than for __GETCWD_PREFIX in config.h (the latter is no 3393 longer defined, ever, due to gnulib changes). 3394 * tests/misc/Makefile.am (TESTS_ENVIRONMENT): Define REPLACE_GETCWD. 3395 3396 Remove the "gnits" option; it prohibits my using "+" as a version 3397 string suffix, and all it does (beyond the default "gnu" option) 3398 is to _require_ the THANKS file. 3399 * configure.ac (AM_INIT_AUTOMAKE): Remove it. 3400 3401 Remove all AUTOMAKE_OPTIONS settings in Makefile.am files. 3402 * tests/chgrp/Makefile.am, tests/chmod/Makefile.am: 3403 * tests/chown/Makefile.am, tests/cp/Makefile.am: 3404 * tests/du/Makefile.am, tests/expr/Makefile.am: 3405 * tests/factor/Makefile.am, tests/general/Makefile.am: 3406 * tests/install/Makefile.am, tests/ln/Makefile.am: 3407 * tests/ls/Makefile.am, tests/mkdir/Makefile.am: 3408 * tests/mv/Makefile.am, tests/readlink/Makefile.am: 3409 * tests/rm/Makefile.am, tests/rmdir/Makefile.am: 3410 * tests/seq/Makefile.am, tests/stty/Makefile.am: 3411 * tests/tee/Makefile.am, tests/touch/Makefile.am: 3412 3413 * README: Document the OSF/1 4.0d build failure and work-around. 3414 Reported by Bruno Haible. 3415 3416 * NEWS: Use a simple "+" suffix to denote pre-release, not "-dirty". 3417 Nicer connotations. 3418 * configure.ac: Use 6.7+, not 6.7-dirty. 3419 34202007-02-24 Paul Eggert <eggert@cs.ucla.edu> 3421 3422 * NEWS: sort no longer compresses temporaries by default. 3423 * bootstrap.conf: Remove findprog. 3424 * doc/coreutils.texi (sort invocation): The default is to not 3425 compress. Don't treat "" specially. 3426 * src/sort.c: Don't include findprog.h. 3427 (create_temp): Compress only if the user specified --compress-program. 3428 * tests/misc/sort-compress: Adjusts tests to match new behavior. 3429 34302007-02-24 Jim Meyering <jim@meyering.net> 3431 3432 Avoid a shell syntax error, when building with an inadequate Perl. 3433 * man/Makefile.am (.x.1): Add quotes around $(PERL) in case, since 3434 it can expand to "/.../missing perl". 3435 3436 * man/Makefile.am (.x.1): Warn when unable to update a man page. 3437 Suggestion from Bruno Haible. 3438 34392007-02-23 Bruno Haible <bruno@clisp.org> 3440 3441 Handle better the combination of old Perl and a pre-c99 compiler. 3442 * man/Makefile.am (.x.1): If the autoconf test has determined that 3443 perl is missing or not a sufficient version, do nothing. 3444 3445 * tests/readlink/can-e: Put the closing double-quote at the end of a 3446 backquoted word, not in the middle. Works around a bug in sh on 3447 OSF/1 4.0d. 3448 * tests/readlink/can-f: Likewise. 3449 * tests/readlink/can-m: Likewise. 3450 3451 * tests/du/slink: Skip the test if executing on an nfsv3 file system. 3452 This avoids a test failure at least on OSF/1 4.0d. 3453 34542007-02-23 Jim Meyering <jim@meyering.net> 3455 3456 * src/date.c (usage): Split a diagnostic that had grown to be 3457 longer than the C89 maximum of 509 bytes. 3458 34592007-02-23 Ed Santiago <ed@edsantiago.com> 3460 3461 * src/date.c (usage): Mention that --rfc-3339 uses space, not 'T', 3462 for a separator. Include sample RFC 2822 and 3339 output. 3463 34642007-02-23 Jim Meyering <jim@meyering.net> 3465 3466 With -Dlint, make shuf free all heap-allocated storage. 3467 * src/shuf.c (main): Move declaration of input_lines to 3468 function scope, and initialize to NULL, so we can free it. 3469 [lint]: Free all malloc'd memory. 3470 * tests/misc/shuf: Also test shuf's -e and -i options. 3471 34722007-02-22 Jim Meyering <jim@meyering.net> 3473 3474 Merge in a change from some other incarnation of this file (gzip?) 3475 * bootstrap (gnulib_tool): Skip get_translations if there is no po/ dir. 3476 3477 Adjust preceding change not to perform an unaligned access. 3478 * src/copy.c (copy_reg): Undo previous change. Instead, make 3479 it clearer that we're using a single-byte sentinel, and 3480 [lint]: Initialize sizeof (uintptr_t) - 1 bytes after the sentinel. 3481 Reported by Andreas Schwab. 3482 3483 Placate valgrind, wrt ./cp --sparse=always 3484 * src/copy.c (copy_reg): Place the sentinel by setting a 3485 full word's worth of bits, not just a single byte's worth. 3486 This avoids a harmless (but distracting) case of memory being 3487 used-uninitialized. 3488 34892007-02-21 Paul Eggert <eggert@cs.ucla.edu> 3490 3491 Honor dd's noatime flag if possible, even if not supported on build fs 3492 * doc/coreutils.texi (dd invocation): Warn that noatime might not be 3493 reliable. 3494 * src/dd.c (flags, usage): Look at O_NOATIME, not 3495 HAVE_WORKING_O_NOATIME, to decide whether to support the noatime 3496 flag, so that dd attempts O_NOATIME even if the build file system 3497 does not support it. Problem reported by Jim Meyering today in 3498 bug-coreutils. 3499 * tests/dd/misc: Generate a warning, not a failure, if noatime 3500 exists but fails. 3501 35022007-02-21 Jim Meyering <jim@meyering.net> 3503 3504 * tests/misc/date: Remove vestigial use of Data::Dumper. 3505 35062007-02-20 Paul Eggert <eggert@cs.ucla.edu> 3507 3508 * src/copy.c (cached_umask): Cast -1 to mode_t to avoid a warning 3509 about out-of-range initializer with Sun C 5.8. 3510 35112007-02-20 Jim Meyering <jim@meyering.net> 3512 3513 * bootstrap (CVS_only_file): Use README-hacking. 3514 3515 Now that we use GIT, not cvs, rename README-cvs. 3516 * README-hacking: Renamed from... 3517 Update to reflect that we now use git. 3518 3519 * README-cvs: ...this. 3520 3521 * src/env.c (main): When invoked with no arguments (i.e. when printing 3522 the environment), use a local variable to iterate through the global 3523 "environ" array, rather than "environ" itself. This is solely to 3524 avoid changing the environment for an LD_PRELOAD-substituted "puts" 3525 or "exit" function. Tiny patch by Harvey Eneman. See 3526 <http://thread.gmane.org/gmane.comp.gnu.coreutils.bugs/9735>. 3527 * THANKS: Update. 3528 3529 * bootstrap: Move definitions of temporary directory names and the 3530 new bt_regex "up" to precede all uses, so it's clearer what their 3531 scope is. Also, use [.], rather than \\., since the former works 3532 even if eval'd. 3533 3534 * bootstrap: Remove occurrences of $bt (._bootmp) from lib/Makefile. 3535 Based on the bison 2007-02-19 change by Joel E. Denny. 3536 35372007-02-19 Paul Eggert <eggert@cs.ucla.edu> 3538 3539 * NEWS: sort now uses a --compress-program option rather than 3540 an environment variable. 3541 * doc/coreutils.texi (sort invocation): Document this. 3542 * src/sort.c (usage): Likewise. 3543 (COMPRESS_PROGRAM_OPTION): New const. 3544 (long_options, create_temp, main): Support new option. 3545 * tests/misc/sort-compress: Test it. 3546 35472007-02-19 Jim Meyering <jim@meyering.net> 3548 3549 * bootstrap: Fix typo s/dowloading/downloading/ in --help output. 3550 35512007-02-18 Jim Meyering <jim@meyering.net> 3552 3553 * src/system.h: Don't include exit.h, now that it's subsumed 3554 by the gnulib-generated stdlib.h. 3555 3556 * tests/rm/fail-eacces: Skip this test when running as root. 3557 Reported by Matthew Woehlke. 3558 3559 * bootstrap: Use "._bootmp" as the temporary directory name, 3560 not ".#bootmp". The latter's "#" caused trouble with the new, 3561 gnulib-added "LINK_WARNING_H = $(top_srcdir)/.#bootmp/..." line. 3562 35632007-02-14 Paul Eggert <eggert@cs.ucla.edu> 3564 3565 * bootstrap.conf (gnulib_modules): Add c-strcase. Remove strcase. 3566 * src/dircolors.c: Include c-strcase.h. 3567 (dc_parse_stream): Use c_strcasecmp rather than 3568 strcasecmp to avoid unreliable results in locales like Turkish 3569 where strcasecmp is incompatible with the C locale. 3570 35712007-02-13 Jim Meyering <jim@meyering.net> 3572 3573 Also check for and print stderr output, in case a program fails. 3574 * tests/misc/tty-eof: Occasionally (not reproducible), this 3575 test would fail, with one or more programs exiting nonzero, e.g., 3576 tty-eof: sha224sum exited with status 1 (expected 0) 3577 Now, maybe we'll get a clue, the next time that happens. 3578 35792007-02-12 Jim Meyering <jim@meyering.net> 3580 3581 * .x-sc_useless_cpp_parens: Ignore a false-positive in a shell script. 3582 3583 * tests/misc/pwd-unreadable-parent: Skip the test if we're 3584 definitely using the replacement. 3585 * tests/misc/Makefile.am (TESTS_ENVIRONMENT): Define CONFIG_HEADER. 3586 35872007-02-10 Jim Meyering <jim@meyering.net> 3588 3589 Remove excess leading spaces that would make help2man misbehave. 3590 * src/printf.c (usage): Remove excess spaces on 2nd line of %b desc. 3591 * src/nl.c (usage): Remove excess spaces on 2nd line of pBRE desc. 3592 * src/dd.c (usage): Remove excess spaces on 2nd line of sync desc. 3593 * src/date.c (usage): Use two spaces after each optional flag, not one. 3594 Reported by Thomas Huriaux in <http://bugs.debian.org/410407>. 3595 3596 * Makefile.maint (longopt_re): Relax the regexp, making square 3597 brackets optional, so it matches the newly reported violations, too. 3598 3599 * src/csplit.c (usage): Use two spaces (not one) to separate 3600 each option string from its description, so help2man formats 3601 the derived man page properly. Reported by Thomas Huriaux in 3602 <http://bugs.debian.org/410407>. 3603 * src/df.c (usage): Likewise. 3604 * src/du.c (usage): Likewise. 3605 * src/install.c (usage): Likewise. 3606 * src/ls.c (usage): Likewise. 3607 36082007-02-03 Jim Meyering <jim@meyering.net> 3609 3610 Test for today's gnulib/lib/getcwd.c fix affecting pwd and readlink 3611 * NEWS: Mention the bug fix. 3612 * tests/misc/pwd-unreadable-parent: New file. 3613 * tests/misc/Makefile.am (TESTS): Ad pwd-unreadable-parent. 3614 36152007-02-02 Paul Eggert <eggert@cs.ucla.edu> 3616 3617 * NEWS: Document fix for cp --preserve=mode. 3618 * src/copy.c (copy_internal): Omit the group- or other-writeable 3619 permissions when creating a directory, to avoid a race condition 3620 if the special mode bits aren't right just after the directory is 3621 created. 3622 * src/cp.c (make_dir_parents_private): Likewise. 3623 * tests/cp/parent-perm-race: Test for the "cp --preserve=mode" 3624 race fix in copy.c. 3625 3626 * NEWS: Document fix for cp --parents. 3627 * src/cp.c (make_dir_parents_private): Report the error sooner with 3628 "cp --parents DIR/FILE DEST" when DIR is a non-directory, thus not 3629 creating the directory, DEST/DIR. 3630 * tests/cp/cp-parents: Test for the non-race-condition bug fixed 3631 by the above change. 3632 36332007-02-02 Jim Meyering <jim@meyering.net> 3634 3635 * src/nl.c (proc_text): Use "NULL", not "(struct re_registers *) 0". 3636 3637 * src/c99-to-c89.diff: Make shred.c Index: and a/b prefixes 3638 consistent, so this can be applied with patch -p0. 3639 Reported by Matthew Woehlke. 3640 3641 Arrange for "make check-root" to run the new root-only test. 3642 * tests/Makefile.am (t9): New target, to run tests/cp/cp-a-selinux. 3643 (all_t): Add t9. 3644 3645 * Makefile.maint (patch-check): Use patch with its -p2 option, 3646 since that makes this check slightly more strict. 3647 3648 Use a directory on a loopback device mounted with -o context=... 3649 * tests/cp/cp-a-selinux: Since this test now runs mount and umount, 3650 it is a root-only one. 3651 36522007-01-29 Jim Meyering <jim@meyering.net> 3653 3654 Plug a leak in ls. 3655 * src/ls.c (print_dir): Don't leak a "DIR"+fd upon failure to 3656 determine dev/inode or upon detecting a symlink loop. 3657 3658 * src/ls.c: Rename three global variables. 3659 (cwd_file): Rename from 'files'. 3660 (cwd_n_alloc): Rename from 'nfiles'. 3661 (cwd_n_used): Rename from 'files_index'. 3662 3663 Shave 8 bytes off the size of "struct fileinfo". 3664 * src/ls.c (fileinfo): Put all members of type "bool" together. 3665 36662007-01-28 Paul Eggert <eggert@cs.ucla.edu> 3667 3668 Modify "ls" to sort its data faster, using the new gnulib mpsort 3669 module rather than qsort. This is particularly a win in 3670 environments where strcoll is slow, since mpsort typically calls 3671 strcoll less often than qsort does. 3672 * bootstrap.conf (gnulib_modules): Add mpsort. 3673 * src/ls.c: Include mpsort.h. 3674 (sorted_file, sorted_file_alloc): New vars, for a new vector of 3675 pointers to the file info, for speed. 3676 (clear_files, extract_dirs_from_files, sort_files, print_current_files): 3677 (print_many_per_line, print_horizontal, print_with_commas): 3678 (calculate_columns): Set and use new vector. 3679 (initialize_ordering_vector): New function. 3680 36812007-01-26 Paul Eggert <eggert@cs.ucla.edu> 3682 3683 Adjust to today's change to gnulib, which added a module for 3684 string.h to replace the little include files like strcase.h. 3685 * src/dircolors.c: Don't include strcase.h. 3686 * src/system.h: Don't include mempcpy.h, memrchr.h, stpcpy.h, strpbrk.h. 3687 36882007-01-26 Jim Meyering <jim@meyering.net> 3689 3690 * src/dd.c (advance_input_after_read_error): Change diagnostic to 3691 say "invalid file offset" rather than "screwy file offset". 3692 3693 * .x-sc_cast_of_argument_to_free: Remove this file. 3694 * Makefile.am (EXTRA_DIST): Likewise. 3695 36962007-01-25 Dan Hipschman <dsh@linux.ucla.edu> 3697 3698 * src/sort.c (create_temp): Remove superfluous access-X_OK 3699 check. find_in_path does this for us. 3700 37012007-01-24 Jim Meyering <jim@meyering.net> 3702 3703 Remove usually-skipped test. 3704 * tests/cp/open-perm-race: Remove this file. It is subsumed 3705 by parent-perm-race. 3706 * tests/cp/Makefile.am (TESTS): Remove open-perm-race. 3707 * tests/sort/Makefile.am: Regenerate. 3708 3709 Pass "make distcheck" again. 3710 * src/sort.c (usage): Split a diagnostic that had grown to be 3711 longer than the C89 maximum of 509 bytes. 3712 * .x-sc_cast_of_argument_to_free: New file. Allow a cast in sort.c. 3713 FIXME: this is just temporary, while we wait to remove the offending 3714 access-calling code. 3715 * Makefile.am (EXTRA_DIST): Add .x-sc_cast_of_argument_to_free. 3716 * Makefile.maint (sc_cast_of_argument_to_free): Use the 3717 canonical, $$($(CVS_LIST_EXCEPT)). 3718 * m4/.gitignore, m4/.cvsignore, lib/.gitignore, lib/.cvsignore: Update. 3719 37202007-01-24 Paul Eggert <eggert@cs.ucla.edu> 3721 3722 * NEWS: New option sort -C, proposed by XCU ERN 127, which looks 3723 like it will be approved. Also add --check=quiet, --check=silent 3724 as long aliases, and --check=diagnose-first as an alias for -c. 3725 * doc/coreutils.texi (sort invocation): Document this. 3726 Also, mention that sort -c can take at most one file. 3727 * src/sort.c: Implement this. 3728 Include argmatch.h. 3729 (usage): Document the change. 3730 (CHECK_OPTION): New constant. 3731 (long_options): --check now takes an optional argument, and is now 3732 treated differently from 'c'. 3733 (check_args, check_types): New constant arrays. 3734 (check): New arg CHECKONLY, which suppresses diagnostic if -C. 3735 (main): Parse the new options. 3736 * tests/sort/Test.pm (02d, 02d, incompat5, incompat6): 3737 New tests for -C. 3738 37392007-01-24 Jim Meyering <jim@meyering.net> 3740 3741 Fix a typo. 3742 * tests/misc/sort-compress: Use $abs_top_builddir, not $top_builddir. 3743 * tests/misc/Makefile.am (TESTS_ENVIRONMENT): Likewise. 3744 3745 Don't depend on "which". 3746 * tests/misc/sort-compress (SORT): Use $abs_builddir, now which. 3747 * tests/misc/Makefile.am (TESTS_ENVIRONMENT): Export top_builddir. 3748 37492007-01-24 Dan Hipschman <dsh@linux.ucla.edu> 3750 3751 Test sort compression. 3752 * tests/misc/Makefile.am: Add the test. 3753 * tests/misc/sort-compress: New file containing the tests. 3754 37552007-01-24 Jim Meyering <jim@meyering.net> 3756 3757 * NEWS: sort temp file compression: tweak wording. 3758 * src/sort.c (struct sortfile) [name]: Declare member to be const. 3759 37602007-01-21 Jim Meyering <jim@meyering.net> 3761 3762 * src/sort.c (MAX_FORK_RETRIES_COMPRESS, MAX_FORK_RETRIES_DECOMPRESS): 3763 In pipe_fork callers, use these named constants, not "2" and "8". 3764 (proctab, nprocs): Declare to be "static". 3765 (pipe_fork) [lint]: Initialize local, pid, 3766 to avoid unwarranted may-be-used-uninitialized warning. 3767 (create_temp): Use the active voice. Describe parameters, too. 3768 37692007-01-21 James Youngman <jay@gnu.org> 3770 3771 Centralize all the uses of sigprocmask(). Don't restore an invalid 3772 saved mask. 3773 * src/sort.c (enter_cs, leave_cs): New functions for protecting 3774 code sequences against signal delivery. 3775 * (exit_cleanup): Use enter_cs and leave_cs instead of 3776 calling sigprocmask directly. 3777 (create_temp_file, pipe_fork, zaptemp): Likewise 3778 37792007-01-21 Dan Hipschman <dsh@linux.ucla.edu> 3780 3781 Add compression of temp files to sort. 3782 * NEWS: Mention this. 3783 * bootstrap.conf: Import findprog. 3784 * configure.ac: Add AC_FUNC_FORK. 3785 * doc/coreutils.texi: Document GNUSORT_COMPRESSOR environment 3786 variable. 3787 * src/sort.c (compress_program): New global, holds the name of the 3788 external compression program. 3789 (struct sortfile): New type used by mergepfs and friends instead 3790 of filenames to hold PIDs of compressor processes. 3791 (proctab): New global, holds compressor PIDs on which to wait. 3792 (enum procstate, struct procnode): New types used by proctab. 3793 (proctab_hasher, proctab_comparator): New functions for proctab. 3794 (nprocs): New global, number of forked but unreaped children. 3795 (reap, reap_some): New function, wait for/cleanup forked processes. 3796 (register_proc, update_proc, wait_proc): New functions for adding, 3797 modifying and removing proctab entries. 3798 (create_temp_file): Change parameter type to pointer to file 3799 descriptor, and return type to pointer to struct tempnode. 3800 (dup2_or_die): New function used in create_temp and open_temp. 3801 (pipe_fork): New function, creates a pipe and child process. 3802 (create_temp): Creates a temp file and possibly a compression 3803 program to which we filter output. 3804 (open_temp): Opens a compressed temp file and creates a 3805 decompression process through which to filter the input. 3806 (mergefps): Change FILES parameter type to struct sortfile array 3807 and update access accordingly. Use open_temp and reap_some. 3808 (avoid_trashing_input, merge): Change FILES parameter like 3809 mergefps and call create_temp instead of create_temp_file. 3810 (sort): Call create_temp instead of create_temp_file. 3811 Use reap_some. 3812 (avoid_trashing_input, merge, sort, main): Adapt to mergefps. 3813 3814 The idea of compressing sorts temporary files was first 3815 suggested/implemented by Jay Soffian in 1998, and again 3816 by Charles Randall in 2001. 3817 38182007-01-20 Jim Meyering <jim@meyering.net> 3819 3820 * tests/misc/pwd-long: Work properly even when run from the 3821 wrong one of two or more bind-mounted sibling directories. 3822 Suggestion from Mike Stone in <http://bugs.debian.org/380552>. 3823 38242007-01-20 Paul Eggert <eggert@cs.ucla.edu> 3825 3826 Standardize on list of signals when an app catches signals. 3827 * src/csplit.c (main): Also catch SIGALRM, SIGPIPE, SIGPOLL, 3828 SIGPROF, SIGVTALRM, SIGXCPU, SIGXFSZ. 3829 * src/ls.c (main): Likewise (except SIGPIPE was already caught). 3830 Note that ls.c is special, as it also catches SIGTSTP. 3831 * src/sort.c (main): Likewise. Also catch SIGQUIT. More details in 3832 <http://thread.gmane.org/gmane.comp.gnu.coreutils.bugs/9510>. 3833 38342007-01-19 Dan Hipschman <dsh@linux.ucla.edu> 3835 and Paul Eggert <eggert@cs.ucla.edu> 3836 3837 * src/sort.c (cleanup): Clear temphead at the end. 3838 (exit_cleanup): New function. 3839 (main): Don't invoke atexit until we're ready. 3840 Invoke it with exit_cleanup, not with cleanup and close_stdout, 3841 to avoid a race condition with cleanup and signal handling. More 3842 details: http://thread.gmane.org/gmane.comp.gnu.coreutils.bugs/9508 3843 38442007-01-18 Jim Meyering <jim@meyering.net> 3845 3846 * src/c99-to-c89.diff: Adjust remove.c offsets. 3847 38482007-01-17 Jim Meyering <jim@meyering.net> 3849 3850 Make "rm --interactive=never ..." never prompt. 3851 * NEWS: Mention this. 3852 * src/remove.h (enum rm_interactive): New ternary type. 3853 (struct rm_options) [interactive]: Use it, here -- rather than bool. 3854 * src/remove.c (prompt): Reflect type change. 3855 * src/mv.c (rm_option_init): Initialize to RMI_NEVER now. 3856 * src/rm.c (main): Add a FIXME comment for '-d' option. 3857 Adapt to type change of rm_options.interactive. 3858 3859 * tests/rm/i-never: New file. Test for the above fix. 3860 * tests/rm/Makefile.am (TESTS): Add i-never. 3861 38622007-01-15 Jim Meyering <jim@meyering.net> 3863 3864 * bootstrap (gnulib_tool): When adding to .cvsignore and .gitignore, 3865 emit foo.h, for each foo_.h. This yields one false-positive, fts.h, 3866 but that's ok, since fts_.h will eventually be renamed. 3867 3868 * src/remove.c (remove_dir): Don't use errno in diagnostic. 3869 Root-only test failure reported by Alex van Hout and Jon Grosshart in 3870 <http://thread.gmane.org/gmane.comp.gnu.coreutils.bugs/9415/focus=9415>. 3871 3872 * bootstrap.conf (avoided_gnulib_modules): Fix my typo: 3873 s/--avoid=canonicalize-lgpl/--avoid=canonicalize-gpl/ 3874 38752007-01-14 Bruno Haible <bruno@clisp.org> 3876 3877 Enable use of gnulib's new fchdir module. 3878 * bootstrap.conf (avoided_gnulib_modules): Avoid canonicalize-lgpl, 3879 since we use canonicalize. 3880 (gnulib_modules): Add fchdir. 3881 * m4/jm-macros.m4 (coreutils_MACROS): Remove fchdir-stub. 3882 38832007-01-13 Jim Meyering <jim@meyering.net> 3884 3885 * tests/cp/open-perm-race: Remove gdb-based test. 3886 It would run only when compiled with -g, and besides is now 3887 subsumed by file-perm-race. 3888 * tests/cp/Makefile.am (TESTS): Remove open-perm-race. 3889 3890 * Transform all Makefile.am files so that when running "make check", 3891 CU_TEST_NAME is set to the name of the test. This is so that when I 3892 run valgrind-enabled (--log-file-qualifier=CU_TEST_NAME) "make check" 3893 on the entire package it is more convenient to map a leak or error 3894 found in a valgrind log file back to the offending test. 3895 Use this command: 3896 (echo tests/Makefile.am.in; find tests -name Makefile.am) \ 3897 |xargs perl -pi -e '/^(\s*)PATH=...VG_PATH_PREFIX/ and ' \ 3898 -e 'print $1,q|CU_TEST_NAME=`basename $(abs_srcdir)`,$$tst |,"\\\n"' 3899 39002007-01-11 Jim Meyering <jim@meyering.net> 3901 3902 Avoid a leak in expr's implementation of the ":" (match) operator. 3903 * src/expr.c (docolon): Free the regexp buffer using regfree, rather 3904 than doing it manually, being careful to set fastmap to NULL first. 3905 Free any re_regs.start and .end members, if necessary. 3906 3907 * tests/misc/test-diag: Work also when libc's error function 3908 reports the entire program name ("../../src/test"), rather than 3909 just the final component. 3910 39112007-01-10 Jim Meyering <jim@meyering.net> 3912 3913 Don't use fts_statp uninitialized for "chown -RLh --preserve-root ...". 3914 * src/chown-core.c (FTSENT_IS_DIRECTORY): New macro. 3915 (change_file_owner): Perform the ROOT_DEV_INO_CHECK only for a 3916 directory. Non-directory entries lack fts_statp data when using 3917 the FTS_NOSTAT option. 3918 39192007-01-07 Jim Meyering <jim@meyering.net> 3920 3921 * tests/sample-test: Update copyright date to 2007. 3922 * Makefile.maint (copyright-check): Also check the copyright date 3923 in tests/sample-test. 3924 39252007-01-06 Jim Meyering <jim@meyering.net> 3926 3927 * tests/fmt/basic (pfx-only, pfx-of-pfx): New tests, 3928 based on examples from G.P. Halkes in 3929 <http://article.gmane.org/gmane.comp.gnu.core-utils.bugs/9388>. 3930 39312007-01-06 G.P. Halkes <buscom@ghalkes.nl> 3932 3933 * src/fmt.c (copy_rest): Correct prefix handling. 3934 Don't elide a line with the prefix followed by only white space. 3935 (get_line): Move EOF-check to loop-termination condition. 3936 * tests/fmt/basic (pfx-1): Adjust test to expect desired result. 3937 (pfx-2): Remove test; its premise was contrary to the documentation. 3938 39392007-01-05 Jim Meyering <jim@meyering.net> 3940 3941 Avoid a used-uninitialized bug for invalid input, i.e., when the size 3942 of the input, not counting newlines, is 1 % 4. 3943 * gl/lib/base64.c (base64_decode): Don't hard-code inlen==4. 3944 It may be smaller when flushing. 3945 39462007-01-05 Mike Frysinger <vapier@gentoo.org> 3947 3948 * src/dircolors.hin: Add a TERM directive for cons25. 3949 39502007-01-04 Jim Meyering <jim@meyering.net> 3951 3952 * Makefile.cfg (local-checks-to-skip): Skip strftime-check, in 3953 case you don't have convenient access to glibc info documentation. 3954 3955 Use the release year, not the current year. 3956 * src/groups.sh (version): Use a better name: @RELEASE_YEAR@. 3957 * src/Makefile.am (RELEASE_YEAR): Define it. 3958 (.sh): Use it. 3959 Thanks to a prod from Eric Blake. 3960 3961 Ensure that "group --version" always prints the current year. 3962 * src/groups.sh (version): Use @CURRENT_YEAR@, rather than 2006. 3963 * src/Makefile.am (.sh): Also substitute for @CURRENT_YEAR@. 3964 Suggestion from Eric Blake. 3965 3966 When decoding, always allow newlines in input, with almost no 3967 performance impact. 3968 * src/base64.c (do_decode): Initialize decode context. 3969 Call base64_decode one more time, after all input is processed. 3970 (usage): When decoding, newlines are always accepted. 3971 3972 * tests/misc/base64: Add a bunch of tests, for the above. 3973 * gl/lib/base64.c: Include <string.h>. 3974 (base64_decode_ctx_init, get_4, decode_4): New functions. 3975 (base64_decode): Efficiently handle interspersed newlines. 3976 (base64_decode_alloc): Update signature. 3977 * gl/lib/base64.h (struct base64_decode_context): Define. 3978 (base64_decode_ctx_init): Add prototype. 3979 (base64_decode, base64_decode_alloc): Update prototypes. 3980 3981 * gl/lib/base64.c: Copied from gnulib. 3982 * gl/lib/base64.h: Likewise. 3983 39842007-01-03 Jim Meyering <jim@meyering.net> 3985 3986 * THANKS: Add Evan Hunt. 3987 39882007-01-03 Bruno Haible <bruno@clisp.org> 3989 3990 Avoid spurious test failures on MacOS X 10.3.9, in a German locale. 3991 * tests/chown/deref: Apply lang-default. 3992 * tests/misc/split-a: Likewise. 3993 * tests/mv/reply-no: Likewise. 3994 3995 * src/copy.c (copy_internal): Use mkfifo as a fallback if mknod fails. 3996 Needed on MacOS X. 3997 39982007-01-02 Paul Eggert <eggert@cs.ucla.edu> 3999 4000 Now, "ls -FRL" always follows symbolic links on Linux. 4001 * NEWS: Mention this bug fix. 4002 * src/ls.c (gobble_file): Fix bug reported by 4003 Nobuyuki Tsuchimura in 4004 http://lists.gnu.org/archive/html/bug-coreutils/2006-12/msg00152.html 4005 where "ls -FRL" didn't follow a symbolic link in some cases on Linux. 4006 * tests/ls/follow-slink: Add a test for this case. 4007 40082007-01-01 Jim Meyering <jim@meyering.net> 4009 4010 * tests/rm/fail-eperm: Revert last change. The PATH=... setting 4011 is not honored at least on HP-UX 11.23 systems. 4012 Instead, simply transform the actual output diagnostic. 4013 Test failure reported by Bob Proulx. 4014 4015 4016 ----- 4017 4018 Copyright (C) 2007, 2009-2010 Free Software Foundation, Inc. 4019 4020 Copying and distribution of this file, with or without 4021 modification, are permitted provided the copyright notice 4022 and this notice are preserved. 4023