summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2012-12-06tests: cut.pl: adjust for changed diagnosticPádraig Brady
* tests/misc/cut.pl: Since we now output the more complete error message irrespective of running in a multi-byte locale or not, adjust the test accordingly.
2012-12-06cut: improve error reportingCojocaru Alexandru
* src/cut.c (main): Treat a NUL delimiter (-d '') consistently with non NUL delimiters, and disallow such a delimiter option, unless a field is also specified. (set_fields): Provide a more accurate error message when a given list is invalid. * tests/misc/cut.pl: Add a test case.
2012-12-06maint: adjust instructions to run a single testPádraig Brady
* README: Adjust as per the recent changes introduced when switching to non recursive make.
2012-12-05maint: remove now auto-added entry from THANKS.inBernhard Voelker
The syntax-check sc_THANKS_in_duplicates complained about that excess entry. * THANKS.in (Colin Watson): Remove entry, now that it will be automatically included in the generated THANKS file.
2012-12-04maint: remove a redundant odd sized alloc from factor.cPádraig Brady
* src/factor.c (mp_factor_init): Init the pointers with NULL, which xrealloc (or realloc) handles fine.
2012-12-04factor: fix infinite loop on 32 bit powerpcColin Watson
Both Debian and Ubuntu builds of coreutils 8.20 hang while running the test suite on powerpc, which is reproducible using 'factor 122'. This turns out to be somewhat related to http://bugs.gnu.org/12754, but not quite the same. uintmax_t is 64 bits, but the cntlzw instruction takes 32-bit operands, and the cntlzd option is only available on 64-bit hardware. * src/longlong.h: Add an _LP64 check around the PPC64 code, so that this falls back to the C implementations. * NEWS: Mention the fix.
2012-11-24cut: do not print extraneous delimiters in some unusual casesJim Meyering
When printing output delimiters, and when a to-EOL range subsumes at least one other range, cut would mistakenly print delimiters for the subsumed range. This bug was probably introduced via commit v5.2.1-639-g847e066. * src/cut.c (set_fields): Ignore any range that is subsumed by a to-EOL range. Also, move two declarations down. * tests/misc/cut.pl: Add tests to exercise this. * NEWS (Bug fixes): Mention it. Reported by Marcel Böhme in http://bugs.gnu.org/12966
2012-11-24cut: treat -b2-,3- like -b2-, not like -b3-Jim Meyering
* src/cut.c (set_fields): When two right-open-ended ranges are specified, don't blindly let the latter one take precedence over the former. Instead, use the union of the ranges. * tests/misc/cut.pl: Add tests to exercise this. * NEWS (Bug fixes): Mention it. Reported by Marcel Böhme in http://bugs.gnu.org/12966 Thanks to Berhard Voelker for catching log and NEWS typos.
2012-11-24doc: cp: clarify behavior of the --preserve=xattr optionBernhard Voelker
* doc/coreutils.texi (cp invocation): Enhance documentation of the --preserve=xattr option regarding the preservation of ACLs, SELinux contexts and capabilities: the user may notice this only when not specifying --preserve=mode and --preserve=context, too, i.e., otherwise, these attributes are preserved anyway.
2012-11-24doc: update info cross reference to bashPádraig Brady
* doc/coreutils.texi (tee invocation): Reference the bash manual rather than bashref, as the latter is more likely to work on newer systems.
2012-11-24tests: use sub-second timeouts to speed up a timeout testPádraig Brady
* tests/misc/timeout.sh: Take advantage of recent support for sub-second timeouts to decrease runtime from about 6s to 2s.
2012-11-24doc: clarify that renice is needed to adjust nicenessPádraig Brady
* doc/coreutils.texi (nice invocation): Ensure there is no ambiguity in the summary in relation to nice being able to adjust the niceness of an existing process. Reference the renice command. * man/nice.x: Reference renice (1)
2012-11-24tests: accept EEXIST from rm -dPádraig Brady
* tests/rm/d-2.sh: EEXIST is a valid error on some systems. Reported by Michael Felt on AIX 6.1
2012-11-24tests: don't rely on sed -i being availablePádraig Brady
* tests/df/df-output.sh: sed --in-place is not generally available. Also add a couple of simplifications from Bernhard Voelker. Removing all spaces, rather than just leading spaces, suffices. Searching for ' --output' in unadjusted df --help, suffices.
2012-11-24seq: ensure correct output width for scientific notation inputPádraig Brady
* src/seq.c (scan_arg): Calculate the width more accurately for numbers specified using scientific notation. * tests/misc/seq.pl: Add tests for cases that were mishandled. * NEWS: Mention the fix. * THANKS.in: Reported by Marcel Böhme. Fixes http://bugs.gnu.org/12959
2012-11-22df: reorder default field list of --output optionBernhard Voelker
As the inodes information is usually not so much of interest, and some file systems including btrfs do not even provide it, reading of the full df --output is easier when the block statistic fields come just left of the last field, the mount point. * src/df.c (all_args_string): Move the inodes fields before the block fields. (usage): Likewise. * tests/df/df-output.sh: Likewise. * doc/coreutils.texi (df invocation): Likewise. Additionally, explicitly mention the default order of the --output option.
2012-11-20install: fix security racePaul Eggert
* NEWS: Document this.
2012-11-20install: fix security racePaul Eggert
* src/copy.c (copy_internal): Use DST_MODE_BITS, not SRC_MODE. See Bernhard R. Link in <http://bugs.gnu.org/12947> and in <http://bugs.debian.org/598018>.
2012-11-20nl: remove deprecated --page-increment optionBernhard Voelker
The above option has been deprecated since coreutils-7.5 by commit v7.4-129-g718b279. * src/nl.c (PAGE_INCREMENT_OPTION_DEPRECATED): Remove enum. (longopts): Remove "page-increment" entry. (main): Remove PAGE_INCREMENT_OPTION_DEPRECATED case. * NEWS (Changes in behavior): Mention the change. Reported by Marcel Böhme in <http://bugs.gnu.org/12940>.
2012-11-19doc: remove already implemented items from TODOBernhard Voelker
* TODO (renice): The renice program is part of util-linux for years now. Remove entry. (dd): The option status=none has been implemented in commit v8.19-143-g7331ab5. Remove entry.
2012-11-19cut: do not accept the invalid range 0-Bernhard Voelker
The command "echo 12345 | cut -b 0-" prints an empty line while it should fail with "fields and positions are numbered from 1". * src/cut.c (set_fields): Add a diagnostic for the invalid open range which starts with Zero, i.e., the range 0-. * tests/misc/cut.pl: Add tests to ensure the range 0- fails for fields (-f) and for positions (-b, -c). * NEWS: Mention the fix. Reported by Marcel Böhme in <http://bugs.gnu.org/12903>.
2012-11-18build: fix compilation failure on x32Daniel Schepler
* src/factor.c [HAVE_ATTRIBUTE_MODE]: Fix typo in #if test: s/HAVE_LONG_LONG/HAVE_LONG_LONG_INT/. Otherwise, factor.c would elicit assembler errors on x32: it was incorrectly defining DItype to long instead of long long. Patch and report in http://bugs.debian.org/693337; Mike Stone notified upstream.
2012-11-18maint: reenable accidentally-disabled cppi-check syntax-check ruleJim Meyering
* cfg.mk (exclude_file_name_regexp--sc_preprocessor_indentation): Fix typo that disabled the sc_preprocessor_indentation syntax-check rule by exempting all files. s/__ll/_ll/ The typo was introduced in commit v8.19-157-g759ebcb.
2012-11-18maint: correct indentation of W_TYPE_SIZE-defining cpp directivesJim Meyering
* src/factor.c: Indent cpp directives to reflect their nesting.
2012-11-18maint: avoid i686-specific syntax-check failureJim Meyering
* cfg.mk (_gl_TS_unmarked_extern_vars): Define.
2012-11-17doc: explain why dd is called "dd"Paul Eggert
* doc/coreutils.texi (dd invocation): Mention JCL.
2012-11-16factor: tidy up primes.h againPaul Eggert
See Stefano Lattarini in <http://bugs.gnu.org/12899>. * src/local.mk (BUILT_SOURCES): Put $(top_srcdir)/src/primes.h here (MAINTAINERCLEANFILES): ... instead of here.
2012-11-13factor: cleanup for primes.hPaul Eggert
* .gitignore: Add src/primes.h back, since it's no longer in the repository.
2012-11-13maint: avoid unnecessary #include to fix syntax-check failureJim Meyering
* src/factor.c: Remove unneeded #inclusion of"verify.h". It's already included via system.h.
2012-11-12factor: improve primes.h changePaul Eggert
This follows suggestions by Jim Meyering in <http://bugs.gnu.org/12841#34>. * src/make-prime-list.c (print_wide_uint): Change "nested" argument to "nesting", and use it to avoid outputting lines that are too long. * src/primes.h: Remove from git. This can be generated by a maintainer. It's nicer to do so on a host with at least 128-bit arithmetic.
2012-11-12factor: maintainer builds primes.h, not builderPaul Eggert
With this change, the maintainer builds primes.h and it is part of the tarball. primes.h's contents are not architecture-specific. * .gitignore: Remove /src/primes.h. * src/factor.c: Include verify.h. (W): New constant. Verify that uintmax_t lacks holes and that W is no wider than the integers used to generate primes.h. * src/local.mk (EXTRA_DIST): Add src/primes.h. (BUILT_SOURCES, CLEANFILES): Remove src/primes.h. ($(top_srcdir)/src/primes.h): Rename from src/primes.h. Do not depend on src/make-prime-list. Instead, use sub-make to build, so that we build primes.h only if it does not exist. * src/make-prime-list.c: Include <limits.h>, for ULONG_MAX. (wide_uint): Define to uintmax_t or unsigned __int128 if not #defined. (struct prime, binvert, process_prime): Use it instead of uintmax_t. (print_wide_uint): New function. This generates the proper pinv value regardless of the width of uintmax_t on the target, so long as the width doesn't exceed that of the width of wide_uint on the maintainer host that generated src/primes.h. (output_primes): Use it. Output WIDE_UINT_BITS, too. Let the target compute its own lim, since its uintmax_t may be narrower than ours. (SZ): Remove. * src/primes.h: New file, generated with 128-bit integers and usable on any host where uintmax_t's width is no greater than 128 bits.
2012-11-12factor: port to systems with rpl_mallocPaul Eggert
* src/make-prime-list.c (malloc): Undef. This fixes a problem on AIX 8.20 reported by Michael Felt in <http://bugs.gnu.org/12841>.
2012-11-09tests: fix factor's tests to use coreutil's own sha1sumBernhard Voelker
The test used the shasum utility which seems to belong to the perl package. On SLES-10.4, perl doesn't include this yet: + seq 0 10000000 + factor + shasum -c --status exp ./tests/factor/t00.sh: line 30: shasum: command not found + Exit 1 It is better to use our own stuff anyway. * tests/factor/run.sh: s/shasum/sha1sum/. Additionally, add sha1sum to the print_ver_ call.
2012-11-09doc: chcon: add descriptions for three undocumented optionsBenno Schulenberg
These were missed in this related change v8.14-104-g44e20cd * src/chcon.c (usage): Mention the two --preserve-root options. * doc/coreutils.texi (chcon invocation): Plus the --dereferece option.
2012-11-09doc: with cp -n, option -f is not redundant but ignoredBenno Schulenberg
* src/cp.c (usage): Replace "redundant" with "ignored". * doc/coreutils.texi (cp invocation): Likewise.
2012-11-09df: port the new df test to POSIX sed, larger file systemsPaul Eggert
* tests/df/df-output.sh: For the test "df -B1K --output=size", do not assume that the file system size fits in 9 bytes; it might be larger than that, so omit leading space. Also, use portable 'sed' commands: POSIX says sed commands inside { } should all end in newline.
2012-11-08df: add a test for the --output optionBernhard Voelker
* tests/df/df-output.sh: Add a test case. * tests/local.mk (all_tests): Mention the test. * cfg.mk (sc_file_system): Exempt the test from this syntax-check.
2012-11-08df: document the new --output optionBernhard Voelker
* src/df.c (usage): Add a short description of --output and its available field names for use in the optional argument. * doc/coreutils.texi (df invocation): Add the new option with more details and a few examples. * NEWS (New features): Mention the new option. (Changes in behvaior): Mention the new placeholder for fields in the "total" line.
2012-11-08df: add --output to select which fields to displayBernhard Voelker
This supports changing the order of the fields displayed, and also allows the simultaneous display of inode and block fields. src/df.c (get_dev): Factor out calling get_header to ... (main): ... here. Call print_table only if file_systems_processed. src/df.c (Displayable fields): Rename DEV_FIELD to SOURCE_FIELD. Rename TYPE_FIELD to FSTYPE_FIELD. Rename FREE_FIELD to AVAIL_FIELD. Rename MNT_FIELD to TARGET_FIELD. * src/df.c (display_field_t): Turn loose enum definition of the displayable fields into a typedef. Add the inode fields ITOTAL_FIELD, IUSED_FIELD, IAVAIL_FIELD, IPCENT_FIELD. (field_data_t): Define structure to hold the display field, the caption, the width and the alignment for each field of the above type. (field_data): Add array the values of field data for each display field. (headers, alignments, widths): Remove arrays. (columns): Add a pointer to the storage for the array of the actual output columns, i.e., fields. (ncolumns): Add counter for the current output columns. (alloc_table_row): Allocate the dynamic ncolumns value of strings. (print_table): Loop over ncolumns instead of constant NFIELDS. Rename loop variable 'field' to 'col' to avoid ambiguity with the 'field' element in the columns structure. Adjust the condition for printing the last column by comparing with the column number instead of the field name (TARGET_FIELD). Use the width and the alignment stored in the columns data. (alloc_field): Add new function to allocate a field in the columns array. (get_field_list): Add new function to fill the array of output columns for each mode. (get_header): Loop over ncolumns instead of constant NFIELDS. Rename the loop variable 'field' to 'col' to avoid ambiguity with the 'field' element in the columns structure. Remove the code for continuing the loop if the current column is the file system type and print_type is not active (which is now impossible). Store the cell in the columns store along with the new width. (get_dev): Loop over ncolumns instead of the constant NFIELDS. Rename the loop variable 'field' to 'col' to avoid ambiguity with the 'field' element in the columns structure; move the definition down to where it is used first. Add cases for the inode fields ITOTAL_FIELD, IUSED_FIELD, IAVAIL_FIELD and IPCENT_FIELD. Store the cell in the columns store along with the new width. (main): Use new get_field_list function to fill the list of output columns. * src/df.c (print_table): Instead of fputs()ing directly, apply ambsalign on the last field, too. Use the new MBA_NO_RIGHT_PAD flag for this. * src/df.c (TOTAL_OPTION): Add new enum value. (long_options): Use it for the "total" option instead of 'c'. (main): Likewise. * src/df.c (get_dev): Remove condition to copy the fstype into the FSTYPE_FIELD - based on whether print_type is non-Null. Since the introduction of get_field_list(), there are only fields added to the columns array which have to be added. * src/df.c (get_dev): Guard the summing up of the values for the grand total: only do it if we have to print the total and if the current invocation is not for processing it. * src/df.c (main): Pass a hyphen "-" for the mount point name to get_dev. (get_dev): As the mount_point is now always there, remove the condition and the else case for the TARGET_FIELD. Instead, simply copy the mount_point. All cells are now always present. Therefore, add an assertion statement if one was not. Furthermore, hide the problematic characters unconditionally. (print_table): Remove the skipping of empty cells. * tests/df/total-verify.sh: Accommodate to the new "-" in the target field of the summary line. * NEWS: Mention the change in behavior. * src/df.c (field_type_t): Add new typedef of 3 enums to distinguish between block, inode and other fields. (field_data_t): Add field_type member of the above new type. (field_data): Add default values for the above field_type, indicating whether a field contains block values, inode values or other, generic values. (field_values_t): Add this struct to store the field values, used by and factored out from get_dev to be able to define such a struct for both the inode and the block values. (get_field_values): Add this function to obtain the block values and the inode values from the file system usage, used by and factored out from get_dev. (add_to_grand_total): Add this function to sum the values of the current mount point up for the grand total, used by and factored out from get_dev. (get_dev): Move the definition of the variables fsu, buf, pct and cell down to where they are used first to give them a better scope. Factor out input_units, output_units, total, available, negate_available, available_to_root, used and negate_used into the above struct field_values_t. Factor out the mapping of the fsu values to the above variables into above function get_field_values. Factor out the summing up of the grand total values into the above function add_to_grand_total. Define block_values and inode_values of the new type and call the new get_field_values to fill them from the fsu values. Call the above function add_to_grand_total for summing up the values for the grand total. Inside the loop over all fields, define a variable 'v' to point to either the block_values or the inode_values, depending on the current field's field_type. Change the code in the cases TOTAL_FIELD/ITOTAL_FIELD, USED_FIELD/IUSED_FIELD, AVAIL_FIELD/ IAVAIL_FIELD and PCENT_FIELD/IPCENT_FIELD to use the field values where 'v' is pointing to, i.e., either the block_values or the inode_values. * src/df.c (main): Remove setting of grand_fsu.fsu_blocks in the inode_format case as this is no longer needed and would lead to wrong results once when mixed block/inode fields will be used. * src/df.c (main): Cleanup the code at the end regarding file_systems_processed to make the code clearer. * src/df.c (inode_format): Remove variable. (main): Remove initialization of the above variable. In getopts loop, directly set the header_mode to INODES_MODE instead of using the above variable. Afterwards, remove the mapping to INODES_MODE as it is already set. * src/df.c (posix_format): Move variable ... (main): ... to here. * src/df.c (print_table): Enhance the comment about 2-line format in cases where the SOURCE_FIELD exceeds 20 chars, as such behavior has been removed long ago by commit v8.10-40-g99679ff. * src/df.c (Display modes): Add OUTPUT_MODE, remove unused NMODES. (display_field_t): Remove unnecessary NFIELDS. (field_data_t): Add member 'arg' for the field name in the --output argument. Add member 'used' to remember if a field is already used in the columns array. (field_data): Add values for the above new members arg and used. (all_args_string): Add variable which represents the argument for the --output option which includes all fields. (OUTPUT_OPTION): Add enum to identify the long --output option. (long_options): Add optional-argument --output option. (alloc_field): Assert that the field is not already used. Mark the field as used. (decode_output_arg): Add function to parse the comma-separated field list passed to the --output option in order to add the appropriate fields to the columns array. (get_field_list): Add case for the new OUTPUT_MODE to add all available fields to columns in the case the --output option has been passed without any values. Use the comma-separated field list form to pass to decode_output_arg to keep the field header mapping for the OUTPUT_MODE only on one place. (main): Define format string msg_mut_excl to be used in the following checks whether the use of --output and the other option is mutually exclusive. In the getopt_long loop, add a check to the case for the -i option to issue an error message when it is used together with --output; Likewise for -T and -P. Add a new case for OUTPUT_OPTION, together with similar checks as above and eventually passing the optarg to decode_output_arg. After the getopt_long loop, consider the OUTPUT_MODE case in order not to run into -h or -P mode. * src/df.c (get_dev): Also xstrdup the dev_name, and free it afterwards to silence a valgrind warning about definitely lost memory. (main): Free the columns store to silence valgrind, guarded by the IF_LINT macro. * src/df.c (main): Pass "total" as the mount point to get_dev if the SOURCE_FIELD is not among the columns to output. * tests/df/df-output.sh: Change the test to ensure the content of the target field of the grand total line: if the source field is present, then the target should be "-", else the target field should be "target". * NEWS (Changes in behavior): Enhance the exiting NEWS entry. * doc/coreutils.texi (df invocation): Document the content of the source and target field in the grand total line. * src/df.c (main): Add another condition to the need_fs_type parameter of read_file_system_list whether the FSTYPE_FIELD is used or not. * src/df.c (get_header): Indicate the block size used, in the "size" header, when using --output without -h. * tests/df/df-output.sh: Adjust for, and add an extra test for, the new behavior.
2012-11-05maint: fix factor's test file name pattern in .gitignoreBernhard Voelker
* .gitignore: Adapt the entry for the files generated during the factor tests (see v8.20-9-g1cace4a).
2012-11-04timeout: add --preserve-status to always propagate the exit statusÁngel González
It's useful for commands that support running for an indeterminite amount of time, to not return a specific timeout exit status (124), and instead let the command handle the timeout signal and return a status for the work done so far. * doc/coreutils.texi (timeout invocation): Describe the new option. * src/timeout.c (preserve_status): A new global boolean to enable the --preserve-status behavior. (usage): Describe the new option. (main): Don't return EXIT_TIMEOUT of preserve_status is set. * tests/misc/timeout.sh: Add a test for the new option.
2012-11-04maint: fix the error message from sc_check-I18N-AUTHORSPádraig Brady
* cfk.mk (sc_check-I18N-AUTHORS): Fix the quoting so you don't get a 'command not found' error.
2012-11-04build: avoid build failure on some HPPA systemsPádraig Brady
* src/longlong.h: Restrict some HPPA assembly variants to PA RISC V2.0. Note we also avoid this assembly for ilp32 runtimes, since even though the assembly is accepted there, it's not safe as the context can get clobbered between the 'add' and 'add,dc'. This fixes a compile failure with newer HPPA systems with default GCC CPU options. Reported by John David Anglin
2012-11-04build: don't assume uintmax_t is 64 bitsPádraig Brady
This was not seen to be an issue in practise, but to make the code more robust, don't assume uintmax_t is 64 bits. * src/factor.c (W_TYPE_SIZE): Define based on integer limits. * src/make-prime-list.c (output_primes): Define format width based on integer limits.
2012-11-04build: don't rely on support for '%j' printf formatPádraig Brady
* src/factor.c (print_uintmaxes): Replace with PRIuMAX. * src/join.c (check_order): Likewise. * cfg.mk (sc_check-j-printf-format): Add a syntax-check rule to flag new cases of this.
2012-11-04build: don't rely on support for '%*j' printf formatPádraig Brady
* src/make-prime-list.c: Hardcode the uintmax_t width to 16 hex digits (64 bit), to avoid this compile issue on HPUS systems at least.
2012-11-01tests: fix syntax error in setuidgid_has_perm_Bernhard Voelker
An invalid sed expression lead to the following error: + sed -n 'ls/.* //p' sed: -e expression #1, char 2: extra characters after command Use "one" instead of "el". Bug introduced in v8.19-111-g51a4b04. * init.cfg (setuidgid_has_perm_): s/ls/1s/. * NEWS (Build-related): Mention the fix.
2012-10-27tests: shorten factor's inordinately-long test file namesBernhard Voelker
Besides what the subject says, this commit moves the test data for the factor tests from tests/local.mk into the directory tests/factor/ where it belongs. * tests/local.mk (EXTRA_DIST): Add new tests/factor/create-test.sh. (p,q,t1,t2) Factor out the factor-related magic numbers. (factor_tests): Rename the test names to t{00..36}.sh. Factor out the triples of test data. ($(factor_tests)): Add dependency to new tests/factor/create-factor.sh. Call that script to generate the test scripts. * tests/factor/run.sh: Turn this script into a template, and therefore remove it's executable permission bit. Add template variables START, END and CKSUM, replacing the code to split the test data from the test script's file name. Use the new template variables in the call to seq and for creating the exp file. * tests/factor/create-test.sh: Add new script to create the test scripts from the template tests/factor/run.sh. Use test data and magic numbers factored out from the above files. Let the script also change the __TEMPLATE__ line in run.sh to make clear that the test scripts are generated. * cfg.mk (sc_tests_list_consistency): Exempt the new test. (exclude_file_name_regexp--sc_prohibit_test_backticks): Likewise. Improved-by: Stefano Lattarini Improved by: Jim Meyering
2012-10-26build: man page generation: degrade gracefully when perl is lackingStefano Lattarini
Since commit v8.19-118-g57da212, our 'dist-hook' rule tweaked the distributed Makefile.in to make each man page 'man/foo.1' depend on the corresponding source 'src/foo.c' rather than the corresponding program 'src/foo'. That was done to accommodate systems without perl, which cannot run help2man to regenerate the manpage after its corresponding program has been built. This seems a right and proper graceful degradation, in that the man pages dependencies are still 100% correct in a git checkout, while being more lax but "more portable" in a distribution tarball. Alas, that is not the case in practice, as it turns out the tweaked Makefile makes the building of man pages unreliable and potentially incorrect! In fact, assume that instead of the correct a dependency: man/ls.1: src/ls we have the laxer one: man/ls.1: src/ls.c and think of what happens if a user modifies, say, 'src/ls.c', and then runs "make -j4" to rebuild everything. The make process will see that it has to rebuild the man page 'man/ls.1' (because its prerequisite 'src/ls.c' has changed), but won't see that it has to rebuild 'src/ls' *before* re-running 'help2man' to generate that man page; so, if 'man/ls.1' is rebuilt before 'src/ls' (which can happen with concurrent make), our user will get either a build error (if 'src/ls' did non exist) or, worse, a man page with an up-to-date timestamp but an out-of-date content. And what's even worse in all of this is that this problem will be present also for users who have perl installed: this is not a "graceful degradation" at all! In our situation, the best and simplest way to implement a graceful degradation it to keep the correct dependencies for man pages (that is, "man/ls.1: src/ls"), and if perl is not present, just generate dummy man pages reporting that built-time issue and redirecting the user back to either the info documentation or the '--help' output. As a consequence of this change, we also stop distributing man pages, since they will now be generated unconditionally. * Makefile.am (do-not-require-help2man): Remove. (dist-hook): Don't depend on it. * man/local.mk: Remove an obsolete comment. (EXTRA_DIST): Stop distributing generated man pages. ($(EXTRA_MANS)): This no longer needs to depend on $(all_programs). (MAINTAINERCLEANFILES): $(ALL_MANS) Do not list it here, and ... (CLEANFILES): ... list it here, instead. (.x.1): Instead of warning if perl is missing, but then trying to run 'help2man' unconditionally, simply run ... (run_help2man): ... the command referenced by this new variable, that expands to a proper invocation of 'help2man' if perl is present, and to an invocation of a shell script generating a dummy manpage if it is not. (EXTRA_DIST): Distribute that shell script. * man/dummy-man: New shell script. * NEWS (Build-related): Mention this. Fixes coreutils http://bugs.gnu.org/12715.
2012-10-25maint: tweak sc_check-I18N-AUTHORSJim Meyering
* cfg.mk (sc_check-I18N-AUTHORS): Remove unnecessary subshell; add a self-explanatory diagnostic.