1 Tue Jul 2 22:56:03 1996 Jim Meyering <meyering@na-net.ornl.gov>
3 * configure.in (VERSION): Bump to 3.12q.
5 * src/system.h [!EXIT_SUCCESS]: Define it.
6 [!EXIT_FAILURE]: Define it.
8 * lib/strndup.c (strndup): Include stdio.h and sys/types.h to
9 get definition of NULL and size_t on SunOS4.1.3.
11 Mon Jul 1 23:47:29 1996 Jim Meyering <meyering@na-net.ornl.gov>
13 * src/ln.c (do_link): Update messages to ease translation.
14 Suggestion from Santiago Vila.
16 Sun Jun 30 16:41:45 1996 Jim Meyering <meyering@na-net.ornl.gov>
18 * src/install.c (usage): Fix typo, 3nd->3rd, in usage message.
19 From Santiago Vila <sanvila@unex.es>.
21 Sat Jun 29 00:33:31 1996 Jim Meyering <meyering@na-net.ornl.gov>
23 * configure.in (PACKAGE_VERSION): Add `GNU ' prefix so we see
24 it in the output of --version. Reported by RMS.
26 * src/Makefile.am (BUILT_SOURCES): Guard dependency on dircolors.h
27 with @MAINT@ so it won't be removed with a casual disctlean.
28 (EXTRA_DIST): Add dcgen.pl and dircolors.hin.
30 Fri Jun 28 22:56:00 1996 Jim Meyering <meyering@na-net.ornl.gov>
32 * src/dircolors.c (dc_parse_stream): Move `enum states' dcl into
35 * src/ln.c (do_link): Allow `ln -sf --backup k k' to succeed in
36 creating the self-referential symlink, since doing so doesn't
37 remove the source but merely renames it.
39 Wed Jun 26 06:58:58 1996 Jim Meyering <meyering@na-net.ornl.gov>
41 * ln.c (same_name): New function.
42 (do_link): Use it to test reliably whether A and B (from
43 ln --force A B) are hard links to the same file.
46 Tue Jun 25 00:03:43 1996 Jim Meyering <meyering@na-net.ornl.gov>
48 * lib/getline.c: New file.
49 * lib/getline.h: New file.
50 * lib/Makefile.am (fu_SOURCES): Add getline.c.
51 (noinst_HEADERS): Add getline.h.
53 Mon Jun 24 22:39:02 1996 Jim Meyering <meyering@na-net.ornl.gov>
55 * configure.in (AC_REPLACE_FUNCS): Add strndup.
56 (AC_PATH_PROG): Check for perl.
58 * ls.c (decode_switches): Allow 0 as argument to --tabsize (-T) option.
59 Interpret as a directive to use no TAB characters to separate columns.
60 (indent): Handle TABSIZE == 0.
62 * dircolors.c (dc_parse_stream): Remove spurious newline in
64 (dc_parse_stream): Give `unrecognized keyword' diagnostic for
65 misspelled `TERM' keyword as well as for others.
67 Sun Jun 23 12:58:32 1996 Jim Meyering <meyering@na-net.ornl.gov>
69 * dircolors.hin: New file.
71 * src/Makefile.am (dircolors.h): Add a rule to create this file.
74 * dircolors.c (parse_line): Rewrite to avoid modifying LINE.
75 Put LINE first in parameter list.
77 (dc_parse_stream): Free KEYWD and ARG.
78 (main): Give diagnostic for unreasonable combinations of
81 * lib/Makefile.am (EXTRA_DIST): Add strndup.c.
82 * configure.in (AC_REPLACE_FUNCS): Add strndup.
83 * strndup.c: New file. From id-utils-3.0k.
85 [!STDC_HEADERS]: Include string.h and stdlib.h.
87 Sat Jun 22 16:57:53 1996 Jim Meyering <meyering@na-net.ornl.gov>
89 * dircolors.c: Major overhaul. No longer read from /etc/DIR_COLORS
90 or from ~/.dircolors. Defaults are now compiled in. If you specify
91 a file on the command line, it is used instead of the compiled-in
93 (main): New option --print-database (-p).
95 Add --bourne-shell and --c-shell aliases for --sh and --csh resp.
97 Tue Jun 18 20:54:05 1996 Jim Meyering <meyering@na-net.ornl.gov>
99 * cp.c (copy_reg): Cast both sides of comparison to size_t
100 to avoid a warning about `comparison between signed and unsigned'
102 Declare pointer parameters const as appropriate.
104 * ln.c (do_link): Refine last change so we don't disallow commands
105 like `ln --force A B' when A and B are hard links to the same file.
106 See comments in the source. Reported by Erik Naggum <erik@naggum.no>
109 * ls.c (decode_switches): Correct typo in error messages:
110 enironment -> environment. From Santiago Vila Doncel
113 * aclocal.m4: Update from gettext-0.10.20.
114 * ABOUT-NLS: Likewise.
117 * cp.c (do_copy): Change message from `missing file argument' to
118 more precise `missing destination file'. From Karl Berry.
120 * ln.c (STREQ): Remove macro definition
121 * system.h (STREQ): Add it here instead.
122 * cp.c (do_copy): Use STREQ here instead of strcmp(...) == 0.
123 * ls.c (parse_ls_color): Likewise.
124 * df.c (selected_fstype, excluded_fstype, show_disk, main): Likewise.
126 * cp.c (do_copy): When the force and backup options have been
127 specified and the source and destination are the same name for an
128 existing, regular file, convert the user's command, e.g.
129 `cp --force --backup foo foo' to `cp --force foo fooSUFFIX'
130 where SUFFIX is determined by any version control options used.
131 (usage): Update --help message.
132 At urging of (most recently) Karl Berry.
134 Sun Jun 16 13:40:22 1996 Jim Meyering <meyering@na-net.ornl.gov>
136 * doc/Makefile.am (EXTRA_DIST): Add texinfo.tex.
138 * Makefile.am (cvs-dist): Use -c option in cvs tag command.
140 Sat Jun 15 22:21:09 1996 Jim Meyering <meyering@na-net.ornl.gov>
142 * configure.in (ALL_LINGUAS): Add pt.
143 (AC_REPLACE_FUNCS): Add basename.
145 * Makefile.am (EXTRA_DIST): Add basename.c.
146 (fu_SOURCES): Remove basename.c.
148 Thu Jun 6 21:57:08 1996 Jim Meyering <meyering@na-net.ornl.gov>
150 * po/Makefile.in.in: Update from gettext-0.10.16.
152 * ABOUT-NLS: Likewise.
153 * aclocal.m4 (AC_REPLACE_GNU_GETOPT): Move definition to precede
154 gettext-related ones.
155 Update from gettext-0.10.16.
157 Sat Jun 1 12:44:51 1996 Jim Meyering <meyering@na-net.ornl.gov>
159 * ls.c: Rename options and internal variables to reflect change to
160 --color=WHEN where WHEN is never, always, or auto (for consistency
161 with e.g. cp --sparse=WHEN. For at least a while, the original
162 slackware-supported arguments `none', `force', `yes', etc will be
163 supported but deprecated by lack of documentation.
164 (decode_switches): Use STDOUT_FILENO instead of `1' in isatty test.
165 (usage): Update/add description of the --color option.
167 * ls.c: Declare pointer parameters const as appropriate.
169 Tue May 28 18:39:49 1996 Jim Meyering <meyering@na-net.ornl.gov>
171 * dd.c (print_stats): Don't mark "%u %s" as a translatable string.
172 * mv.c (main): Don't mark "%s" as a translatable string.
173 From Göran Uddeborg.
175 Thu May 23 07:50:38 1996 Jim Meyering <meyering@na-net.ornl.gov>
177 * ls.c (usage): Make --literal (-N) description clearer.
179 * acconfig.h (MOUNTED_LISTMNTENT): Add it.
180 * fsusage [_CRAY]: Don't include sys/filsys.h because although
181 Unicos-9 has it, it's not needed and would cause other problems
182 because it requires inclusion of other, non-standard headers.
183 * mountlist.c (read_filesystem_list) [MOUNTED_LISTMNTENT]: New
185 From Johan Danielsson (joda@pdc.kth.se).
187 * configure.in (AC_CHECK_FUNCS): Add listmntent for Unicos-9.
188 Define MOUNTED_LISTMNTENT #ifdef _CRAY and HAVE_GETMNTENT.
189 With an initial patch from Johan Danielsson.
191 Wed May 22 18:58:01 1996 Jim Meyering <meyering@na-net.ornl.gov>
193 * configure.in (LINGUAS): Add sv.
195 Tue May 21 07:06:30 1996 Jim Meyering <meyering@na-net.ornl.gov>
197 * lib/euidaccess.c (euidaccess) [!S_IROTH]: Define.
200 Marcus Daniels <marcus@sysc.pdx.edu> reported that m68k NEXTSTEP 3.2
201 doesn't define S_IROTH or S_IWOTH unless some posix compile option
202 is used and associated symbols defined.
204 Sun May 19 09:32:51 1996 Jim Meyering (meyering@na-net.ornl.gov)
206 * chown.c: New option: --no-dereference (-h). Solaris 5.4's chown
208 (change_file_owner): Use lchown if --no-dereference (-h) was given.
210 (main): Fail if user requests --no-dereference on a system that
211 doesn't have support for it.
213 * chgrp.c: New option: --no-dereference (-h).
214 [!MAXUID]: Define to INT_MAX.
215 (change_file_group): Use lchown if --no-dereference (-h) was given.
217 (main): Fail if user requests --no-dereference on a system that
218 doesn't have support for it.
220 Wed May 15 22:54:31 1996 Jim Meyering (meyering@na-net.ornl.gov)
222 * fsusage.c (get_fs_usage): Declare parameter PATH to be const.
223 * fsusage.h: Update prototype to match.
225 * chmod.c (describe_change): Declare pointer parameters to be const.
226 (change_file_mode): Likewise.
227 (change_dir_mode): Likewise.
229 * ln.c (do_link): Declare pointer parameters to be const.
231 * df.c (main): Fail with a diagnostic if both --human-readable and
232 --portability are used.
233 Likewise if --megabytes and --portability are used.
234 Rearrange function definitions to precede respective uses to obviate
235 all forward dcls. Remove forward dcls.
236 Declare parameters const as appropriate.
238 * modechange.c (mode_compile): Declare parameter MODE_STRING const.
239 Remove register attribute.
240 (mode_adjust): Likewise for CHANGES.
241 * modechange.h: Reflect above changes in prototypes.
243 * lib/Makefile.am (getdate.c): Disable dependencies that can
244 require rerunning YACC when not in maintainer mode.
245 (posixtm.c): Likewise.
247 Tue May 14 23:36:54 1996 Jim Meyering (meyering@na-net.ornl.gov)
249 * dd.c (print_stats): Restructure pluralization of error message
250 so it's easier to translate. Reported by Göran Uddeborg
251 <gvran@uddeborg.pp.se>.
252 * mv.c (main): Likewise.
254 Tue May 7 22:10:20 1996 Jim Meyering (meyering@na-net.ornl.gov)
256 * configure.in: Require autoconf-2.10.
258 * aclocal.m4 (jm_MAINTAINER_MODE): New macro.
259 * configure.in (jm_MAINTAINER_MODE): Use it.
261 Sun May 5 20:27:47 1996 Jim Meyering (meyering@na-net.ornl.gov)
263 * src/Makefile.am (bin_PROGRAMS): Add dircolors.
264 (DEFS): Add -DSHAREDIR=\"$(datadir)\".
265 (GNUVER): Remove definition of unused variable.
267 Sat May 4 20:54:32 1996 Jim Meyering (meyering@na-net.ornl.gov)
269 * system.h [IN_CTYPE_DOMAIN]: Rename from ISASCII.
270 * backupfile.c [IN_CTYPE_DOMAIN]: Rename from ISASCII.
272 * dircolors.c: Make enumerated constants upper case.
273 (main): Don't use ANSI-style string concatenation.
274 Add `static' and/or `const' to some file scope variables.
276 Wed May 1 00:20:00 1996 Jim Meyering (meyering@na-net.ornl.gov)
278 * lib/Makefile.am (EXTRA_DIST): Add strcasecmp.c.
279 * configure.in (AC_REPLACE_FUNCS): Add strcasecmp.
281 * ls.c (parse_ls_color, usage): Remove support for alternate spellings:
282 --colours and LS_COLOURS.
283 (parse_ls_color): Reverse sense of test for LS_COLORS environment
284 variable and return -- save a level of indentation on a 100+-line
287 Mon Apr 29 22:07:41 1996 Jim Meyering (meyering@na-net.ornl.gov)
289 * POTFILES.in: Add chgrp.c. From François Pinard.
291 * dircolors.c: New file. Written by H. Peter Anvin.
293 Sun Apr 28 16:32:38 1996 Jim Meyering (meyering@na-net.ornl.gov)
295 * ls.c: Apply color ls changes by Peter Anvin <Peter.Anvin@linux.org>
296 and Dennis Flaherty <dennisf@denix.elk.miles.com> based on original
297 patches by Greg Lee <lee@uhunix.uhcc.hawaii.edu>. And on top of all
298 that, a few changes from Ulrich Drepper.
300 * ls.c (parse_ls_color): Use strcpy to initialize 3-character array.
301 Automatic aggregate initialization isn't portable.
303 (get_funky_string): Declare static and move to precede single
304 caller: parse_ls_color.
305 Make some globals `static' and/or `const'.
306 (LEN_STR_PAIR): New macro.
307 (color_indicator): Use it in this declaration.
308 (parse_ls_color): Use error, not fprintf.
309 (decode_switches): Add a comment.
310 (print_name_with_quoting): Add braces around inner if-else
311 statement to clarify.
313 * configure.in: Add a comment that fp_C_PROTOTYPES must precede
314 AC_C_INLINE. Otherwise, some systems lose because the value
315 AC_C_INLINE choses with plain `cc' is different from that chosen
316 when using the ANSI-mode C compiler. From Kaveh Ghazi.
318 * fileblocks.c [HAVE_ST_BLOCKS || _POSIX_VERSION]: Add extern dcl
319 of unused variable so that after preprocessing, the file will never
320 be empty. Otherwise, some compilers in ANSI mode (among them, the
321 Dec Alpha OSF 2.0 C compiler) reject empty files. From Kaveh Ghazi.
322 Indent CPP conditionals.
324 Fri Apr 26 05:52:03 1996 Karl Eichwalder <ke@ke.Central.DE>
326 * ls.c (usage): Add newline at end of printf format string.
328 Wed Apr 24 21:33:43 1996 Jim Meyering (meyering@na-net.ornl.gov)
330 * ln.c (do_link): Remove duplicate `if (lstat(...' block.
332 * ln.c (do_link): With --force, don't remove DEST when it's
333 the same as SOURCE. Before, `ln -f FILE FILE' would remove FILE.
334 Reported by Bruno Haible (haible@ilog.fr).
336 * mkdir.c (main): Use verbose_fmt_string, not string literal in
337 call to make_path for --parents. Reported by Ulrich Drepper.
339 * doc/mdate-sh: Get year as last rather than 6th field in output
340 of date. Otherwise, people with 2-word TZ (like `MET DST') lost.
343 Tue Apr 23 22:05:35 1996 Jim Meyering (meyering@na-net.ornl.gov)
345 * src/*.c, src/*.h: Update Copyright years to include 1996.
347 * aclocal.m4 (AC_REPLACE_GNU_GETOPT): New macro.
348 * configure.in: Use it.
349 * lib/Makefile.am (fu_SOURCES): Remove getopt.c and getopt1.c.
350 (EXTRA_DIST): Add getopt.c and getopt1.c
352 * configure.in (AC_CHECK_FUNCS): Add lchown.
353 * chgrp.c [HAVE_LCHOWN]: Define chown to lchown.
354 * chown.c [HAVE_LCHOWN]: Likewise.
355 * cp.c [HAVE_LCHOWN]: Likewise.
356 * mv.c [HAVE_LCHOWN]: Likewise.
357 Suggested by François Pinard.
359 * backupfile.c (find_backup_file_name, max_backup_version,
360 make_version_name, version_number, concat): Const-ify decls of
362 * backupfile.h: Likewise.
364 * du.c (usage): The long-named arg is --human-readable, not --human.
365 * df.c: Be consistent. Accept --human-readable, not just --human.
366 (usage): Reflect the change.
369 Sun Apr 21 08:04:51 1996 Jim Meyering (meyering@na-net.ornl.gov)
371 * df.c (usage): Reflect that now --no-sync is the default.
373 * Makefile.am (LDADD): Put @INTLLIBS@ before package library.
375 Sat Apr 20 22:48:59 1996 Jim Meyering (meyering@na-net.ornl.gov)
377 * ls.c: Include xstrtol.h.
378 (decode_switches): Use xstrtol, not atoi.
379 Detect and ignore invalid value for COLUMNS environment variable.
380 In error about invalid TABSIZE, don't reference optarg!
381 [!POSIXLY_CORRECT]: Don't consider TABSIZE environment variable.
383 * install.c: Include xstrtol.h.
384 [HAVE_VALUES_H]: Include <values.h>.
385 [!BITSPERBYTE]: Define.
386 [!UID_T_MAX]: Define.
387 [!GID_T_MAX]: Define.
388 (get_ids): Use xstrtol, not atoi.
389 (is_number): Remove now-unused function.
390 * configure.in (AC_CHECK_HEADERS): Add values.h.
392 Fri Apr 19 00:06:02 1996 Jim Meyering (meyering@na-net.ornl.gov)
394 * Makefile.am (cvs-dist): New rule. Based on the one from
395 Tom Tromey's automake.
397 * df.c: No longer call sync by default.
399 * cp.c (copy_reg): Rearrange arithmetic in conditional to avoid
400 integer overflow with large files.
402 Fri Apr 12 21:40:44 1996 Jim Meyering (meyering@na-net.ornl.gov)
404 * mkdir.c (main): Add new option: --verbose.
405 Remove long-deprecated and nowhere-documented --path, a synonym
406 for --parents. It was confusing to get an error about `--p'
409 Thu Apr 4 21:28:03 1996 Jim Meyering (meyering@na-net.ornl.gov)
411 * configure.in (LINGUAS): Add de.
412 * po/de.po: New file.
414 * src/Makefile.am (EXTRAdir): Set to $(bindir).
416 Wed Apr 3 06:12:23 1996 Jim Meyering (meyering@na-net.ornl.gov)
418 * cp.c (copy_reg): Use `ST_NBLOCKS (sb) * 512', not `sb.st_blocks *
419 DEV_BSIZE.' From H.J. Lu (hjl@lucon.org).
423 (fullpath): Rewrite to use save_cwd, xgetcwd, and restore_cwd
424 rather than explicit chdir/getcwd calls.
426 * src/Makefile.am (INCLUDES): Add -I$(srcdir) to get system.h
427 when srcdir != builddir. From Kaveh Ghazi.
429 Mon Apr 1 23:50:29 1996 Jim Meyering (meyering@na-net.ornl.gov)
431 * cp.c: Include assert.h (disabled).
432 (path_concat): New function.
433 (do_copy): Use path_concat instead of open-coding part of its
434 functionality in two places. This has the additional benefit
435 of avoiding forming destination names like `D//file' when the
436 destination directory D includes a trailing slash -- as would
437 happen when cp is used like this:
438 mkdir D; touch file D/file; cp -i file D/
439 Reported by François Pinard.
441 Sun Mar 31 11:18:09 1996 Jim Meyering (meyering@na-net.ornl.gov)
443 * ls.c (quote_filename): Use ISGRAPH and ISPRINT in place of
444 ASCII-centric tests against literals.
445 (length_of_file_name_and_frills): Likewise.
447 Thu Mar 21 16:43:13 1996 Jim Meyering (meyering@na-net.ornl.gov)
449 * src/*.c (main): Declare to be of type int, not void.
451 Sat Mar 16 10:46:23 1996 Jim Meyering (meyering@na-net.ornl.gov)
453 * configure.in (PACKAGE_VERSION): New macro.
454 * acconfig.h (PACKAGE_VERSION): Add it.
455 * src/Makefile.am: Remove rules for generating version.c.
456 Remove references to version.o, version.h, and stamp-v.
457 * version.c: Remove file.
458 * version.h: Remove file.
459 * chgrp.c chmod.c chown.c cp.c dd.c df.c du.c install.c ln.c
460 ls.c mkdir.c mkfifo.c mknod.c mv.c mvdir.c rm.c rmdir.c sync.c
461 touch.c: Don't include version.h.
462 (main): Use PACKAGE_VERSION instead of version_string.
464 Sun Mar 10 22:36:11 1996 Jim Meyering (meyering@na-net.ornl.gov)
466 * backupfile.c (max_backup_version): Declare file_name_length to
467 be of type size_t. This avoids a warning from gcc -Wall.
469 * chmod.c chown.c cp.c dd.c df.c du.c install.c ln.c ls.c
470 mkdir.c mkfifo.c mknod.c mv.c mvdir.c rm.c rmdir.c sync.c
471 touch.c (main): Initialize for internationalized message support:
472 call setlocale, bindtextdomain, and textdomain.
473 * system.h: Add definitions and includes for NLS.
474 * Makefile.am (SUBDIRS): Add intl and po.
475 * src/Makefile.am (datadir): Define.
477 (DEFS): Add LOCALEDIR definition.
478 (LDADD): Add @INTLLIBS@.
479 * aclocal.m4: Add NLS-related macro definitions from
480 gettext distribution.
481 * acconfig.h (ENABLE_NLS, HAVE_CATGETS, HAVE_GETTEXT, HAVE_LC_MESSAGES,
482 HAVE_STPCPY): New macros.
483 Add PACKAGE and VERSION.
484 * configure.in (PACKAGE): Define with AC_DEFINE_UNQUOTED.
486 (ALL_LINGUAS): Define.
487 (ud_GNU_GETTEXT): Use it.
489 (AC_OUTPUT): Reflect addition of two new directories, intl and po.
491 From François Pinard.
493 Thu Mar 7 20:26:07 1996 Jim Meyering (meyering@na-net.ornl.gov)
495 * df.c (main): Tell read_filesystem_list that it should determine
496 file system type when the user specifies --print-type or -T.
497 From Michael Rendell <michael@cs.mun.ca>.
499 Tue Feb 27 23:13:46 1996 Jim Meyering (meyering@na-net.ornl.gov)
501 * src/Makefile.am: Adapt for automake-0.30.
502 (noinst_HEADERS): Rename from HEADERS.
503 (EXTRA_PROGRAMS): Set to `df mvdir'.
504 (PROGRAMS): Remove definition.
505 (bin_PROGRAMS): Remove hard-coded df. Use @DF_PROG@ instead.
506 (libexec_PROGRAMS): Remove hard-coded mvdir. Use @MVDIR_PROG@ instead.
507 * lib/Makefile.am: (noinst_HEADERS): Rename from HEADERS.
509 * configure.in (DF_PROG, MVDIR_PROG): Use these instead of bundling
512 Mon Feb 26 21:23:58 1996 Jim Meyering (meyering@na-net.ornl.gov)
514 * dd.c (copy): Remove bogus (now that we're using full_write)
515 increment of w_partial.
516 Change sense of the tests (though they're equivalent) that check
517 the value returned by full_write. making it clearer where errno
518 is valid. full_write always writes the full amount or fails.
520 Thu Feb 15 23:08:41 1996 Jim Meyering (meyering@na-net.ornl.gov)
522 * cp.c (copy): Detect (and fail) when creating backup file would
523 destroy the source file. Before, running the commands
524 cd /tmp; rm -f a a~; : > a; echo A > a~; cp -b -V simple a~ a
525 would leave two zero-length files: a and a~.
526 Reported by Martin C. Martin <mcm@cs.cmu.edu>.
528 Mon Feb 12 23:23:25 1996 Jim Meyering (meyering@na-net.ornl.gov)
530 * configure.in (LIBOBJS): Split assignment into two statements to
531 accomodate automake-0.29 buglet.
533 Update for automake-0.29.
534 * Makefile.am (CONFIG_HEADER): Don't define. Automake now does it.
535 * src/Makefile.am: Likewise.
536 * lib/Makefile.am: Likewise.
537 * doc/Makefile.am (info_TEXINFOS): Renamed from TEXINFOS.
538 * man/Makefile.am (man_MANS): Renamed from MANS.
540 Wed Jan 31 21:50:41 1996 Jim Meyering (meyering@na-net.ornl.gov)
542 * dd.c (skip): Change type of parameter #5 from char* to
543 unsigned char* to match type of argument.
544 (copy): Cast first arg in memset call to char* to avoid warnings
546 (copy_simple): Likewise.
548 * du.c: Remove comma after last item in enum.
550 * df.c: Remove block of usage comments at beginning of file.
552 * df.c (main): New options --human-readable (-h) and --megabytes (-m).
553 (human_readable_1k_blocks): New function.
554 (print_header): Honor new options.
555 (show_dev): Honor new options.
556 Add ifdef'd-out code to avoid printing lines for mount points that
557 match ^/auto/.* and ^/tmp_mnt.*. Rather than hard-coding those
558 two prefixes, the code should allow the user to specify a regular
559 expression. From Larry McVoy (lm@sgi.com).
561 * du.c (human_readable): Fix off-by-one error that converted
562 1024*1024 to 1024K rather than 1G. Describe the function.
563 * df.c (human_readable_1k_blocks): Likewise
564 (usage): Update usage message to reflect additions.
566 Sat Jan 20 06:00:09 1996 Jim Meyering (meyering@na-net.ornl.gov)
568 * cp-aux.c (usage): Fix description of --archive. From Andreas Schwab.
570 * install.c (copy_files): Accept backup/suffix options just as cp,
571 ln, and mv do. From Marty Leisner <leisner@sdsp.mc.xerox.com>.
573 * src/Makefile.am (DISTCLEANFILES): Set to stamp-v version.c.
574 (version.c): Update with rules from textutils.
575 (transform): Add `s/ginstall/install/;' prefix.
577 * lib/Makefile.am (BUILT_SOURCES): Set to posixtm.c getdate.c so
578 autodependencies work after `make maintainer-clean.'
580 * du.c (main): New options --human-readable (-h) and --megabytes (-m).
581 (human_readable): New function.
582 From Larry McVoy (lm@sgi.com).
584 Fri Dec 22 21:34:55 1995 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
586 * configure.in: Touch stamp-h only if config.h is remade.
588 Sat Dec 23 11:33:19 1995 Jim Meyering (meyering@comco.com)
590 * ls.c (decode_switches): Make -o a synonym for -lG for compatibility
591 with most other versions of ls. Reported by Karl Berry.
594 Fri Dec 22 00:48:01 1995 Jim Meyering (meyering@comco.com)
596 * dd.c (cleanup): New function -- broken out from quit.
597 (interrupt_handler): Rewrite to reset default signal handler,
598 call cleanup, then repost caught signal.
600 Thu Dec 21 23:15:06 1995 Jim Meyering (meyering@comco.com)
602 * argmatch.h: New file.
603 * lib/Makefile.am (HEADERS): Add argmatch.h.
604 * argmatch.c: (argmatch): Add const attribute to parameters.
605 (invalid_arg): Add const attribute to parameters.
607 * cp.c: Include argmatch.h.
611 * cp.c (main): Accept new option, --sparse={never,auto,always},
612 to control creation of sparse files.
613 (copy_reg): Set local, make_holes, from global flag_sparse.
614 * cp-aux (usage): Describe new option.
616 Mon Dec 18 22:29:49 1995 Jim Meyering (meyering@comco.com)
618 * ln.c: [SYMBOLIC_SPACE_STRING]: New macro.
619 (do_link): Use SYMBOLIC_SPACE_STRING instead of open-coded #ifdef.
620 For --verbose, output `create [symbolic ]link DEST to SRC' instead
621 of ambiguous (or inconsistent with cp -v and mv -v) `SRC -> DEST.'
623 Tue Dec 5 17:38:11 1995 Jim Meyering (meyering@comco.com)
625 * rm.c (rm): Work around SunOS 4 bug whereby lstat doesn't fail
626 when given a zero-length file name argument. Reported by
627 Mark Calabretta <mcalabre@atnf.csiro.au>.
629 Wed Nov 22 23:12:47 1995 Jim Meyering (meyering@comco.com)
631 * Makefile.in (all et. al.): If make was invoked with -k and a
632 sub-make fails, fail after the loop rather than exiting right away.
633 Otherwise, make's -k option could be ineffective.
635 Thu Nov 16 21:25:45 1995 Jim Meyering (meyering@comco.com)
637 * Makefile.in (default): New default target. Depend on `all' to work
638 around bug in AIX-3.2.5's /bin/make. Reported by Andreas Luik
641 Fri Nov 10 23:31:46 1995 Jim Meyering (meyering@comco.com)
643 * src/Makefile.in (.c._o, ._c._o): Remove temporary source files.
644 (.c._c): Don't redirect directly to $@.
646 * src/Makefile.in (DISTFILES): Include ansi2knr.c and ansi2knr.1.
647 (clean): Remove temp files generated by ansi2knr rules.
648 (ansi2knr): New rule.
649 Add suffixes, dependencies, and rules to convert ANSI source to K&R
651 ($(OBJECTS)): Depend on $(ANSI2KNR)
653 * configure.in: Add fp_C_PROTOTYPES.
655 * Makefile.in (DISTFILES): Add aclocal.m4.
656 (configure): Depend on aclocal.m4.
657 (stamp.h.in): Depend on aclocal.m4 and acconfig.h.
658 * acconfig.h: Add PROTOTYPES.
660 * cp.h: Remove declaration of error. Include error.h instead.
661 Protoize forward dcls of functions in cp-hash.c and cp-aux.c
662 * cp-aux.c: Protoize and add const attribute to parameters.
663 * cp-hash.c: Likewise.
665 Thu Nov 9 23:27:05 1995 Jim Meyering (meyering@comco.com)
667 * system.h [__P]: Define it.
671 * ls.c (enum filetype): Move dcl to precede prototypes.
672 (struct fileinfo): Likewise.
673 Add const attribute to some parameters.
675 * rm.c (struct pathstack): Move dcl to precede prototypes.
677 * dd.c (translate_charset): Make parameter `const'.
679 * ln.c (main): Move to the end.
680 Remove most fwd dcls.
685 * mkfifo.c: Likewise.
690 * mv.c: Rearrange functions to obviate forward dcls.
693 * cp.c: Protect prototyped forward dcls with __P.
697 * install.c: Likewise.
701 Wed Nov 1 23:11:05 1995 Jim Meyering (meyering@comco.com)
703 * cp.c (copy): Use euidaccess instead of euidaccess_stat.
704 * mv.c (do_move): Likewise.
705 * rm.c (remove_file, remove_dir): Likewise.
707 Sun Oct 29 06:06:13 1995 Jim Meyering (meyering@comco.com)
709 * aclocal.m4 (jm_WITH_AUTODEPS): New directive.
710 * configure.in: Use it.
712 * lib/Makefile.in (INCLUDE, COMPILE): New variables.
713 (.c.o): Rewrite to be more like src/Makefile.in.
714 Add line that (--with-autodeps) will include mkdep-Makefile.
715 (distclean): Remove .deps.
716 * src/Makefile.in: Likewise.
718 * src/Makefile.in (test.o): Remove special rule.
720 * mkdep-Makefile: New file.
721 * Makefile.in (DISTFILES): Add mkdep-Makefile.
723 * doc/Makefile.in (mostlyclean): Remove *.info.
725 * touch.c: Change long option name `--file' to `--reference'.
726 Leave --file as an alias, for now. It will be removed later.
727 (usage): Reflect option name change. From Franc,ois Pinard.
729 Wed Oct 18 23:09:55 1995 Jim Meyering (meyering@comco.com)
731 * configure.in (AC_CHECK_HEADERS): Add sys/wait.h and sys/ioctl.h.
732 (AC_CHECK_FUNCS): Add endpwent.
734 * fileblocks.c: Use _POSIX_VERSION, not _POSIX_SOURCE.
736 * userspec.c [endgrent]: Test !HAVE_ENDGRENT rather than _POSIX_SOURCE.
737 [endpwent]: Test !HAVE_ENDPWENT rather than _POSIX_SOURCE.
739 * chgrp.c [endgrent]: Test !HAVE_ENDGRENT rather than _POSIX_SOURCE.
741 * chown.c [endpwent]: Test !HAVE_ENDPWENT rather than _POSIX_SOURCE.
742 [endgrent]: Remove unused definition.
744 * df.c (main): Fail if the same file system type was both selected
745 and excluded. Reported by Paul Close pdc@lunch.engr.sgi.com.
747 * rm.c (duplicate_entry): Always return 0 if !D_INO_IN_DIRENT,
748 rather than if _POSIX_SOURCE.
750 * install.c: Use HAVE_SYS_WAIT_H, not _POSIX_VERSION in conditional
751 inclusion of sys/wait.h.
752 [endgrent]: Test !HAVE_ENDGRENT rather than _POSIX_SOURCE.
753 [endpwent]: Test !HAVE_ENDPWENT rather than _POSIX_SOURCE.
755 * ls.c Use HAVE_SYS_IOCTL_H, rather than !_POSIX_SOURCE || _AIX.
757 Thu Oct 5 21:49:34 1995 Jim Meyering (meyering@comco.com)
759 * configure.in (HAVE_STRUCT_UTIMBUF): Add new test. Testing for
760 the existence of <utime.h> is insufficient on some Next systems.
761 * acconfig.h (HAVE_STRUCT_UTIMBUF): Add it.
762 * system.h [!HAVE_UTIME_H]: Don't declare struct utimbuf here.
763 [!HAVE_STRUCT_UTIMBUF]: Declare struct utimbuf here instead.
765 * chgrp.c: Include limits.h.
766 [!INT_MAX]: Define it.
768 * df.c (show_point): Cast -2 to dev_t before assignment.
769 * mountlist.c (read_filesystem_list): Cast -1 to dev_t before
772 Sun Oct 1 13:22:36 1995 Jim Meyering (meyering@comco.com)
774 * configure.in (AC_REPLACE_FUNCS): Add strtoul.
775 * strtoul.c: New file.
776 * lib/Makefile.in (SOURCES): Add strtoul.c.
778 * acconfig.h (STATFS_TRUNCATES_BLOCK_COUNTS): Add it.
779 * configure.in (STATFS_TRUNCATES_BLOCK_COUNTS): New check to enable
780 workaround for SunOS statfs brokenness. Block counts in struct
781 statfs for partitions 2GB and larger are truncated, but correct
782 values are stored in f_spare array member.
784 * fsusage.c (get_fs_usage) [STATFS_TRUNCATES_BLOCK_COUNTS]: Copy
785 untruncated block counts from f_spare array into proper members
786 of struct statfs. From Eirik Fuller (eirik@netapp.com);
788 * ls.c (dired_dump_obstack): Don't generate any output if the
790 (main): Always initialize and dump subdired_obstack, not just if -R.
791 `ls -lDR dir dir2' was using uninitialized subdired_obstack.
792 Reported by Samuli K{rkk{inen <hskarkka@snakemail.hut.fi>.
794 Tue Sep 26 23:05:01 1995 Jim Meyering (meyering@comco.com)
796 * man/Makefile.in (install-data, uninstall): Use sed not basename.
797 The GNU Coding Standard suggests that only a select set of
798 relatively standard utilities be used in Makefiles. basename is
799 not among them. Suggested by Ulrich Drepper.
801 Mon Sep 25 23:12:37 1995 Jim Meyering <meyering@gremlin.comco.com>
803 * src/df.c (show_point): Ignore mtab entries with either
804 nonexistent mount points or with inconsistent device number.
805 From Eirik Fuller <eirik@synopsys.com>.
807 Wed Aug 9 00:33:05 1995 Jim Meyering (meyering@comco.com)
809 * mknod.c (my_strtol): Remove function.
810 (main): Use xstrtol instead.
812 Mon Aug 7 23:27:54 1995 Jim Meyering (meyering@comco.com)
814 * Makefile.in (DISTFILES): Don't distribute unneeded COPYING.LIB.
817 Fri Aug 4 22:11:06 1995 Jim Meyering (meyering@comco.com)
819 * install.c (isnumber): Rename to is_number to avoid conflict with
820 FreeBSD 2.0.5 macro definition. Reported by David O'Brien
821 (obrien@sea.legent.com).
823 * lib/save-cwd.c: New file.
824 * lib/save-cwd.h: New file.
825 * lib/Makefile.in (SOURCES, OBJECTS, DISTFILES): Update for new files.
827 * configure.in: (AC_REPLACE_FUNCS): Remove fnmatch.
828 Add check for working fnmatch functions so that
829 systems providing it don't incur the space overhead of linking
830 with the version in lib. Cross compiling builds always use the
833 * ls.c (decode_switches): Set SORT_TYPE. Before, ls -c was sorting
834 by name, rather than change time. Reported by Ken Estes
835 (m-ke0082@sparky.cs.nyu.edu).
837 * du.c: (save_cwd, restore_cwd, free_cwd): Remove functions.
838 New versions have been broken out into save-cwd.c.
839 (du_files): Adapt to handle status code returned by new versions
840 of save_cwd and restore_cwd.
841 (count_entry): Likewise.
843 * all programs (main): Include program name in --version output.
845 * src/Makefile.in (cp.o): Depend on ../lib/obstack.h.
847 * xstrtol.c, xstrtol.h: New files.
848 * xstrtoul.c, xstrtoul.h: New files.
849 * lib/Makefile.in (SOURCES, OBJECTS, DISTFILES): Update for new files.
851 * chgrp.c (parse_group): Use xstrtoul instead of isnumber; the
852 latter would silently overflow, accepting a group id larger
854 (isnumber): Remove now-unused static function.
855 (change_file_group) [MAXUID]: Give a more descriptive message
856 when numeric group id is larger than MAXUID.
858 Sat May 27 00:35:47 1995 Jim Meyering (meyering@comco.com)
860 * system.h [!STDC_HEADERS && HAVE_MEMORY_H]: Include memory.h.
861 Without this, SunOS doesn't get type for memchr.
862 Reported by Kaveh Ghazi.
864 Sun May 21 07:20:55 1995 Jim Meyering (meyering@comco.com)
866 * all source files (usage): Include one- or two-line synopsis
867 in --help output. From Karl Berry.
869 * Makefile.in (.PHONY): TAGS is not a phony target. From Franc,ois.
871 * All Makefile.in (install-exec, install-exec): New targets.
874 * all Makefile.in (maintainer-clean): Renamed from realclean
877 * euidaccess.c: No longer include safe-l?stat.h.
878 * fsusage.c: Likewise.
880 * makepath.c: Likewise.
882 * rename.c : Likewise.
885 Sat May 13 07:47:44 1995 Jim Meyering (meyering@comco.com)
887 * lib/Makefile.in: Remove safe-l?stat.[ch]in and related rules.
888 (maintainer-clean): Rename from realclean.
889 (.PHONY): New dependencies.
890 [.c.o]: Remove -I. since safe-l?stat.h are no longer used.
892 * argmatch.c (argmatch): Include sys/types.h and declare length
893 argument with type size_t.
895 * backupfile.c: Remove unnecessary definitions for r?index.
896 Update definitions for ISDIGIT.
898 * basename.c (basename): Make argument const.
900 * euidaccess.c (eaccess_stat): Make statp and path arguments const.
901 (euidaccess): Make statp argument const. Use stat, not safe_stat.
903 * fsusage.c (statfs): Use stat, not safe_stat.
904 * isdir.c (isdir): Likewise.
905 * mkdir.c (mkdir): Likewise.
906 * rename.c (rename): Likewise.
907 * rmdir.c (rmdir): Likewise.
909 * userspec.c (parse_user_spec): Use strchr, not index.
910 [!HAVE_STRING_H]: Define strchr in terms of index, not the
913 * makepath.c: (make_path): Use stat, not SAFE_STAT.
914 Use strchr, not index. Adjust defines accordingly.
916 * makepath.h: Undef __P before defining.
917 Guard definition with simpler `#if __STDC__'.
919 * chgrp.c: Use stat (lstat), not safe_stat (safe_lstat).
922 * cp-hash.c: Likewise.
926 * install.c: Likewise.
934 Fri May 12 21:21:23 1995 Jim Meyering (meyering@comco.com)
936 * mv.c (movefile): Remove a single trailing slash from destdir
937 before concatenating with `/' and filename for `ok to overwrite...'
938 message. Reported by Franc,ois Pinard.
940 Mon May 1 23:03:30 1995 Jim Meyering (meyering@comco.com)
942 * ls.c (quote_filename): Never return NULL when quoting filenames
943 as C-strings. --quote-name was quoting only strings containing
944 at least one C-quotable character. Reported by David J. MacKenzie.
946 Mon Mar 20 21:44:40 1995 Jim Meyering (meyering@comco.com)
948 * rename.c (rename): Compare src and dest inode numbers rather
949 than src inode and dest dev when determining whether they refer
950 to the same file. From marc@math.cornell.edu (Marc Parmet).
952 * df.c (usage): Add ellipsis after `[OPTION]'. Use FILE,
953 not deprecated PATH in text of help message. From Karl Berry.
955 Fri Mar 10 21:13:23 1995 Jim Meyering (meyering@comco.com)
957 * src/*.c: Update Copyright dates.
959 * src/Makefile.in (uninstall): Handle case in which LIBPROGS is empty.
960 Reported by Peter Smidt <smidt@cd.chalmers.se>.
962 Thu Feb 23 22:29:11 1995 Jim Meyering (meyering@comco.com)
964 * du.c (save_cwd) [!HAVE_FCHDIR]: Always initialize cwd->desc.
965 (restore_cwd) [!HAVE_FCHDIR]: Remove unnecessary redefinition
966 of fchdir. Both from Bruno Haible.
968 Mon Feb 20 22:54:39 1995 Jim Meyering (meyering@comco.com)
970 * du.c (save_cwd, restore_cwd): New functions.
971 (main): Use them instead of open coded versions.
972 (count_entry): Use them here instead of relying on chdir ("..") --
973 but only when necessary. Before, with --dereference (-L),
974 traversing a symlink caused failure because chdir ("..") didn't
975 work as expected. Reported by Bruno Haible.
977 Sat Feb 11 07:52:01 1995 Jim Meyering (meyering@comco.com)
979 * configure.in (AC_REPLACE_FUNCS): Add memcmp, memcpy, and memset.
980 (AC_CHECK_FUNCS): Add strchr and strrchr.
981 * lib/Makefile.in (SOURCES): Add memcmp.c, memcpy.c, and memset.c.
983 * system.h: Remove index/rindex and bcmp/bcopy/bzero references.
984 Separate errno declaration from STDC_HEADERS.
986 * dd.c (copy): Use memset, not bzero.
987 (copy_simple): Use memcpy, not bcopy.
989 * fsusage.c (get_fs_usage, statfs): Use safe_read, and safe_stat
990 rather than bare read and stat. From Bruno Haible.
992 * lib/Makefile.in (DISTFILES): Add error.h.
994 * chgrp.c, chmod.c, chown.c, cp-hash.c, cp.c, df.c, du.c, install.c,
995 ln.c, ls.c, mv.c, mvdir.c, rm.c, touch.c: Rename SAFE_STAT and
996 SAFE_LSTAT to safe_stat and safe_lstat.
998 * basename.c (basename): Use strrchr, not rindex.
999 [!STDC_HEADERS && !HAVE_STRING_H]: Define strrchr to rindex.
1001 Tue Dec 27 07:07:53 1994 Jim Meyering (meyering@comco.com)
1003 * src/*.c: Include "error.h" rather than simply declaring
1005 * src/Makefile.in (OBJECTS): Depend on ../lib/error.h.
1007 * sync.c (main): Make error message accurate.
1009 * dd.c (skip): Use safe_read instead of read.
1010 (copy): Use full_write instead of write.
1013 Sat Dec 10 00:02:09 1994 Jim Meyering (meyering@comco.com)
1015 * Makefile.in (install): Install `install' first as transformed
1016 `ginstall,' then remove the target (transformed `install')
1017 and move GNU install into its place. Before, the installation
1018 process failed on systems (e.g. HPUX) that can't overwrite the
1019 executable associated with a running process.
1021 * system.h [!HAVE_STRING_H]: Define strchr to index and strrchr to
1022 rindex instead of the other way around.
1023 * rmdir.c (remove_parents): Use strr?chr instead of r?index.
1024 * mvdir.c (main): Likewise.
1025 * dd.c (parse_conversion, scan_args): Likewise.
1026 * cp.c (copy, make_path_private): Likewise.
1028 * system.h: Include <ctype.h> and define IS* macros.
1029 * touch.c: No longer include <ctype.h>.
1030 * chown.c: Likewise.
1031 * install.c: Likewise.
1032 [isascii, ISDIGIT]: Remove definitions.
1033 * chgrp.c: Likewise.
1036 Sun Dec 4 14:53:12 1994 Jim Meyering (meyering@comco.com)
1038 * doc/Makefile.in (DISTFILES): Add getdate.texi.
1040 Fri Nov 11 11:15:20 1994 Jim Meyering (meyering@comco.com)
1042 * mknod.c (my_strtol): New function.
1043 (main): Use it instead of atoi to convert argument strings to
1044 major and minor device numbers. Now, mknod diagnoses invalid
1045 device numbers and accepts octal and hexadecimal as well as
1046 decimal string arguments. Ralf Lammers
1047 <rlammers@physik.uni-osnabrueck.de> suggested that mknod accept
1048 hex device numbers for compatibility with HPUX's mknod program.
1050 * configure.in (AC_REPLACE_FUNCS): Add strtol.
1051 * lib/Makefile.in (SOURCES): Add strtol.c.
1053 Sun Nov 06 00:18:56 1994 Jim Meyering (meyering@comco.com)
1057 Sat Nov 05 15:20:07 1994 Jim Meyering (meyering@comco.com)
1059 * group-member.c: Use up-to-date version.
1060 * group-member.h: New file.
1061 * lib/Makefile.in (DISTFILES): Add group-member.h.
1062 (group-member.o): Depend on group-member.h.
1066 * src/Makefile.in (obstack.o): Depend on obstack.h.
1067 * makepath.c (makepath) [__STDC__]: Add an ANSI-style prototype.
1070 Fri Nov 04 17:27:55 1994 Jim Meyering (meyering@comco.com)
1074 Thu Nov 03 12:59:34 1994 Jim Meyering (meyering@comco.com)
1076 * makepath.h: New file.
1077 * makepath.c: Include it.
1078 Add an argument: PRESERVE_EXISTING.
1079 Declare char* arguments const.
1080 * install.c, mkdir.c: Update callers. Set it in mkdir.c so
1081 that `mkdir -p' ignores existing directories as POSIX mandates.
1082 Before, it would try to change owner and/or permissions of such
1083 directories. Christopher S. Arthur <csa@halcyon.com> reported
1084 the mkdir -p failure.
1085 * lib/Makefile.in (DISTFILES): Add it.
1086 (makepath.o): Depend on makepath.h.
1087 * src/Makefile.in (install.o, mkdir.o): Depend on makepath.h.
1088 * cp.c (make_path_private): Rename function from make_path to
1090 (do_copy): Update caller.
1092 * ls.c: Include <limits.h> before system.h because limits.h on
1093 some systems undefines PATH_MAX, whereas system.h includes pathmax.h
1094 which sets PATH_MAX. From Kaveh Ghazi.
1096 * euidaccess.c: Define S_IXUSR, S_IXGRP, and S_IXOTH in terms of
1097 S_IEXEC if they're not already defined. Reported by Kaveh Ghazi
1098 and Daniel Hagerty <hag@gnu.ai.mit.edu>.
1100 Tue Nov 01 06:18:20 1994 Jim Meyering (meyering@comco.com)
1102 * eaccess.c (euidaccess): Rename from eaccess to avoid conflict
1103 with like-named, different function in some C libraries.
1104 * euidaccess.c: Renamed from eaccess.c
1105 * lib/Makefile.in (SOURCES): Rename eaccess.c.
1106 Update dependency, too.
1107 * configure.in (AC_REPLACE_FUNCS): Check for euidaccess
1109 Mon Oct 31 08:02:31 1994 Jim Meyering (meyering@comco.com)
1111 * ls.c (dired_dump_obstack): Cast obstack_finish for non-ANSI
1112 compilers. Kaveh Ghazi reported the problem.
1114 Sat Oct 29 00:42:18 1994 Jim Meyering (meyering@comco.com)
1116 * fsusage.c (get_fs_usage) [STAT_STATFS4]: Define CONVERT_BLOCKS
1117 to adjust_blocks for _AIX. Was getting off-by-8x numbers.
1119 * df.c: Make --sync the default.
1120 Add new option: --no-sync.
1121 Remove short option alias for --sync.
1124 * ls.c [!STDC_HEADERS]: Declare free.
1125 (dired_dump_obstack): Cast pos[i] (of type size_t) to int so it
1126 matches %d in printf.
1127 (quote_filename): Fix typo in stpcpy call.
1129 Thu Oct 27 00:02:45 1994 Jim Meyering (meyering@comco.com)
1131 * fsusage.c: Include <sys/stat.h> before safe-stat.h.
1133 * cp.c (make_path): Don't change protections on existing directory.
1134 Reported by Andreas Schwab.
1136 * df.c: New option: --sync. No longer perform sync by default.
1137 Do it only when this option is used. Invoking sync can be very
1138 expensive, and it's not clear that doing so yields more up to date
1139 results. With encouragement/prodding from Paolo Zeppegno
1140 (paolo@to.sem.it), Nick Holloway, and Kaveh Ghazi.
1142 Thu Oct 20 00:52:59 1994 Jim Meyering (meyering@comco.com)
1144 * system.h [!S_IEXEC]: Define as S_IXUSR.
1146 * cp.h [S_IEXEC]: Remove definition. cp.c doesn't use it.
1148 * ls.c [!INT_MAX]: Define to 2^31 - 1 so subsequent #if test works.
1149 [S_IEXEC]: Remove definition. It's in system.h now.
1150 (usage): Sort options, but without segregating upper and lower case.
1152 * ls.c: Support for new option: --dired (-D).
1153 (dired, dired_pos, dired_obstack, subdired_obstack): Global variables.
1154 [PUTCHAR, FPUTS, FPUTS_LITERAL, PUSH_CURRENT_DIRED_POS]: New macros
1155 (dired_dump_obstack, quote_filename): New functions.
1156 (main): Initialize obstacks.
1157 (decode_switches): Recognize -D.
1158 (print_dir): Make arguments `const.'
1159 Record directory name indices in obstack.
1160 (print_dir, print_long_format, print_type_indicator): Use macros
1161 FPUTS, FPUTS_LITERAL, PUTCHAR for output.
1162 (print_long_format): Record file name indices in obstack.
1163 (print_name_with_quoting): Just call quote_filename and output the
1166 Mon Oct 17 23:56:36 1994 Jim Meyering (meyering@comco.com)
1168 * savedir.c: Indent CPP conditionals. Change some #ifdefs to #ifs.
1169 From Franc,ois Pinard.
1171 Mon Oct 17 10:27:26 1994 David J. MacKenzie (djm@duality.gnu.ai.mit.edu)
1173 * lib/dirname.c: Use strrchr, not rindex.
1175 Sun Oct 16 07:53:27 1994 Jim Meyering (meyering@comco.com)
1177 * system.h (S_IXUSR, S_IXGRP, S_IXOTH): Define these in terms of
1178 S_IEXEC if they're not already defined. From Kaveh Ghazi.
1180 * eaccess.c (eaccess_stat): Don't use NULL in comparison.
1181 Some systems don't define it except in stdio.h -- and including
1182 (yes, just including) stdio.h has been known to significantly
1183 increase object code size (though admittedly, that probably
1184 happens only on old systems). Kaveh Ghazi reported the problem.
1186 * src/Makfile.in lib/Makfile.in (DEFS): Remove -Dlint.
1187 It causes problems on broken pyramid system.
1190 Sat Oct 08 10:39:32 1994 Jim Meyering (meyering@comco.com)
1192 * mountlist.c: Always include <sys/param.h> if it exists.
1193 (fstype_to_string) [__NetBSD__]: Don't define this function.
1194 (read_filesystem_list) [__NetBSD__]: Use fsp's f_fstypename field,
1195 rather than fstype_to_string (f_type). With suggestions from
1196 Greg Hudson (ghudson@mit.edu).
1198 * lib/Makefile.in (OBJECTS): Remove eaccess.o.
1199 * configure.in (AC_REPLACE_FUNCS): Add `eaccess' here instead.
1200 The Hurd and Linux will have it.
1202 Fri Oct 07 20:27:48 1994 Jim Meyering (meyering@comco.com)
1204 * (doc): New subdirectory with texinfo documentation.
1205 * fileutils.texi: Thanks to Franc,ois Pinard and Karl Berry!
1207 * Makefile.in (All of them): Update from the ones in sh-utils.
1208 From now on, rules and definitions that are comon to the fileutils,
1209 textutils, and sh-utils will get ChangeLog entries only in the
1212 * Makefile.in (install, uninstall): Prepend ginstall->install
1213 mapping to standard $(transform) sed mapping.
1215 * chgrp.c, chmod.c, chown.c, install.c, mkdir.c, mkfifo.c, mknod.c,
1216 rm.c, rmdir.c (main): Diagnose wrong number of argument -- usually
1217 too few -- instead of just referring the user to the --help option.
1218 * mknod.c (main): Give diagnostics explaining specific problems
1219 instead of just the usage message. Reported by Karl Berry.
1221 * configure.in: Overhaul tests that determine how to get filesystem
1222 usage statistics. Now, most use AC_TRY_RUN and test for the precise
1223 feature that will be used. I know that that will make configuring a
1224 little harder for the people who cross compile, but if one of them
1225 is annoyed enough (or complains loudly enough :-) maybe someone will
1226 find the time to add tests to be used solely when cross compiling.
1227 * acconfig.h (STAT_READ): Rename to STAT_READ_FILSYS.
1228 * fsusage.c: Reorganize accordingly.
1230 Tue Oct 04 20:38:12 1994 Jim Meyering (meyering@comco.com)
1232 * chmod.c (main): Remove trailing slashes from file name arguments.
1233 Otherwise, `chmod 600 foo/; chmod 700 foo/' failed with the error
1234 `chmod: foo/: Permission denied' under Linux 1.1.51. Reported by
1235 Thomas Koenig (ig25@fg70.rz.uni-karlsruhe.de).
1236 * chown.c (main): Likewise.
1238 Thu Oct 2 23:03:32 1994 Jim Meyering (meyering@comco.com)
1240 * configure.in: Replace obsolete AC_DIR_HEADER with AC_HEADER_DIRENT
1241 and AC_FUNC_CLOSEDIR_VOID.
1243 * configure.in: Remove AC_SIZEOF_TYPE(int).
1244 ls.c: Instead of comparing SIZEOF_INT == 2, compare INT_MAX to 2^16.
1245 Suggestion from Roland McGrath.
1247 Sat Oct 01 21:23:27 1994 Jim Meyering (meyering@comco.com)
1249 * src/*.c: Remove CONFIG_BROKETS conditional.
1251 * {*/,}Makefile.in: Revamp to look much like those in sh-utils.
1252 * acconfig.h (HAVE_FTRUNCATE): Remove it.
1253 (ino_t, D_INO_IN_DIRENT): Add these.
1255 * configure.in: Convert for autoconf-2.0.
1256 * backupfile.c: Likewise.
1257 * savedir.c: Likewise.
1259 * mkdir.c, rmdir.c: Split the two functions from old mkdir.c into
1262 * chgrp.c [_POSIX_VERSION]: Test this instead of _POSIX_SOURCE.
1264 * ls.c: Don't use SIZEOF_INT because it would require configure
1265 to run a program -- then cross compilers would lose. Instead,
1266 compare INT_MAX to 64k-1 since all we need to know is whether
1267 an int is 2 bytes or larger.
1269 * rm.c [D_INO]: Use D_INO_IN_DIRENT rather than _POSIX_SOURCE in the
1270 test for how to define this macro.
1272 * system.h: Use HAVE_SYS_PARAM_H (not _POSIX_SOURCE) in test
1273 for whether to include <sys/param.h>.
1274 Likewise for <utime.h>.
1275 Update for DIRENT->HAVE_DIRENT_H etc. autoconf-2.0 changes.
1276 Ditto for VOID_CLOSEDIR->CLOSEDIR_VOID.
1278 * xgetcwd.c [!_POSIX_VERSION && !HAVE_GETCWD]: Remove
1279 !defined (_POSIX_VERSION) conjunct. From Kaveh Ghazi.
1281 Mon Sep 26 17:47:17 1994 David J. MacKenzie (djm@churchy.gnu.ai.mit.edu)
1283 * lib/*.c: Remove CONFIG_BROKETS conditional.
1284 * lib/Makefile.in src/Makefile.in: Don't define it.
1286 Sun Sep 25 12:20:52 1994 Jim Meyering (meyering@comco.com)
1288 * ln.c (do_link): Give a diagnostic when trying to make a hard
1289 link to a nonexistent source file. Before, running the command
1290 `ln -i no-such-file existing-file' and responding `yes' to the
1291 prompt would both remove `existing-file' and fail to make a link.
1292 Karl Berry reported the problem.
1294 Sat Sep 10 04:34:34 1994 Roland McGrath <roland@churchy.gnu.ai.mit.edu>
1296 * src/rm.c (remove_dir): Pass pathname to eaccess_stat.
1298 Fri Sep 2 13:54:13 1994 Michael I Bushnell <mib@geech.gnu.ai.mit.edu>
1300 * lib/Makefile.in (safe-lstat.c, safe-lstat.h, safe-stat.c,
1301 safe-stat.h): Use $(srcdir) to find source files.
1302 (.c.o): Use -I. to get safe-lstat.h and safe-stat.h from the
1304 * src/Makefile.in (incl): Add -I../lib to get lib/safe-lstat.h and
1305 lib/safe-stat.h from the build directory.
1307 Sat Aug 27 16:33:04 1994 Jim Meyering (meyering@comco.com)
1309 * ln.c (main): Accept new option --no-dereference (-n).
1310 (do_link): If the destination command line argument is a symlink
1311 to a directory and --no-dereference is given, use that as the
1312 destination instead of the file in the directory.
1313 * ln.1: Document this.
1315 * system.h [BROKEN_STAT_MACROS]: Remove unnecessary #ifdef's.
1316 From Francois Pinard.
1318 * isdir.c, makepath.c, rename.c [STAT_MACRO_BROKEN]: Remove
1321 Thu Aug 25 00:12:20 1994 Jim Meyering (meyering@comco.com)
1323 * dd.c (copy): Clean up and fix off-by-one error when freeing
1326 Thu Aug 18 11:41:16 1994 Jim Meyering (meyering@comco.com)
1328 * du.c (du_files) [HAVE_FCHDIR]: Use open (".", ...) and fchdir
1329 instead of xgetcwd and chdir. Otherwise, running du in a subdirectory
1330 of an unreadable directory would fail because xgetcwd fails.
1331 * configure.in (AC_HAVE_FUNCS): Add fchdir. AIX-2.3 (for one)
1334 * lib/Makefile.in (DISTFILES): Include getdate.c and posixtim.c
1335 so one doesn't need $(YACC).
1336 Add dependencies on safe-stat.h.
1338 Sat Jul 30 08:08:02 1994 Jim Meyering (meyering@comco.com)
1340 * du.c (main): Don't initialize automatic array CWD_ONLY in declaration.
1341 Some compilers don't allow that.
1343 * backupfile.c [DIRENT]: Remove spurious `|| defined(_POSIX_VERSION)'.
1346 * safe-xstat.c.in, safe-xstat.h.in: New files.
1347 * lib/Makefile.in: Add rules and dependencies for building safe-stat.c,
1348 safe-stat.h, safe-lstat.c, and safe-lstat.h from them.
1350 * eaccess.c (eaccess): Use SAFE_STAT instead of stat
1351 (and/or SAFE_LSTAT instead of lstat) to avoid unnecessary failure
1352 on systems for which stat (lstat) can return EINTR.
1353 * fsusage.c (statfs): Ditto.
1354 * isdir.c (isdir): Ditto.
1355 * makepath.c (make_path): Ditto.
1356 * rename.c (rename): Ditto.
1357 * chgrp.c (change_file_group): Ditto.
1358 * chmod.c (change_file_mode): Ditto.
1359 * chown.c (change_file_owner): Ditto.
1360 * cp-hash.c (remember_created): Ditto.
1361 * cp.c (main, do_copy): Ditto.
1362 * df.c (main, show_point): Ditto.
1363 * du.c (main, du_files, count_entry): Ditto.
1364 * install.c (copy_file): Ditto.
1365 * ln.c (main, do_link): Ditto.
1366 * ls.c (gobble_file): Ditto.
1367 * mv.c (is_real_dir, do_move): Ditto.
1368 * mvdir.c (main): Ditto.
1370 * touch.c (main, touch): Ditto.
1372 * Makefile.in (install): Tell GNU make that this target is .PHONY
1373 so it doesn't unnecessarily build ./install from install.sh.
1375 Tue Jul 26 11:33:53 1994 Jim Meyering (meyering@comco.com)
1377 * system.h: Remove `|| defined(_POSIX_VERSION)' from test that
1378 decides whether to include <fcntl.h>. From Francois Pinard.
1380 Sun Jul 03 08:44:00 1994 Jim Meyering (meyering@comco.com)
1382 * configure.in [AC_HAVE_HEADERS]: Add sys/param.h, for definition
1383 of HAVE_SYS_PARAM_H, now tested in pathmax.h.
1385 * makepath.c (make_path): Avoid spurious failure for file names
1386 that contain `/.' or `/..'. From Andreas Schwab
1387 <schwab@issan.informatik.uni-dortmund.de>.
1389 * dd.c (main): Handle SIGPIPE like other interrupts.
1390 From Scott L. Burson <gyro@zeta-soft.com>.
1392 * df.c (main, show_dev, usage): New option --print-type=fstype.
1393 From Arne Henrik Juul.
1396 Thu Jun 30 10:28:32 1994 Jim Meyering (meyering@comco.com)
1398 * ls.c (longdiff) [SIZEOF_INT == 2]: Choose which version of this
1399 macro to use based on SIZEOF_INT rather than obsolete INT_16_BITS.
1400 [INODE_DIGITS]: New macro.
1401 (print_long_format): Use it.
1402 (print_file_name_and_frills): Ditto.
1403 (length_of_file_name_and_frills): Ditto.
1404 (print_long_format): Add a couple casts to unsigned types.
1406 * ls.c: Change type name from `struct file' to `struct fileinfo'.
1407 David J. Mackenzie reported a name conflict on HPUX with the former.
1409 * dd.c (copy): Allocate an extra byte so I/O buffer begins on an
1410 even address. This because the ITOS 3000WS running SEIUX 3.1
1411 (a descendant of MIPS RISC/OS 4.x) has SCSI device drivers that
1412 require the I/O buffer begin on an even address. From
1413 Tilman Schmidt <tilman@gb1.sema.de>.
1415 Mon Jun 20 23:45:34 1994 Jim Meyering (meyering@comco.com)
1417 * configure.in: Use AC_PROGRAM_PATH to get values for LN, MV, RM.
1418 (AC_HAVE_FUNCS): Add getgroups.
1419 (AC_OUTPUT): Remove touch command.
1421 * eaccess.c (in_group): Remove static function. Use group_member
1423 (eaccess_stat, eaccess): Change calling sequence to take filename.
1424 Save UID and GID and use access if they are the same as effective IDs.
1425 (main) [TEST]: Test driver.
1426 * cp.c (copy): Update callers.
1427 * mv.c (do_move): Ditto.
1428 * rm.c (remove_file): Ditto.
1430 * cp.c (copy): With --preserve (-p) for non-root users, don't even
1431 try to preserve file ownership in chown call. Otherwise, on systems
1432 with the mis-feature allowing non-root users to change file ownership,
1433 the subsequent chmod would fail.
1435 * userspec.c (parse_user_spec): Rewrite. Be careful to free all
1436 allocated memory upon error.
1437 (main) [TEST]: Test driver.
1439 * src/Makefile.in (uninstall): Delete $(LIBPROGS) one at a time
1440 instead of like `rm -f $(libdir)/$(LIBPROGS)'. The old way loses
1441 when LIBPROGS is empty and $(libdir) is a non-directory, and would
1442 lose if LIBPROGS could ever have more than one word.
1443 * (RM, LN, MV, INSTALL): Use values determined by ./configure instead
1444 of the newly built binaries so people can build with a cross
1445 compiler and still run `make (un)install.'
1447 * chgrp.c (change_file_group): Give a better error message when
1448 failing because the invoking user does not belong to the requested
1449 group. This affects systems on which chown sets errno to EPERM
1450 for both `inaccessible file' and `user not a member of the specified
1451 group' errors. Before, `chgrp bin file-I-own' would give the
1452 misleading and incorrect diagnostic `chgrp: file-I-own: Not owner'.
1453 Now it reports `you are not a member of group `bin''.
1454 Thomas A Peterson (tap@src.honeywell.com) reported this weakness.
1456 * long-options.c: Move from src/ to lib/.
1457 * long-options.h: Ditto.
1458 * src/Makefile.in: Remove references to long-options.[ch].
1459 * lib/Makefile.in (SOURCES, OBJECTS): Add long-options.[co].
1461 Sat Jun 18 15:45:34 1994 Jim Meyering (meyering@comco.com)
1463 * du.c (count_entry): Print "/" instead of zero-length string.
1464 From Kjetil Torgrim Homme <kjetilho@ifi.uio.no>.
1466 Sun May 29 13:43:50 1994 Jim Meyering (meyering@comco.com)
1468 * group-member.c: New file.
1469 * lib/Makefile.in (SOURCES, OBJECTS): Add group-member.[co].
1472 * Makefile.in (PROGS): Add sync.
1473 (SOURCES): Add sync.c
1474 * src/Makefile.in: Add rules and dependencies for sync.
1476 * configure.in: Use AC_SET_MAKE and AC_PROG_INSTALL.
1477 If AC_FUNC_CHECK doesn't find getgroups, add -lbsd if possible.
1478 This was reported by Tilman Schmidt <ts@gb1.sema.de>
1479 to be necessary on an ITOS 3000WS running SEIUX 3.1.
1481 * Makefile.in: Edit MAKE assignments into @SET_MAKE@.
1482 (Makefile): Remove dependencies on */Makefile.in.
1483 Change the rule so running config.status creates only Makefile.
1484 (stamp-config): Have config.status generate only config.h.
1486 * {lib,man,src}/Makefile.in (Makefile): Add single dependency on
1487 Makefile.in and rule to make config.status create only Makefile.
1489 * system.h: Move from lib to src.
1490 * src/Makefile.in (DISTFILES): Add system.h.
1491 * lib/Makefile.in (DISTFILES): Remove system.h.
1493 Mon Apr 18 19:54:24 1994 Jim Meyering (meyering@comco.com)
1495 * documentation: Change uses of `pathname' and `path' as per
1498 Fri Apr 15 20:41:15 1994 Jim Meyering (meyering@comco.com)
1500 * mv.c (main): Give a reason for failure when given fewer than
1501 two non-option arguments, rather than just the pointer to --help.
1502 * ln.c (main): Ditto, but for no non-option arguments.
1504 * configure.in: Update for autoconf-1.8.
1505 Use AC_CHECKING instead of echo.
1506 Use AC_SIZEOF_TYPE instead of obsolete AC_INT_16_BITS.
1508 Wed Apr 13 11:18:19 1994 Jim Meyering (meyering@comco.com)
1510 * cp.c (copy_reg): Correct off-by-DEV_BSIZE error in test for
1511 whether a file has holes. From Michael Bushnell <mib@gnu.ai.mit.edu>.
1513 Wed Mar 30 08:53:21 1994 Jim Meyering (meyering@comco.com)
1515 * configure.in: Use AC_SET_MAKE.
1516 * Makefile.in: Edit MAKE assignments into @SET_MAKE@.
1518 Mon Mar 14 11:01:09 1994 Jim Meyering (meyering@comco.com)
1520 * fsusage.c (adjust_blocks): Return -1 when FROMSIZE is non-positive.
1521 Suggestion from Andries.Brouwer@cwi.nl. He reported that df failed
1522 with divide by zero when trying to process an entry for an nfs file
1523 system mounted over a SLIP line after the SLIP connection had been
1525 [convert_blocks]: Rename macro to CONVERT_BLOCKS.
1527 Sat Jan 29 13:24:07 1994 Jim Meyering (meyering@comco.com)
1529 * du.c (main): Call du_files (with ".") when there are no
1530 non-option arguments rather than treating that as a special case.
1531 (du_files): Ignore return value from count_entry.
1532 (count_entry): Accumulate file sizes into new global sum used for
1533 the -c option; the return value is unchanged and is still used
1534 by recursive calls. Now, using -S and -c together works.
1535 Add parentheses to clarify precedence.
1537 Fri Jan 28 11:02:21 1994 Jim Meyering (meyering@comco.com)
1539 * configure.in: Don't set LDFLAGS since linking now uses both
1542 Thu Jan 13 17:27:38 1994 Jim Meyering (meyering@comco.com)
1544 * src/Makefile.in: Change all link commands to use both $(CFLAGS)
1547 Mon Jan 10 01:20:38 1994 Jim Meyering (meyering@comco.com)
1549 * man/Makefile.in (manprefix): Use binprefix as the default.
1551 Thu Dec 30 23:11:10 1993 Jim Meyering (meyering@comco.com)
1553 * The following changes are necessary to avoid spurious failures
1554 when a read or write system call is interrupted (e.g. by SIGTSTP).
1555 A POSIX implementation of those system calls may either return
1556 -1 and set errno to EINTR or return a positive value indicating
1557 that a partial read or write has completed successfully. On Linux
1558 0.99.14, interrupted read and write system calls return -1/EINTR.
1559 Thanks to Bruno Haible <haible@ma2s2.mathematik.uni-karlsruhe.de>
1560 for pointing this out.
1562 * full-write.c, safe-read.c: New files.
1564 * cp.c (copy_reg): Use full_write instead of write. Handle
1565 errno == EINTR (instead of failing) after read system call.
1566 * dd.c (skip): Handle errno == EINTR (instead of failing) after
1568 (copy): Use safe_read instead of read.
1569 * install.c (copy_file): Use safe_read and full_write instead of
1570 read and write system calls.
1571 * mv.c (copy_reg): Ditto.
1572 * touch.c (utime_now): Ditto.
1574 Tue Dec 28 15:49:32 1993 Jim Meyering (meyering@comco.com)
1576 * install.sh: New file.
1577 Makefile.in [DISTFILES]: Add it.
1579 Sat Dec 18 01:12:24 1993 Jim Meyering (meyering@comco.com)
1581 * configure.in (AC_OUTPUT): Put `touch stamp-config' in second arg
1582 so it goes in config.status. This eliminates unnecessary second run
1585 Thu Nov 18 00:03:24 1993 Jim Meyering (meyering@comco.com)
1587 * configure.in [STAT_STATFS2_FSIZE]: Fix test (that had obsolete
1588 and now-broken use of AC_HEADER_EGREP) so that this flag is set
1591 Mon Oct 25 20:27:00 1993 Jim Meyering (meyering@comco.com)
1593 * cp-aux.c, df.c, install.c, ln.c, ls.c, mkdir.c, mkfifo.c,
1594 mknod.c, mv.c, touch.c: Use the preferred `--longopt=arg'
1595 syntax in --help message rather than `--longopt arg'.
1596 From Francois Pinard.
1598 Tue Oct 19 07:02:18 1993 Jim Meyering (meyering@comco.com)
1602 Mon Oct 18 00:13:40 1993 Jim Meyering (meyering@comco.com)
1604 * src/*.c (usage): Now the usage message is simply
1605 "Try `%s --help' for more information. From Francois Pinard.
1607 * src/Makefile.in [LIBPROGS]: Depend on ../lib/libfu.a and
1608 version.o. From Francois Pinard.
1610 * src/*.c (usage): Remove blank line before "Try `%s --help..."
1613 Sun Oct 17 00:19:58 1993 Jim Meyering (meyering@comco.com)
1615 * fileblocks.c [!NINDIR]: Define BSIZE only if it's not already
1618 * ls.c (print_long_format): Cast printf args major and minor
1619 so they'll have types matching %u format even on systems
1620 where those macros have signed type.
1622 Sat Oct 16 00:25:42 1993 Jim Meyering (meyering@comco.com)
1624 * chmod.c (change_file_mode): Reapply Oct 6 change for symlinks.
1625 Somehow it got removed from working sources.
1627 * lib/Makefile.in [OBJECTS]: Change dependency to ../config.h so
1628 it works when building in a subdirectory. From Rick Sladkey
1629 (jrs@world.std.com).
1631 Wed Oct 13 19:43:47 1993 Jim Meyering (meyering@comco.com)
1633 * cp.c (copy), ls.c (get_link_name): Complete Aug 27 change so
1634 that we use PATH_MAX + 1 rather than sizeof(char*) as size of
1635 buffer in readlink call. This was causing spurious errors.
1637 * cp.c (copy), mv.c (do_move), rm.c (remove_file, remove_dir):
1638 Cast to `unsigned int' stat->st_mode printf arguments corresponding
1639 to %o formats to avoid warnings.
1641 * lib/Makefile.in [DEFS]: Remove -DMVDIR. Add -DCONFIG_BROKETS.
1642 (rename.o): Add a specific rule. Use -DMVDIR=... here instead.
1644 * src/Makefile.in [DEFS]: Add -DCONFIG_BROKETS.
1645 (distclean): Don't delete dir.c and vdir.c; they aren't
1648 * lib/Makefile.in: Make all .o files depend on $(srcdir)/../config.h.
1649 * src/Makefile.in: Ditto.
1651 Sun Oct 10 13:38:54 1993 Jim Meyering (meyering@comco.com)
1653 * src/Makefile.in (dist): Depend on $(DISTFILES).
1655 * src/Makefile.in [libdir, LIBPROGS]: Define them.
1656 From Francois Pinard.
1658 * posixtm.y: [HAVE_CONFIG_H, CONFIG_BROKETS]: Include <config.h>
1659 or "config.h". From Francois Pinard.
1661 * makepath.c: [HAVE_CONFIG_H, CONFIG_BROKETS]: Remove the duplicate
1662 #ifdef block following the alloca #ifdefs. From Francois Pinard.
1664 * df.c: Remove unnecessary dcl of strstr.
1666 Sat Oct 9 13:30:28 1993 Jim Meyering (meyering@comco.com)
1668 * configure.in [STATFS_OSF1]: Change name to STAT_STATFS3_OSF1
1669 to be consistent with names of the other STAT_* macros.
1670 * acconfig.h: Ditto.
1673 * acconfig.h: Add comments.
1674 * Makefile.in: Remove comments about -D flags that could be added
1675 to DEFS; now (using autoheader) those comments end up in config.h.
1677 * Makefile.in (configure, config.h.in): Warn that they may not be
1678 up to date. Don't touch them.
1680 * ls.c (usage): Split long usage string between two fprintf
1681 statements to avoid default limit of SGI's cc on string length.
1683 * Makefile.in, src/Makefile.in [PROGS]: Alphabetize.
1685 * configure.in: Remove AC_UNISTD_H; add unistd.h to AC_HAVE_HEADERS.
1687 Thu Oct 07 12:57:10 1993 Jim Meyering (meyering@comco.com)
1689 * chgrp.c, chmod.c, chown.c, cp-aux.c, cp.c, dd.c, df.c, du.c,
1690 install.c, ln.c, ls.c, mkdir.c, mkfifo.c, mknod.c, mv.c, mvdir.c,
1691 rm.c, rmdir.c, touch.c (usage): Using --help gets long well-
1692 formatted help. Now --help writes to stdout and exits successfully.
1693 From Francois Pinard <pinard@iro.umontreal.ca>.
1695 * lib/Makefile.in [libdir]: Make sure it's defined.
1697 * posixtm.y [!__GNUC__ && !HAVE_ALLOCA_H]: Declare alloca as void*
1698 rather than char*. The latter conflicts with a dcl from bison.simple.
1700 Wed Oct 06 18:22:00 1993 Jim Meyering (meyering@comco.com)
1702 * chmod.c (change_file_mode): Add an argument to control how symbolic
1704 (main, change_dir_mode): Reflect changed calling sequence.
1705 Now symlinks listed on the command line are processed (they
1706 were ignored before); the permissions of the dereferenced files are
1707 changed. Symlinks encountered in recursive traversals are still
1708 ignored. This makes GNU chmod act more like e.g. Sun's.
1709 From Nick Holloway <alfie@dcs.warwick.ac.uk>.
1710 * chmod.1: Document it.
1712 Tue Oct 05 14:52:02 1993 Jim Meyering (meyering@comco.com)
1714 * configure.in: Add AC_STAT_MACROS_BROKEN.
1716 * isdir.c, makepath.c, rename.c, system.h [STAT_MACROS_BROKEN]:
1719 * install.c (install_file_in_dir): Use stpcpy instead of slow sprintf.
1721 * argmatch.c, backupfile.c, basename.c, dirname.c, eaccess.c,
1722 fileblocks.c, fsusage.c, getversion.c, idcache.c, isdir.c,
1723 makepath.c, mountlist.c, rename.c, savedir.c, stripslash.c,
1724 userspec.c, xgetcwd.c, xstrdup.c, yesno.c, [HAVE_CONFIG_H,
1725 CONFIG_BROKETS]: Include <config.h> or "config.h".
1727 * lib/Makefile.in, src/Makefile.in [.c.o]: Put -I.. before
1728 -I$(srcdir) so <config.h> will get the right file.
1730 * chgrp.c, chmod.c, chown.c, cp-aux.c, cp-hash.c, cp.c, dd.c,
1731 df.c, du.c, install.c, ln.c, ls.c, mkdir.c, mkfifo.c, mknod.c,
1732 mv.c, mvdir.c, rm.c, rmdir.c, touch.c, version.c [HAVE_CONFIG_H,
1733 CONFIG_BROKETS]: Include <config.h> or "config.h".
1735 * configure.in [AC_CONFIG_HEADER]: Use it.
1737 * configure.in (rename.o) [MVDIR definition]: Remove it.
1738 * lib/Makefile.in [DEFS]: Put it here instead.
1740 * config.h.in, acconfig.h: New files
1741 * Makefile [DISTFILES]: Add them.
1742 (config.h.in): Add a rule to warn if it may need to be rebuilt.
1744 * lib/Makefile [YACC]: Get definition from @YACC@.
1746 * system.h: Include <unistd.h>. This is needed for the definition
1749 Thu Sep 9 08:52:10 1993 Jim Meyering (meyering@comco.com)
1751 * src/*.c: Print version on standard output, not stderr.
1753 Fri Aug 27 23:53:50 1993 Jim Meyering (meyering@comco.com)
1755 * cp.c (copy), ls.c (get_link_name): Don't use PATH_MAX as array
1756 length in declarations because on some systems it gets defined
1757 to the function pathconf. Use dynamic allocation instead.
1759 * fsusage.c (adjust_blocks): Use `1' instead of `+1'. Many
1760 compilers don't parse the latter. From Kaveh R. Ghazi.
1762 Thu Aug 26 22:26:09 1993 Jim Meyering (meyering@comco.com)
1764 * ls.c (print_long_format, print_file_name_and_frills): Cast inode
1765 number to unsigned long and print it with %lu to avoid warnings from
1766 gcc -Wformat because the size and type of ino_t are system dependent.
1768 * cp.c (do_copy): Plug a memory leak with --parents.
1770 * ln.c (main): Like mv and cp, convert `ln x y/' to ln x y/x
1771 when a is not a directory.
1772 [PATH_BASENAME_CONCAT]: New macro.
1773 (do_link): Use it here, too.
1775 * ls.c (sort_files): Add `default: abort();' clause to switch stmts.
1777 * cp.c (do_copy): Don't remove trailing slashes from source.
1779 Wed Aug 25 21:40:00 1993 Jim Meyering (meyering@comco.com)
1781 * cp.c: Add --parents as synonym for --path. Change --path to
1782 --parents in comments. --path is deprecated.
1784 * rm.c (clear_directory): Fix incorrect test for determining when
1785 to reallocate buffer. Thanks to Ric Anderson <ric@CS.Arizona.EDU>.
1787 Fri Aug 13 17:19:52 1993 Jim Meyering (meyering@comco.com)
1789 * fsusage (adjust_blocks): Round away from zero -- this matters
1790 when computing the negative free-block count for disks that are
1791 more than 100% full.
1793 * mv.c (movefile): Use nested calls to stpcpy instead of sprintf.
1794 (is_real_dir): New function.
1795 (movefile): In addition to when dest is a directory, if dest has
1796 a trailing `/' and source is not a directory, presume the target
1797 is dest/`basename source`. This converts `mv x y/' to `mv x y/x'
1798 when x is not a directory. This change means that the command
1799 `mv any file/' will now fail rather than performing the move.
1801 * cp.c (do_copy): Similarly, convert `cp x y/' to cp x y/x when
1802 x is not a directory.
1804 Wed Aug 4 17:43:18 1993 Jim Meyering (meyering@comco.com)
1806 * ls.c (get_link_name): Don't ever use the stat field st_size as a
1807 buffer size. Too many systems don't set it properly for mount points.
1808 Instead, use a fixed-length buffer. From Michael Joosten
1809 <joost@ori.CAdlab.DE>.
1810 * cp.c (copy): Ditto.
1812 Mon Jul 19 17:39:01 1993 Jim Meyering (meyering@comco.com)
1814 * backupfile.c (concat): Temporary STR1_LENGTH should have type `int'
1817 Fri Jul 16 22:00:16 1993 David J. MacKenzie (djm@goldman.gnu.ai.mit.edu)
1819 * dd.c (print_stats): Change message from "truncated blocks"
1820 to "truncated records" for final POSIX.2 spec.
1822 Fri Jun 25 17:18:15 1993 Jim Meyering (meyering@comco.com)
1824 * mkdir.c, rmdir.c: Change --path long option to --parents to avoid
1825 confusion with search-path semantics of --path as an option to other
1826 programs. --path will still work, but is no longer documented.
1828 Tue Jun 8 00:46:26 1993 Jim Meyering (meyering@comco.com)
1830 * dd.c (parse_integer): Also accept `c' multiplier for consistency
1831 with find's -size option.
1833 Thu May 27 00:03:51 1993 Jim Meyering (meyering@comco.com)
1837 * configure.in (STAT_OSF1): Reference the statfs f_fsize member
1838 so that configure defines STAT_OSF1 only if there is such a member.
1839 Without such a reference, a Pyramid MIServer running OSx 5.1
1840 improperly defined STAT_OSF1 instead of the one it needed:
1843 Wed May 26 00:57:46 1993 Jim Meyering (meyering@comco.com)
1845 * ls.h, ls-ls.c ls-dir.c, ls-vdir.c: New files that define or
1846 simply set the new global variable ls_mode. ls_mode defines whether
1847 the executable built from ls.o should act like ls, dir, or vdir.
1848 * ls.c (decode_switches): Use the variable instead of #ifdefs.
1849 This is modelled after the approach used in GNU binutils 2.x for
1850 ar and ranlib. Here we avoid two redundant compilations.
1852 * install.c (change_attributes, copy_file, install_file_in_file):
1853 Don't call chown if we can efficiently determine that doing so is
1854 unnecessary. On some systems, calls to chown (even with your own
1855 uid and gid) fail unless made by root. On such systems install
1856 got spurious failures.
1858 Sat May 22 02:13:12 1993 Jim Meyering (meyering@comco.com)
1862 Fri May 21 18:42:27 1993 Jim Meyering (meyering@comco.com)
1864 * rename.c (rename): Be careful not to unlink `from' if it happens
1865 to be equal to `to' or (on filesystems that silently truncate
1866 filenames after 14 characters) if `from' and `to' share the
1867 significant characters. From Bruno Haible
1868 <haible@ma2s2.mathematik.uni-karlsruhe.de>.
1870 * mountlist.c, fsusage.c: Make these work under m88k DolphinOS.
1871 From Kjetil Wiekhorst J|rgensen <jorgens@pvv.unit.no>.
1873 Tue May 18 23:49:26 1993 Jim Meyering (meyering@comco.com)
1875 * mkinstalldirs: New file.
1876 * Makefile.in (installdirs): Use it.
1878 Sat May 15 01:20:26 1993 Jim Meyering (meyering@comco.com)
1880 * ln.c (do_link): Make `ln -s dir_pathname .' work when the
1881 pathname has a trailing slash.
1883 Fri May 14 23:45:52 1993 Jim Meyering (meyering@comco.com)
1885 * all source: With --version, print version and exit immediately.
1887 Wed May 12 20:48:55 1993 Jim Meyering (meyering@comco.com)
1889 * configure.in: Add check for the -ldgc library that is required
1890 for getmntent on m88k DGUX-5.4 systems.
1892 * Makefile.in (installdirs): New rules for creating installation
1893 directories. (install): Depend on it.
1895 Sat May 8 11:31:14 1993 Jim Meyering (meyering@comco.com)
1897 * lib/Makefile.in (dist): Use `cp -p' instead of just `cp'
1900 Thu May 6 22:45:25 1993 Jim Meyering (meyering@comco.com)
1902 * makepath.c: Use explicit dcl of errno only if !STDC_HEADERS.
1903 Some systems have <errno.h> but don't declare errno.
1904 From Kaveh R. Ghazi <ghazi@caip.rutgers.edu>.
1906 * getdate.y: Test TIME_WITH_SYS_TIME, not TIME_AND_SYS_TIME.
1908 Wed May 5 00:21:12 1993 Jim Meyering (meyering@comco.com)
1910 * configure.in: Add AC_TIME_WITH_SYS_TIME.
1911 * getdate.y: Use it (this is a version local to fileutils).
1913 Tue May 4 20:25:41 1993 Jim Meyering (meyering@comco.com)
1915 * du.c (count_entry): Give an error and exit if chdir ("..") fails.
1916 From Bruce Evans <bde@runx.oz.AU>.
1918 * eaccess (eaccess_stat): Cast NGROUPS_MAX to appropriate types.
1919 From Bruce Evans <bde@runx.oz.AU>.
1921 Mon May 3 22:09:24 1993 Jim Meyering (meyering@comco.com)
1923 * configure.in: Add AC_GETGROUPS_T.
1924 * eaccess.c: Don't define GETGROUPS_T. Now configure does it.
1926 Sun May 2 09:18:53 1993 Jim Meyering (meyering@comco.com)
1928 * configure.in: Check for libypsec.a on Dolphin M88K machines.
1929 This can result in significant speedup for programs that access
1930 YP information. From Kjetil Wiekhorst J{\o}rgensen
1931 <jorgens@pvv.unit.no>.
1933 Fri Apr 30 02:21:48 1993 Jim Meyering (meyering@comco.com)
1935 * ls.c (main): Make `-f' work like on standard Unix ls, instead
1936 of as a short equivalent of --full-time.
1937 * ls.1: Document it.
1939 Thu Apr 29 00:46:46 1993 Jim Meyering (meyering@comco.com)
1941 * src/Makefile.in [dir.o, vdir.o]: Make ordering of CFLAGS etc
1942 in compilation rules consistent with that in .c.o rule.
1944 * Makefile.in (dist): Depend on Makefile so that changes to
1945 Makefile.in (like adding new files to DISTRIB) are reflected
1946 in the new distribution.
1948 Tue Apr 27 21:35:11 1993 Jim Meyering (meyering@comco.com)
1950 * configure.in: Remove unnecessary AC_PROG_INSTALL.
1952 Fri Apr 23 23:39:16 1993 Jim Meyering (meyering@comco.com)
1954 * {lib,src}/Makefile.in [.c.o]: Make CPPFLAGS and CFLAGS follow
1955 other options so users can use them to override DEFS.
1957 * lib/mktime.c: Use new version from glibc instead of one from
1958 libc-subst. `touch' built with the latter didn't set proper
1959 time unless given a specific --date option.
1961 Thu Apr 22 00:22:25 1993 Jim Meyering (meyering@comco.com)
1963 * makepath.c: Decouple inclusion of errno.h from definition of
1964 STDC_HEADERS; many systems have errno.h, yet shouldn't define
1966 * makepath.c (make_path): Add EPERM clause only if both AFS and
1968 * configure.in: Test for errno.h header file.
1970 Mon Apr 19 11:21:14 1993 Jim Meyering (meyering@comco.com)
1974 * ls.c, touch.c: Don't include time.h explicitly -- it's included
1975 by system.h. From Franc,ois Pinard.
1977 * posixtm.y: Use TM_IN_SYS_TIME.
1979 * backupfile.c [index, rindex]: Don't redefine them.
1981 * system.h [alloca]: Don't redefine it.
1983 * configure.in: Check for sys/time.h; getdate.y needs it for
1984 structs timeval and timezone on some systems.
1986 Sun Apr 18 22:40:19 1993 David J. MacKenzie (djm@kropotkin.gnu.ai.mit.edu)
1988 * ls.c: Include fnmatch.h after system.h, so we get our
1989 definitions of FNM_*, not those from unistd.h.
1991 * mountlist.c [MOUNTED_GETMNTINFO]: Add #ifdef around MOUNT_PC.
1993 * configure.in: Fix test for 4.4BSD statfs to not grep for a
1994 macro in cpp output.
1996 Sun Apr 18 02:35:36 1993 Jim Meyering (meyering@comco.com)
1998 * configure.in: Check for gettimeofday.
1999 Check for `struct tm'.
2000 Change MVDIR definition so it works with new AC_DEFINE.
2002 * system.h: Remove last vestiges of USG; instead, use specific
2003 test for TM_IN_SYS_TIME to determine whether to include time.h
2006 * src/Makefile.in (install): Rewrite the test for whether to install
2007 mvdir so that it doesn't cause gratuitous failures with broken shells.
2008 Split long rule so the pieces fit in 80-column lines.
2010 Thu Apr 15 23:44:01 1993 Jim Meyering (meyering@comco.com)
2012 * lib/Makefile.in (posixtm.c): Add dependency on getdate.c to enforce
2013 sequential invocations of YACC.
2014 * (posixtm.c, getdate.c): Remove use of `bison -o' and associated
2015 conditional rename commands -- not needed since the parser generators
2016 won't be run in parallel; now bison (when used) is always invoked
2019 Tue Apr 13 09:18:18 1993 Jim Meyering (meyering@comco.com)
2021 * configure.in: Find a parser generator.
2022 * Makefile.in [MDEFINES]: Add YACC to the list of variables passed to
2024 * lib/Makefile.in (posixtm.c, getdate.c): Try first to build with
2025 `bison -o' -- for parallel makes. If that fails, use $(YACC).
2027 * posixtm.y [HAVE_MEMCPY && !HAVE_BCOPY]: Define bcopy in terms
2028 of memcpy for old versions of bison that generate parsers that
2031 * configure.in: Add tests for memcpy and bcopy.
2033 Mon Apr 12 23:02:14 1993 Jim Meyering (meyering@comco.com)
2035 * configure.in (mounted, space): Add filesystem checks for DEC Alpha
2036 running OSF/1 to complement new code in mountlist.c and fsusage.c.
2038 * lib/mountlist.c (read_filesystem_list) [MOUNTED_GETFSSTAT]: Add code
2039 to do it the OSF/1 way on a DEC alpha.
2040 From Brian Fox (bfox@tinker.crseo.ucsb.edu).
2042 * lib/fsusage.c (get_fs_usage) [STATFS_OSF1]: Add code to call OSF/1's
2043 variant of statfs. From Brian Fox (bfox@tinker.crseo.ucsb.edu).
2045 Sun Apr 11 20:29:31 1993 Jim Meyering (meyering@comco.com)
2047 * df.c (main, show_dev): Don't list dummy (automounter) filesystems
2048 unless they're explicitly listed on the command line or if the -a
2051 Fri Apr 9 11:40:48 1993 Jim Meyering (meyering@comco.com)
2053 * src/Makefile.in [.c.o]: Put CFLAGS after include directives.
2055 Wed Apr 7 23:54:48 1993 Jim Meyering (meyering@comco.com)
2057 * eaccess.c: Undefine NGROUPS_MAX before redefining it.
2058 From ghazi@caip.rutgers.edu (Kaveh R. Ghazi).
2060 Mon Apr 5 20:14:17 1993 Jim Meyering (meyering@comco.com)
2062 * chgrp.c, chmod.c, chown.c, install.c, ls.c, mkfifo.c, mknod.c,
2063 touch.c: Add `case 0: break;' for long-only options help and version.
2065 Sun Apr 4 09:38:00 1993 Jim Meyering (meyering@comco.com)
2067 * src/*.c (usage): Mention --help and --version.
2068 (main): Handle flag_help and flag_version before checking for
2071 * cp.c (copy): Declare to be static.
2073 * cp.c (copy, make_path, re_protect): Explicitly cast alloca return
2075 * ln.c (do_link): Ditto
2076 * mv.c (do_move): Ditto
2077 * makepath.c (make_path): Ditto
2079 * lib/eaccess.c (eaccess_stat): Cast to unsigned the value to
2080 be right-shifted to avoid ANSI vs K&R semantic ambiguity.
2082 * src/Makefile.in (incl): New variable.
2084 * chown.c (main): Explicitly cast -1 to [ug]id_t to avoid compiler
2087 * cp.h: Remove unneeded extern dcl of exit_status.
2089 * basename.c [rindex]: Don't redefine it.
2090 * system.h [rindex, incl, bcopy, bzero]: Ditto.
2091 * userspec.c [index]: Ditto.
2093 * Makefile.in [CFLAGS, LDFLAGS]: Don't hard-code these; get their
2094 definitions from configure.
2095 * configure.in [CFLAGS, LDFLAGS]: Assign reasonable defaults.
2097 Sat Apr 3 18:17:23 1993 Jim Meyering (meyering@comco.com)
2099 * Makefile.in [Makefile]: Add dependencies and a rule to remake it.
2100 [targets that cd then run make in subdirectories]: Don't depend
2101 on `cd ..'; use a subshell instead.
2102 [info, install-info, dvi, check, installcheck]: New targets but no
2103 rules; comply with standards.
2105 * src/Makefile.in [.c.o, dir.o, vdir.o]: Put CFLAGS after DEFS and
2106 CPPFLAGS per standards.texi.
2107 Use automatically generated dependencies.
2109 * mvdir.c (main): Remove dcl of unused variable.
2111 Thu Apr 1 18:05:48 1993 Jim Meyering (meyering@comco.com)
2113 * install.c, chgrp.c, dd.c [isascii]: Undefine before redefining.
2115 * ls.c: Move some dcls so they appear before first function.
2117 * all programs: Add --help and --version options.
2118 * version.c: Remove `Version: ' and newlines from version string.
2120 * dd.c: Convert usage to take no arguments.
2121 * lib/Makefile.in [DISTFILES]: Add version.h.
2123 Wed Mar 31 22:03:28 1993 Jim Meyering (meyering@comco.com)
2125 * configure.in [MVDIR]: Don't quote right hand side.
2126 * backupfile.c, chgrp.c, install.c: Define isascii macro to be 1
2127 also if STDC_HEADERS.
2129 Tue Mar 30 17:42:11 1993 david d `zoo' zuhn (zoo at cirdan.cygnus.com)
2131 * ls.c: Add -G,--no-group option to inhibit display of group
2133 * ls.1: Document it.
2135 Mon Mar 29 22:22:40 1993 Jim Meyering (meyering@comco.com)
2137 * system.h [ST_NBLOCKS]: Check also for __hpux. From Henrik B}kman
2138 <Henrik.Bakman@csd.uu.se>.
2140 Sun Mar 28 21:22:30 1993 Jim Meyering (meyering@comco.com)
2142 * Makefile.in (dist): Use cp when hard link fails.
2143 Use tar-1.11.2's -z option instead of -Z.
2145 * makepath.c [index]: Don't redefine.
2147 Fri Mar 26 00:32:39 1993 Jim Meyering (meyering@comco.com)
2149 * df.c (add_excluded_fs_type, excluded_fs_type): New functions adding
2150 support for --exclude-type option. Derived from Kaveh R. Ghazi
2151 <ghazi@caip.rutgers.edu>.
2153 * ls.c (decode_switches, print_long_format): New option: --full-time.
2154 From K. Richard Pixley (rich@rtl.cygnus.com)
2156 Thu Mar 25 21:02:36 1993 David J. MacKenzie (djm@goldman.gnu.ai.mit.edu)
2158 * dirname.c [rindex]: Don't redefine.
2160 Tue Mar 23 23:13:33 1993 Jim Meyering (meyering@comco.com)
2162 * ls.c (gobble_file): Don't stat symlinks unless we need to.
2163 From Mike Rendell <michael@mercury.cs.mun.ca>.
2165 * dd.c (copy, copy_with_block, copy_with_block): Decrement
2166 pending_spaces only if it's > 0. The following command didn't
2168 perl -e 'print "a a\n";'| dd of=/dev/null ibs=1 cbs=3 conv=unblock
2169 With suggestions from Chris Weber <weber@bucknell.edu>,
2170 Marlys.A.Nelson@uwrf.edu, and Albert-Lunde@nwu.edu.
2172 Fri Mar 05 00:02:53 1993 Jim Meyering (meyering@comco.com)
2174 * chmod.c: Add long-named options.
2176 Mon Feb 15 23:34:55 1993 Jim Meyering (meyering@comco.com)
2178 * rm.c (remove_file): Don't ask about overriding a mode if the
2179 target is a symbolic link -- some systems (like SGI's Irix 4.0)
2180 zero the permissions fields of symbolic links.
2181 From Arne Henrik Juul (arnej@imf.unit.no).
2183 Fri Dec 11 16:46:50 1992 David J. MacKenzie (djm@kropotkin.gnu.ai.mit.edu)
2185 * rm.c (main): If -f is given, don't complain if no file args
2188 Tue Dec 8 21:09:16 1992 David J. MacKenzie (djm@kropotkin.gnu.ai.mit.edu)
2190 * posixtm.y: Include alloca.h if HAVE_ALLOCA_H, not if sparc.
2192 Mon Dec 7 20:09:59 1992 Jim Meyering (meyering@idefix.comco.com)
2194 * install.c (isnumber), chgrp.c (change_file_group): Define ISDIGIT
2195 and use it instead of isdigit.
2197 * dd.c: Define ISLOWER and ISUPPER independent of STDC_HEADERS.
2198 Define ISDIGIT and use it instead of isdigit.
2200 Wed Dec 2 12:28:10 1992 Jim Meyering (meyering@idefix.comco.com)
2202 * all files using getopt.h: Convert static declarations of
2203 struct option to use new macros from getopt.h: no_argument,
2204 required_argument, and optional_argument.
2206 Tue Nov 24 07:54:45 1992 David J. MacKenzie (djm@goldman.gnu.ai.mit.edu)
2208 * system.h: Use HAVE_FCNTL_H instead of USG.
2210 * xgetcwd.c: Use HAVE_GETCWD instead of USG.
2212 * backupfile.c, basename.c, dirname.c, idcache.c, makepath.c,
2213 mountlist.c, stripslash.c, userspec.c, xstrdup.c, system.h:
2214 Use HAVE_STRING_H instead of USG.
2216 * system.h: Use SYSDIR and NDIR instead of USG.
2217 Define direct as dirent, not vice-versa.
2218 * ls.c, rm.c, backupfile.c, savedir.c: Use `struct dirent',
2219 not `struct direct'.
2221 Thu Nov 12 23:10:56 1992 David J. MacKenzie (djm@goldman.gnu.ai.mit.edu)
2223 * system.h: If dirent is #defined, don't define direct as dirent;
2224 for Sinix. Derived from Heinfried Korn (korn@med-in.uni-sb.de).
2226 Mon Nov 9 14:13:57 1992 Jim Meyering (meyering@idefix.comco.com)
2228 * fsusage.c (adjust_blocks): Reverse Oct 31 change --
2229 the function is more readable than the macro.
2231 * All files in src: Make all functions and extern variables static.
2232 Make all longopts arrays const as well as static.
2233 Make a couple statically initialized aggregates `const.'
2235 Sat Oct 31 16:32:17 1992 Jim Meyering (meyering@idefix.comco.com)
2237 * fsusage.c (adjust_blocks): Convert to a macro. The static
2238 function wasn't always used.
2240 * makepath.c, cp.c, ls.c: Add parentheses to expressions
2241 like (c = *p++) as per suggestion from gcc -Wall.
2243 * dd.c (swab_buffer): Fix typo that incremented pointer instead
2244 of counter. Add braces around static struct initializers.
2246 Fri Oct 30 11:40:58 1992 David J. MacKenzie (djm@goldman.gnu.ai.mit.edu)
2248 * ln.c, cp.c (main): Make -s on systems without symlinks an
2249 error, not a warning.
2251 Thu Oct 29 14:57:21 1992 David J. MacKenzie (djm@kropotkin.gnu.ai.mit.edu)
2255 * cp.c (copy, re_protect), mv.c (copy_reg): Do utime and chown
2256 before chmod, so set[ug]id bits don't get nuked.
2259 Wed Oct 28 16:13:18 1992 David J. MacKenzie (djm@kropotkin.gnu.ai.mit.edu)
2261 * cp.c, mv.c, ln.c: Rename some variables to use consistent
2262 terminology: source and destination.
2264 * ln.c, mkdir.c, mkfifo.c, mknod.c: Don't strip trailing slashes.
2265 * install.c: Don't strip slashes from dest. dirs.
2267 Mon Aug 24 12:49:14 1992 David J. MacKenzie (djm@nutrimat.gnu.ai.mit.edu)
2269 * xgetcwd.c: Make path_max unsigned, not long. From Bruce Evans.
2271 Sun Aug 23 03:06:04 1992 David J. MacKenzie (djm@nutrimat.gnu.ai.mit.edu)
2273 * idcache.c: Use a union for uid_t and gid_t. From
2274 bde@runx.oz.au (Bruce Evans).
2276 * eaccess.c: Use NGROUPS_MAX if it's defined. 386BSD is like sun.
2278 Sat Aug 22 02:36:49 1992 David J. MacKenzie (djm@churchy.gnu.ai.mit.edu)
2280 * makepath.c: Use uid_t and gid_t.
2282 * system.h, makepath.c: Use HAVE_ALLOCA_H, not sparc.
2284 * cp.c (make_path, re_protect): Allocate room for terminating NULs.
2286 Fri Aug 21 21:12:18 1992 David J. MacKenzie (djm@nutrimat.gnu.ai.mit.edu)
2288 * fsusage.c [STAT_STATVFS]: Use f_bsize if f_frsize is 0.
2289 From Paul M Reilly <pmr@rock.concert.net>.
2291 * xgetcwd.c [!errno]: Declare errno. From Karl Berry.
2293 * chown.c (main, change_file_owner, change_dir_owner): Use
2294 uid_t and gid_t. From Rob McMahon <cudcv@csv.warwick.ac.uk>
2295 and glaze@cs.mu.oz.au (Glaze).
2297 Thu Jul 23 14:29:17 1992 David J. MacKenzie (djm@nutrimat.gnu.ai.mit.edu)
2301 Sat Jul 18 20:12:56 1992 David J. MacKenzie (djm@nutrimat.gnu.ai.mit.edu)
2303 * idcache.c: Use uid_t and gid_t.
2304 (getuidbyname, getgidbyname): New functions, for cpio.
2306 * userspec.c: New file, from code in chown.c.
2309 Fri Jul 17 00:43:38 1992 David J. MacKenzie (djm@nutrimat.gnu.ai.mit.edu)
2311 * system.h: Protect from getopt prototype in stdlib.h.
2313 * ls.c [_AIX]: Include sys/ioctl.h.
2314 * fsusage.c: Include sys/vfs.h if AIX PS/2, but not if RS6000.
2315 From tranle@intellicorp.com (Minh Tran-Le).
2317 * mvdir.c: Declare getcwd. From Francois Pinard.
2319 * chown.c, chgrp.c, install.c [_POSIX_SOURCE]: Define endpwent
2320 and endgrent as empty.
2322 * makepath.c (make_path): Add cast to alloca call.
2325 * cp.c (copy, re_protect), mv.c (copy_reg): Notify root of
2326 EPERM errors from chown.
2327 * makepath.c, install.c [AFS]: Ignore EPERM from chown.
2329 * system.h (ST_NBLOCKS) [_AIX && _I386]: st_blocks is in 4K units.
2330 * fsusage.c (statfs) [_AIX && _I386]: Supply this function.
2331 From tranle@intellicorp.com (Minh Tran-Le).
2333 Thu Jul 16 23:08:39 1992 David J. MacKenzie (djm@nutrimat.gnu.ai.mit.edu)
2335 * df.c (print_header, show_dev): In inode format, print the
2336 total number of inodes as well.
2338 * fsusage.[ch], df.c (show_dev): Count internally using
2339 512-byte blocks, not 1024-byte, to avoid rounding errors.
2341 Mon Jul 6 20:03:54 1992 David J. MacKenzie (djm@nutrimat.gnu.ai.mit.edu)
2343 * rename.c: Use S_ISDIR instead of S_IFDIR.
2345 Fri Jul 3 14:36:34 1992 David J. MacKenzie (djm@nutrimat.gnu.ai.mit.edu)
2347 * fileblocks.c, system.h, cp.c, dd.c, mv.c, touch.c: Change
2348 FOO_MISSING to HAVE_FOO.
2350 Wed Jun 3 19:28:04 1992 David J. MacKenzie (djm@wookumz.gnu.ai.mit.edu)
2352 * xgetcwd.c (xgetcwd): Accept errno==EINVAL as nonfatal.
2354 Wed May 20 00:05:52 1992 David J. MacKenzie (djm@churchy.gnu.ai.mit.edu)
2356 * system.h: If we include a header file specifically to get
2357 major et al., assume we have them.
2359 Mon May 11 20:04:10 1992 David J. MacKenzie (djm@churchy.gnu.ai.mit.edu)
2361 * chgrp.c, chown.c: --show-changes -> --changes.
2363 Sat May 9 18:39:38 1992 David J. MacKenzie (djm@wookumz.gnu.ai.mit.edu)
2365 * system.h: Define DEV_BSIZE if not defined.
2367 Thu Apr 30 13:55:37 1992 David J. MacKenzie (djm@churchy.gnu.ai.mit.edu)
2369 * du.c (count_entry): Remove the trailing "/" before printing.
2371 Wed Apr 29 11:34:38 1992 David J. MacKenzie (djm@churchy.gnu.ai.mit.edu)
2373 * rename.c (rename): If removing `from' fails, remove `to' to
2374 clean up. From Matthew Farwell <dylan@ibmpcug.co.uk>.
2376 Thu Apr 23 21:14:16 1992 David J. MacKenzie (djm@churchy.gnu.ai.mit.edu)
2378 * ls.c (gobble_file): Only read the link contents if -l or the
2379 file was named on the command line.
2381 Wed Apr 22 02:16:38 1992 David J. MacKenzie (djm@churchy.gnu.ai.mit.edu)
2383 * fsusage.c (get_fs_usage) [STAT_STATFS4 and _SEQUENT_]: Has f_bavail.
2384 From Donn Cave <donn@carson.u.washington.edu>.
2386 * getversion.c (get_version): If given invalid arg, exit.
2388 * cp.c (copy): Fix mode with chmod if copying as a regular file.
2390 * system.h, dd.c: SIGTYPE -> RETSIGTYPE.
2392 Sat Apr 18 00:18:41 1992 David J. MacKenzie (djm@wookumz.gnu.ai.mit.edu)
2394 * fsusage.[ch] (get_fs_usage): Take another arg, the device name.
2395 * fsusage.c (get_fs_usage) [STAT_READ]: Fix number of inodes
2396 calculation. Use the device name. From Brian Matthews.
2397 * df.c (show_dev): Pass the device name.
2399 Fri Apr 17 11:25:28 1992 David J. MacKenzie (djm@wookumz.gnu.ai.mit.edu)
2401 * fsusage.c: Special-case AIX.
2403 * mountlist.c [MOUNTED_VMOUNT]: New code for AIX, from
2404 Garrett A. Wollman (wollman@uvm.edu).
2406 * ls.c (gobble_file): Use stat, not lstat, on symlinked-to
2407 file, for Unix compat. From ian@airs.com (Ian Lance Taylor).
2409 Mon Apr 6 14:16:06 1992 David J. MacKenzie (djm@wookumz.gnu.ai.mit.edu)
2411 * xgetcwd.c: Include stdio.h to get NULL.
2413 Thu Apr 2 14:41:18 1992 David J. MacKenzie (djm@wookumz.gnu.ai.mit.edu)
2415 * df.c: Call sync only once, instead of once per filesystem.
2417 Wed Apr 1 16:00:08 1992 David J. MacKenzie (djm@wookumz.gnu.ai.mit.edu)
2421 Tue Mar 31 13:39:06 1992 David J. MacKenzie (djm@wookumz.gnu.ai.mit.edu)
2423 * df.c (main): stat all arg pathnames before getting
2424 list of mounted filesystems.
2425 (show_entry, show_point): Take a struct stat * as another arg,
2426 to avoid repeatedly statting files.
2428 Mon Mar 30 12:21:28 1992 David J. MacKenzie (djm@wookumz.gnu.ai.mit.edu)
2430 * install.c (main): Allow symbolic modes for -m.
2431 (atoo): Function removed.
2433 * mkdir.c (main): Include invalid -m arg in error message.
2435 * fsusage.c (get_fs_usage) [STAT_STATFS4]: Go back to using
2436 512 instead of f_bsize. Empirically, it gives the right answer.
2438 * mvdir.c (main): Don't deref NULL pointer on last iteration
2441 * fsusage.c (adjust_blocks): New function.
2442 (get_fs_usage): Call it.
2444 * mvdir.c (main): Don't possibly try to use ".." entry of new dir
2447 * fsusage.c (get_fs_usage) [STAT_STATFS4]: Use f_bsize member
2450 Sat Mar 28 00:36:57 1992 David J. MacKenzie (djm@wookumz.gnu.ai.mit.edu)
2452 * dd.c (copy_simple, copy_with_block, copy_with_unblock,
2453 translate_buffer, swab_buffer): New functions, mostly made
2454 from code taken from copy. Incorporate some optimizations due
2455 to Stuart Kemp: For each type of conversion, only check
2456 whether to do it once per buffer read, instead of once per character.
2457 (copy): If conv=block and the input didn't end with a newline,
2458 pad the final block with spaces.
2460 Wed Mar 25 14:35:17 1992 David J. MacKenzie (djm@wookumz.gnu.ai.mit.edu)
2462 * system.h: Don't use BSIZE for calculating ST_BLKSIZE if it
2465 * mountlist.c [MOUNTED_FREAD], fsusage.c [STAT_READ]: New code
2466 for SVR2, from archive@ideahb.sublink.org (Lele Gaifax).
2468 Tue Mar 24 14:53:19 1992 David J. MacKenzie (djm@wookumz.gnu.ai.mit.edu)
2470 * mvdir.c: Use getcwd, not getwd.
2472 * system.h, xgetcwd.c: Redo how PATH_MAX is figured out, to
2475 * fsusage.c, mountlist.c: New files split from fsinfo.c.
2476 Revise conditionals to make the two files independent of each other.
2477 * fsusage.h, mountlist.h: New files split from fsinfo.h.
2480 Mon Mar 23 13:01:07 1992 David J. MacKenzie (djm@wookumz.gnu.ai.mit.edu)
2482 * fsinfo.c (read_filesystem_list): Take another arg, all_fs.
2483 [FS_MNTENT]: Ignore type "auto" (from amd) as well as "ignore"
2484 (from automounter), if not all_fs.
2485 * df.c (main): Pass the new arg.
2487 * fsinfo.h: Add function decls.
2489 * chown.c, chgrp.c, chmod.c: Remove -L option. Didn't handle
2490 changing symlinks correctly and wasn't very useful.
2492 Sat Mar 14 17:38:38 1992 David J. MacKenzie (djm@wookumz.gnu.ai.mit.edu)
2494 * dirname.c (dirname): Don't use strdup.
2496 Fri Mar 13 14:56:15 1992 David J. MacKenzie (djm@wookumz.gnu.ai.mit.edu)
2498 * rm.c (remove_file, remove_dir, clear_directory): If -f was
2499 given, don't complain about ENOENT when removing.
2501 Mon Mar 9 00:09:48 1992 David J. MacKenzie (djm@nutrimat.gnu.ai.mit.edu)
2503 * install.c (main): Allow making multiple dirs with -d.
2504 (usage): Document it.
2505 * makepath.c (make_path): Clear umask while working and
2506 restore it when done. chmod dirs that should have
2507 set[ug]id or sticky bits set, if we're chowning them.
2508 Make chown failure nonfatal. Do chmod after chown, not before.
2510 * du.c (count_entry): Set exit_status on nonfatal error.
2513 Sun Mar 8 22:07:50 1992 David J. MacKenzie (djm@nutrimat.gnu.ai.mit.edu)
2515 * du.c (du_files): New function, from code in main.
2516 Use xgetcwd instead of getcwd or getwd.
2517 * system.h: Don't declare getcwd or getwd.
2519 * xgetcwd.c: New file.
2521 * ls.c (main): Exit with `exit_status' instead of 0.
2522 (print_dir, gobble_file, get_link_name): Set exit_status on error.
2524 * ls.c (print_long_format): Allow a slop factor for deciding
2525 what is in the future.
2527 * All programs: Change usage messages and documentation for
2528 long options to use -- instead of +.
2530 * df.c (main, usage): Add -v option for SysV compat.
2532 Tue Feb 4 12:45:09 1992 David J. MacKenzie (djm at wookumz.gnu.ai.mit.edu)
2534 * fileblocks.c [!NINDIR]: Try to fake indirect block info for
2535 systems that don't define it.
2537 Thu Jan 16 01:04:16 1992 David J. MacKenzie (djm at wookumz.gnu.ai.mit.edu)
2539 * df.c (print_header): Capitalize some header words for
2542 Sat Jan 4 01:19:25 1992 David J. MacKenzie (djm at wookumz.gnu.ai.mit.edu)
2544 * posixtm.y: Capitalize token name.
2546 Tue Dec 24 01:05:44 1991 David J. MacKenzie (djm at wookumz.gnu.ai.mit.edu)
2548 * system.h, makepath.c, idcache.c, eaccess.c, backupfile.c,
2549 install.c, dd.c, chown.c, chgrp.c: Change POSIX ifdefs to
2552 Wed Dec 18 16:42:00 1991 David J. MacKenzie (djm at wookumz.gnu.ai.mit.edu)
2554 * system.h: To get major, minor and makedev, don't check for
2555 _POSIX_SOURCE and USG; use MAJOR_IN_MKDEV and MAJOR_IN_SYSMACROS.
2557 Mon Dec 16 18:16:42 1991 David J. MacKenzie (djm at wombat.gnu.ai.mit.edu)
2559 * dd.c (skip): Fix typos in arg name.
2560 (output_char): Fix off by one error in check.
2562 Sun Dec 8 19:55:06 1991 David J. MacKenzie (djm at wookumz.gnu.ai.mit.edu)
2564 * system.h: Only define major et al. if not already defined.
2566 Fri Dec 6 18:26:53 1991 David J. MacKenzie (djm at wookumz.gnu.ai.mit.edu)
2568 * dd.c (main) [POSIX]: Use sigaction instead of signal, which
2571 * df.c, du.c, ls.c: POSIX_ME_HARDER -> POSIXLY_CORRECT.
2573 Wed Dec 4 14:30:16 1991 David J. MacKenzie (djm at wookumz.gnu.ai.mit.edu)
2575 * dd.c: Cleanups, mostly from Stuart Kemp:
2576 (output_char): New macro, from code in copy.
2577 (write_output): New function, used by output_char, from code
2579 (skip): New function, from code in copy.
2580 (copy): Use output_char and skip.
2581 Simplify test for quitting before main loop.
2582 Zero buffer using bzero for speed.
2584 Sun Nov 17 19:39:04 1991 David J. MacKenzie (djm at wookumz.gnu.ai.mit.edu)
2586 * fsinfo.c (get_fs_usage) [FS_MNTENT]: Take blocksize into account.
2587 (read_filesystem_list) [FS_MNTENT]: Ignore filesystems of type
2588 "ignore" (automounter dummy entries).
2590 * install.c (change_attributes): Do chmod even if chown fails.
2592 Thu Oct 24 23:50:46 1991 David J. MacKenzie (djm at wookumz.gnu.ai.mit.edu)
2594 * chown.c (change_file_owner), chgrp.c (change_file_group):
2595 don't skip symlinks, since the chown system call works on them.
2597 Fri 18 Oct 1991 23:29:24 Jim Meyering (meyering at wombat)
2599 * configure: fixed test to detect sequent's strange interpretation
2600 of utime(file, NULL).
2602 Fri Oct 18 00:30:42 1991 David J. MacKenzie (djm at wookumz.gnu.ai.mit.edu)
2604 * eaccess.c: GID_T -> GETGROUPS_T, for clarity.
2606 Sat Oct 12 12:25:55 1991 David J. MacKenzie (djm at churchy.gnu.ai.mit.edu)
2608 * configure: Define uid_t and gid_t as int if they're not
2609 defined in sys/types.h. That's probably right for old Unixes
2610 and avoids trying to find the C preprocessor.
2612 * df.c: Don't declare sync, to avoid conflict with Minix (and
2613 maybe others) unistd.h.
2614 (show_point): Cast -1 to dev_t before comparing, in case dev_t
2615 is unsigned. From Rainer Orth.
2617 * chown.c [!POSIX]: Declare getgrgid.
2619 Fri Sep 13 14:55:41 1991 David J. MacKenzie (djm at churchy.gnu.ai.mit.edu)
2621 * eaccess.c [POSIX]: Always use sysconf to get NGROUPS_MAX.
2623 Thu Sep 5 23:40:39 1991 David J. MacKenzie (djm at apple-gunkies)
2625 * system.h: Instead of defining getwd in terms of getcwd with
2626 PATH_MAX as an arg (which might be -1 on POSIX), define getcwd
2628 * du.c (main): Call getcwd with path_max as an arg.
2630 * install.c (change_attributes): Do chown before chmod, so
2631 chown doesn't remove set[ug]id bits.
2633 Wed Aug 28 20:53:50 1991 David J. MacKenzie (djm at wookumz.gnu.ai.mit.edu)
2637 Mon Aug 26 15:44:16 1991 David J. MacKenzie (djm at pogo.gnu.ai.mit.edu)
2639 * du.c (main): If pathconf fails, use 1024 for PATH_MAX. This
2640 happens if "/" is NFS-mounted.
2642 Sun Aug 25 00:56:11 1991 David J. MacKenzie (djm at apple-gunkies)
2644 * df.c, fsinfo.c, fsinfo.h: New program.
2645 * configure: Check for various ways of getting info on mounted
2648 Thu Aug 22 10:53:23 1991 David J. MacKenzie (djm at apple-gunkies)
2650 * src/Makefile.in: Workaround #10006 for C compilers that are
2651 too dumb to allow -c and -o together. Copy the source files.
2652 * system.h: Moved from src to lib to avoid having to add yet
2653 more -I options to CFLAGS.
2655 * du.c, ls.c: If POSIX_ME_HARDER is set in environment, use
2656 512-byte blocks by default.
2658 Wed Aug 21 13:03:14 1991 David J. MacKenzie (djm at wookumz.gnu.ai.mit.edu)
2662 * du.c, ls.c: Make 1K blocks the default size, and -k a no-op.
2663 Down with dumb standards!
2665 * system.h, backupfile.c, savedir.c [VOID_CLOSEDIR]: Fake a
2666 return value for closedir, which returns void on some systems,
2668 * configure: Check sys/dir.h for 'void closedir'.
2670 Tue Aug 20 22:22:47 1991 Jim Meyering (meyering at nutrimat)
2672 * mvdir.c (main): Clean up loop to stat component
2673 directories -- as in makepath and pathchk.
2675 Tue Aug 20 22:10:47 1991 Jim Meyering (meyering at nutrimat)
2677 * dirname.c (dirname): Allocate exact amount of space
2680 Tue Aug 20 02:13:40 1991 David J. MacKenzie (djm at apple-gunkies)
2682 * savedir.c (savedir): Try to open directory before allocating
2683 buffer. From Jim Meyering.
2685 Mon Aug 19 01:14:13 1991 David J. MacKenzie (djm at wookumz.gnu.ai.mit.edu)
2687 * Many files: indent '#pragma alloca' so non-ANSI compilers
2690 * backupfile.c (max_backup_version): Check closedir return
2691 value (though it might not do any good).
2693 Tue Aug 6 20:50:56 1991 David J. MacKenzie (djm at wheat-chex)
2695 * configure, Makefile.in's: Support +srcdir option, using VPATH.
2696 Don't check for bison, just try it and if it fails use yacc.
2697 Create config.status. Fix up clean targets.
2699 * posixtm.y (posixtm): New function.
2701 Most of the following is from Paul Eggert:
2702 * savedir.c (savedir), ls.c (print_dir), rm.c
2703 (clear_directory): Check closedir return for errors.
2704 * dd.c (main): Check for stdin or stdout being closed.
2705 * dd.c (quit), install.c (copy_file): Check for close errors.
2706 * mv.c (copy): Was missing a close.
2708 Sat Aug 3 02:05:51 1991 David J. MacKenzie (djm at apple-gunkies)
2710 * ln.c: Declare link() unconditionally (SCO UNIX needs it).
2712 Tue Jul 30 00:23:19 1991 David J. MacKenzie (djm at wookumz.gnu.ai.mit.edu)
2714 * configure: NEED_TZSET has become FTIME_MISSING.
2716 * configure: Define uid_t and gid_t if sys/types.h doesn't.
2718 Sat Jul 27 00:55:16 1991 David J. MacKenzie (djm at wookumz.gnu.ai.mit.edu)
2720 * configure: Only compile fileblocks.c if st_blocks is missing.
2722 * cp.c (copy): Make directories with initial mode of source
2723 permissions minus umask, plus 0700. For POSIX and John Gilmore.
2725 * system.h: Include errno.h and, if STDC_HEADERS, stdlib.h.
2726 * All programs: Remove includes of those files.
2728 * ftruncate.c: New file.
2729 * configure: Use it if needed.
2731 Wed Jul 24 02:09:45 1991 David J. MacKenzie (djm at wookumz.gnu.ai.mit.edu)
2733 * ls.c (get_name_link), cp.c (copy) [_AIX]: Allocate extra
2734 space for the buffer, since st_size is wrong.
2736 * system.h: Don't declare alloca for AIX.
2737 * makepath.c, posixtm.y, cp.c, du.c, ln.c, ls.c, mv.c:
2738 Declare alloca first (AIX needs it).
2740 * cp.c, dd.c, touch.c: Use SEEK_ instead of L_.
2741 * system.h: Define SEEK_ if not defined.
2743 Tue Jul 23 15:02:20 1991 David J. MacKenzie (djm at wookumz.gnu.ai.mit.edu)
2745 * eaccess.c: GID_T is int if ultrix as well as if sun.
2747 Mon Jul 22 11:39:31 1991 David J. MacKenzie (djm at bleen)
2749 * install.c: Use uid_t and gid_t.
2751 * eaccess.c: Support POSIX method of getting multiple groups.
2753 Sat Jul 20 14:24:40 1991 David J. MacKenzie (djm at bleen)
2755 * Move cat cmp cut expand head paste split tac tail unexpand
2758 * system.h [MKFIFO_MISSING]: Define mkfifo macro.
2759 * cp.c, mkfifo.c: Don't define it.
2761 * mknod.c, gmknod.1: New files.
2763 Fri Jul 19 13:43:01 1991 David J. MacKenzie (djm at apple-gunkies)
2765 * version.c: New file.
2766 * All C programs: Link with it, to get version number in the
2767 binary where at least `strings -' and GNU grep can find it.
2769 Mon Jul 15 13:46:53 1991 David J. MacKenzie (djm at wookumz.gnu.ai.mit.edu)
2771 * configure: Also look in sys/signal.h for signal decl.
2773 Sun Jul 14 22:43:57 1991 David J. MacKenzie (djm at wookumz.gnu.ai.mit.edu)
2775 * Rename touchtm.y back to posixtm.y, as the date command will
2778 Mon Jul 8 22:56:36 1991 David J. MacKenzie (djm at wookumz.gnu.ai.mit.edu)
2780 * Replace lib/Makefile with lib/Makefile.in.
2781 * configure: For some library functions that might be missing,
2782 conditionally add the .o files to lib/Makefile instead of
2783 defining func_MISSING.
2784 * lib/mkdir.c: Renamed from lib/mkrmdir.c.
2786 Sat Jul 6 02:19:09 1991 David J. MacKenzie (djm at geech.gnu.ai.mit.edu)
2788 * xstrdup.c [STDC_HEADERS]: Include string.h.
2790 * stripslash.h: Include string header file.
2792 * configure: Add to DEFS if Minix.
2794 * system.h [_POSIX_SOURCE]: Make ST_BLKSIZE 1024 instead of
2795 512, for better performance.
2797 * system.h, configure: If sys/mkdev.h exists, use it instead
2800 * configure: echo messages to stdout, not stderr.
2801 Use test programs to see if alloca needs -lPW and if chars are
2804 Tue Jul 2 03:16:32 1991 David J. MacKenzie (djm at geech.gnu.ai.mit.edu)
2806 * chown.c, chgrp.c [!POSIX]: Declare pwd.h and grp.h functions.
2808 Sat Jun 29 16:46:12 1991 David J. MacKenzie (djm at geech.gnu.ai.mit.edu)
2810 * cp.h: Don't declare `open', to avoid conflict with varargs
2813 * chown.c, chgrp.c: Include sys/types.h before, not after,
2814 pwd.h and grp.h, to get uid_t and gid_t if necessary.
2816 Fri Jun 28 01:12:45 1991 David J. MacKenzie (djm at geech.gnu.ai.mit.edu)
2818 * ls.c: Use time_t instead of long, where appropriate.
2820 Thu Jun 27 16:31:45 1991 David J. MacKenzie (djm at geech.gnu.ai.mit.edu)
2822 * touchtm.y: Renamed from posixtime.y for SysV systems with Bison.
2824 * configure: No longer need to pass bison the -y option.
2825 Now lib/Makefile should allow a parallel make with bison.
2827 * cp.c (copy_reg), cat.c (main),
2828 touch.c (touch, utime_now), mv.c (copy): Check close return
2829 value for delayed error report due to NFS.
2831 Thu Jun 20 01:33:06 1991 David J. MacKenzie (djm at geech.gnu.ai.mit.edu)
2833 * configure: Include $DEFS when compiling test programs.
2835 * configure: Use test programs instead of grep to check for
2836 USG, POSIX, and ANSI C headers, in case symbols are defined in
2837 header files included by the standard ones. Check for BSD
2838 memory functions (bcopy et al.) as well as string functions.
2839 Add notice to top of generated Makefile saying that it's
2840 automatically generated.
2842 Thu Jun 13 00:50:18 1991 David J. MacKenzie (djm at geech.gnu.ai.mit.edu)
2846 * configure: If rename is missing, define MVDIR.
2847 Use , instead of / as sed substitution separator so variables'
2848 values can contain slashes.
2850 * du.c (main): Use alloca to allocate `wd' instead of making
2851 it an auto array, since PATH_MAX might be a call to pathconf.
2853 Wed Jun 12 19:56:22 1991 David J. MacKenzie (djm at geech.gnu.ai.mit.edu)
2855 * cp-aux.c (usage), install.c (usage), ln.c (usage), mv.c
2856 (usage): Combine the option lists for the multiple usage forms.
2858 Tue Jun 11 00:12:15 1991 David J. MacKenzie (djm at geech.gnu.ai.mit.edu)
2860 * idcache.c: pwd.h and grp.h might need sys/types.h.
2862 * configure: Create Makefile from Makefile.in instead of
2863 makefile from makefile.skel, to more closely follow the new
2864 GNU coding standards.
2866 * ls.c (file_interesting): Use POSIX.2 fnmatch instead of glob_match.
2868 * configure: If $RANDOM is implemented (ksh, bash or zsh), use
2869 the `type' builtin to determine if gcc, bison, ranlib are
2870 available. ksh writes "fubar: command not found" to stderr,
2871 foiling the test -n "`command 2>&1`" method.
2872 Remove makefile on signal.
2874 * system.h: Include sys/param.h if not _POSIX_SOURCE instead
2875 of if not POSIX, to get DEV_BSIZE.
2877 * makepath.c, posixtime.y, system.h: Add _AIX case to alloca decl.
2879 Sun Jun 9 01:26:27 1991 David J. MacKenzie (djm at geech.gnu.ai.mit.edu)
2883 * basename.c, dirname.c: Use str[r]chr and string.h if
2884 STDC_HEADERS as well as if USG.
2886 * touch.c (utime_now): Created from code in touch ().
2888 Sat Jun 8 11:02:32 1991 David J. MacKenzie (djm at geech.gnu.ai.mit.edu)
2890 * backupfile.c: Use POSIX instead of _POSIX_SOURCE to
2891 determine whether to check whether readdir returned a valid
2894 Fri Jun 7 21:44:51 1991 David J. MacKenzie (djm at geech.gnu.ai.mit.edu)
2896 * fileblocks.c (st_blocks), system.h (ST_NBLOCKS): Always
2897 return number of 512 byte blocks, not DEV_BSIZE blocks.
2898 (convert_blocks): Always expect 512-byte blocks.
2900 Thu Jun 6 12:54:26 1991 David J. MacKenzie (djm at geech.gnu.ai.mit.edu)
2902 * system.h [POSIX]: If PATH_MAX not defined, use pathconf.
2903 Remove NAME_MAX stuff; not used.
2905 * system.h: Make #include <strings.h> depend on not (USG or
2906 STDC_HEADERS) instead of not (USG or POSIX).
2908 * configure: New shell script to aid compilation.
2910 Mon Jun 3 16:42:41 1991 David J. MacKenzie (djm at wheat-chex)
2912 * cp.h: Remove some decls of functions returning int that
2913 conflict with prototypes on HPUX.
2915 * cp.c (make_path, re_protect): New functions from Jim
2916 Meyering. Changes to other functions as well, to add +path,
2917 +link, +symbolic-link options.
2919 Sun Jun 2 15:45:24 1991 David J. MacKenzie (djm at wheat-chex)
2921 * most files: use GPL version 2.
2923 Sat Jun 1 20:17:35 1991 David J. MacKenzie (djm at wheat-chex)
2925 * rm.c, backupfile.c: If _POSIX_SOURCE, don't refer to d_ino.
2927 Sun May 19 18:42:09 1991 David J. MacKenzie (djm at churchy.gnu.ai.mit.edu)
2929 * touch.c: Renamed getdate to get_date to avoid SVR4 conflict.
2931 Thu May 16 23:12:01 1991 David J. MacKenzie (djm at albert.gnu.ai.mit.edu)
2933 * cp.c, mv.c, ln.c: Use alloca and strcpy directly instead of
2934 in a macro for generating backup filename. The latter
2935 sometimes coredumps for some reason.
2937 Sat Apr 20 00:03:09 1991 David J. MacKenzie (djm at geech.gnu.ai.mit.edu)
2939 * dd.c: Add conv=notrunc and truncate output file by default,
2942 * rm.c (rm): Refuse to remove path/. and path/.., as well as `.'
2943 and `..', for POSIX.
2945 * chown.c: Allow `:' as well as `.' to separate group from
2946 user, for POSIX.2 draft 11.
2948 * Many programs: Don't bother to get the long-option index
2949 value from getopt_long, since we ignore it.
2951 * Many programs: Separate long-option option names from their
2952 args with `=' instead of ` ' in usage messages.
2954 * touch.c (touch): Don't refuse to touch non-regular files.
2956 Wed Apr 10 12:19:30 1991 David J. MacKenzie (djm at churchy.gnu.ai.mit.edu)
2958 * cp.c, cp-aux.c: Add -a +archive option, an easier to
2959 remember synonym for -dpR.
2961 Fri Mar 15 16:16:54 1991 David J. MacKenzie (djm at geech.ai.mit.edu)
2963 * mv.c (copy): Try to preserve file ownership in
2964 cross-filesystem copies.
2966 * backupfile.c, rm.c: Go back to using d_ino instead of
2967 d_fileno. POSIX.1 specifies neither, and d_ino is more
2968 common, perhaps ubiquitous.
2970 * chown.c (describe_change): Don't print the group name if it
2971 didn't change (thus is a null pointer).
2972 (main): Initialize group name to null.
2974 Mon Feb 25 11:44:14 1991 David J. MacKenzie (djm at geech.ai.mit.edu)
2976 * dd.c (copy): Only seek if not seeking to start of file, so
2977 "dd >> foo" works with Minix shell that doesn't open foo in
2980 Thu Feb 21 11:59:39 1991 David J. MacKenzie (djm at geech.ai.mit.edu)
2982 * ln.c (do_link), mv.c (do_move), cp.c (copy): Store backup
2983 filename using alloca so we don't have to free it every place
2984 we return. From Jim Meyering.
2986 Thu Feb 14 00:41:43 1991 David J. MacKenzie (djm at geech.ai.mit.edu)
2988 * cp.c (copy_reg): Only make holes when copying a regular file
2989 onto a regular file.
2991 Fri Jan 18 06:31:59 1991 David J. MacKenzie (djm at albert.ai.mit.edu)
2993 * ls.c: Move defn. of S_IEXEC to after header files are included.
2994 * cp.h: Always declare stat and lstat.
2996 Thu Jan 10 02:16:55 1991 David J. MacKenzie (djm at albert.ai.mit.edu)
2998 * cp.h: Only declare some system calls if not POSIX.
3000 * eaccess.c, idcache.c, dd.c, install.c, ln.c, system.h:
3001 Change _POSIX_SOURCE to POSIX.
3003 * fileblocks.c, system.h: Change STBLOCKS_MISSING to
3004 ST_BLOCKS_MISSING (was already that way in cp.c).
3006 Fri Dec 28 18:40:34 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
3008 * chmod.c, chown.c, chgrp.c, du.c: Rename -d option to -L for
3009 similarity to ls and cpio.
3011 Thu Dec 27 00:06:45 1990 David J. MacKenzie (djm at egypt)
3013 * rm.c (clear_directory): Keep looking for files to remove
3014 until we don't find any, so that any .nfs* files created by
3015 removing other files are also removed, eventually.
3017 * install.c (main): Strip trailing slashes on all args.
3019 * mv.c (copy): Open target file with mode 0600, not 0777.
3020 [FCHMOD_MISSING]: Perform chmod after closing files, not
3023 * cp.c (do_copy): Don't append `..' to target dir name.
3025 * du.c (main, count_entry, usage): Add -D +dereference-args
3026 and -d +dereference options.
3028 Wed Dec 26 03:39:18 1990 David J. MacKenzie (djm at egypt)
3030 * dirname.c, xstrdup.c: Get decls from standard files, if available.
3032 Thu Dec 20 23:10:22 1990 David J. MacKenzie (djm at egypt)
3034 * makepath.c: New file, adapted from code in mkdir.c,
3035 install.c, and cpio util.c by Jim Meyering.
3036 * mkdir.c, install.c: Use make_path.
3038 Sun Dec 16 00:56:54 1990 David J. MacKenzie (djm at egypt)
3040 * chown.c, chgrp.c: New files.
3042 Sat Dec 15 20:42:32 1990 David J. MacKenzie (djm at egypt)
3044 * cp.h: Declare POSIX functions always -- _POSIX_SOURCE
3045 doesn't imply STDC declarations.
3047 * system.h: Define S_ISTYPE macros not defined by sys/stat.h.
3049 * Many files: Use S_ISTYPE macros.
3051 * backupfile.c, rm.c: Use name d_fileno for member of struct
3052 dirent instead of d_ino, for POSIX.
3054 Wed Dec 12 23:38:22 1990 David J. MacKenzie (djm at egypt)
3056 * ls.c: Declare time() as time_t instead of long, to prevent
3057 conflict with standard header files.
3059 * cp.c (copy_reg): Instead of using NO_SPARSE_FILES, use
3060 st_blocks to determine whether the original file contains any
3061 sparse blocks, and only create them if so. On systems without
3062 st_blocks, to be safe, never create sparse blocks.
3064 Thu Nov 8 12:16:27 1990 David J. MacKenzie (djm at apple-gunkies)
3066 * idcache.c: If _POSIX_SOURCE not defined, declare getpw and
3067 getgr functions (not an optimal solution, but I hate to add
3068 yet another configuration macro).
3070 * Makefile: Define AR and RANLIB and pass to child makes.
3071 lib/Makefile: Use them.
3073 Tue Nov 6 23:18:06 1990 David J. MacKenzie (djm at mole.ai.mit.edu)
3075 * idcache.c: New file from code in ls.c.
3077 Fri Nov 2 14:34:40 1990 David J. MacKenzie (djm at apple-gunkies)
3079 * Move files into src and lib directories, split out library
3080 functions into separate files in lib, and rewrite Makefiles.
3082 Mon Oct 29 01:20:46 1990 David J. MacKenzie (djm at apple-gunkies)
3084 * mv.c (do_move), rm.c (remove_file, remove_dir): If stdin is
3085 a tty and file is unwritable, prompt before overwriting.
3087 * cp.c (copy_reg): Only make sparse files if
3088 NO_SPARSE_FILES is undefined, to accommodate dumb kernels.
3090 * du.c (count_entry): Remove misinformed HPUX kludge that
3091 doesn't really fix the problem.
3093 * rm.c (rm): Check for textual equality with '.' and '..', not
3096 Sat Oct 27 23:38:55 1990 David J. MacKenzie (djm at apple-gunkies)
3098 * rm.c (check_stack): If not interactive, don't prompt when
3099 corruption is found, just quit.
3100 (remove_file, remove_dir): Delete leading spaces in verbose
3103 * cp.c (copy), rm.c (remove_dir): If we think the dest. file
3104 is unwritable, warn the user in the interactive prompt instead
3105 of automatically skipping the file. Because of race
3106 conditions and other protection mechanisms we might not know
3109 Mon Oct 8 18:51:25 1990 David J. MacKenzie (djm at apple-gunkies)
3111 * du.c (main, usage, count_entry): Add +separate-dirs -S option.
3113 * dd.c (main): Don't trap SIGINT if it was being ignored.
3115 Tue Sep 25 16:40:43 1990 David J. MacKenzie (djm at apple-gunkies)
3117 * install.c (copy_file, install_file_in_file): Change
3118 attributes after stripping, to guard against strip programs
3119 that clear setuid bits, etc.
3121 Fri Sep 21 22:31:43 1990 David J. MacKenzie (djm at apple-gunkies)
3123 * cp.c (copy_reg): Put back ftruncate way of making holes
3124 because the other way can't make a hole at the end of a file.
3126 Tue Sep 18 03:47:45 1990 David J. MacKenzie (djm at apple-gunkies)
3128 * install.c (change_attributes): Don't ignore EPERM for chown,
3129 since the default uid is now the current uid.
3131 Sun Sep 9 16:54:19 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
3135 * cp.h: Declare free returning void, not int, so it
3136 doesn't bomb on Xenix.
3138 Fri Sep 7 04:35:35 1990 David J. MacKenzie (djm at apple-gunkies)
3140 * system.h, backupfile.c, savedir.c [DIRENT]: if direct is
3141 defined (as on Ultrix 4.0), undefine it before redefining it.
3143 Tue Sep 4 03:10:24 1990 David J. MacKenzie (djm at apple-gunkies)
3145 * dd.c (apply_translations, translate_charset): Code moved
3146 from parse_conversion.
3147 (apply_translations): Convert from EBCDIC to ASCII before
3150 * mvdir.c (fullpath): Return a value.
3152 * dd.c (copy): Increment count of truncated records once
3153 per record, not once per character that overflows.
3155 Mon Sep 3 22:23:57 1990 David J. MacKenzie (djm at coke)
3157 * dd.c (swab_array): Function removed.
3158 (copy): Rewrite conv=swab to work when odd number of bytes
3160 (scanargs): Die if invalid numeric value is given.
3161 (parse_integer): Return -1 if invalid arg.
3162 (bit_count): Faster version from Jim Meyering.
3164 * cp.c, mkfifo.c [MKFIFO_MISSING]: Define mkfifo.
3166 Thu Aug 30 00:17:02 1990 David J. MacKenzie (djm at apple-gunkies)
3168 * mvdir.c (main): Make sure `from' is not a parent of any part
3169 of `to', not just the explicitly given part.
3170 (fullpath): New function.
3172 Wed Aug 29 19:50:05 1990 David J. MacKenzie (djm at apple-gunkies)
3174 * mvdir.c: Renamed from mv_dir.c, for consistency with mkdir and rmdir.
3175 * dirlib.c: Caller changed.
3177 Tue Aug 28 18:05:24 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
3179 * touch.c (main): Don't interpret first non-option arg as a
3180 time if `--' is given (POSIX-required kludge).
3182 * touch.c: Add long-named options.
3184 * Many files: Include <getopt.h> instead of "getopt.h" since
3185 getopt.h will be in the GNU /usr/include.
3187 * install.c: Declare some functions.
3189 * touch.c, getdate.y, posixtime.y, mktime.c: New files, from bin-src.
3191 * posixtime.y: Move year from before time to after it (but
3192 before the seconds), for 1003.2 draft 10.
3194 Mon Aug 27 03:25:36 1990 David J. MacKenzie (djm at apple-gunkies)
3196 * touch.c (main): If no time is given and first arg is a valid
3197 timespec, use it as one.
3199 Sat Aug 25 01:36:16 1990 David J. MacKenzie (djm at apple-gunkies)
3201 * posixtime.y: Enclose YYABORT in braces in case some yacc's
3204 * touch.c: Remove -i option. Change some error messages.
3205 (readname): Function removed.
3207 Thu Aug 23 12:56:33 1990 David J. MacKenzie (djm at apple-gunkies)
3209 * cp.c (copy): Only restore dir mode if it was changed.
3211 Wed Aug 22 01:45:54 1990 David J. MacKenzie (djm at apple-gunkies)
3213 * cp.c (copy): Don't only backup files when -f is given.
3215 * ls.c: Add -X +sort=extension option. Rename
3216 +kilobyte-file-size to +kilobytes.
3218 * du.c: Rename -f option to -x, for POSIX. Rename
3219 +kilobyte-file-size to +kilobytes. Add -b, +bytes option for
3222 * cp-aux.c (usage): Change -o to -x.
3223 (stpcpy): Renamed from str_cpy. Change callers in cp.c.
3225 * cp.c: New variable, `flag_copy_as_regular'.
3226 (main): For -R, unset `flag_copy_as_regular'.
3227 Rename -o to -x for consistency with du.
3228 (copy): Only unlink destination files when -f is given.
3229 Only prompt when -i given and copying as a regular file.
3230 Move check for previous link after other checks, reducing
3232 Create directories with mode 0700 initially, for POSIX.
3234 Mon Aug 20 03:29:08 1990 David J. MacKenzie (djm at apple-gunkies)
3236 * dd.c (copy): Swap input bytes instead of output bytes.
3237 (swab_array): New function.
3239 * dd.c (copy): If sync and noerror, zero the buffer before the
3240 read instead of after so that any data read before an error
3241 occurred are preserved.
3242 On read error, print stats and seek past the bad block if noerror.
3243 noerror doesn't affect write errors, for POSIX.
3244 (scanargs): Use two buffers if no buffer sizes given.
3245 Do not block or unblock if cbs not given.
3246 (print_stats): New function.
3249 Mon Aug 13 23:30:03 1990 David J. MacKenzie (djm at apple-gunkies)
3251 * cp.c (copy): If dest. exists and is unwritable, skip the file.
3253 * rm.c, mv.c, cp.c, ln.c (main): Respect the last -f or -i given,
3256 * rm.c (remove_file): Only prompt if -i is given.
3257 (main, usage): Remove -o +override-mode option, obsolete if
3258 POSIX accepts our objection about prompting.
3260 * mv.c (do_move): Only prompt if -i is given.
3262 * ln.c (do_link): If dest. file exists and -i and -f not
3263 given, skip the file.
3265 Tue Aug 7 12:51:18 1990 David J. MacKenzie (djm at apple-gunkies)
3267 * dd.c (main): If seek= given, don't truncate output file.
3268 (copy): Use `read' to skip output blocks if not regular file.
3269 Sync with NUL instead of SPC.
3271 Mon Aug 6 14:43:30 1990 David J. MacKenzie (djm at pogo.ai.mit.edu)
3273 * rm.c: Rename `ignore_errors' to `ignore_missing_files', and
3274 have it only suppress messages about nonexisting files.
3275 (main): Get dev and ino of `.' and `..'.
3276 (rm): If file is the same as `.' or `..', return with error.
3277 (remove_file): Remove the file rather than skipping it if
3278 unwritable, no -i, and stdin not tty.
3279 (remove_dir): Return an error if directory is nonwritable,
3280 rather than nonreadable or nonsearchable, for POSIX.2 draft 10.
3282 * chmod.c (main): Use fixed error checking to make sure that
3283 options aren't mixed together in the same args as mode specifiers.
3285 Sun Aug 5 11:51:12 1990 David J. MacKenzie (djm at pogo.ai.mit.edu)
3287 * chmod.c (main): Use umask for '-' op.
3289 Sat Aug 4 10:11:30 1990 David J. MacKenzie (djm at pogo.ai.mit.edu)
3291 * mkfifo.c: Remove -p +path option, no longer specified by POSIX.
3293 Fri Aug 3 13:38:28 1990 David J. MacKenzie (djm at pogo.ai.mit.edu)
3295 * mkdir.c, mkfifo.c, create.c (main): Don't tell mode_compile to
3296 respect the umask for certain operations, since the umask is 0 anyway.
3298 * install.c (get_ids): Use getuid and getgid to get defaults,
3301 Fri Jul 27 14:32:40 1990 David J. MacKenzie (djm at apple-gunkies)
3303 * backupfile.c (dirname): Always replace frontmost slash with a null.
3305 Thu Jul 26 00:20:35 1990 David J. MacKenzie (djm at apple-gunkies)
3307 * cp.h: Declare umask as unsigned short.
3309 * eaccess.c: Make uid and gid unsigned short, and group array unsigned.
3311 Wed Jul 25 18:38:57 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
3313 * rm.c (remove_file, remove_dir): Print verbose message right
3314 before actually trying to remove the file, after the prompting.
3316 * ls.c (getuser, getgroup): Make uid and gid unsigned short, not int.
3318 Tue Jul 24 03:39:42 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
3320 * cp.c (copy), ln.c (do_link), mv.c (do_move): For +verbose,
3321 print the file names just before actually attempting the
3322 copy/link/move, to produce a list of the files that they
3323 actually try to copy/link/move, omitting skipped files.
3324 Remove leading spaces from +verbose output.
3326 Mon Jul 23 16:57:44 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
3328 * cp.c (copy): Make +update operate silently, like +one-file-system.
3330 * ln.c: Add -F as synonym for -d, for SunOS compatibility.
3332 Sun Jul 15 23:23:28 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
3334 * cp.c (copy): Go back to using xstat on dest.
3336 Wed Jul 11 12:10:33 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
3338 * cp.c (copy): Make directories with desired mode plus u+wx so
3339 if the copy is interrupted, the dir is closer to the desired mode.
3340 Don't backup directories.
3342 Sun Jul 8 00:39:31 1990 David J. MacKenzie (djm at apple-gunkies)
3344 * rm.c (main, usage): Add new option -d, +directory.
3345 (rm): If -d given, use remove_file instead of remove_dir for
3347 (remove_file): If directory, print "remove directory `foo'?"
3348 for interactive instead of "remove `foo'?".
3350 * ln.c (main): If -s given, print warning message if symlinks
3352 * mkfifo.c (main): If fifo's are not available, print message
3355 Fri Jul 6 02:02:49 1990 David J. MacKenzie (djm at apple-gunkies)
3357 * install.c (main): Use the current user and group ID for the
3358 default owner and group.
3360 * mv.c (main): New option -u, +update.
3361 (do_move): Don't move nondirectories if -u and there is an existing
3362 destination that has the same or newer mtime.
3363 (usage): Document -u, +update.
3365 * cp.c (main): New option -u, +update.
3366 (copy): Don't copy nondirectories if -u and there is an existing
3367 destination that has the same or newer mtime.
3368 * cp-aux.c (usage): Document -u ,+update.
3370 Thu Jul 5 10:04:12 1990 David J. MacKenzie (djm at apple-gunkies)
3372 * ln.c (do_link): Don't check whether OLD exists before trying
3375 Tue Jul 3 01:51:55 1990 David J. MacKenzie (djm at apple-gunkies)
3377 * ls.c: Allow "+time=atime" and "+time=ctime" for C hackers.
3379 * chmod.c (main): Don't check whether multiple mode arguments
3380 are given, because optind has a different value depending on
3381 whether or not the option is the last character in the
3384 Sat Jun 30 12:32:51 1990 David J. MacKenzie (djm at apple-gunkies)
3386 * cp.c (copy): Use lstat on dest. file, not *xstat.
3388 Mon Jun 25 18:07:20 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
3390 * ls.c (print_long_format): Truncate user and group names to 8
3391 chars to preserve column alignment.
3392 (length_of_file_name_and_frills): Don't assume type indicator
3393 will be printed for unknown file types that some os's have.
3395 * install.c: Declare getgrnam for systems where grp.h doesn't.
3397 Sat Jun 23 00:06:35 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
3401 * du.c (count_entry) [HPUX_NFS_BUG]: If the size of the file
3402 according to the number of blocks reported is twice or more than
3403 the size of the file according to the number of bytes
3404 reported, halve the number of blocks.
3406 Fri Jun 22 00:38:20 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
3408 * cp.c (copy_dir): Initialize 'ret' to 0.
3410 * cp.c (main), ln.c (main), mv.c (main), rm.c (main):
3411 Make -i override -f and -o, to be conservative about
3412 removing peoples' files.
3414 * mkdir.c (make_path), mkfifo.c (make_path): Don't try to stat
3417 * rm.c, rmdir.c, mkdir.c, mkfifo.c: Move code to remove
3418 slashes at the end of an arg from main to
3419 strip_trailing_slashes.
3421 * install.c (strip): Print error message if the `strip'
3422 program can't be run.
3424 * system.h (convert_blocks): Macro moved from du.c and ls.c.
3425 Take a second parameter indicating whether to convert to
3426 kilobytes or 512 byte blocks.
3427 * ls.c, du.c: Pass second parameter to convert_blocks.
3429 Thu Jun 21 01:19:28 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
3431 * ls.c (print_long_format): Use mode_string instead of filemodestring.
3433 * ls.c (print_long_format): Compare times as longs, not ints.
3434 (longdiff): Macro to compare two longs efficiently if sizeof
3435 int == sizeof long and less efficiently but correctly if they
3436 are different sizes.
3437 (compare_ctime, etc.): Use longdiff.
3439 * ls.c (decode_switches): Make -k not imply -s, to allow the
3440 summary directory size printed by -l to be in 1k blocks
3441 without having the size of each file printed as well.
3442 (convert_blocks): Provide for systems with a blocksize that is
3443 other than 512 or 1024 bytes.
3445 * du.c (main): Exit with status 0 normally.
3446 (convert_blocks): Provide for systems with a blocksize that is
3447 other than 512 or 1024 bytes.
3449 Wed Jun 20 01:46:09 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
3451 * ln.c (do_link): Take out code to give an error if source and
3452 dest are the same file. The dubious usefulness of the special
3453 case to prevent 'ln x x' from removing 'x' (ln -i can be used
3454 instead) is not worth preventing 'ln x y' from failing the
3455 second time in a row, and appears to contradict POSIX anyway.
3457 Mon Jun 18 02:48:17 1990 David J. MacKenzie (djm at apple-gunkies)
3459 * ls.c (print_file_name_and_frills):
3460 (length_of_file_name_and_frills, print_long_format):
3461 Allow 6 digits for i-number, not 5.
3463 Sun Jun 17 00:09:23 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
3465 * install.c (install_dir): Don't check whether "" or the root
3466 directory exists (the former fails on some systems).
3468 * system.h: Make inclusion of sys/file.h conditional on USG
3469 and _POSIX_SOURCE, not DIRENT.
3471 * chmod.c (change_dir_mode): Use xrealloc instead of free and
3472 xmalloc in case malloc already left extra room.
3473 (xrealloc): New function.
3475 * rm.c (clear_directory): Prevent buffer overruns.
3476 More efficient string handling. Don't skip rest of directory
3477 if continuing after finding circular inode.
3478 (xrealloc): New function.
3480 Sat Jun 16 01:45:42 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
3482 * argmatch.c (invalid_arg): Change order in which the items
3485 * ls.c: Add +tabsize (-T) option.
3487 Fri Jun 15 23:40:55 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
3489 * dd.c (scanargs): For ibs and obs, set C_HARDWAY.
3490 (copy): Use different buffers only if C_HARDWAY, not if
3491 blocksizes are the same, to ensure constant output block sizes.
3493 Wed Jun 13 23:56:20 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
3495 * savedir.c: New file from code in chmod.c, modified to
3496 prevent buffer overruns.
3497 * chmod.c (change_dir_mode), cp.c (copy_dir), du.c
3498 (count_entry): Use savedir.
3500 Thu Jun 7 03:52:02 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
3502 * system.h (ST_BLKSIZE) [!STBLOCKS_MISSING]: If st_blksize is
3503 0 (as on pipe reads on some systems), use BSIZE instead.
3504 Define BSIZE as DEV_BSIZE if necessary.
3506 * Makefile, system.h, fileblocks.c: Use STBLOCKS_MISSING to
3507 control whether st_blksize and st_blocks are used.
3508 * Makefile, system.h, backupfile.c: Use DIRENT to control
3509 whether <dirent.h> is used.
3511 Thu May 31 00:55:36 1990 David J. MacKenzie (djm at apple-gunkies)
3513 * fileblocks.c: New file.
3514 * du.c (blocks_to_kb): Replace with convert_blocks macro.
3515 (main): Recognize new -k option.
3516 (usage): Document it.
3517 * ls.c (nblocks): Replace with convert_blocks macro.
3518 * system.h (ST_BLKSIZE) [USG]: Use BSIZE from sys/param.h instead of
3519 having the user define BLKSIZE.
3520 (ST_NBLOCKS) [USG]: Use st_blocks from fileblocks.c.
3522 Wed May 23 00:40:39 1990 David J. MacKenzie (djm at apple-gunkies)
3524 * argmatch.c: New file, taken from ls.c.
3525 * getversion.c (get_version): Use argmatch, to allow
3526 abbreviations. Default backup type is existing_numbered.
3527 * mv.c (main), ln.c (main), cp.c (main): Only make backups if
3528 -b (+backup) is given. If envar SIMPLE_BACKUP_SUFFIX is set,
3529 use it as a default instead of `~'.
3530 * mv.c (usage), ln.c (usage), cp-aux.c (usage): Update messages.
3532 Tue May 22 00:56:51 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
3534 * install.c: New file (from ../bin-src).
3536 * dd.c (copy): Don't count completely failed writes as partial
3537 writes. Make buffers unsigned. If blocking or unblocking,
3538 pad final partial buffer if necessary.
3540 * getversion.c: New file.
3541 * mv.c (main), cp.c (main), ln.c (main): Control backup types
3542 with getenv ("VERSION_CONTROL") and +version-control or -V.
3544 * cp.c (yesno), mv.c (yesno), ln.c (yesno): Stop reading if
3545 EOF reached as well as at newline.
3547 * backupfile.[ch]: Rename var `version_control' to `backup_type'.
3549 Sat May 19 23:38:46 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
3551 * touch.c: Change some error messages. Include "getopt.h".
3553 Sat May 19 00:16:50 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
3555 * mv.c (main), ln.c (main), cp.c (main): Revise
3556 backup-creation options.
3557 * mv.c (usage), ln.c (usage), cp-aux.c (usage): Revise messages.
3559 * chmod.c (describe_change): Use mode_string instead of
3562 * cp.c (main): Recognize new options for making backups.
3563 * cp.c (copy): Make backups if requested. Fix typo.
3564 * cp-aux.c (usage): Update message.
3566 * mv.c, cp.c: Remove code to conditionally use utimes instead
3567 of utime, since the extra resolution of utimes was not being
3568 used, the emulation overhead is probably insignificant,
3569 and utime is a standard function.
3571 * cp-hash.c: Fix up comments.
3573 Fri May 18 23:06:23 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
3575 * mv.c (do_move): Only make backup if dest file exists.
3576 Don't continue moving file if dest can't be backed up.
3577 * ln.c (do_link): Don't try to unlink dest if it was backed up.
3578 Don't continue moving file if dest can't be backed up.
3580 * system.h: Make SIGTYPE default to void if not defined.
3582 * modechange.[ch]: Rename struct and external functions to start
3584 * modechange.c (oatoi): Make static.
3585 (mode_compile): Take an additional arg indicating which
3586 symbolic operators should be affected by the umask.
3587 * modechange.h: Add defines for mode_compile arg mask.
3588 If __STDC__, use prototypes.
3589 * chmod.c, mkdir.c, mkfifo.c, create.c: Account for above changes.
3591 Tue May 15 16:17:34 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
3593 * dd.c (copy): Quit with nonzero status if final write fails.
3595 Mon May 14 14:34:10 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
3597 * dd.c: Make translation tables unsigned.
3598 (main): Give `input_file' and `output_file' nonzero values for
3600 (parse_conversion): Set new global vars 'space_character' and
3601 'newline_character' to correct values when translating to EBCDIC
3603 (copy): Use 'space_character' and 'newline_character' instead
3604 of hardcoded ASCII values. Ignore attempts to seek on output pipe,
3605 socket, or fifo. If possible, seek instead of reading to skip
3606 initial input records. Sync with `space_character' instead of
3609 * cp.c (copy_reg): Compare lseek values as longs, not ints.
3611 Sat May 12 01:16:42 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
3613 * cp-hash (remember_created): Return error status instead of
3615 * cp.c (copy): Change caller.
3616 (do_copy, copy_reg): Return error status instead of fatal error.
3618 * Move rename emulation from mv.c to dirlib.c so other
3619 programs can use it.
3620 * mv.c, ln.c (main): Recognize new options for making backups.
3621 * mv.c (do_move), ln.c (do_link): Make backups if requested.
3622 * mv.c, ln.c (usage): Update message.
3623 * backupfile.c, backupfile.h: New files.
3625 * cp.h: Ifdef out decl of umask because of SunOS 4.1 (POSIX) conflict.
3627 * Define all `main' functions as returning void.
3629 Fri May 11 02:11:03 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
3631 * ln.c, mv.c, rm.c, rmdir.c, create.c, chmod.c: Change some
3634 * du.c, cp-aux.c (error): Function removed.
3635 Change callers to use error.c version.
3636 * cp.c (copy, do_copy, copy_dir): Return an error status.
3637 * ls.c (error, fatal, perror_with_name): Functions removed.
3638 Change callers to use error.c.
3640 Sat May 5 23:46:48 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
3642 * ln.c (do_link): Don't allow trying to link a file to itself,
3643 because the source file would be removed if they are the same
3644 directory entry, and also for consistency with mv and cp.
3646 Fri May 4 13:42:53 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
3648 * cp.c (copy_reg): Only write a null to the end of the file if
3649 the end of the file was sparse.
3651 * ls.c (print_name_with_quoting): Make the char to print
3652 unsigned to prevent sign extension problems with -b.
3654 Fri Apr 20 13:52:15 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
3656 * Version 1.2 released.
3658 Wed Apr 18 14:36:15 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
3660 * Makefile: Use chsize for ftruncate on Xenix.
3662 * cp.c (copy): Remove broken code that attempted to
3663 substitute for ftruncate on systems missing it.
3665 Mon Apr 16 13:58:01 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
3667 * cp-aux.c (usage): Fix mistake in message.
3669 * Version 1.1 released.
3671 Sat Apr 14 17:23:11 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
3673 * ls.c (main): Don't remove leading path from program_name.
3674 (basename): Function removed.
3675 (length_of_file_name_and_frills): Don't add 1 for type indicator
3676 for block and character special files.
3678 Thu Apr 12 19:50:15 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
3680 * Makefile: Suggest using -DBLKSIZE=512 instead of 1024 for USG.
3682 * dd.c (copy): Print copying statistics when exiting because
3683 of a read or seek error.
3684 (interrupt_handler): New function.
3685 (main): Trap SIGINT to run interrupt_handler, for POSIX.
3687 Tue Apr 10 01:09:38 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
3689 * chmod.c (change_file_mode): Don't change the mode of
3692 Mon Apr 9 13:30:00 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
3694 * modechange.c (compile_mode): Return an error if an octal
3695 number argument is too large.
3697 Sun Apr 8 20:33:20 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
3699 * dd.c: Use `error' instead of `fatal' and `pfatal_with_name',
3700 for greater control of the message format.
3701 * head.c, tail.c: Use `error' instead of `fatal_perror' and
3702 `nonfatal_perror'. Remove some unnecessary info from messages.
3703 * chmod.c, create.c, ln.c, mkdir.c, mkfifo.c, mv.c, mv_dir.c,
3704 rm.c, rmdir.c: Remove definition of `error'.
3705 * error.c: New file created from code in mv.c.
3706 * Makefile: Link the above programs with error.o.
3708 * ln.c (do_link): Use eaccess_stat to determine writability.
3709 * mv.c (do_move): Ditto.
3710 * rm.c (remove_file): Ditto.
3711 (remove_dir): Use eaccess_stat to determine readability and
3712 searchability. Move initial interactive query here from
3714 * Makefile: Link ln, mv, and rm with eaccess.o.
3716 Sat Apr 7 11:47:52 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
3718 * Makefile: Link cp with eaccess.o.
3719 * eaccess.c: New file adapted from code in cp.c and cp-aux.c.
3720 * cp.c (copy): Use eaccess_stat to determine writability.
3721 Consider a file unwritable by root if it has no permissions.
3722 (main): Remove groups initialization code.
3723 * cp-aux.c (member): Function deleted.
3725 * cp.c (copy): Temporarily change the mode of directories if
3726 necessary to overwrite them when running recursively.
3727 Consider a directory to be non-overwritable if it lacks write
3728 permission as well as if it lacks execute permission.
3730 * rm.c, mv.c, mv_dir.c, chmod.c, create.c, ln.c: Remove some
3731 irrelevant or redundant information from error messages.
3733 Fri Apr 6 15:20:45 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
3735 * cp.c (copy): Only change mode of regular files and directories;
3736 others are already correct.
3738 Thu Apr 5 04:31:56 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
3740 * dd.c: Remove the vars that are set by command line options
3741 from a useless struct and give them more meaningful names.
3743 Mon Apr 2 02:58:34 1990 David J. MacKenzie (djm at spike.ai.mit.edu)
3745 * cp.c (main): Use NGROUPS from sys/param.h to determine
3746 whether BSD multiple groups are supported and how large to
3748 * Makefile: Remove references to GETGROUPS_MISSING.
3750 Sun Apr 1 18:53:57 1990 David J. MacKenzie (djm at spike.ai.mit.edu)
3752 * cp.c (main): Always initialize group info.
3754 Sat Mar 31 22:29:57 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
3756 * mv.c [RENAME_MISSING] (rename): To rename directories, run
3757 setuid root mv_dir program.
3759 Tue Mar 20 14:28:25 1990 David J. MacKenzie (djm at pogo.ai.mit.edu)
3761 * touch.c: Remove POSIX_COMPAT ifdef since there is no reason
3762 to disable the GNU extensions.
3763 (main): Set new global var `program_name'.
3764 (error): Replace with more versatile version.
3765 Global: Change calls to fprintf and error to use the new error.
3766 (main): Initialize global variables. Don't bother making
3767 temporary copy of arg to -d. Don't ignore any files named on
3768 the command line if -i is given.
3769 (usage): Don't take an arg. Use `program_name' instead of
3771 (touch): In utime emulation for BSD, ftruncate the file to its
3772 original size so empty files stay empty after being touched.
3774 Sun Mar 18 01:02:39 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
3776 * ln.c (strip_trailing_slashes): New function.
3777 (main, do_link): Call it.
3779 * cp-aux.c (strip_trailing_slashes): New function.
3780 * cp.c (do_copy): Call it.
3783 * mv.c (strip_trailing_slashes): New function.
3784 (main, movefile): Call it.
3786 Sat Mar 17 21:45:35 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
3788 * cp-aux.c, cp.h: Rename user_confirm_overwriting to yesno and
3789 don't have it print a prompt, so it can be used in several
3792 * cp.c (do_copy): Change an error message to resemble mv's.
3793 Remove all trailing slashes from all non-option args.
3794 (main): Set new global var `stdin_not_tty'.
3795 (copy): Use POSIX method of handling file overwriting and
3798 * dirlib.c (mkdir): Use chmod to set the directory mode after
3799 successful creation, so set[ug]id and sticky bits are set
3802 Thu Mar 15 12:33:23 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
3804 * Makefile: Add commented out definitions for SCO Xenix.
3806 * ls.c (print_type_indicator): Don't print a '*' next to
3807 executable block or character special files.
3809 * chmod.c (error): New function, replacing nonfatal_perror,
3810 memory_out, and invalid_mode.
3811 Global: Call error instead of the above functions.
3812 (change_dir_mode): Make the new size of the path twice the
3813 size of the name that was too long, rather than twice its old
3816 * rm.c: Move interactive query about whether to remove a
3817 directory from remove_dir to clear_directory; only query for
3818 directories that are not empty.
3820 Wed Mar 14 10:48:40 1990 David J. MacKenzie (djm at rice-chex)
3822 * system.h [USG]: Define X_OK.
3824 * rm.c (main): Set new global var `stdin_not_tty'.
3825 (rm): Most of code moved to two new functions, remove_file and
3827 (remove_file): Use POSIX method of determining whether to remove
3829 (remove_dir): Use POSIX method of determining whether to
3830 remove directories, almost.
3831 (perror_with_name): Function removed.
3832 (error): Simple version replaced with more powerful version.
3833 Global: Change calls to fprintf, perror_with_name, and old
3834 error to calls to new error.
3836 * ln.c (main): Set new global var `stdin_not_tty'.
3837 If force, turn off interactive.
3838 (do_link): By default, don't allow hard links to symbolic links to
3839 directories. Use POSIX method of determining whether to
3840 overwrite destination.
3841 (yesno): Function renamed from confirm, and arg removed.
3842 (lisdir): Function removed.
3844 * mv.c (main): Set new global var `stdin_not_tty'.
3845 (yesno): Function renamed from yes.
3846 (do_move): Use POSIX method of determining whether to
3847 overwrite destination.
3849 * Makefile: Make executables depend on .o files, not .c files,
3850 to allow for parallel compilation.
3852 Tue Mar 13 00:50:14 1990 David J. MacKenzie (djm at rice-chex)
3854 * rm.c (main): Disallow removal of paths that have '..' as the
3856 (basename): New function.
3858 * ls.c (print_type_indicator): Mark FIFOs with '|' and sockets
3860 (print_long_format): Print numbers as unsigned and add extra
3861 space for POSIX flag.
3863 * dd.c: Make the record counts unsigned.
3864 (quit): Print them as unsigned.
3866 * modechange.c (compile_mode): Only get umask value when needed.
3867 If users are not given or are `a', affect set?id and sticky bits.
3868 If memory is exhausted while allocating a new list element,
3869 free the old elements before returning.
3871 * Makefile (CC): Add comment noting that either fixincludes or
3872 -traditional needs to be used for gcc to compile ioctl calls
3875 Mon Mar 12 16:25:23 1990 Jim Kingdon (kingdon at pogo.ai.mit.edu)
3877 * touch.c [UTIME_OF_NULL_MISSING]: Call lseek() before write().
3879 * posixtime.y [__GNUC__]: Use __builtin_alloca.
3881 Fri Mar 9 10:25:09 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
3883 * chmod.c (main): Recognize "a,+-=" as valid options.
3885 * mv.c: Move the code to copy files across filesystems from
3886 do_move to a new function, copy, which will eventually be
3887 replaced with modules from cp and rm (POSIX requires mv to
3888 move directories recursively across filesystems).
3889 (do_move): Don't query about overriding a mode that prohibits
3890 writing if interactive. Remove unneeded variable.
3891 (copy): Unlink target if copy fails partway through.
3893 Thu Mar 8 10:56:16 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
3895 * cp.c (copy): Don't remove a destination file of a different
3896 type unless +force is given.
3898 * ls.c (decode_switches, usage): Add -U (for "unsorted") as an
3899 equivalent to +sort=none.
3901 Mon Mar 5 16:31:14 1990 Torbj|rn Granlund (tege at echnaton)
3903 * cp.c (copy): Test for temporarily modified permission mode
3904 after the other test, so that `-p' work for files whose mode
3905 needed a temporary mode change.
3906 * cp.c (copy): Don't waste time calling unlink if we already
3907 know that the destination doesn't exists.
3908 * cp.c (comment before do_copy): Correct.
3909 * cp.c (comment before copy): Describe all params.
3910 * cp.c (copy): Only change permission mode for regular files
3912 * cp.c (copy): Unlink the destination file if its type is
3913 different from the source. If the destination is a
3916 Mon Mar 5 00:34:36 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
3918 * chmod.c (nonfatal_perror): Don't check for force_silent.
3919 (change_file_mode, change_dir_mode): If force_silent, don't
3920 print error messages.
3922 * mv.c (main): If force, turn off interactive.
3923 (do_move): Simplify check for query. Rename `stb' to
3924 `to_stats' and `stbf' to `from_stats'.
3925 Return error condition if original file could not be renamed or
3928 * rm.c: Rename global `force_flag' to `ignore_errors' and change its
3929 meaning so that it does not overlap with `override_mode'.
3930 (main): Have -f +force set override_mode. If override_mode is
3931 set, turn off interactive.
3932 (rm): Simplify checks for whether to query the user, based on
3933 the new relationship between override_mode and interactive.
3935 Sun Mar 4 23:39:03 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
3937 * ln.c (main): Reword an error message to be more like mv's.
3939 * rmdir.c: Move global `errors' into main instead of having
3942 * mkdir.c: Move global `errors' into main and have make_path
3943 return an error status instead of having error set it.
3945 * chmod.c: Move global `errors' into main and have
3946 change_file_mode and change_dir_mode return an error status
3947 instead of setting it in nonfatal_perror.
3949 Sat Mar 3 13:59:40 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
3951 * ln.c (main): Don't strip leading dirs from argv[0].
3953 * ln.c (confirm), mv.c (yes, do_move),
3954 cp-aux.c (user_confirm_overwriting), rm.c (rm, yesno, check_stack):
3955 Print query messages to stderr instead of stdout, for POSIX.
3956 Include program name in messages.
3958 Sat Mar 3 11:27:27 1990 Torbj|rn Granlund (tege at echnaton)
3960 * cp.c (copy): Don't unlink directories with flag_force
3961 (`-f'). Also avoid using force when not necessary.
3962 Always copy fifo's and symbolic links as themselves.
3964 * cp.c (copy_reg): Make int scan first, char scan then, to
3965 find first non-zero byte. This to avoid false hole
3968 Sat Mar 3 10:22:28 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
3970 * mv.c: Rename `pgm' to `program_name'. Move global `errors'
3971 into main. Have do_move and movefile return an error status
3972 instead having error set it. Remove global vars `args'
3974 (main): Rename `ac' and `av' to `argc' and `argv' and use them
3975 and `optind' instead of `args' and `args_left'.
3977 * cp.c (copy): Don't ignore errors other than EPERM from chown.
3979 Fri Mar 2 16:20:57 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
3981 * rm.c (main, usage): Allow -R as a synonym for -r, for POSIX.
3983 * cp.c (copy): If flag_preserve, preserve the owner and group
3984 if possible, as well as mode.
3985 (main): Allow -R as a synonym for -r option, for POSIX.
3986 * cp-aux.c (usage): Mention -R.
3988 Tue Feb 27 11:49:04 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
3990 * cp.c (copy): If not recursive, copy special files and
3991 symlinks like regular files and omit fifos.
3993 Mon Feb 26 19:55:24 1990 Jim Kingdon (kingdon at pogo.ai.mit.edu)
3995 * ls.c (print_long_format): If time is in the future, print the year.
3996 Make the cutoff for old files 6 months not 300 days.
3998 Mon Feb 26 13:31:07 1990 Jim Kingdon (kingdon at pogo.ai.mit.edu)
4000 * touch.c, Makefile: Use getdate.y instead of unctime.y.
4002 * touch.c: Remove posixtime.
4003 (main): Check for error from posixtime.
4004 posixtime.y: New file.
4006 * touch.c: Change a few cryptic error messages.
4007 Include <errno.h> not <sys/errno.h>.
4008 (just_set_amtime): New variable.
4009 (touch): Add if (just_set_amtime) code.
4011 Mon Feb 26 15:03:29 1990 Torbj|rn Granlund (tege at echnaton)
4013 * cp.c (copy): Test for recursive copy in DIR alternative in
4014 the switch statement, so all file types are copied correctly
4015 even in a non-recursive copy.
4016 * cp.c (copy): Return after having created a symlink, since
4017 chmod and utimes dereference, and would affect the symlink
4018 target. Remove test for symlinks after switch.
4020 Sun Feb 25 18:31:09 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
4022 * Makefile: Compile ls after vdir so systems with a cc that
4023 can't do -c -o don't have to compile ls.c twice for ls.
4025 * dd.c (usage): Add braces around alternatives.
4027 * ls.c (print_long_format): Always print the group, for POSIX.
4028 (decode_switches): Make -g option a no-op for BSD users.
4029 (usage): Remove +group option.
4031 Wed Feb 21 11:13:26 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
4033 * ln.c (error): New function.
4034 (main, do_link): Call error instead of fprintf and exit.
4035 (main): Recognize new -d +directory option to allow superuser to
4036 make hard links to dirs, like the BSD ln -f option.
4037 (do_link): Don't allow hard links to dirs (they are hard to
4038 get rid of -- rmdir and unlink don't do it), unless -d was given.
4039 (usage): Mention -d +directory option.
4041 * rmdir.c (main): Remove trailing slashes from args (added by
4042 shell file completion but the rmdir syscall can't handle them).
4043 * mkdir.c (main): Remove trailing slashes from args, for
4044 uniformity with rmdir (you can't do file completion on dirs
4045 that haven't been made yet . . .).
4047 * mv.c: Rename global var `nargs' to `args_left' to avoid
4048 conflict with undocumented BSD libc function (the new name is
4051 Tue Feb 20 17:09:19 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
4053 * dd.c: Use new global var `program_name' in error messages
4054 instead of hardcoded "dd".
4055 (main): Set program_name from argv[0].
4057 * chmod.c, head.c, tail.c (main): Don't strip leading dirs
4059 (basename): Function removed.
4061 * rm.c (main): Don't strip leading dirs from argv[0].
4063 Mon Feb 19 14:34:18 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
4065 * rm.c (main): Strip trailing slashes from each arg.
4067 Thu Feb 15 13:23:52 1990 David J. MacKenzie (djm at rice-chex)
4069 * Makefile [HPUX CFLAGS]: Add -DUTIMES_MISSING.
4071 Wed Feb 14 15:01:18 1990 David J. MacKenzie (djm at rice-chex)
4073 * Makefile (dist): Don't make a non-compressed tar file.
4075 * mv.c (do_move): Refuse to copy non-regular files across filesystems.
4077 Tue Feb 13 15:06:18 1990 Jim Kingdon (kingdon at pogo.ai.mit.edu)
4079 * touch.c (getname): New function.
4082 Mon Feb 12 11:30:45 1990 David J. MacKenzie (djm at rice-chex)
4084 * ln.c (do_link): Check error return from unlink.
4087 * du.c (main): Check error return from stat.
4088 (str_copyc, str_concatc): Don't return a value, since it is
4091 * cp.c (copy): Check error return from unlink and chmod. Fix
4092 typo in call to error.
4094 * mv.c (do_move): Check error return of fchmod/chmod and utime[s].
4095 (rename): Check error return of unlink.
4097 * Makefile Definitions of preprocessor macros moved from
4098 cp.c and mv.c. HAVE_FTRUNCATE changed to FTRUNCATE_MISSING.
4099 * Makefile, dirlib.c: NEED_MKDIR changed to MKDIR_MISSING.
4100 * mv.c, cp.c: Change USG ifdefs to UTIMES_MISSING.
4102 Sun Feb 11 17:50:29 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
4104 * chmod.c (usage): Add yet another ellipsis.
4106 Sun Feb 11 16:41:30 1990 Jim Kingdon (kingdon at pogo.ai.mit.edu)
4108 * cp.c (copy_reg): Use HAVE_FTRUNCATE to decide whether to
4110 (main): Use GETGROUPS_MISSING to decide whether to use getgroups().
4111 [hpux || !USG]: Define HAVE_FTRUNCATE.
4112 [USG && !hpux]: Define GETGROUPS_MISSING.
4113 mv.c (rename): Put in #ifdef RENAME_MISSING not #ifdef USG.
4114 (do_move): Use FCHMOD_MISSING to decide whether to use fchmod().
4115 [USG && !hpux]: Define FCHMOD_MISSING and RENAME_MISSING.
4117 Fri Feb 9 10:25:03 1990 David J. MacKenzie (djm at rice-chex)
4119 * mv.c (movefile): Remove trailing slashes from FROM (some
4120 filename completion systems add them for dirs, and they cause
4121 the rename syscall to fail).
4123 Thu Feb 8 22:50:12 1990 Torbj|rn Granlund (tege at sics.se)
4125 * cp.c (copy_reg): Change error handling after lseek, since
4126 this is a fatal error. Also change error message to
4127 something more generally understood.
4128 * Handle files that end in a zero block on USG systems.
4130 * cp-aux.c (error): Use FATAL to recog fatal errs.
4132 Thu Feb 8 21:25:40 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
4134 * ln.c: Remove incorrect comment.
4136 * cp.c, cp-aux.c (usage): Change +dereference option to
4137 +no-dereference, since dereferencing is done by default and
4138 the option turns it off.
4140 Mon Feb 5 17:29:20 1990 David J. MacKenzie (djm at albert.ai.mit.edu)
4142 * Version 1.0 released.
4147 version-control: never