]> git.ipfire.org Git - thirdparty/coreutils.git/commitdiff
Use comma-separated list in ./configure --help output.
authorJim Meyering <meyering@redhat.com>
Thu, 20 Dec 2007 16:38:57 +0000 (17:38 +0100)
committerJim Meyering <meyering@redhat.com>
Thu, 20 Dec 2007 16:38:57 +0000 (17:38 +0100)
* configure.ac: Map commas to spaces in excluded-program list.
Use a comma-separated list, not a space-separated one.
* m4/include-exclude-prog.m4 (gl_INCLUDE_EXCLUDE_PROG):
Expect list of program names to be comma-separated.
Reported by Jan Bauke Douma.

ChangeLog
configure.ac
m4/include-exclude-prog.m4

index 412f13a0583e250cea84e3648ac09f1cbc631da8..7273199c8f608c980da3d65ffea3febdb003f785 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,12 @@
 2007-12-20  Jim Meyering  <meyering@redhat.com>
 
+       Use comma-separated list in ./configure --help output.
+       * configure.ac: Map commas to spaces in excluded-program list.
+       Use a comma-separated list, not a space-separated one.
+       * m4/include-exclude-prog.m4 (gl_INCLUDE_EXCLUDE_PROG):
+       Expect list of program names to be comma-separated.
+       Reported by Jan Bauke Douma.
+
        Avoid another "make check" failure due to omitted programs.
        * tests/test-lib.sh (require_built_): New function.
        * tests/misc/groups-version: Use it to skip this test if
index 6d996de706187440227c781b2916e1a2ab9e74ba..78c662abcee7483d205ceb73f7b1d342b682ae73 100644 (file)
@@ -279,12 +279,12 @@ no_install_progs_default=`echo "$t"|sed 's/ $//'`
 # The compromise is to ensure that the space-separated list extracted
 # above matches the literal 2nd argument below.
 c="$srcdir/configure.ac"
-t=`sed -n '/^g''l_INCLUDE_EXCLUDE_PROG(.* [\[\(.*\)\]])/s//\1/p' $c`
+t=`sed -n '/^g''l_INCLUDE_EXCLUDE_PROG(.* [\[\(.*\)\]])/{s//\1/;s/,/ /gp}' $c`
 case $t in
   $no_install_progs_default) ;;
   *) AC_MSG_ERROR([[internal error: g'l_INCLUDE_EXCLUDE_PROG's 2nd arg, $t,
                    does not match the list of default-not-installed programs
-                  ($no_install_progs_default) extracted also recorded in $mk]],
+                  ($no_install_progs_default) also recorded in $mk]],
                   1) ;;
 esac
 
@@ -294,7 +294,10 @@ esac
 # "don't-install" requests.
 # I.e., add any program name specified via --enable-install-program=..., and
 # remove any program name specified via --enable-no-install-program=...
-gl_INCLUDE_EXCLUDE_PROG([optional_bin_progs], [arch hostname su])
+# Note how the second argument below is a literal, with "," separators.
+# That is required due to the way the macro works, and since the
+# corresponding ./configure option argument is comma-separated on input.
+gl_INCLUDE_EXCLUDE_PROG([optional_bin_progs], [arch,hostname,su])
 
 # Set INSTALL_SU if su installation has been requested via
 # --enable-install-program=su.
index c5e31d9a14b45f3fed5421988195249f14b535ea..cf11c78354ff5a7f16234e48013389f60e662a5a 100644 (file)
@@ -27,12 +27,13 @@ AC_DEFUN([gl_REMOVE_PROG],
 # Given the name of a variable containing a space-separated list of
 # install-by-default programs and the list of do-not-install-by-default
 # programs, modify the former variable to reflect "no-install" and
-# "do-install" requests.
+# "do-install" requests.  The names in the latter list should be comma-
+# separated.
 #
 # Usage: gl_INCLUDE_EXCLUDE_PROG([prog_list_var_name], [no_inst_prog_list])
 AC_DEFUN([gl_INCLUDE_EXCLUDE_PROG],
 [{
-  gl_no_install_progs_default='$2'
+  gl_no_install_progs_default=`echo '$2'|sed 's/,/ /g'`
   AC_ARG_ENABLE([install-program],
     [AS_HELP_STRING([--enable-install-program=PROG_LIST],
                    [install the programs in PROG_LIST (comma-separated,