update changelog
[platform/upstream/diffutils.git] / ChangeLog
1 2013-03-24  Jim Meyering  <meyering@fb.com>
2
3         version 3.3
4         * NEWS: Record release date.
5
6 2013-03-23  Paul Eggert  <eggert@cs.ucla.edu>
7
8         doc: fix menu typo
9         * doc/diffutils.texi (Comparing Three Files): Fix out-of-order menu.
10         Bug caught by Texinfo 5.0.
11
12         maint: update build procedure to recent gettext etc.
13         * bootstrap.conf (gnulib_modules): Add vararrays.
14         (needed_gnulib_files, unnecessary_gettext_files): New vars.
15         (bootstrap_post_import_hook): New function, to implement these vars.
16         (excluded_files): Remove; 'bootstrap' no longer supports this.
17         Its function is now performed by unnecessary_gettext_files.
18         (buildreq): Update automake to 1.12.2, to avoid CVE-2012-3386.
19         * configure.ac (AM_GNU_GETTEXT_VERSION): Bump from 0.17 to 0.18.2,
20         to lessen the probability that we'll have outlandishly old files
21         during a build.
22         * m4/vararrays.m4: Remove from repository, as we now use the
23         gnulib version.
24
25 2013-03-21  Jim Meyering  <jim@meyering.net>
26
27         build: update gnulib to latest and adapt; update bootstrap, too
28         Blindly updating to the latest from gnulib, bootstrap would
29         fail due to failure of our local patches to apply.  Hence,
30         these first two updates.
31         * gl/lib/regex_internal.c.diff: Update offsets, so this patch
32         applies to the latest from gnulib.
33         * gl/lib/regex_internal.h.diff: Remove file.  No longer needed.
34         * bootstrap: Update from gnulib.
35
36 2013-01-06  Paul Eggert  <eggert@cs.ucla.edu>
37
38         tests: port to hosts lacking fmt, make -C
39         * tests/Makefile.am (built_programs): Don't assume fmt works.
40         Don't rely on 'make -C', either.
41
42         maint: update .gitignore for recent gnulib
43         * .gitignore: Add tests/*.trs and several *.h and *.sed files in lib,
44
45 2013-01-04  Jim Meyering  <jim@meyering.net>
46
47         build: update gnulib submodule to latest
48
49         maint: update all copyright year number ranges
50         Run "make update-copyright".
51
52 2012-10-23  Eric Blake  <eblake@redhat.com>
53
54         build: default to --enable-gcc-warnings in a git tree
55         Anyone building from cloned sources can be assumed to have a new
56         enough environment, such that enabling gcc warnings by default will
57         be useful.  Tarballs still default to no warnings, and the default
58         can still be overridden with --disable-gcc-warnings.
59         * configure.ac (gl_gcc_warnings): Set default based on environment.
60
61 2012-10-03  Paul Eggert  <eggert@cs.ucla.edu>
62
63         * doc/diffutils.texi (cmp Options): Document -l format better.
64
65 2012-09-10  Jim Meyering  <meyering@redhat.com>
66
67         maint: use xasprintf in place of xmalloc+sprintf
68         * bootstrap.conf (gnulib_modules): Add gnulib's xvasprintf module.
69         * src/util.c: Include "xvasprintf.h".
70         (begin_output): Use xasprintf in place of xmalloc+sprintf.
71
72 2012-09-10  Andreas Gruenbacher  <agruen@gnu.org>
73
74         diff: encode file names with special characters
75         * src/util.c (c_escape_char): New function.
76         (c_escape): New function.
77         (begin_output): Escape file names when needed.
78         * src/context.c (print_context_header): New names parameter.
79         (print_context_label): New name parameter.
80         * src/diff.h (print_context_header): Change prototype.
81         * tests/filename-quoting: New file.
82         * NEWS: Document this change.
83
84 2012-08-30  Paul Eggert  <eggert@cs.ucla.edu>
85
86         diff: silence GCC warning instead of slowing down
87         * src/dir.c (find_dir_file_pathname): Use 'IF_LINT (volatile)' to
88         silence the gcc warning, rather than using 'volatile', as the
89         warning appears to be bogus.
90
91 2012-08-28  Jim Meyering  <meyering@redhat.com>
92
93         diff: avoid possible longjmp-triggered misbehavior
94         * src/dir.c (find_dir_file_pathname): gcc 4.8.0 20120825 reported
95         that a local variable's value might be clobbered.  Declare "match"
96         to be volatile.
97
98         build: update gnulib, bootstrap and init.sh to latest
99
100         maint: avoid new syntax-check failure due to @xref use
101         * doc/diffutils.texi: Change several "; @xref{..." to ".  @xref{...",
102         since @xref should start a sentence.
103
104 2012-05-15  Paul Eggert  <eggert@cs.ucla.edu>
105
106         maint: remove ms subdirectory
107         diffutils is now designed to build with Cygwin or MinGW.
108         The old DJGPP stuff probably doesn't work anyway.
109         * Makefile.am (SUBDIRS): Remove ms.
110         * NEWS: Document this.
111         * configure.ac (AC_CONFIG_FILES): Remove ms/Makefile.
112         * ms/Makefile.am, ms/README, ms/config.bat, ms/config.sed:
113         * ms/config.site: Remove.
114
115 2012-05-14  Paul Eggert  <eggert@cs.ucla.edu>
116
117         maint: update bootstrap from gnulib
118         * bootstrap: Update from gnulib.
119
120         main: port subcommands to mingw
121         Problem reported by Eli Zaretskii in
122         <http://lists.gnu.org/archive/html/bug-gnu-utils/2012-05/msg00013.html>.
123         Approach suggested by Bruno Haible as option (4) in
124         <http://lists.gnu.org/archive/html/bug-gnu-utils/2012-05/msg00036.html>.
125         * bootstrap.conf (gnulib_modules): Add system-quote.
126         * src/diff3.c, src/sdiff.c, src/util.c:
127         Include <system-quote.h>, not <sh-quote.h>.
128         * src/diff3.c (read_diff):
129         * src/sdiff.c (main, edit):
130         * src/util.c (begin_output):
131         Use system_quote_argv, for portability to Mingw.
132         * src/sdiff.c (NUM_SIGS, handler_index_of_SIGINT): Now enum
133         values, not macros; this is cleaner and avoids a GCC warning if
134         !HAVE_WORKING_VFORK.
135         * src/util.c (begin_output) [! HAVE_WORKING_FORK]: Do not use -f,
136         for consistency with the HAVE_WORKING_FORK code.
137
138         maint: update bootstrap from gnulib
139         * bootstrap: Update from gnulib.
140
141         maint: m4/gnulib-cache.m4 is not under version control
142         This is like what coreutils does, and suppresses 'git status' chatter.
143         * .gitignore: Add /m4/gnulib-cache.m4.
144
145         Use binary mode when testing for binary files.
146         This reverts the 2006-01-05 change and modernizes to the current API.
147         Idea suggested by Eli Zaretskii in:
148         http://lists.gnu.org/archive/html/bug-gnu-utils/2012-05/msg00066.html
149         * src/cmp.c (main):
150         * src/diff.c (main, compare_files):
151         Use set_binary_mode rather than SET_BINARY.
152         * src/diff.c (compare_files): Omit unnecessary use of O_BINARY.
153         * src/io.c (sip): Sample unknown files in binary mode, to see
154         whether they are binary.
155         (read_files): Read binary files in binary mode.
156
157         build: update gnulib submodule to latest
158
159 2012-05-13  Stefano Lattarini  <stefano.lattarini@gmail.com>
160
161         build: omit obsolete AM_PROG_CC_STDC macro
162         The Automake-provided macro 'AM_PROG_CC_STDC' has been superseded by
163         the Autoconf-provided one 'AC_PROG_CC' since October 2002, and will
164         be removed in the next major automake version.
165         * configure.ac (AM_PROG_CC_STDC): Drop it.
166
167 2012-05-05  Jim Meyering  <meyering@redhat.com>
168
169         diff: fix a typo that was always disabling the same_special_file macro
170         * src/system.h (same_special_file): Correct cpp guard expression:
171         s/HAVE_ST_RDEV/HAVE_STRUCT_STAT_ST_RDEV/.  Reported by Eli Zaretskii.
172
173 2012-04-17  Jim Meyering  <meyering@redhat.com>
174
175         maint: update bootstrap from gnulib
176         * bootstrap: Update from gnulib.
177
178 2012-03-07  Eric Blake  <eblake@redhat.com>
179
180         usage: improve wording of --ignore-matching-lines
181         * src/diff.c (option_help_msgid): Tweak wording.
182
183 2012-03-04  Paul Eggert  <eggert@cs.ucla.edu>
184
185         doc: explain -I RE better in --help output
186         * src/diff.c, src/sdiff.c (option_help_msgid): For -I RE,
187         change "whose lines all match" to "all whose lines match" to avoid
188         unintended interpretation.  Reported by Danijel Tasov in
189         <http://bugs.debian.org/648411>.
190
191 2012-02-12  Paul Eggert  <eggert@cs.ucla.edu>
192
193         sdiff: remove dependency on sigprocmask
194         * bootstrap.conf (gnulib_modules): Remove sigprocmask.
195         * src/sdiff.c (temporary_file): No need to invoke sigprocmask
196         here, since the signal handler merely sets a flag.
197
198 2012-02-04  Paul Eggert  <eggert@cs.ucla.edu>
199
200         diff: -N, --unidirectional-new-file now compare to "-" too
201         * NEWS: Document this.
202         * doc/diffutils.texi (Comparing Directories): Likewise.
203         Also, document that these options work at the top level.
204         * src/diff.c (compare_files): Treat EBADF like ENOENT, to handle
205         the case where "-" is closed.  Allow the other file to be
206         STDIN_FILENO, in case it's "-".
207         * tests/Makefile.am (TESTS): Add new-file.
208         * tests/new-file: New file.
209
210 2012-01-25  Paul Eggert  <eggert@cs.ucla.edu>
211
212         maint: quote 'like this' or "like this", not `like this'
213         This is in response to a recent change in the GNU coding standards,
214         which now suggest quoting 'like this' or "like this", instead of
215         `like this' or ``like this''.
216         * HACKING, NEWS, README, README-hacking, TODO, doc/diagmeet.note:
217         * doc/diffutils.texi, ms/config.bat, ms/config.site:
218         * src/analyze.c, src/cmp.c, src/context.c, src/diff.c:
219         * src/diff.h, src/diff3.c, src/dir.c, src/ifdef.c, src/io.c:
220         * src/sdiff.c, src/side.c, src/system.h, src/util.c:
221         * tests/help-version:
222         Quote 'like this' or "like this" in commentary.
223         * cfg.mk (old_NEWS_hash): Adjust to reflect new NEWS quoting.
224         * man/help2man: Update to 1.40.4 version, with quoting fixed as above.
225         * po/en.po: Remove translation involving `, as it's no longer needed.
226         * src/cmp.c (try_help, specify_ignore_initial, usage, main):
227         * src/diff.c (main, try_help, option_help_msgid, specify_value)
228         (compare_files):
229         * src/diff3.c (main, try_help, option_help_msgid, usage)
230         (read_diff):
231         * src/dir.c (compare_names):
232         * src/sdiff.c (try_help, usage, check_child_status, main):
233         * src/util.c (finish_output):
234         * tests/help-version:
235         Quote 'like this' in output.
236
237         build: update gnulib submodule to latest
238
239 2012-01-12  Jim Meyering  <meyering@redhat.com>
240
241         build: accommodate newer bootstrap from gnulib
242         * bootstrap.conf (gnulib_tool_option_extras): Add both --symlink
243         and --makefile-name=gnulib.mk.  Also remove now-obsolete $bt/ prefix.
244         * bootstrap: Update from gnulib.
245         * tests/init.sh: Update from gnulib.
246         * lib/Makefile.am: Initialize numerous variables, so that
247         generated code in gnulib.mk may use += to append to them.
248
249         maint: avoid new syntax-check failure
250         * src/diff.c (compare_files): Use STREQ, not strcmp.
251
252 2012-01-08  Bruno Haible  <bruno@clisp.org>
253
254         New option --no-dereference.
255         * src/diff.h (no_dereference_symlinks): New variable.
256         * src/diff.c: Include xreadlink.h.
257         (longopts): Add --no-dereference option.
258         (main): Accept --no-dereference option.
259         (option_help_msgid): Mention the --no-dereference option.
260         (compare_files): If no_dereference_symlinks is true, use lstat()
261         instead of stat(). Compare symbolic links by comparing their values.
262         * bootstrap.conf (gnulib_modules): Add lstat, stat, xreadlink.
263         * doc/diffutils.texi (Comparing Directories, diff Options): Mention the
264         --no-dereference option.
265         * tests/no-dereference: New file.
266         * tests/Makefile.am (TESTS): Add it.
267
268 2012-01-01  Jim Meyering  <meyering@redhat.com>
269
270         maint: update all copyright year number ranges
271         Run "make update-copyright".
272
273 2011-12-14  Jim Meyering  <meyering@redhat.com>
274
275         build: update to latest gnulib and adapt
276         * tests/binary: Reverse arguments to compare to avoid failure of
277         new syntax-check rule.
278         * configure.ac: Use -Wno-format-nonliteral.
279         Mark functions as pure of const, per recommendations enabled by
280         new gcc -W options.  Use _GL_ATTRIBUTE_PURE and _GL_ATTRIBUTE_CONST.
281         * lib/cmpbuf.h (buffer_lcm, block_compare):
282         Apply pure and/or const attributes.
283         * src/cmp.c (block_compare): Likewise.
284         * src/context.c (find_hunk): Likewise.
285         * src/diff.h (lines_differ): Likewise.
286         * src/diff3.c (skipwhite): Likewise.
287         * src/dir.c (dir_loop): Likewise.
288         * src/util.c (find_change, find_reverse_change): Likewise.
289         (translate_line_number): Likewise.
290
291         build: stop distributing gzip'd releases;  xz is enough
292         * configure.ac (AM_INIT_AUTOMAKE): Add no-dist-gzip.
293
294 2011-11-29  Jim Meyering  <meyering@redhat.com>
295
296         tests: use "compare exp out", not "compare out exp"
297         Likewise, when an empty file is expected, use "compare /dev/null out",
298         not "compare out /dev/null". I.e., specify the expected/desired contents
299         via the first file name.  Prompted by a suggestion from Bruno Haible
300         in http://thread.gmane.org/gmane.comp.gnu.grep.bugs/4020/focus=29154
301
302         Run these commands:
303
304           git grep -l -E 'compare [^ ]+ exp' \
305             |xargs perl -pi -e 's/\b(compare) (\S+) (exp\S*)/$1 $3 $2/'
306           git grep -l -E 'compare [^ ]+ /dev/null' \
307             |xargs perl -pi -e 's,\b(compare) (\S+) (/dev/null),$1 $3 $2,'
308
309         But manually convert this one:
310
311           -compare out exp-$(echo $opt|tr ' ' _)
312           +compare exp-$(echo $opt|tr ' ' _) out
313
314         and avoid an inappropriate change to cfg.mk.
315
316 2011-10-12  Stefano Lattarini  <stefano.lattarini@gmail.com>
317
318         tests: use more portable fd redirection in TESTS_ENVIRONMENT
319         * tests/Makefile.am (TESTS_ENVIRONMENT): Redirection with `exec 9>&2'
320         is not portable to various Korn shells, and to (at least) HP-UX 11
321         /bin/sh.  Use a more portable idiom.
322         See http://thread.gmane.org/gmane.comp.gnu.coreutils.bugs/22488 for
323         lots of discussion.
324
325 2011-10-11  Stefano Lattarini  <stefano.lattarini@gmail.com>
326
327         tests: make test runner a script, not a shell function
328         All the test scripts in the diffutils testsuite are shell scripts,
329         so the current definition of TESTS_ENVIRONMENT, which adaptively
330         run tests using either perl or the shell depending on their kind,
331         is an overkill.
332
333         Moreover, this change is required in order for the testsuite to
334         continue to work with the new testsuite harness that is planned
335         to be introduced in Automake 1.12 (which, as of the writing date,
336         is still under development and in late alpha state).
337
338         See also related discussion on bug-coreutils:
339          <http://debbugs.gnu.org/cgi/bugreport.cgi?bug=8887>
340
341         * tests/Makefile.am (TESTS_ENVIRONMENT): Remove definition of the
342         `shell_or_perl_' shell function, which is not required anymore.
343         (LOG_COMPILER): New, define to `$(SHELL)'.
344         * tests/binary: Make executable.
345         * tests/colliding-file-names: Likewise.
346         * tests/excess-slash: Likewise.
347         * tests/no-newline-at-eof: Likewise.
348
349 2011-10-04  Claudio Bley  <claudio.bley@gmail.com>
350
351         portability: use SET_BINARY rather than xfreopen (NULL, ...
352         * src/diff.c: Include binary-io.h, not xfreopen.h.
353         (main): Use SET_BINARY (...) rather than xfreopen (NULL, X, ...),
354         because the latter doesn't work on MinGW and crashes using MSVC.
355         * src/cmp.c (main): Likewise.
356
357 2011-10-04  Jim Meyering  <meyering@redhat.com>
358
359         build: update gnulib submodule to latest
360
361 2011-09-02  Jim Meyering  <meyering@redhat.com>
362
363         post-release administrivia
364         * NEWS: Add header line for next release.
365         * .prev-version: Record previous version.
366         * cfg.mk (old_NEWS_hash): Auto-update.
367
368         version 3.2
369         * NEWS: Record release date.
370
371         build: update bootstrap and tests/init.sh from gnulib
372         * bootstrap: Update from gnulib.
373         * tests/init.sh: Likewise.
374
375         build: update gnulib submodule to latest
376
377 2011-09-01  Jim Meyering  <meyering@redhat.com>
378
379         doc: diffutils' texi-derived doc may now be in debian's "main" section
380         * NEWS (Packaging): Mention the "no front/back-cover" change.
381
382 2011-08-14  Jim Meyering  <meyering@redhat.com>
383
384         maint: avoid new "make sytnax-check" failure.
385         * src/diff.h (find_dir_file_pathname): Mark declaration with "extern"
386         keyword, in order to placate the tight-scope syntax check.
387
388 2011-08-14  Paul Eggert  <eggert@cs.ucla.edu>
389
390         * src/io.c (find_and_hash_each_line): Refactor for brevity.
391
392 2011-08-14  Roland McGrath  <roland@hack.frob.com>
393
394         diff, sdiff: new option --ignore-trailing-space (-Z)
395         Derived from Roland McGrath's patch (dated June 2004!) in:
396         http://lists.gnu.org/archive/html/bug-gnu-utils/2004-07/msg00000.html
397         * NEWS:
398         * doc/diffutils.texi (White Space, Blank Lines)
399         (sdiff Option Summary, diff Options, sdiff Options): Document -Z.
400         * src/diff.h (IGNORE_TRAILING_SPACE)
401         (IGNORE_TAB_EXPANSION_AND_TRAILING_SPACE): New constants, for -Z.
402         * src/diff.c (shortopts, longopts, main, option_help_msgid):
403         * src/sdiff.c (longopts, option_help_msgid, main):
404         * src/io.c (find_and_hash_each_line):
405         * src/util.c (lines_differ, analyze_hunk): Support -Z.
406
407 2011-08-13  Paul Eggert  <eggert@cs.ucla.edu>
408
409         * bootstrap.conf (gnulib_modules): Remove timegm.
410         This fixes a problem noted by Andreas Schwab in:
411         http://lists.gnu.org/archive/html/bug-diffutils/2011-08/msg00035.html
412
413 2011-08-13  Tim Waugh  <twaugh@redhat.com>
414
415         diff: --ignore-file-name-case now applies at top level too
416         Derived from Tim Waugh's patch in:
417         http://lists.gnu.org/archive/html/bug-diffutils/2011-08/msg00034.html
418         * NEWS, doc/diffutils.texi (diff Options): Document this.
419         * src/diff.c (compare_files): Implement this, by using
420         find_dir_file_pathname.
421         * src/diff.h (find_dir_file_pathname): New decl.
422         * src/dir.c: Include filenamecat.h.
423         (find_dir_file_pathname): New function.
424
425 2011-08-13  Paul Eggert  <eggert@cs.ucla.edu>
426
427         * .gitignore: Add lib/unistr, lib/unused-parameter.h.
428
429 2011-08-10  Jim Meyering  <meyering@redhat.com>
430
431         post-release administrivia
432         * NEWS: Add header line for next release.
433         * .prev-version: Record previous version.
434         * cfg.mk (old_NEWS_hash): Auto-update.
435
436         version 3.1
437         * NEWS: Record release date.
438
439         build: use largefile module and update to latest gnulib
440         * configure.ac: Remove AC_SYS_LARGEFILE, subsumed by ...
441         * bootstrap.conf (gnulib_modules): ...this.  Use largefile module.
442         * gnulib: Update to latest.
443
444 2011-08-08  Santiago Vila  <sanvila@unex.es>
445
446         doc: insert comma in --help line for --ignore-space-change (-b)
447         * src/diff.c (option_help_msgid): Insert omitted comma between
448         "-b" and "--ignore-space-change".  (tiny change)
449
450 2011-08-04  Jim Meyering  <meyering@redhat.com>
451
452         doc: relax restriction on front-cover and back-cover texts
453         * doc/diffutils.texi (copying): Relax restriction on front-cover
454         and back-cover texts (just as m4 did here:
455         http://git.savannah.gnu.org/cgit/m4.git/commit?id=ee1e92ec).
456         Reported by Santiago Vila.  Fix suggested by Eric Blake.
457
458 2011-08-03  Jim Meyering  <meyering@redhat.com>
459
460         tests: update init.sh from gnulib
461         * tests/init.sh: Update from gnulib.
462
463         build: update gnulib submodule to latest
464
465 2011-07-03  Jim Meyering  <meyering@redhat.com>
466
467         maint: remove inclusion of unused header, for "make syntax-check"
468         * src/diff3.c: Don't include <inttostr.h>.  Not used.
469         * src/context.c: Likewise.
470
471 2011-06-19  Jim Meyering  <meyering@redhat.com>
472
473         build: don't require perl when building from a tarball
474         But do ensure -- in all other circumstances -- that the man/*.1
475         files are rebuilt whenever the version number changes.
476         * configure.ac (SRC_VERSION_C): Define.
477         * man/Makefile.am (dist_man1_MANS): Rename from $(man1_MANS),
478         so that we distribute those pesky man/*.1 files.
479         (EXTRA_DIST): Reflect name change.
480         (MAINTAINERCLEANFILES): Define this, not DISTCLEANFILES,
481         now that these generated files are distributed.
482         ($(dist_man1_MANS)): Depend on $(SRC_VERSION_C), so we get the
483         full dependency when not building from a tarball.
484
485 2011-06-13  Jim Meyering  <meyering@redhat.com>
486
487         doc: do not distribute generated man/*.1 man files
488         * man/help2man: New file.
489         * man/Makefile.am: Use $(srcdir)/help2man.
490         Convert $(dist_man1_MANS) to $(man1_MANS), to tell automake
491         not to distribute the generated man/*.1 files.  Now they're
492         generated at build-from-tarball time.
493         ($(man1_MANS)): Depend on version.c, so that man pages are
494         regenerated whenever the version string changes.
495
496         build: ccache works better without embedded version strings
497         * src/Makefile.am: Generate version.c and version.h and put the
498         new symbol in a tiny library to be used by each program.
499         (LDADD): Add the new library.
500         * src/cmp.c (main): Use Version, not PACKAGE_VERSION, so the .o
501         file does not change with each commit-derived version increment.
502         * src/diff.c (main): Likewise.
503         * src/diff3.c (main): Likewise.
504         * src/sdiff.c (main): Likewise.
505         * src/system.h: Include "version.h".
506         * .gitignore: Add version.[ch]
507
508 2011-06-12  Jim Meyering  <meyering@redhat.com>
509
510         doc: ensure each program has a man/*.x file: add "SEE ALSO" references
511         * man/cmp.x: New file.
512         * man/diff3.x: New file.
513         * man/sdiff.x: New file.
514         * man/diff.x: Add xrefs to the other three programs, and to patch.
515         * man/Makefile.am (EXTRA_DIST): List new files.
516         (cmp.1, diff3.1, sdiff.1): Depend on each .x file.
517
518         doc: rename diff.texi to diffutils.texi
519         This makes the .texi basename the same as the package name,
520         which is consistent with most other GNU packages.
521         * doc/diffutils.texi: Rename from...
522         * doc/diff.texi: ...removed.
523         * doc/Makefile.am (info_TEXINFOS): Reflect name change.
524         (diffutils_TEXINFOS): Likewise.
525         * cfg.mk (gendocs_options_): Remove this customization.  It is no
526         longer needed, now that the .texi name matches that of the package.
527         * man/Makefile.am ($(dist_man1_MANS)): Remove now-unnecessary sed
528         filter.
529         * README: Update references to diffutils.texi etc. here, too.
530         * .gitignore: Update here, too.
531         Suggested by Karl Berry.
532
533 2011-06-08  Karl Berry  <karl@freefriends.org>
534
535         cmp, diff, diff3, sdiff: edit and align --help text.
536         * cmp.c (option_help_msgid, usage),
537         * diff.c (option_help_msgid, usage),
538         * diff3.c (option_help_msgid, usage),
539         * sdiff.c (option_help_msgid, usage): align descriptions in the --help
540         output and slightly edit content.
541
542 2011-05-27  Paul Eggert  <eggert@cs.ucla.edu>
543
544         diff: don't use locales after local-specific sorting fails
545         * src/dir.c (compare_names): Don't invoke strcasecmp if
546         locale-specific sorting fails, because POSIX.1-2008 says strcasecmp
547         has unspecified behavior outside the POSIX locale.  See:
548         http://lists.gnu.org/archive/html/bug-diffutils/2011-05/msg00008.html
549
550         bootstrap: Avoid multithreading.
551         * bootstrap.conf (gnulib_tool_option_extras):
552         Add "--avoid=localename --avoid=lock", because we don't want to
553         bring in the multithreading code that recent gnulib changes would
554         otherwise bring in.
555         (excluded_files): Remove m4/lock.m4; no longer needed, now that
556         we use --avoid=lock.
557
558         build: update gnulib submodule to latest
559
560 2011-05-23  Karl Berry  <karl@gnu.org>
561
562         maint: update README-hacking
563         * README-hacking: Update a la coreutils for git, etc.
564
565 2011-05-23  Jim Meyering  <meyering@redhat.com>
566
567         maint: update gnulib to latest with accompanying tight-scope tweaks
568         * cfg.mk: Include $(srcdir)/dist-check.mk using "-include",
569         to accommodate the new sc_tight_scope rule.
570         (_gl_TS_extern): Define, to tell gnulib's tight_scope rule that
571         headers here mark externs with "XTERN".
572         * gnulib: Update to latest.
573
574 2011-05-18  Jim Meyering  <meyering@redhat.com>
575
576         maint: use gnulib's new readme-release module
577         * bootstrap.conf (gnulib_modules): Add readme-release.
578         (bootstrap_epilogue): Add the recommended perl one-liner.
579         * README-release: Remove file; it is now generated from gnulib.
580         * .gitignore: Add it.
581
582         build: update gnulib submodule to latest
583
584         maint: prepare for the tight-scope check
585         * src/diff.h: Mark function declarations with "extern" in
586         preparation for the tight-scope check.
587         (ignore_white_space): Separate enum decl from declaration
588         of this variable.
589         * src/Makefile.am (diff_SOURCES): Move diff.h from here to ...
590         (noinst_HEADERS): ...here.
591         For convenience, since the tight-scope rule uses $(noinst_HEADERS).
592
593         maint: don't use now-removed gnulib "exit" module
594         * bootstrap.conf (gnulib_modules): Remove "exit" module.
595         It no longer exists.
596
597 2011-03-26  Jim Meyering  <meyering@redhat.com>
598
599         build: update gnulib submodule to latest
600
601         * .x-sc_space_tab: Remove file.  Instead, ...
602         * cfg.mk (exclude_file_name_regexp--sc_space_tab): ...define this.
603
604         maint: fix typo in unused rule
605         * cfg.mk (config-save): Fix typo: add leading "_" in variable name.
606
607 2011-03-18  Jim Meyering  <meyering@redhat.com>
608
609         doc: add a reference to wdiff(1) from diff.1
610         * man/diff.x: New file, to add "SEE ALSO" reference to wdiff(1).
611         * man/Makefile.am (diff.1): Depend on diff.x.
612         ($(dist_man1_MANS)): Tell help2man to include diff.x.
613         (EXTRA_DIST): Add diff.x.
614         Suggestion from Dan Jacobson in http://bugs.debian.org/613319
615
616 2011-03-18  Eric Blake  <eblake@redhat.com>
617
618         docs: info should mention -L
619         * doc/diff.texi (diff Options): Document -L.
620
621         docs: diff --help should mention -L
622         * src/diff.c (option_help_msgid): Document -L.
623
624 2011-02-15  Jim Meyering  <meyering@redhat.com>
625
626         doc: speak of the --test (-a) option, not "the -a or --test option"
627         Convert using this command:
628         perl -pi -e \
629           's/(\@option{-.}) or (\@option{--.*?}) option/$2 ($1) option/' \
630           doc/diff.texi
631         Then convert some more with this:
632         perl -pi -e \
633             's/the (\@option{-.}) or (\@option{--.*?})$/the $2 ($1)/' \
634           doc/diff.texi
635         Then convert more manually.
636
637         Suggested by Dan Jacobson
638
639 2011-01-24  Jim Meyering  <meyering@redhat.com>
640
641         maint: remove all uses of vfork: use fork instead
642         Our use of vfork now provokes warnings from gcc-4.6.0.
643         Also, vfork is no longer even specified by POSIX.1-2008.
644         * src/diff3.c (read_diff): Change each use of vfork to "fork".
645         Remove #ifdef'd code.
646         * src/util.c (begin_output, finish_output): Likewise.
647         * src/sdiff.c (cleanup, main, edit): Likewise.
648         (handler_index_of_SIGPIPE): Remove now-unused definition.
649         * src/system.h: Don't include <vfork.h>.
650         (vfork): Remove definition.
651         * ms/config.site: Remove reference to vfork cache variable.
652
653         tests: avoid newer but less-portable tail option syntax
654         * tests/function-line-vs-leading-space: Use sed -n '3,$p' rather than
655         tail -n+3.  Older versions of tail do not accept that newer syntax.
656         Reported by Sudhakara Peram.
657
658         tests: fix an erroneous test
659         On most systems, like-named files were compared, by luck.
660         However, on others, different-named files would be compared
661         since their names were being treated as equal -- but they had
662         different content, so the test would fail.
663         * tests/colliding-file-names: Use different sets of file names
664         in d1 and d2 so that they cannot accidentally match.
665         Put the same line in each test file.  This is required
666         when files named e.g., abc and ABC are compared.
667         This test was failing on a NixOS 86_64-darwin system.
668
669         build: update gnulib submodule to latest
670
671         tests: fix typo that silently disabled all tests
672         * tests/Makefile.am (TESTS): Fix typo: s/jESTS/TESTS/
673
674 2011-01-23  Jim Meyering  <meyering@redhat.com>
675
676         build: update gnulib submodule to latest
677
678         maint: avoid new syntax-check failure
679         * src/diff.c (specify_value): Use !STREQ(...), not strcmp(...) != 0.
680         * src/diff3.c (main): Likewise.
681
682 2011-01-03  Jim Meyering  <meyering@redhat.com>
683
684         maint: update copyright year ranges to include 2011
685         Run "make update-copyright", so "make syntax-check" works in 2011.
686
687         build: update gnulib submodule to latest
688
689 2010-12-16  Paul Eggert  <eggert@cs.ucla.edu>
690
691         bootstrap: adjust to recent gnulib changes
692         * bootstrap.conf (excluded_files): Do not exclude m4/size_max.m4
693         and m4/xsize.m4 when using an external gettext, since they are
694         now needed by other gnulib modules.
695
696 2010-12-16  Jim Meyering  <meyering@redhat.com>
697
698         doc: add contributor guidelines: HACKING
699         * HACKING: New file, copied 99% from the one in grep's repository.
700
701 2010-10-09  Jim Meyering  <meyering@redhat.com>
702
703         maint: describe policy on copyright year number ranges
704         * README: Mention coreutils' long-standing policy on use of M-N
705         ranges in copyright year lists.  Requested by Richard Stallman.
706
707 2010-09-04  Jim Meyering  <meyering@redhat.com>
708
709         maint: adjust init.sh use to conform
710         * tests/help-version: Use one line: "${srcdir=.}/init.sh"; ...
711         * tests/basic: Likewise.
712         * tests/binary: Likewise.
713         * tests/colliding-file-names: Likewise.
714         * tests/excess-slash: Likewise.
715         * tests/function-line-vs-leading-space: Likewise.
716         * tests/help-version: Likewise.
717         * tests/label-vs-func: Likewise.
718         * tests/no-newline-at-eof: Likewise.
719         * tests/stdin: Likewise.
720
721         maint: avoid shadowing warning
722         * src/dir.c (diff_dirs): Rename shadowed local cmp to "c".
723
724 2010-09-03  Jim Meyering  <meyering@redhat.com>
725
726         build: use gettext-h, not gettext
727         * bootstrap.conf (gnulib_modules): Use gettext-h, not gettext.
728         The latter is overkill for a package that uses
729         AM_GNU_GETTEXT([external]...
730
731         build: update build/test tools from gnulib
732         * bootstrap: Update from gnulib.
733         * tests/init.sh: Likewise.
734
735         build: update gnulib submodule to latest
736
737 2010-08-14  Jim Meyering  <meyering@redhat.com>
738
739         diff -r: avoid printing excess slashes in concatenated file names
740         * bootstrap.conf (gnulib_modules): Add filenamecat.
741         * src/diff.c: Include "filenamecat.h".
742         (compare_files): Use file_name_concat, rather than dir_file_pathname.
743         * src/util.c (dir_file_pathname): Remove now-unused function.
744         * src/diff.h: Remove its declaration.
745         * tests/excess-slash: New script to test for this.
746         * tests/Makefile.am (TESTS): Add it.
747         Forwarded by Santiago Vila from <bugs.debian.org/586301a>,
748         reported by Jari Aalto.
749
750 2010-08-12  Paul Eggert  <eggert@cs.ucla.edu>
751
752         diff: avoid spurious diffs when two distinct dir entries compare equal
753         Problem reported by Christoph Anton Mitterer in:
754         http://lists.gnu.org/archive/html/bug-diffutils/2010-08/msg00000.html
755
756         * NEWS: Mention this bug fix.
757         * src/dir.c (compare_names_for_qsort): Fall back on file_name_cmp
758         if two distinct entries in the same directory compare equal.
759         (diff_dirs): Prefer a file_name_cmp match when available.
760         * tests/Makefile.am (TESTS): New test colliding-file-names.
761         * tests/colliding-file-names: New file.
762
763 2010-05-09  Jim Meyering  <meyering@redhat.com>
764
765         build: update gnulib submodule to latest
766
767         build: don't define macros that gnulib provides
768         * bootstrap.conf (gnulib_modules): Add signal, stdint.
769         * lib/cmpbuf.c (SA_RESTART, SA_INTERRUPT): Remove definitions.
770         (SIZE_MAX, PTRDIFF_MAX): Likewise.
771         Include <stdint.h>.
772         * src/system.h (WEXITSTATUS, WIFEXITED): Remove definitions.
773         (SA_RESTART, SA_INTERRUPT): Likewise.
774
775         build: rely on gnulib's sigprocmask module
776         * src/sdiff.c: Remove #if-!HAVE_SIGPROCMASK-guarded code.
777         * bootstrap.conf (gnulib_modules): Add sigprocmask.
778
779 2010-05-04  Jim Meyering  <meyering@redhat.com>
780
781         doc: README-release: don't mention To:, Cc:, etc announcement headers,
782         now that those are supplied automatically via gnulib's maint.mk.
783         * README-release: sync with coreutils.
784
785         maint: teach web-doc-generating code how to do its job
786         * cfg.mk (gendocs_options): Define, so that gendocs.sh knows
787         the name of our texinfo source file.
788         * gnulib: Update to latest, for new gnu-web-doc-update and maint.mk.
789
790 2010-05-03  Jim Meyering  <meyering@redhat.com>
791
792         doc: update release procedure
793         * README-release: Rearrange slightly: post the announcement to
794         Savannah first, so you can include a link to that post in the email.
795         Sync a few details from coreutils' README-release.
796
797         post-release administrivia
798         * NEWS: Add header line for next release.
799         * .prev-version: Record previous version.
800         * cfg.mk (old_NEWS_hash): Auto-update.
801
802         version 3.0
803         * NEWS: Record release date.
804
805         build: update gnulib submodule to latest
806
807 2010-04-30  Jim Meyering  <meyering@redhat.com>
808
809         build: use gnulib's sys_wait module
810         * bootstrap.conf (gnulib_modules): Use gnulib's sys_wait module,
811         now that we assume its presence.
812
813         build: update gnulib submodule to latest
814         * bootstrap: Also update from gnulib.
815         * tests/init.sh: Likewise
816
817         maint: remove now-useless #if HAVE_HEADER_H guards
818         * src/system.h: Include <sys/wait.h> unconditionally,
819         now that gnulib guarantees its presence.
820         * lib/cmpbuf.c: Likewise for <unistd.h> and <inttypes.h>.
821
822 2010-04-16  Jim Meyering  <meyering@redhat.com>
823
824         tests: use original no-newline-at-eof test, but with -U1, not -U2
825         * tests/no-newline-at-eof: Revert to the smaller test, but with
826         -U1 rather than -U2, since that actually triggers the bug.
827
828 2010-04-16  Paul Eggert  <eggert@cs.ucla.edu>
829
830         Followon improvements for the fix for Debian bug 577832.
831         * src/io.c (find_and_hash_each_line): Omit the inserted newline in
832         a simpler way.
833         * tests/no-newline-at-eof: Fix the test case so that it rejects
834         the old, buggy behavior.
835
836 2010-04-16  Jim Meyering  <meyering@redhat.com>
837
838         build: update gnulib submodule to latest
839
840         tests: test for the no-newline-at-EOF bug
841         * tests/no-newline-at-eof: New file.
842         * tests/Makefile.am (TESTS): Add it.
843
844 2010-04-16  Jim Meyering  <meyering@redhat.com>
845
846         diff: fix a regression when at least one input lacks a newline-at-EOF,
847         and the final hunk plus context-length aligns exactly with the end
848         of the newline-lacking file.  Diff would fail to output the required
849         "\ No newline at end of file" line, thus rendering the output invalid.
850         This bug appears to have been introduced by 2006-05-07
851         commit 58d0483b, "(find_identical_ends): Fix huge performance bug...",
852         at least to the extent that reverting that change fixes the bug.
853         Considering the stated effect of that change and lack of metrics,
854         reverting it is not an option, so here we take a more direct approach.
855
856         Given these inputs,
857
858             printf '\n1'>a; printf '\n0\n\n1'>b
859
860         and running diff like this:
861
862             ./diff -U1 a b
863
864         for input file "b", the pointer, files[1].linbuf[4][-1], to
865         the last byte on the final line was mistakenly pointing at the
866         sentinel newline at EOF, rather than at the preceding byte.
867
868           (gdb) p files[1].linbuf[4][-1]
869           $3 = 10 '\n'
870
871         Thus, this test in the final print_1_line call:
872
873           if ((!line_flag || line_flag[0]) && limit[-1] != '\n')
874             fprintf (out, "\n\\ %s\n", _("No newline at end of file"));
875
876         would fail, because limit[-1] (which is files[1].linbuf[4][-1])
877         was mistakenly '\n', rather than the desired '1'.
878
879         My first thought was simply to adjust the final linbuf[line] setting,
880         at the end of io.c's find_and_hash_each_line function function:
881
882                if (p == bufend)
883         -       break;
884         +       {
885         +         if (current->missing_newline)
886         +           --linbuf[line];
887         +         break;
888         +       }
889
890         But that would make diff misbehave with this input
891         (same as above, but with a newline appended to "a"),
892
893             printf '\n1\n'>a; printf '\n0\n\n1'>b
894             ./diff -U1 a b
895
896         due to the block (100 lines above) that is triggered in that case
897         (but not in the both-files-missing-newline case):
898
899               if (p == bufend
900                   && current->missing_newline
901                   && ROBUST_OUTPUT_STYLE (output_style))
902                 {
903                   /* This line is incomplete.  If this is significant,
904                      put the line into buckets[-1].  */
905                   if (ignore_white_space < IGNORE_SPACE_CHANGE)
906                     bucket = &buckets[-1];
907
908                   /* Omit the inserted newline when computing linbuf later.  */
909                   p--;
910                   bufend = suffix_begin = p;
911                 }
912
913         Note how "p" is decremented and "bufend" adjusted.
914         When that happens, we certainly don't want to decrement
915         "bufend" yet again.
916
917         Since there is no other way to determine at the end whether "bufend"
918         was already decremented, add a new variable to serve as witness.
919
920         * NEWS (Bug fixes): Mention it.
921         Reported by Timo Juhani Lindfors in http://bugs.debian.org/577832.
922         Forwarded by Santiago Vila.
923
924 2010-04-16  Jim Meyering  <meyering@redhat.com>
925
926         tests: update init.sh from gnulib
927         * tests/init.sh: Update from gnulib.
928
929 2010-04-08  Jim Meyering  <meyering@redhat.com>
930
931         build: include cfg.mk and dist-check.mk in the distribution tarball
932         * Makefile.am (EXTRA_DIST): Add cfg.mk and dist-check.mk.
933
934         maint: update to latest gnulib
935         * cfg.mk (sc_cross_check_PATH_usage_in_tests): Remove rule,
936         now that it's in gnulib's maint.mk.
937         * gnulib: Update to latest.
938
939 2010-04-07  Jim Meyering  <meyering@redhat.com>
940
941         tests: make new PATH-crosschecking syntax-check tighter
942         * cfg.mk (sc_cross_check_PATH_usage_in_tests): Use grep's -x (match
943         entire line) option with -F.
944
945         tests: pull latest help-version from gzip
946         * tests/help-version: Update from gzip.
947         * Makefile.am (TESTS_ENVIRONMENT): Export VERSION,
948         as required for this new help-version script.
949
950         tests: add syntax-check rule to verify that tests use proper PATH
951         * cfg.mk (sc_cross_check_PATH_usage_in_tests): New rule, that is
952         useful only in conjunction with the help-version script.
953
954         tests: use path_prepend_ consistently; remove unnecessary VERBOSE check
955         * tests/basic: Likewise.
956         * tests/binary: Likewise.
957         * tests/function-line-vs-leading-space: Likewise.
958         * tests/label-vs-func: Likewise.
959         * tests/stdin: Likewise.
960
961 2010-04-06  Eric Blake  <eblake@redhat.com>
962
963         maint: ignore generated files
964         * .gitignore: Ignore recent gnulib additions.
965
966         maint: update to latest bootstrap
967         * bootstrap: Copy from gnulib/build-aux.
968
969 2010-04-05  Jim Meyering  <meyering@redhat.com>
970
971         tests: get latest init.sh from gnulib
972         * tests/init.sh: Update from gnulib.
973
974         build: update gnulib submodule to latest; adapt
975         * cfg.mk (local-checks-to-skip): Add new sc_texinfo_acronym, to skip it.
976
977         diff -F/-p: don't depend on locale-specific white-space definition
978         * src/context.c: Include "c-ctype.h".
979         Use c_isspace, not isspace.
980
981 2010-03-18  Jim Meyering  <meyering@redhat.com>
982
983         tests: exercise new behavior of -F RE
984         * tests/function-line-vs-leading-space: New file.
985         * tests/Makefile.am (TESTS): Add it.
986
987 2010-03-18  Yannick Moy  <yannick.moy@adacore.com>
988
989         with -F or -p, emit better function lines: no leading white space
990         * src/diff.c (print_context_function): For languages like Ada
991         that allow local functions and procedures, the plain context
992         function line may start with enough blank characters that the
993         function name does not get completely printed in the 40
994         characters limit.  This patch solves this problem by removing
995         these useless initial blank characters.
996         * NEWS (Changes in behavior): Mention this change.
997
998 2010-03-17  Jim Meyering  <meyering@redhat.com>
999
1000         build: don't require a specific version of help2man
1001         * bootstrap.conf (buildreq): Bootstrap can't deal with it,
1002         perhaps because the command name contains a digit.
1003
1004         build: make bootstrap ensure that help2man is available
1005         * bootstrap.conf (buildreq): Add help2man.
1006
1007 2010-02-23  Jim Meyering  <meyering@redhat.com>
1008
1009         tests: test for the "Binary files A and B differ" diagnostic
1010         * tests/binary: New script.
1011         * tests/Makefile.am (TESTS): Add it.
1012
1013         revert 2002 change that removed "Binary " from "files A and B differ"
1014         With this change, "printf '\0'|diff - /dev/null" now prints
1015         "Binary files - and /dev/null differ" once again.
1016         This reverts 2002-06-28 commit a352f0980,
1017         "(briefly_report): Don't say "Binary files differ", ...".
1018         * src/analyze.c (briefly_report): Do include the "Binary " prefix
1019         in the diagnostic, when !brief.
1020         * NEWS (Changes in behavior): Mention the diagnostic change.
1021         Reported by Andreas Hoenen in http://bugs.debian.org/570064.
1022
1023 2010-02-14  Juan Manuel Guerrero  <juan.guerrero@gmx.de>
1024
1025         avoid compilation failure on systems lacking both fork and vfork
1026         * src/sdiff.c [!HAVE_WORKING_FORK && !HAVE_WORKING_VFORK] (main):
1027         Pass the right number of arguments to shell_quote_copy.
1028         * src/util.c [!HAVE_WORKING_FORK && !HAVE_WORKING_VFORK] (begin_output):
1029         Likewise.
1030
1031 2010-02-11  Jim Meyering  <meyering@redhat.com>
1032
1033         post-release administrivia
1034         * NEWS: Add header line for next release.
1035         * .prev-version: Record previous version.
1036         * cfg.mk (old_NEWS_hash): Auto-update.
1037
1038         version 2.9
1039         * NEWS: Record release date.
1040
1041         doc: document the release procedure
1042         * README-release: New file.
1043
1044 2010-02-10  Jim Meyering  <meyering@redhat.com>
1045
1046         maint: change use of "|" to more maintainable "||" (no semantic change)
1047         * src/analyze.c (diff_2_files): Using the "||" operator happens to
1048         be equivalent to using "|" in this case.  It is also clearer and
1049         less prone to inadvertent bug introduction, in case the variable,
1050         "changes" were ever to take on a value not in {0,1}.
1051         Patch by Tim Waugh, via Mike Frysinger.
1052
1053         portability: avoid "diff - ..." failure at least on *BSD and Solaris
1054         The new "stdin" test was failing on many types of systems.
1055         * src/diff.c (compare_files): Guard use of xfreopen (NULL, "rb", ...
1056         also with O_BINARY, so as to avoid this unnecessary call on
1057         systems where it's not needed (on some it fails with "Bad address".
1058
1059 2010-02-09  Jim Meyering  <meyering@redhat.com>
1060
1061         tests: honor VERBOSE
1062         * tests/basic: Enable "set -x" if $VERBOSE.
1063         * tests/help-version: Likewise.
1064         * tests/label-vs-func: Likewise.
1065         * tests/stdin: Likewise.
1066
1067 2010-02-04  Jim Meyering  <meyering@redhat.com>
1068
1069         build: update gnulib submodule to latest
1070
1071         sync with gnulib
1072         * gl/lib/regcomp.c.diff: Adjust to apply to the latest in gnulib.
1073         * gnulib: Update submodule to latest.
1074
1075 2010-02-04  Jim Meyering  <meyering@redhat.com>
1076
1077         build: do not override gnulib-provided AM_CFLAGS options
1078         Avoid a warning from automake:
1079         lib/Makefile.am:23: AM_CFLAGS multiply defined in condition TRUE ...
1080         lib/gnulib.mk:30: ... `AM_CFLAGS' previously defined here
1081         lib/Makefile.am:18:   `lib/gnulib.mk' included from here
1082
1083         * lib/Makefile.am (AM_CFLAGS): Append $(WARN_CFLAGS) and
1084         $(WERROR_CFLAGS), i.e., use "+=", not "=".
1085         This was introduced via 2009-12-17 commit e58efa5b
1086         "build: enable warnings and -Werror.",
1087         but fortunately is not a bug, because the definition
1088         it would have overridden was always empty.
1089
1090 2010-01-17  Jim Meyering  <meyering@redhat.com>
1091
1092         maint: add to .gitignore
1093         * .gitignore: Ignore more.
1094
1095 2010-01-15  Jim Meyering  <meyering@redhat.com>
1096
1097         doc: add to TODO
1098         * TODO: Add an item, suggested by Dan Jacobson.
1099
1100 2010-01-13  Jim Meyering  <meyering@redhat.com>
1101
1102         tests: ensure that an argument of "-" is treated as standard input
1103         * tests/stdin: New test.
1104         * tests/Makefile.am (TESTS): Add it.
1105
1106 2010-01-10  Jim Meyering  <meyering@redhat.com>
1107
1108         tests: now "make distcheck" runs more tests, incl. syntax-check
1109         * cfg.mk: Include dist-check.mk, from coreutils.
1110         * Makefile.am (distcheck-hook): Define rule, to hook to...
1111         * dist-check.mk: New file.
1112
1113 2010-01-09  Jim Meyering  <meyering@redhat.com>
1114
1115         build: update gnulib to latest, for fixed syntax-check rule
1116
1117         maint: record updated NEWS hash
1118         * cfg.mk (old_NEWS_hash): Update to account for GFDL change.
1119
1120         build: update gnulib submodule to latest
1121
1122         tests: add a test of basic functionality
1123         * tests/basic: Start adding tests.
1124         * tests/Makefile.am (TESTS): Add it.
1125
1126         maint: udpate GFDL license to 1.3
1127         * doc/diff.texi: Update to use GFDL version 1.3.
1128
1129 2010-01-04  Eric Blake  <ebb9@byu.net>
1130
1131         build: allow compilation on cygwin
1132         * src/Makefile.am (cmp_LDADD): Move LIBICONV...
1133         (LDADD): ...into global flags, since all programs need it.
1134
1135 2010-01-03  Jim Meyering  <meyering@redhat.com>
1136
1137         maint: record update-copyright options for this package
1138         * cfg.mk: Next time, just run "make update-copyright".
1139
1140         tests: prepend ../src, not "." to PATH
1141         * tests/help-version: Correct PATH.
1142
1143 2010-01-01  Jim Meyering  <meyering@redhat.com>
1144
1145         maint: update all FSF copyright year lists to include 2010
1146         Use this command:
1147         git ls-files |grep -vE '^(\..*|COPYING|gnulib)$' |xargs \
1148         env UPDATE_COPYRIGHT_USE_INTERVALS=1 build-aux/update-copyright
1149
1150 2009-12-31  Jim Meyering  <meyering@redhat.com>
1151
1152         maint: newer gnulib; don't hard-code my GPG key ID
1153         * cfg.mk (gpg_key_ID): Remove definition, now that maint.mk automates it.
1154         * gnulib: Update to latest.
1155
1156         tests: exercise diff -p's function-name matching
1157         * tests/label-vs-func: New file.
1158         * tests/Makefile.am (TESTS): Add label-vs-func.
1159         Reported by Simon Arlott <simon@fire.lp0.eu>
1160         http://article.gmane.org/gmane.linux.kernel.janitors/14260
1161
1162         tests: use gnulib's init.sh
1163         * tests/Makefile.am (EXTRA_DIST): Add init.sh.
1164         Remove test-lib.sh.
1165         * tests/init.sh: New file.
1166         * tests/test-lib.sh: Remove file.
1167         * tests/help-version: Use init.sh, not test-lib.sh.
1168
1169 2009-11-28  Jim Meyering  <meyering@redhat.com>
1170
1171         maint: don't let trailing spaces in diffs perturb make syntax-check
1172         * .x-sc_space_tab: New file.
1173
1174 2009-11-22  Jim Meyering  <meyering@redhat.com>
1175
1176         build: enable warnings and -Werror.
1177         * src/Makefile.am (AM_CFLAGS): Enable warnings and -Werror.
1178         Set to this: $(WARN_CFLAGS) $(WERROR_CFLAGS)
1179         * lib/Makefile.am (AM_CFLAGS): Similarly, but use this:
1180         $(GNULIB_WARN_CFLAGS) $(WERROR_CFLAGS)
1181         * configure.ac (GNULIB_WARN_CFLAGS): Don't turn off -Wuninitialized.
1182
1183         build: avoid a warning from gnulib's sh-quote.c
1184         * gl/lib/sh-quote.c.diff: New file, to avoid a warning.
1185
1186         maint: avoid warnings via patched versions of gnulib's regex functions
1187         * gl/lib/regcomp.c.diff: New file.
1188         * gl/lib/regex_internal.c.diff: Likewise.
1189         * gl/lib/regex_internal.h.diff: Likewise.
1190         * gl/lib/regexec.c.diff: Likewise.
1191
1192         build: update gnulib submodule to latest
1193
1194 2009-11-20  Eric Blake  <ebb9@byu.net>
1195
1196         build: ignore more files
1197         * .gitignore: Add config.cache, *.exe.
1198
1199 2009-11-20  Eric Blake  <ebb9@byu.net>
1200
1201         build: fix test run on cygwin
1202         This, plus a gnulib update for xalloc-die-tests, are necessary
1203         for make check to pass on cygwin.
1204
1205         * tests/Makefile.am (built_programs): Ignore $(EXEEXT).
1206         * src/Makefile.am (paths.h): Add missing dependency.
1207
1208 2009-11-20  Jim Meyering  <meyering@redhat.com>
1209
1210         maint: remove vestiges of nanosleep
1211         * src/Makefile.am (LDADD): Remove $(LIB_NANOSLEEP), now
1212         that we no longer use the nanosleep module.
1213         Spotted by Eric Blake.
1214
1215         maint: don't pull in gnulib's nanosleep unnecessarily
1216         * bootstrap.conf (gnulib_modules): Remove nanosleep.  Not needed.
1217         Spotted by Eric Blake.
1218
1219         maint: cfg.mk: remove factored-out ftp host/dir definitions
1220         * cfg.mk (gnu_ftp_host-alpha, gnu_ftp_host-beta gnu_ftp_host-stable):
1221         (gnu_rel_host, url_dir_list): Remove definitions.  The defaults,
1222         now provided by maint.mk, are the same.
1223         * gnulib: Update for latest, including those maint.mk additions.
1224
1225         build: link with now-required libraries
1226         * src/Makefile.am (LDADD): Add gnulib-required libraries.
1227         (cmp_LDADD): Add $(LIBICONV), for cmp's use of proper_name_utf8.
1228
1229         maint: lib/xfreopen.c contains translatable strings
1230         * po/POTFILES.in: Add lib/xfreopen.c.
1231
1232         maint: remove hard-coded macro definitions provided by intprops.h
1233         * lib/cmpbuf.c: Include "intprops.h" rather than open-coding macros
1234         like TYPE_SIGNED and TYPE_MINIMUM.
1235
1236         maint: add gnulib's announce-gen module
1237         * bootstrap.conf (gnulib_modules): Add announce-gen
1238
1239         build: suppress warnings about bindtextdomain and textdomain
1240         * src/system.h (bindtextdomain, textdomain) [!ENABLE_NLS]: Define away.
1241
1242         build: use more gnulib modules
1243         * bootstrap.conf (gnulib_modules): Add mktime, nanosleep, strptime
1244         and timegm.
1245
1246         use xfreopen rather than freopen
1247         * src/cmp.c: Include "xfreopen.h".
1248         Use xfreopen in place of freopen.
1249         * src/diff.c Likewise, and...
1250         (main): Set exit_failure to EXIT_TROUBLE, rather than to 2.
1251         * src/diff3.c: Likewise.
1252         * bootstrap.conf (gnulib_modules): Add xfreopen.
1253
1254         build: enable many warnings
1255         * configure.ac: Add support for --enable-gcc-warnings.
1256         * bootstrap.conf (gnulib_modules): Add manywarnings.
1257         * Makefile.am (AM_CFLAGS): Add $(WARN_CFLAGS) $(WERROR_CFLAGS)
1258
1259         build: update gnulib submodule to latest
1260
1261         maint: add an assertion to suppress clang-detected warning
1262         The clang static analyzer reported that a NULL parent could be
1263         dereferenced.  However, that cannot happen, because for all callers,
1264         the parameter, parent, is always non-NULL at that point.
1265         * src/diff.c: Include <assert.h>.
1266         Assert that parent is not NULL.
1267
1268         maint: remove dead assignment from diff3.c
1269         * src/diff3.c (make_3way_diff): Remove dead assignment.
1270
1271 2009-11-17  Jim Meyering  <meyering@redhat.com>
1272
1273         build: update gnulib submodule to latest
1274
1275         maint: hide build commands behind $(AM_V_GEN)
1276         * src/Makefile.am (paths.h): Use $(AM_V_GEN), and split a long line.
1277         * man/Makefile.am ($(dist_man1_MANS)): Use $(AM_V_GEN) here, too.
1278
1279 2009-11-16  Jim Meyering  <meyering@redhat.com>
1280
1281         build: let automake generate better man-installation rules
1282         * man/Makefile.am (dist_man1_MANS): Rename from dist_man_MANS,
1283         to enable better automake-generated installation rules.
1284
1285         admin: ignore all of gnulib-tests
1286         * .gitignore: Add gnulib-tests
1287
1288 2009-11-16  Eric Blake  <ebb9@byu.net>
1289
1290         build: avoid link failure when libsigsegv is used
1291         * src/Makefile.am (LDADD): Link against LIBSIGSEGV.
1292
1293 2009-11-16  Jim Meyering  <meyering@redhat.com>
1294
1295         maint: define/use PROGRAM_NAME and AUTHORS; use propername module
1296         * bootstrap.conf (gnulib_modules): Add propername.
1297         * src/cmp.c (PROGRAM_NAME, AUTHORS): Define.
1298         (main): Use them in use of version_etc.
1299         * src/diff.c (PROGRAM_NAME, AUTHORS, main): Likewise.
1300         * src/diff3.c (PROGRAM_NAME, AUTHORS, main): Likewise.
1301         * src/sdiff.c (PROGRAM_NAME, AUTHORS, main): Likewise.
1302         * src/system.h: Include "propername.h".
1303
1304         maint: no longer define *_FILENO constants
1305         * src/system.h (STDIN_FILENO, STDOUT_FILENO, STDERR_FILENO):
1306         Remove definitions.  Now guaranteed by gnulib.
1307
1308         maint: bug-diffutils@gnu.org is the new bug-reporting address
1309         * configure.ac (AC_INIT): Use bug-diffutils@..., not bug-gnu-utils
1310         as the bug-reporting address.
1311         * NEWS (Administrivia): Mention this.
1312         * src/cmp.c (usage): Remove hard-coded address.
1313         Instead, use gnulib's emit_bug_reporting_address function.
1314         * src/diff.c (usage, option_help_msgid): Likewise.
1315         * src/diff3.c (usage): Likewise.
1316         * src/sdiff.c (usage): Likewise.
1317
1318         sdiff, diff3: exec diff, not $(bindir)/diff
1319         * src/Makefile.am (paths.h): Emit a definition of DEFAULT_DIFF_PROGRAM
1320         that is simply "diff" (or whatever $(transform) would convert that to,
1321         e.g., "gdiff").  This makes it so that tests can work without first
1322         installing diff, and so that the binaries do not hard-code $(prefix).
1323         * NEWS (Changes in behavior): Mention this.
1324
1325 2009-11-14  Jim Meyering  <meyering@redhat.com>
1326
1327         tests: add the first script; hook up gnulib-tests
1328         * configure.ac (AC_CONFIG_FILES): Add tests/Makefile and
1329         gnulib-tests/Makefile.
1330         * tests/help-version: New file, from coreutils.
1331         * tests/test-lib.sh: Likewise.
1332         * tests/Makefile.am: New file, from gzip.
1333         * Makefile.am (SUBDIRS): Add tests and gnulib-tests.
1334         * tests/t-local.sh: New, empty(for now) file.
1335
1336 2009-11-13  Jim Meyering  <meyering@redhat.com>
1337
1338         build: require gettext-0.17
1339         * configure.ac: Require gettext-0.17; it was released two years ago.
1340
1341         build: correct gettext configure-time support
1342         * configure.ac: Use AM_GNU_GETTEXT([external], [need-ngettext]),
1343         rather than AM_GNU_GETTEXT([external], [need-formatstring-macros]).
1344         Reported by Martin Jacobs in
1345         http://thread.gmane.org/gmane.comp.parsers.bison.bugs/3181
1346
1347 2009-11-12  Jim Meyering  <meyering@redhat.com>
1348
1349         build: generalize autoheader check
1350         * bootstrap: Look for AC_CONFIG_HEADER as well as AC_CONFIG_HEADERS.
1351
1352 2009-11-11  Jim Meyering  <meyering@redhat.com>
1353
1354         maint: use a git submodule for gnulib
1355         * .gitmodules: New file, to track gnulib.
1356         * gnulib: New file, created by running this:
1357         git submodule add git://git.sv.gnu.org/gnulib.git gnulib
1358
1359         maint: tell git what it can ignore
1360         * .gitignore: Ignore generated files.