882 Commits

Author SHA1 Message Date
Jim Meyering
78524ae4ba version 3.1
* NEWS: Record release date.
v3.1
2011-08-10 12:33:36 +02:00
Jim Meyering
3edb801c06 build: use largefile module and update to latest gnulib
* configure.ac: Remove AC_SYS_LARGEFILE, subsumed by ...
* bootstrap.conf (gnulib_modules): ...this.  Use largefile module.
* gnulib: Update to latest.
2011-08-10 10:21:14 +02:00
Santiago Vila
8832cf045d doc: insert comma in --help line for --ignore-space-change (-b)
* src/diff.c (option_help_msgid): Insert omitted comma between
"-b" and "--ignore-space-change".  (tiny change)
2011-08-08 18:00:23 +02:00
Jim Meyering
789252980f doc: relax restriction on front-cover and back-cover texts
* doc/diffutils.texi (copying): Relax restriction on front-cover
and back-cover texts (just as m4 did here:
http://git.savannah.gnu.org/cgit/m4.git/commit?id=ee1e92ec).
Reported by Santiago Vila.  Fix suggested by Eric Blake.
2011-08-04 18:59:29 +02:00
Jim Meyering
c06794dacf tests: update init.sh from gnulib
* tests/init.sh: Update from gnulib.
2011-08-03 18:07:33 +02:00
Jim Meyering
1ce0b3604b build: update gnulib submodule to latest 2011-08-03 14:22:24 +02:00
Jim Meyering
01fc077bbf maint: remove inclusion of unused header, for "make syntax-check"
* src/diff3.c: Don't include <inttostr.h>.  Not used.
* src/context.c: Likewise.
2011-07-03 22:44:26 +02:00
Jim Meyering
c8b5b09d13 build: don't require perl when building from a tarball
But do ensure -- in all other circumstances -- that the man/*.1
files are rebuilt whenever the version number changes.
* configure.ac (SRC_VERSION_C): Define.
* man/Makefile.am (dist_man1_MANS): Rename from $(man1_MANS),
so that we distribute those pesky man/*.1 files.
(EXTRA_DIST): Reflect name change.
(MAINTAINERCLEANFILES): Define this, not DISTCLEANFILES,
now that these generated files are distributed.
($(dist_man1_MANS)): Depend on $(SRC_VERSION_C), so we get the
full dependency when not building from a tarball.
2011-06-19 17:15:26 +02:00
Jim Meyering
e783a23b19 doc: do not distribute generated man/*.1 man files
* man/help2man: New file.
* man/Makefile.am: Use $(srcdir)/help2man.
Convert $(dist_man1_MANS) to $(man1_MANS), to tell automake
not to distribute the generated man/*.1 files.  Now they're
generated at build-from-tarball time.
($(man1_MANS)): Depend on version.c, so that man pages are
regenerated whenever the version string changes.
2011-06-13 09:17:49 +02:00
Jim Meyering
7faccb437c build: ccache works better without embedded version strings
* src/Makefile.am: Generate version.c and version.h and put the
new symbol in a tiny library to be used by each program.
(LDADD): Add the new library.
* src/cmp.c (main): Use Version, not PACKAGE_VERSION, so the .o
file does not change with each commit-derived version increment.
* src/diff.c (main): Likewise.
* src/diff3.c (main): Likewise.
* src/sdiff.c (main): Likewise.
* src/system.h: Include "version.h".
* .gitignore: Add version.[ch]
2011-06-13 09:17:15 +02:00
Jim Meyering
929cf56472 doc: ensure each program has a man/*.x file: add "SEE ALSO" references
* man/cmp.x: New file.
* man/diff3.x: New file.
* man/sdiff.x: New file.
* man/diff.x: Add xrefs to the other three programs, and to patch.
* man/Makefile.am (EXTRA_DIST): List new files.
(cmp.1, diff3.1, sdiff.1): Depend on each .x file.
2011-06-12 10:25:15 +02:00
Jim Meyering
df0a31f611 doc: rename diff.texi to diffutils.texi
This makes the .texi basename the same as the package name,
which is consistent with most other GNU packages.
* doc/diffutils.texi: Rename from...
* doc/diff.texi: ...removed.
* doc/Makefile.am (info_TEXINFOS): Reflect name change.
(diffutils_TEXINFOS): Likewise.
* cfg.mk (gendocs_options_): Remove this customization.  It is no
longer needed, now that the .texi name matches that of the package.
* man/Makefile.am ($(dist_man1_MANS)): Remove now-unnecessary sed
filter.
* README: Update references to diffutils.texi etc. here, too.
* .gitignore: Update here, too.
Suggested by Karl Berry.
2011-06-12 09:47:27 +02:00
Karl Berry
a2b10ab0d6 cmp, diff, diff3, sdiff: edit and align --help text.
* cmp.c (option_help_msgid, usage),
* diff.c (option_help_msgid, usage),
* diff3.c (option_help_msgid, usage),
* sdiff.c (option_help_msgid, usage): align descriptions in the --help
output and slightly edit content.
2011-06-08 15:44:52 +02:00
Paul Eggert
de65c25dc1 diff: don't use locales after local-specific sorting fails
* src/dir.c (compare_names): Don't invoke strcasecmp if
locale-specific sorting fails, because POSIX.1-2008 says strcasecmp
has unspecified behavior outside the POSIX locale.  See:
http://lists.gnu.org/archive/html/bug-diffutils/2011-05/msg00008.html
2011-05-27 23:41:07 -07:00
Paul Eggert
a3318fdbca bootstrap: Avoid multithreading.
* bootstrap.conf (gnulib_tool_option_extras):
Add "--avoid=localename --avoid=lock", because we don't want to
bring in the multithreading code that recent gnulib changes would
otherwise bring in.
(excluded_files): Remove m4/lock.m4; no longer needed, now that
we use --avoid=lock.
2011-05-27 23:41:07 -07:00
Paul Eggert
1850ea03ac build: update gnulib submodule to latest 2011-05-27 23:41:07 -07:00
Karl Berry
0b7299f98e maint: update README-hacking
* README-hacking: Update a la coreutils for git, etc.
2011-05-23 19:23:48 +02:00
Jim Meyering
91d850a78b maint: update gnulib to latest with accompanying tight-scope tweaks
* cfg.mk: Include $(srcdir)/dist-check.mk using "-include",
to accommodate the new sc_tight_scope rule.
(_gl_TS_extern): Define, to tell gnulib's tight_scope rule that
headers here mark externs with "XTERN".
* gnulib: Update to latest.
2011-05-23 19:20:09 +02:00
Jim Meyering
39213a3bbc maint: use gnulib's new readme-release module
* bootstrap.conf (gnulib_modules): Add readme-release.
(bootstrap_epilogue): Add the recommended perl one-liner.
* README-release: Remove file; it is now generated from gnulib.
* .gitignore: Add it.
2011-05-18 20:31:42 +02:00
Jim Meyering
167d1e3125 build: update gnulib submodule to latest 2011-05-18 20:31:42 +02:00
Jim Meyering
a531a3cff2 maint: prepare for the tight-scope check
* src/diff.h: Mark function declarations with "extern" in
preparation for the tight-scope check.
(ignore_white_space): Separate enum decl from declaration
of this variable.
* src/Makefile.am (diff_SOURCES): Move diff.h from here to ...
(noinst_HEADERS): ...here.
For convenience, since the tight-scope rule uses $(noinst_HEADERS).
2011-05-18 20:30:38 +02:00
Jim Meyering
0744f3339d maint: don't use now-removed gnulib "exit" module
* bootstrap.conf (gnulib_modules): Remove "exit" module.
It no longer exists.
2011-05-18 20:30:38 +02:00
Jim Meyering
7d638238a2 build: update gnulib submodule to latest 2011-03-26 13:45:52 +01:00
Jim Meyering
8a22305698 * .x-sc_space_tab: Remove file. Instead, ...
* cfg.mk (exclude_file_name_regexp--sc_space_tab): ...define this.
2011-03-26 13:44:13 +01:00
Jim Meyering
d9d3cf9f09 maint: fix typo in unused rule
* cfg.mk (config-save): Fix typo: add leading "_" in variable name.
2011-03-26 13:43:53 +01:00
Jim Meyering
23d970ea5f doc: add a reference to wdiff(1) from diff.1
* man/diff.x: New file, to add "SEE ALSO" reference to wdiff(1).
* man/Makefile.am (diff.1): Depend on diff.x.
($(dist_man1_MANS)): Tell help2man to include diff.x.
(EXTRA_DIST): Add diff.x.
Suggestion from Dan Jacobson in http://bugs.debian.org/613319
2011-03-18 22:44:32 +01:00
Eric Blake
ffd622a281 docs: info should mention -L
* doc/diff.texi (diff Options): Document -L.
2011-03-18 15:28:44 -06:00
Eric Blake
c549fc6c77 docs: diff --help should mention -L
* src/diff.c (option_help_msgid): Document -L.
2011-03-18 15:22:05 -06:00
Jim Meyering
3f2d868741 doc: speak of the --test (-a) option, not "the -a or --test option"
Convert using this command:
perl -pi -e \
  's/(\@option{-.}) or (\@option{--.*?}) option/$2 ($1) option/' \
  doc/diff.texi
Then convert some more with this:
perl -pi -e \
    's/the (\@option{-.}) or (\@option{--.*?})$/the $2 ($1)/' \
  doc/diff.texi
Then convert more manually.

Suggested by Dan Jacobson
2011-02-15 10:21:34 +01:00
Jim Meyering
91da1da696 maint: remove all uses of vfork: use fork instead
Our use of vfork now provokes warnings from gcc-4.6.0.
Also, vfork is no longer even specified by POSIX.1-2008.
* src/diff3.c (read_diff): Change each use of vfork to "fork".
Remove #ifdef'd code.
* src/util.c (begin_output, finish_output): Likewise.
* src/sdiff.c (cleanup, main, edit): Likewise.
(handler_index_of_SIGPIPE): Remove now-unused definition.
* src/system.h: Don't include <vfork.h>.
(vfork): Remove definition.
* ms/config.site: Remove reference to vfork cache variable.
2011-01-24 16:49:37 +01:00
Jim Meyering
4e0d3664c7 tests: avoid newer but less-portable tail option syntax
* tests/function-line-vs-leading-space: Use sed -n '3,$p' rather than
tail -n+3.  Older versions of tail do not accept that newer syntax.
Reported by Sudhakara Peram.
2011-01-24 16:34:32 +01:00
Jim Meyering
bf4003c13d tests: fix an erroneous test
On most systems, like-named files were compared, by luck.
However, on others, different-named files would be compared
since their names were being treated as equal -- but they had
different content, so the test would fail.
* tests/colliding-file-names: Use different sets of file names
in d1 and d2 so that they cannot accidentally match.
Put the same line in each test file.  This is required
when files named e.g., abc and ABC are compared.
This test was failing on a NixOS 86_64-darwin system.
2011-01-24 13:36:17 +01:00
Jim Meyering
7e27c1ae46 build: update gnulib submodule to latest 2011-01-24 12:36:12 +01:00
Jim Meyering
13b0958f25 tests: fix typo that silently disabled all tests
* tests/Makefile.am (TESTS): Fix typo: s/jESTS/TESTS/
2011-01-24 12:13:16 +01:00
Jim Meyering
c16c317684 build: update gnulib submodule to latest 2011-01-23 21:39:18 +01:00
Jim Meyering
9de94f53b5 maint: avoid new syntax-check failure
* src/diff.c (specify_value): Use !STREQ(...), not strcmp(...) != 0.
* src/diff3.c (main): Likewise.
2011-01-23 18:57:50 +01:00
Jim Meyering
ce5367b6b3 maint: update copyright year ranges to include 2011
Run "make update-copyright", so "make syntax-check" works in 2011.
2011-01-03 22:13:35 +01:00
Jim Meyering
7f0be31391 build: update gnulib submodule to latest 2011-01-03 22:04:45 +01:00
Paul Eggert
6fc3b9737d bootstrap: adjust to recent gnulib changes
* bootstrap.conf (excluded_files): Do not exclude m4/size_max.m4
and m4/xsize.m4 when using an external gettext, since they are
now needed by other gnulib modules.
2010-12-16 10:05:44 -08:00
Jim Meyering
5c65882aff doc: add contributor guidelines: HACKING
* HACKING: New file, copied 99% from the one in grep's repository.
2010-12-16 15:20:53 +01:00
Jim Meyering
9026760882 maint: describe policy on copyright year number ranges
* README: Mention coreutils' long-standing policy on use of M-N
ranges in copyright year lists.  Requested by Richard Stallman.
2010-10-09 15:24:05 +02:00
Jim Meyering
361b3b13da maint: adjust init.sh use to conform
* tests/help-version: Use one line: "${srcdir=.}/init.sh"; ...
* tests/basic: Likewise.
* tests/binary: Likewise.
* tests/colliding-file-names: Likewise.
* tests/excess-slash: Likewise.
* tests/function-line-vs-leading-space: Likewise.
* tests/help-version: Likewise.
* tests/label-vs-func: Likewise.
* tests/no-newline-at-eof: Likewise.
* tests/stdin: Likewise.
2010-09-04 09:15:32 +02:00
Jim Meyering
d5d4b828b4 maint: avoid shadowing warning
* src/dir.c (diff_dirs): Rename shadowed local cmp to "c".
2010-09-04 09:04:43 +02:00
Jim Meyering
edf0032df4 build: use gettext-h, not gettext
* bootstrap.conf (gnulib_modules): Use gettext-h, not gettext.
The latter is overkill for a package that uses
AM_GNU_GETTEXT([external]...
2010-09-04 08:55:48 +02:00
Jim Meyering
0d0c959471 build: update build/test tools from gnulib
* bootstrap: Update from gnulib.
* tests/init.sh: Likewise.
2010-09-04 08:54:18 +02:00
Jim Meyering
0ffe188b2b build: update gnulib submodule to latest 2010-09-04 08:53:28 +02:00
Jim Meyering
53de393ca3 diff -r: avoid printing excess slashes in concatenated file names
* bootstrap.conf (gnulib_modules): Add filenamecat.
* src/diff.c: Include "filenamecat.h".
(compare_files): Use file_name_concat, rather than dir_file_pathname.
* src/util.c (dir_file_pathname): Remove now-unused function.
* src/diff.h: Remove its declaration.
* tests/excess-slash: New script to test for this.
* tests/Makefile.am (TESTS): Add it.
Forwarded by Santiago Vila from <bugs.debian.org/586301a>,
reported by Jari Aalto.
2010-08-14 17:15:57 -05:00
Paul Eggert
f2ad578b24 diff: avoid spurious diffs when two distinct dir entries compare equal
Problem reported by Christoph Anton Mitterer in:
http://lists.gnu.org/archive/html/bug-diffutils/2010-08/msg00000.html

* NEWS: Mention this bug fix.
* src/dir.c (compare_names_for_qsort): Fall back on file_name_cmp
if two distinct entries in the same directory compare equal.
(diff_dirs): Prefer a file_name_cmp match when available.
* tests/Makefile.am (TESTS): New test colliding-file-names.
* tests/colliding-file-names: New file.
2010-08-12 17:55:38 -07:00
Jim Meyering
a0e9e5e67a build: update gnulib submodule to latest 2010-05-09 19:09:26 +02:00
Jim Meyering
bec2cfcd8f build: don't define macros that gnulib provides
* bootstrap.conf (gnulib_modules): Add signal, stdint.
* lib/cmpbuf.c (SA_RESTART, SA_INTERRUPT): Remove definitions.
(SIZE_MAX, PTRDIFF_MAX): Likewise.
Include <stdint.h>.
* src/system.h (WEXITSTATUS, WIFEXITED): Remove definitions.
(SA_RESTART, SA_INTERRUPT): Likewise.
2010-05-09 18:39:39 +02:00