Commit Graph

327 Commits

Author SHA1 Message Date
Jim Meyering
2232b4d08f maint: update all Copyright year lists to include 2009 2009-06-23 22:33:15 +02:00
Pádraig Brady
a5a2a406f8 stdbuf: A new program to run a command with modified stdio buffering
* AUTHORS: Register as the author.
* NEWS: Mention this change.
* README: Add stdbuf command to list.
* configure.ac: Only enable on ELF systems with GCC.
* cfg.mk (sc_system_h_headers): Use VC_LIST_EXCEPT rather than
VC_LIST, so we can add an exception, if needed.
* .x-sc_system_h_headers: New file.  Exempt libstdbuf.c.
* Makefile.am (syntax_check_exceptions): Add .x-sc_system_h_headers.
* doc/coreutils.texi (stdbuf invocation): Add stdbuf info.
* man/.gitignore: Ignore generated manpage.
* src/.gitignore: Ignore stdbuf and libstdbuf.so binaries.
* man/Makefile.am (stdbuf.1): Add dependency.
* man/stdbuf.x: New file with example usage.
* po/POTFILES.in: Reference new command and shared library sources.
* src/Makefile.am (build_if_possible__progs): Add stdbuf and libstdbuf,
(pkglib_PROGRAMS): Reference optional shared lib,
(libstdbuf_so_LDADD): Ensure we don't link with non PIC libcoreutils.a.
(libstdbuf_so_LDFLAGS): Add -shared GCC option,
(libstdbuf_so_CFLAGS): Add -fPIC GCC option.
(check-README): Exclude libstbuf.
(check-AUTHORS): ditto.
(sc_tight_scope): Exclude functions starting with __.
* src/libstdbuf.c: The LD_PRELOAD shared library to control buffering.
* src/stdbuf.c: New file to setup env variables before execing command.
* tests/Makefile.am: Reference new test file.
* tests/misc/help-version: Set expected exit codes.
* tests/misc/invalid-opt: ditto.
* tests/misc/stdbuf: Add 9 tests.
2009-06-17 14:54:29 +01:00
Jim Meyering
0818c52874 build: make generated man/*.1 files read-only
This should help people notice that they are generated.
Note: each file already has a comment to that effect from help2man.
* man/Makefile.am (.x.1): Make generated files read-only.
Also, don't redirect directly to the target, $@.
2009-06-02 16:35:14 +02:00
Jim Meyering
a5c627f9c6 build (man/): use automake's new $(AM_V_GEN) variable
* man/Makefile.am (.x.1, check-x-vs-1, check-programs-vs-x):
Mark with $(AM_V_GEN), so that automake-1.11 prints
"GEN $@" by default (stick with "GEN" in spite of the latter two
rules not officially generating anything -- they're just tests).
2009-06-02 16:35:14 +02:00
Pádraig Brady
39285f6008 doc: clarify the operation of the comm -123 parameters
* src/comm.c (usage): give more information on the -123 parameters,
with examples to show that they can be combined.
Addresses <http://savannah.gnu.org/bugs/?24974>.
* doc/coreutils.texi (comm invocation): Mention that the
column separators are suppressed along with the column.
Suggestion from Dan Jacobson.
* man/comm.x: Reference other commands that match adjacent lines.
* man/join.x: ditto.
* man/uniq.x: ditto.
2009-05-18 16:17:31 +01:00
Jim Meyering
e6d2d94794 maint: normalize leading-TAB indentation in Makefiles
* maint.mk (sc_makefile_TAB_only_indentation): New rule.
Replace each TAB+8-space sequence with two TABs.
* man/Makefile.am: Likewise.
* build-aux/check.mk: Likewise.
I used this command (run it more than once, if needed):
t=$'\t'; git grep -l -E "$t {8}"|grep -E 'Makefile|\.mk$' \
| xargs perl -pi -e 's/\t {8}/\t\t/'
2009-03-18 12:40:07 +01:00
Tobias Stoeckmann
3a8d16800c truncate: fix typo in man page
* man/truncate.x: Fix spelling.
* THANKS: Update.
2009-02-22 10:16:15 -07:00
Jim Meyering
1eaacac312 doc: id: make --help and .man more descriptive
* src/id.c (usage): Improve description, based on a suggestion
from Brian M. Carlson in http://bugs.debian.org/514675
* man/id.x: Use a better one-liner, based on the one at top of id.c.
2009-02-15 10:17:19 +01:00
Jim Meyering
e3e9713fad doc: preserve --help line breaks in 'REPORTING BUGS' man page section
* man/help2man: Insert .br between adjacent lines.
2009-02-02 09:37:48 +01:00
Jim Meyering
ddf56e0440 doc: ensure that emit_bug_reporting_address changes propagate to *.1
* man/Makefile.am ($(MAN)): Depend on system.h.
2009-01-27 20:20:07 +01:00
Jim Meyering
2fbee63cc9 doc: restore "REPORTING BUGS" section to generated man pages
* man/help2man ($PAT_BUGS): Update regexp to match the newer
"Report PROG bugs ..." --help output, as well as "Report bugs...".
Reported by Eric Blake.
2009-01-27 19:17:14 +01:00
Pádraig Brady
4000c35ae3 doc: Remove curly quotes from shell examples in man pages
Use \(aq rather than a literal ' as groff will convert apostrophe
to a right quote (\u2029) in utf8 locales for example.
Stepan Kasal details the issue and fix here:
http://lists.gnu.org/archive/html/bug-coreutils/2008-12/msg00124.html
2008-12-17 10:47:23 +00:00
Ralf Wildenhues
e10e4b6697 various VPATH-related fixes
* maint.mk (VC_LIST): Prepend '$(srcdir)/'.
(patch-check): Fix to make it work with a VPATH build.
* src/Makefile.am (sc_tight_scope): Likewise.
* man/Makefile.am (.x.1): Do not make outputs unwritable.
2008-09-14 17:42:48 +02:00
Pádraig Brady
75e0047c4b Add new program: truncate
* AUTHORS: Register as the author
* NEWS: Mention this change
* README: Add truncate command to list
* src/truncate.c: New command
* src/Makefile.am: Add truncate command to list to build
* src/.gitignore: Add truncate binary to list to ignore
* doc/coreutils.texi (truncate invocation): Add truncate info
* man/Makefile.am: Add truncate man page to list to build
* man/truncate.x: Add truncate man page template
* po/POTFILES.in: Add truncate to list to translate
* tests/Makefile.am: Add truncate tests
* tests/misc/help-version: Add support for new truncate command
* tests/misc/truncate-dangling-symlink: check dangling link ok
* tests/misc/truncate-dir-fail: ensure dirs fail
* tests/misc/truncate-fail-diag: validate messages for missing paths
* tests/misc/truncate-fifo: ensure fifos ignored
* tests/misc/truncate-no-create-missing: ensure -c option honoured
* tests/misc/truncate-overflow: check signed integer overflows
* tests/misc/truncate-owned-by-other: root permissions check
* tests/misc/truncate-parameters: check invalid parameter combinations
* tests/misc/truncate-relative: check invalid relative sizes
2008-06-06 14:16:45 +02:00
Pádraig Brady
265c4b83a8 new program: timeout
* AUTHORS: Register as the author.
* NEWS: Mention this change.
* README: Add timeout command to list.
* src/timeout.c: New file.
* src/kill.c (operand2sig): Move function to its own file,
now that timeout.c will also use it.
* src/operand2sig.c (operand2sig): New file, extracted from kill.c.
* src/operand2sig.h (operand2sig): Declare.
* src/Makefile.am (EXTRA_PROGRAMS): Add timeout.
* src/.gitignore: Add timeout binary to list to ignore.
* doc/coreutils.texi (timeout invocation): Add timeout info.
(Signal specifications): New section, also referenced by kill.
* man/Makefile.am (timeout.1): Add dependency.
* man/timeout.x: New file.
* po/POTFILES.in: Add timeout.c and operand2sig.c to list to translate.
* tests/Makefile.am (TESTS): Add the two new tests.
* tests/misc/help-version: Add support for new timeout command.
* tests/misc/invalid-opt: Add support for new timeout command.
* tests/misc/timeout: New file: check basic timeout operation.
* tests/misc/timeout-parameters: New file: check invalid parameter
combinations.
2008-06-02 14:40:26 +02:00
Jim Meyering
cca51697aa fix typo in comments: s/ouput/output/
adjust spelling in that same comment: s/localisation/localization/
2008-05-06 08:21:29 +02:00
Jim Meyering
2224ef83fe help2man: fix perl 5.10 problem properly
* man/help2man: Do pull LC_ALL via "use POSIX".
Instead, limit the importing of gettext-related symbols
to just those two we'll use: gettext and textdomain.
2008-05-06 00:35:28 +02:00
Jim Meyering
0b66c5776e help2man: avoid failure with Debian unstable's Perl 5.10.0
Avoid failure that produced this diagnostic:
Constant subroutine main::LC_ALL redefined at /.../Exporter.pm
* man/help2man: Don't include LC_ALL in the "use POSIX" list,
since Locale::gettext->import will get it.
2008-05-05 23:46:30 +02:00
Jim Meyering
5916dec460 printf doc: xref print(3) and libc's "Output Conversion Syntax" node
* coreutils.texi (printf invocation): Add xref.
Use "The GNU C Library Reference Manual" as the name of the 'libc'
document consistently.
* man/printf.x: Add See also: printf(3).
Suggested by A. Costa in http://bugs.debian.org/465522
2008-04-01 12:06:05 +02:00
Jim Meyering
677610ec7c Remove today's automake kludge, altogether. Fix properly.
* man/Makefile.am: Use dist_man1_MANS instead of dist_man_MANS.
Suggestion from Ralf Wildenhues.
2008-03-20 19:04:50 +01:00
Jim Meyering
4682f132f2 Kludge to make automake generate install-man rules
* man/Makefile.am (dist_man_MANS): Add a literal, rm.1.
Without this, "make install" would not install man pages.
However, with this kludge, the rm.1 man page is installed
even when you configure with --enable-no-install-program=rm.
2008-03-20 18:01:35 +01:00
Jim Meyering
8058da0065 Revert recent man/Makefile.am change.
Revert 4b544e447e.
* man/Makefile.am: That change was only a band-aid.  It solved
the stated problem, but not a deeper one: that "make install"
would no longer man pages.  Reported by Dmitry V. Levin.
The latter problem arose in
167b8025ac with the removal of
the sole literal from the definition of dist_man_MANS.  When
automake perceives dist_man_MANS as empty, it no longer emits
the install-man* rules.
2008-03-20 17:59:44 +01:00
Jim Meyering
4b544e447e "make" would not always update man/*.1 files (but "make dist" would)
* man/Makefile.am (BUILT_SOURCES): Define, so that "make" always
updates man/*.1 files.  Reported by Bob Proulx.
2008-03-19 08:46:41 +01:00
James Youngman
167b8025ac Replace groups.sh with groups.c.
* src/groups.c (main): New file, replacing groups.sh.
* src/group-list.c, src/group-list.h: New files, factored out of id.c,
implementing the functionality that "id" and "groups" have in common.
* src/id.c (print_full_info): Avoid a segfault when trying to print
an error message if getgroups fails.
(print_group_list): Move to group-list.c.
(print_group): Likewise.
* man/Makefile.am: When building groups.1, obtain the help text
from src/groups.c, not src/groups.sh.
(noinst_HEADERS): Add group-list.h.
(group): Remove rule.
(dist_man_MANS): Remove groups.1.
* doc/coreutils.texi (groups: Print group names a user is in):
Explain why "groups" and "groups $(id -un)" give different results
in existing login sessions after you change the group database.
(id: Print user identity): Likewise for "id".
* po/POTFILES.in: Add src/group-list.c and src/groups.c.
* NEWS: mention this.
* AUTHORS: Update.
2008-02-13 14:37:22 +01:00
Bob Proulx
7cf7888ee9 Improve wording of date and time man page.
* man/date.x: Improve compact description of the --date=STRING.
* man/touch.x: Likewise.
Suggested by A. Costa.
2008-01-31 17:33:54 +01:00
Bob Proulx
69b1a35c6d Improve the man pages of --date=STRING for 'date' and 'touch'.
* man/date.x: Add a compact description of the --date=STRING.
* man/touch.x: Likewise.
Reported by A. Costa in http://bugs.debian.org/363011
2008-01-29 14:27:06 +01:00
Jim Meyering
a7f5e64909 Avoid "make distcheck" failure: newly-created man/*.1 files not removed
* Makefile.am (EXTRA_DIST): Add .version.
(.version): New rule.
(dist-hook): Don't create $(distdir)/.version here, now that it's
being distributed.
* man/Makefile.am (common_dep): Use ../.version, not ../VERSION.
(../VERSION): Remove rule.
* GNUmakefile (dummy): Create .version, not VERSION.
Add an extra "...:= $(shell..." statement to ensure that
.version exists even when the preceding code is not run.
* .gitignore: Remove both .version and VERSION.

Signed-off-by: Jim Meyering <meyering@redhat.com>
2008-01-29 09:40:31 +01:00
Jim Meyering
77abf69a60 Emit "info coreutils 'PROG invocation'" into the man page,
rather than just "info PROG".  The latter would often fail
or simply display the man page.
* man/help2man: Change the template.
Prompted by http://bugs.debian.org/399684
2008-01-26 19:37:23 +01:00
Jim Meyering
ca3de82a18 Ensure that each version string change propagates to man pages.
* man/Makefile.am (common_dep): Don't depend on configure.ac for
version changes.  Instead, depend on ../VERSION.
(../VERSION): New rule.
* Makefile.am (DISTCLEANFILES): Define.
* GNUmakefile: Update ./VERSION.
* .gitignore: List VERSION.
Reported by Sven Joachim.
2008-01-26 17:16:38 +01:00
Jim Meyering
8ddc5056f2 Avoid spurious "make check" failures due to omitted programs.
* man/Makefile.am (distcheck-hook): Make check rules dependents of
this target, not of check-local, so that people aren't distracted by
failures due to programs omitted via --enable-no-install-program=...
2007-12-20 14:03:12 +01:00
Jim Meyering
d471effd85 Use tighter regexps when performing name substitution.
* man/Makefile.am (mapped_name): Add ^ and $$ anchors.

Signed-off-by: Jim Meyering <meyering@redhat.com>
2007-11-05 11:14:05 +01:00
Jim Meyering
99b039fead New program: mktemp.
* NEWS: Mention this.
* README: Add mktemp to the list.
* AUTHORS: Add this: mktemp: Jim Meyering
* src/mktemp.c: New file.
* src/Makefile.am (bin_PROGRAMS): Add mktemp.
(mktemp_LDADD): Add $(LIB_GETHRXTIME).
* man/mktemp.x: New file.
* man/Makefile.am (dist_man_MANS): Add mktemp.1.
(mktemp.1): New dependency.
* man/.cvsignore: Add mktemp.1.
* man/.gitignore: New file.
* src/.cvsignore, src/.gitignore: Add mktemp.
* tests/misc/mktemp: New file.
* tests/misc/Makefile.am (TESTS): Add mktemp.
* tests/Coreutils.pm (run_tests): Give the POST-test function
access to stdout and stderr contents, so it can verify that
the named-on-stdout file/dir does indeed exist and has proper
permissions, etc.
[po/ChangeLog]
* POTFILES.in: Add src/mktemp.c.
2007-10-07 19:44:38 +02:00
Jim Meyering
6e3e819f4b Remove all .cvsignore files from version control. 2007-08-25 00:27:11 +02:00
Jim Meyering
71aa3ea880 Update all copyright notices to use the newer form. 2007-07-23 14:35:58 +02:00
Jim Meyering
471d33582e Add support for enabling/disabling installation of specified programs.
* NEWS: Mention new configure-time options.
Mention that neither arch nor su is built/installed, by default.
* m4/include-exclude-prog.m4: New file.
* configure.ac: Use new macro, gl_ADD_PROG, rather than
manually appending to OPTIONAL_BIN_PROGS and MAN.
Move the code that adds "df" to the list of programs to build from
m4/jm-macros into this file.
Use gl_INCLUDE_EXCLUDE_PROG, then handle special cases: ginstall, [.
(NO_INSTALL_PROGS_DEFAULT): AC_SUBST it.  Used by man/Makefile.am.
* man/Makefile.am (dist_man_MANS): Remove from this list all man pages
corresponding to "bin" programs. Add $(MAN) instead.
(optional_mans): Remove all uses.
(check-x-vs-1): Adapt to work even though arch and su are typically
no longer built (and neither are their .1 files).
* src/Makefile.am (install_su): Rename from INSTALL_SU, now that
INSTALL_SU has a different meaning. Use the new $(INSTALL_SU) value.
2007-07-10 22:55:15 +02:00
Karel Zak
264021699c New program: arch
* NEWS: Mention arch.
* README: Add arch to the list of programs.
* AUTHORS: Add arch.
* src/uname.c: Include "uname.h".
(PROGRAM_NAME): Handle arch, too.
(ARCH_AUTHORS): Define.
(uname_long_options, arch_long_options): Renamed and new globals.
(usage): Handle arch-mode as well as uname-mode.
(decode_switches): New function, extracted from main,
to handle arch-mode as well as uname-mode.
(main): Handle both modes.
* src/uname-arch.c: New program, alias for "uname -m".
* src/uname-uname.c: New file, default uname mode.
* src/uname.h: New file, uname modes.
* src/Makefile.am (EXTRA_PROGRAMS): Add arch.
(uname_SOURCES, arch_SOURCES): Define.
* man/arch.x: New file.
* man/Makefile.am (dist_man_MANS): Add arch.1.
(arch.1): New dependency.
* tests/misc/arch: New test, compare "arch" with "uname -m"
* configure.ac (OPTIONAL_BIN_PROGS): Add arch.
(MAN): Add arch.1.
* .x-sc_require_config_h: Exempt uname-arch.c and uname-uname.c
from the always-include-<config.h> rule.

Signed-off-by: Karel Zak <kzak@redhat.com>
Signed-off-by: Jim Meyering <jim@meyering.net>
2007-07-10 19:00:00 +02:00
Jim Meyering
33342c1a0a Change "version 2" to "version 3" in all copyright notices. 2007-07-10 13:35:56 +02:00
Paul Eggert
f4a5097ea3 * man/chmod.x: Document chmod's behavior with setuid and setgid bits.
Remove misleading implication about leading zero.  Problem
reported by Jan Engelhardt in
<http://lists.gnu.org/archive/html/bug-coreutils/2007-05/msg00134.html>.
2007-05-15 07:14:55 +02:00
Jim Meyering
c6922b6f7e * src/runcon.c: New program.
* src/Makefile.am (bin_PROGRAMS): Add runcon.
(runcon_LDADD): Define.
* README: Add runcon to the list of programs.
* AUTHORS: Add this: runcon: Russell Coker
* tests/help-version: Add runcon as an exception.
* man/Makefile.am (dist_man_MANS): Add runcon.1.
(runcon.1): New dependency.
* po/POTFILES.in: Add src/runcon.c.
2007-03-29 21:37:06 +02:00
Jim Meyering
85d6c618b0 * man/chcon.x: New file.
* man/Makefile.am: Build chcon.1.
2007-03-29 21:37:05 +02:00
Jim Meyering
75460e090c Avoid a shell syntax error, when building with an inadequate Perl.
* man/Makefile.am (.x.1): Add quotes around $(PERL) in case, since
it can expand to "/.../missing perl".
2007-02-24 09:26:56 +01:00
Jim Meyering
90390c6a92 * man/Makefile.am (.x.1): Warn when unable to update a man page.
Suggestion from Bruno Haible.
2007-02-24 09:14:56 +01:00
Bruno Haible
63813d0950 Handle better the combination of old Perl and a pre-c99 compiler.
* man/Makefile.am (.x.1): If the autoconf test has determined that
perl is missing or not a sufficient version, do nothing.
2007-02-24 08:51:19 +01:00
Jim Meyering
0ee9adb1fa * man/Makefile.am (.x.1): Make help2man use $(PACKAGE_STRING) as the
"source".  I.e. "GNU coreutils 6.7".
2006-12-09 19:20:56 +01:00
Ralf Wildenhues
8b139ff78c Arrange to install manpages only for tools that are installed.
* man/Makefile.am (dist_man_MANS): Replace all optional manpages
with `$(MAN)', computed at configure time; also, list them ...
(optional_mans): ... in this new variable.
(max_aux, EXTRA_DIST): Ensure that we distribute all manpages.
2006-11-16 09:57:34 +01:00
Jim Meyering
bad80a7223 * Makefile.am (THANKS-to-translators): Add missing $(srcdir).
(MAINTAINERCLEANFILES): Add .kludge-stamp.
* man/Makefile.am (MAINTAINERCLEANFILES): Typo $(dist_man_MANS)
instead of $(man_MANS).

2006-10-12  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
2006-10-12 21:10:43 +00:00
Paul Eggert
6d124bf98a * aclocal.m4, config.hin, configure:
Remove from CVS, since ./bootstrap generates them automatically.
* .cvsignore: Add INSTALL, Makefile.in, *.cache, *.lineno, *.log.
Remove more-specific entries.  This catches files like configure.lineno.
* man/.cvsignore: Add Makefile.in.
* src/.cvsignore: Add Makefile.in.
Remove .version, dir.c, install, mvdir, stamp-v, vdir.c, version.c.

For .cvsignore file under the tests directory:
Add Makefile.in.  Sort entries if necessary.  Remove *.I, *.E,
*.X, *.O, *-tests, build-script, mk-script if they're never
created in this directory.

* build-aux/.cvsignore: New file.
* doc/.cvsignore: Add Makefile.in, coreutils.html, coreutils.pdf,
coreutils.ps, coreutils.tps.  Remove coreutils.cm (dunno what it
is, but the makefile doesn't mention it).  Remove coreutils.info
as it is subsumed by coreutils.info*.
* lib/.cvsignore: Add Makefile.in, getdate.tab.h.
Remove stat.c, sysexit.h.
* m4/.cvsignore: Remove Makefile, dev-ino.m4, glibc2.m4, intdiv0.m4,
inttypes-h.m4, inttypes-pri.m4, jm-glibc-io.m4, lcmessage.m4,
lock.m4, printf-posix.m4, same-inode.m4, size_max.m4,
uintmax_t.m4, ulonglong.m4, visibility.m4, xsize.m4.  Many of
these are put in automatically by ../bootstrap, but that's a
bootstrap bug that I plan to fix shortly.
* po/.cvsignore: More ../bootstrap-related fixes, plus remove old
cruft.  Add *.po, LINGUAS, Makevars.  Remove *.cat, *.msg,
cat-id-dbl.c, messages.mo, stamp-cat-id.
2006-08-22 18:50:24 +00:00
Paul Eggert
0f7a044109 Remove from CVS, since the bootstrap script generates them automatically. 2006-08-21 07:26:38 +00:00
Jim Meyering
03ffc923e9 . 2006-08-19 19:34:16 +00:00
Paul Eggert
218fa5c61b Add/fix copyright notices and adjust to latest GNU FDL. 2006-08-17 19:58:17 +00:00