From: Tom Tromey Date: Tue, 5 Aug 1997 23:51:42 +0000 (+0000) Subject: use correct form of split X-Git-Tag: Release-1-2b~34 X-Git-Url: https://sourceware.org/git/?a=commitdiff_plain;h=6df54456f736737a70698731cd5eeea51c46c0e5;p=automake.git use correct form of split --- diff --git a/ChangeLog b/ChangeLog index 39074a8c..d0cc469c 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +Tue Aug 5 17:49:54 1997 Tom Tromey + + * Makefile.am: Check for bad splits. + * automake.in (various): Use split(' ',...), not split(/ /,...). + Tue Aug 5 14:08:51 1997 Ian Lance Taylor * ylwrap: If the program is a relative path, force it to be diff --git a/Makefile.am b/Makefile.am index d77a79a7..4c6b3a44 100644 --- a/Makefile.am +++ b/Makefile.am @@ -83,6 +83,11 @@ maintainer-check: automake aclocal echo "Found undef in automake.in; use delete instead" 1>&2; \ exit 1; \ fi +## We never want split (/ /,...), only split (' ', ...). + @if fgrep 'split (/ /' $(srcdir)/automake.in > /dev/null 2>&1; then \ + echo "Found bad split in automake.in" 1>&2; \ + exit 1; \ + fi # Tag before making distribution. Also, don't make a distribution if # checks fail. Also, make sure the NEWS file is up-to-date. diff --git a/Makefile.in b/Makefile.in index 61326d72..b81d415e 100644 --- a/Makefile.in +++ b/Makefile.in @@ -2,8 +2,7 @@ # Copyright (C) 1994, 1995, 1996, 1997 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. +# gives unlimited permission to copy, distribute and modify it. SHELL = /bin/sh @@ -123,9 +122,9 @@ config.status: $(srcdir)/configure $(srcdir)/configure: $(srcdir)/configure.in $(ACLOCAL_M4) $(CONFIGURE_DEPENDENCIES) cd $(srcdir) && $(AUTOCONF) automake: $(top_builddir)/config.status automake.in - cd $(top_builddir) && CONFIG_FILES=$@:automake.in CONFIG_HEADERS= ./config.status + cd $(top_builddir) && CONFIG_FILES=$@ CONFIG_HEADERS= ./config.status aclocal: $(top_builddir)/config.status aclocal.in - cd $(top_builddir) && CONFIG_FILES=$@:aclocal.in CONFIG_HEADERS= ./config.status + cd $(top_builddir) && CONFIG_FILES=$@ CONFIG_HEADERS= ./config.status install-binSCRIPTS: $(bin_SCRIPTS) @$(NORMAL_INSTALL) @@ -278,12 +277,7 @@ clean-aminfo: distclean-aminfo: maintainer-clean-aminfo: - for i in $(INFO_DEPS); do \ - rm -f $$i; \ - if test "`echo $$i-[0-9]*`" = "$$i-[0-9]*"; then \ - rm -f $$i-[0-9]*; \ - fi; \ - done + for i in $(INFO_DEPS); do rm -f `eval echo $$i*`; done install-pkgdataDATA: $(pkgdata_DATA) @$(NORMAL_INSTALL) @@ -549,6 +543,10 @@ maintainer-check: automake aclocal echo "Found undef in automake.in; use delete instead" 1>&2; \ exit 1; \ fi + @if fgrep 'split (/ /' $(srcdir)/automake.in > /dev/null 2>&1; then \ + echo "Found bad split in automake.in" 1>&2; \ + exit 1; \ + fi # Tag before making distribution. Also, don't make a distribution if # checks fail. Also, make sure the NEWS file is up-to-date. diff --git a/automake.in b/automake.in index 039e680d..7909f4db 100755 --- a/automake.in +++ b/automake.in @@ -4328,7 +4328,7 @@ sub conditional_true_when sub check_ambiguous_conditional { local ($var_name, $cond) = @_; - local (@cond_vals) = split (/ /, $conditional{$var_name}); + local (@cond_vals) = split (' ', $conditional{$var_name}); while (@cond_vals) { local ($vcond) = shift (@cond_vals); @@ -4363,7 +4363,7 @@ sub variable_defined # look through the conditions under which the variable is # defined, and see if any of them match the conditional we # have been asked to check. - local (@cond_vars) = split (/ /, $conditional{$var}); + local (@cond_vars) = split (' ', $conditional{$var}); while (@cond_vars) { if (&conditional_same ($cond, shift (@cond_vars))) @@ -4467,7 +4467,7 @@ sub variable_conditions_sub } local (@this_conds) = (); - local (@condvals) = split (/ /, $conditional{$var}); + local (@condvals) = split (' ', $conditional{$var}); while (@condvals) { local ($cond) = shift (@condvals); @@ -4742,7 +4742,7 @@ sub variable_value_as_list } elsif ($cond eq 'all' && $conditional{$var}) { - local (@condvals) = split (/ /, $conditional{$var}); + local (@condvals) = split (' ', $conditional{$var}); while (@condvals) { shift (@condvals); @@ -4752,7 +4752,7 @@ sub variable_value_as_list } elsif ($cond && $conditional{$var}) { - local (@condvals) = split (/ /, $conditional{$var}); + local (@condvals) = split (' ', $conditional{$var}); local ($onceflag); while (@condvals) { diff --git a/lib/am/Makefile.am b/lib/am/Makefile.am index d77a79a7..4c6b3a44 100644 --- a/lib/am/Makefile.am +++ b/lib/am/Makefile.am @@ -83,6 +83,11 @@ maintainer-check: automake aclocal echo "Found undef in automake.in; use delete instead" 1>&2; \ exit 1; \ fi +## We never want split (/ /,...), only split (' ', ...). + @if fgrep 'split (/ /' $(srcdir)/automake.in > /dev/null 2>&1; then \ + echo "Found bad split in automake.in" 1>&2; \ + exit 1; \ + fi # Tag before making distribution. Also, don't make a distribution if # checks fail. Also, make sure the NEWS file is up-to-date.