From c62b42b64c588c98d9b1f370d208056e82b39d8b Mon Sep 17 00:00:00 2001 From: Stefano Lattarini Date: Thu, 3 May 2012 18:56:57 +0200 Subject: [PATCH] [ng] dist: rename some non-public vars to make clear they are internal The variable $(DISTFILES), $(DIST_COMMON) and $(DIST_SOURCES) have never been documented, and they were always intended to be internal variables. This is absolutely not evident from their names, though. So rename them like this: DISTFILES => am__dist_files DIST_COMMON => am__dist_common DIST_SOURCES => am__dist_sources * NG-NEWS: Update. * automake.in: Adjust code and comments. * lib/am/configure.am, lib/am/data.am, lib/am/java.am, lib/am/lisp.am, lib/am/python.am, lib/am/scripts.am, lib/am/texi-vers.am: Likewise. * lib/am/distdir.am: Likewise, and related variable renamings. And throw in a few improvements to comments since we are at it. * Several tests: Adjust. * syntax-checks.mk: Add rules (and supporting variables) verifying that the obsolete 'DIST*' variables are actually not used anymore. Signed-off-by: Stefano Lattarini --- NG-NEWS | 11 +++++++ automake.in | 37 ++++++++++----------- lib/am/configure.am | 4 +-- lib/am/data.am | 2 +- lib/am/distdir.am | 53 +++++++++++++++---------------- lib/am/java.am | 2 +- lib/am/lisp.am | 2 +- lib/am/python.am | 2 +- lib/am/scripts.am | 2 +- lib/am/texi-vers.am | 2 +- syntax-checks.mk | 23 ++++++++++++++ t/autodist-acconfig-no-subdir.sh | 4 +-- t/autodist-acconfig.sh | 2 +- t/autodist-aclocal-m4.sh | 4 +-- t/autodist-config-headers.sh | 12 +++---- t/autodist-configure-no-subdir.sh | 4 +-- t/autodist-stamp-vti.sh | 2 +- t/autodist-subdir.sh | 10 +++--- t/autodist.sh | 6 ++-- t/colon5.sh | 2 +- t/colon7.sh | 6 ++-- t/confh.sh | 4 +-- t/confh8.sh | 8 ++--- t/depdist.sh | 2 +- t/dist-auxfile.sh | 8 ++--- t/distcom-subdir.sh | 2 +- t/distcom2.sh | 6 ++-- t/distcom3.sh | 4 +-- t/distcom4.sh | 3 +- t/distcom5.sh | 5 +-- t/distdir.sh | 4 +-- t/hdr-vars-defined-once.sh | 4 +-- t/insh2.sh | 3 +- t/libobj7.sh | 8 ++--- t/nodist.sh | 4 +-- t/nodist3.sh | 2 +- t/pr2.sh | 2 +- t/subdir4.sh | 6 ++-- t/substref.sh | 4 +-- t/test-driver-is-distributed.sh | 2 +- t/txinfo.sh | 4 +-- t/txinfo2.sh | 4 +-- t/txinfo8.sh | 4 +-- t/vtexi3.sh | 4 +-- t/vtexi4.sh | 4 +-- t/yacc-basic.sh | 2 +- t/yacc-cxx.sh | 2 +- t/yacc-d-basic.sh | 2 +- t/yacc-d-cxx.sh | 2 +- 49 files changed, 168 insertions(+), 133 deletions(-) diff --git a/NG-NEWS b/NG-NEWS index 452ecd9a3..78ab1c26b 100644 --- a/NG-NEWS +++ b/NG-NEWS @@ -127,6 +127,17 @@ Miscellaneous variable $(AM_MAKEFLAGS) has been removed, and its content is no more passed to recursive make invocations. +* The variables $(DISTFILES), $(DIST_COMMON) and $(DIST_SOURCES) had + never been documented in mainline Automake, and were always intended + to be internal variables. But that was not clear from their names. + So we have renamed rename like this: + + DISTFILES => am__dist_files + DIST_COMMON => am__dist_common + DIST_SOURCES => am__dist_sources + + Do not use any of these variables in your Makefiles! + ----- Copyright (C) 2012 Free Software Foundation, Inc. diff --git a/automake.in b/automake.in index fa30d6dd7..9c75d9cd0 100644 --- a/automake.in +++ b/automake.in @@ -226,7 +226,7 @@ my @libtool_files = qw(ltmain.sh config.guess config.sub); my @libtool_sometimes = qw(ltconfig ltcf-c.sh ltcf-cxx.sh ltcf-gcj.sh); # Commonly found files we look for and automatically include in -# DISTFILES. +# distributed files. my @common_files = (qw(ABOUT-GNU ABOUT-NLS AUTHORS BACKLOG COPYING COPYING.DOC COPYING.LIB COPYING.LESSER ChangeLog INSTALL NEWS README THANKS TODO @@ -418,7 +418,7 @@ my %configure_cond = (); # This maps extensions onto language names. my %extension_map = (); -# List of the DIST_COMMON files we discovered while reading +# List of the distributed files we discovered while reading # configure.ac. my $configure_dist_common = ''; @@ -3759,7 +3759,7 @@ sub handle_dist () # check that. But if the file is in a subdir without a Makefile, # we want to distribute it here if we are doing '.'. Ugly! # Also, in some corner cases, it's possible that the following code - # will cause the same file to appear in the $(DIST_COMMON) variables + # will cause the same file to appear in the $(am__dist_common) variables # of two distinct Makefiles; but this is not a problem, since the # 'distdir' target in 'lib/am/distdir.am' can deal with the same # file being distributed multiple times. @@ -3774,8 +3774,8 @@ sub handle_dist () } } - # We don't expected further attempts to modify DIST_COMMON after - # this point, so disallow it, for extra safety. + # We don't expected further attempts to modify $(am__dist_common) + # after this point, so disallow it, for extra safety. $handle_dist_run = 1; # Scan EXTRA_DIST to see if we need to distribute anything from a @@ -5381,7 +5381,7 @@ sub scan_autoconf_files () if -f $config_aux_dir . '/install.sh'; # Preserve dist_common for later. - $configure_dist_common = variable_value ('DIST_COMMON') || ''; + $configure_dist_common = variable_value ('am__dist_common') || ''; } @@ -6578,7 +6578,7 @@ sub read_am_file ($$) push (@include_stack, "\$\(top_srcdir\)/$path"); # Distribute any included file. - # Always use the $(top_srcdir) prefix in DIST_COMMON, + # Always use the $(top_srcdir) prefix in am__dist_common, # otherwise OSF make will implicitly copy the included # file in the build tree during "make distdir" to satisfy # the dependency. @@ -6589,7 +6589,7 @@ sub read_am_file ($$) { $path =~ s/\$\(srcdir\)\///; push (@include_stack, "\$\(srcdir\)/$path"); - # Always use the $(srcdir) prefix in DIST_COMMON, + # Always use the $(srcdir) prefix in am__dist_common, # otherwise OSF make will implicitly copy the included # file in the build tree during "make distdir" to satisfy # the dependency. @@ -7424,7 +7424,7 @@ sub locate_aux_dir () # &push_required_file ($DIR, $FILE, $FULLFILE) # -------------------------------------------------- -# Push the given file onto DIST_COMMON. +# Push the given file onto $(am__dist_common). sub push_required_file { my ($dir, $file, $fullfile) = @_; @@ -7499,7 +7499,8 @@ sub push_required_file else { prog_error "a Makefile in relative directory $relative_dir " . - "can't add files in directory $dir to DIST_COMMON"; + "can't add files in directory $dir to the list " . + "of distributed files"; } } @@ -7534,11 +7535,10 @@ sub required_file_check_or_copy ($$$) return if $found_it && (! $add_missing || ! $force_missing); - # If we've already looked for it, we're done. You might - # wonder why we don't do this before searching for the - # file. If we do that, then something like - # AC_OUTPUT(subdir/foo foo) will fail to put foo.in into - # DIST_COMMON. + # If we've already looked for it, we're done. You might wonder why + # we don't do this before searching for the file. If we do that, + # then something like AC_OUTPUT(subdir/foo foo) will fail to put + # 'foo.in' into the list of distributed files $(am__dist_common). if (! $found_it) { return if defined $required_file_not_found{$fullfile}; @@ -7825,8 +7825,8 @@ sub push_dist_common { prog_error "push_dist_common run after handle_dist" if $handle_dist_run; - Automake::Variable::define ('DIST_COMMON', VAR_AUTOMAKE, '+', TRUE, "@_", - '', INTERNAL, VAR_PRETTY); + Automake::Variable::define ('am__dist_common', VAR_AUTOMAKE, '+', + TRUE, "@_", '', INTERNAL, VAR_PRETTY); } @@ -7924,7 +7924,8 @@ sub generate_makefile ($$) define_pretty_variable ('SOURCES', TRUE, INTERNAL, @sources); if (! option 'no-dist') { - define_pretty_variable ('DIST_SOURCES', TRUE, INTERNAL, @dist_sources); + define_pretty_variable ('am__dist_sources', TRUE, INTERNAL, + @dist_sources); } handle_texinfo; diff --git a/lib/am/configure.am b/lib/am/configure.am index e0cd44317..ac816c460 100644 --- a/lib/am/configure.am +++ b/lib/am/configure.am @@ -81,7 +81,7 @@ endif %?TOPDIR_P% ## Avoid the "deleted header file" problem for the dependencies. ?HAVE-MAKEFILE-IN-DEPS?%MAKEFILE-IN-DEPS%: -DIST_COMMON += %MAKEFILE-AM% +am__dist_common += %MAKEFILE-AM% ## --------------------------- ## @@ -93,7 +93,7 @@ if %?TOPDIR_P% ## don't exist. This is especially important for configure, since it ## won't be created until autoconf is run -- which might be after ## automake is run. -DIST_COMMON += $(top_srcdir)/configure $(am__configure_deps) +am__dist_common += $(top_srcdir)/configure $(am__configure_deps) endif %?TOPDIR_P% $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) diff --git a/lib/am/data.am b/lib/am/data.am index b8b658800..2bed9aee3 100644 --- a/lib/am/data.am +++ b/lib/am/data.am @@ -95,5 +95,5 @@ endif %?INSTALL% ## -------------- ## if %?DIST% -DIST_COMMON += %DISTVAR% +am__dist_common += %DISTVAR% endif %?DIST% diff --git a/lib/am/distdir.am b/lib/am/distdir.am index 7fe451a83..273b4d6fb 100644 --- a/lib/am/distdir.am +++ b/lib/am/distdir.am @@ -14,14 +14,14 @@ ## You should have received a copy of the GNU General Public License ## along with this program. If not, see . -DISTFILES = $(call am__uniq, \ - $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)) +am__dist_files = $(call am__uniq, \ + $(am__dist_common) $(am__dist_sources) $(TEXINFOS) $(EXTRA_DIST)) -## Try to avoid repeated slashed in the $(DISTFILES) entries, to make the +## Try to avoid repeated slashed in the entries, to make the ## filtering in the 'am__dist_files_1' definition below more reliable. ## This idiom should compress up to four consecutive '/' characters in -## each $(DISTFILES) entry. -am__dist_files_1 = $(subst //,/,$(subst //,/,$(DISTFILES))) +## each $(am__dist_files) entry. +am__dist_files_1 = $(subst //,/,$(subst //,/,$(am__dist_files))) am__dist_files_2 = \ ## Files filtered out here require an ad-hoc "munging"; see the two @@ -40,25 +40,27 @@ am__dist_files_2 = \ ## situations that it's probably not worth worrying about. $(patsubst $(srcdir)/%, %, \ $(filter $(srcdir)/%, $(am__dist_files_1))) \ -## Also rewrite $(top_srcdir) (which sometimes appears in DISTFILES, and -## can be absolute) by $(top_builddir) (which is always relative). If -## needed, $(srcdir) will be prepended later by our VPATH-aware rules. +## Also rewrite $(top_srcdir) -- which can sometimes appear in +## $(am__dist_common), and can be absolute -- by $(top_builddir) +## (which is always relative). If needed, $(srcdir) will be +## prepended later by our VPATH-aware rules. ## The same caveats reported above apply. $(patsubst $(top_srcdir)/%, $(top_builddir)/%, \ $(filter $(top_srcdir)/%, $(am__dist_files_1))) ## Strip extra whitespaces, for more safety. -am__dist_files = $(strip $(am__dist_files_2)) - -## Given the pro-processing done above to 'am__dist_files', this -## definition ensures that we won't try to create the wrong directories -## when $(top_srcdir) or $(srcdir) appears in DISTFILES. For example, -## with EXTRA_DIST containing "$(srcdir)/subdir/file", this will allow -## our rules to correctly create "$(distdir)/subdir", and not +am__dist_files_cooked = $(strip $(am__dist_files_2)) + +## Given the pre-processing done above to the list of distributed files, +## this definition ensures that we won't try to create the wrong +## directories when $(top_srcdir) or $(srcdir) appears in some entry of +## the list of all distributed files. +## For example, with EXTRA_DIST containing "$(srcdir)/subdir/file", this +## will allow our rules to correctly create "$(distdir)/subdir", and not ## "$(distdir)/$(srcdir)/subdir" -- which, in a VPATH build where -## $(subdir) = .., would be the build directory! +## "$(subdir) = ..", would be the build directory! am__dist_parent_dirs = $(call am__uniq, \ - $(filter-out ., $(patsubst ./%,%,$(dir $(am__dist_files))))) + $(filter-out ., $(patsubst ./%,%,$(dir $(am__dist_files_cooked))))) if %?TOPDIR_P% distdir = $(PACKAGE)-$(VERSION) @@ -118,7 +120,7 @@ if %?SUBDIRS% AM_RECURSIVE_TARGETS += distdir endif %?SUBDIRS% -distdir: $(DISTFILES) +distdir: $(am__dist_files) ## ## For Gnits users, this is pretty handy. Look at 15 lines ## in case some explanatory text is desirable. @@ -175,7 +177,7 @@ endif %?TOPDIR_P% ## There are situations in which 'ln' can fail. For instance a file to ## distribute could actually be a cross-filesystem symlink -- this can ## easily happen if "gettextize" was run on the distribution. - @lst='$(am__dist_files)'; for file in $$lst; do \ + @lst='$(am__dist_files_cooked)'; for file in $$lst; do \ ## Always look for the file or directory to distribute in the build ## directory first, in VPATH spirit. if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ @@ -199,14 +201,11 @@ endif %?TOPDIR_P% fi; \ cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ else \ -## Test for file existence because sometimes: -## - a file gets included in DISTFILES twice (for example, this happens -## when a single source file is used in building more than one -## program), or -## - a single auxiliary file is distributed from several Makefiles at -## once (see automake bug#9546 and bug#9651, and the follow-up commits -## v1.11-1219-g326ecba, v1.11-1220-g851b1ae and v1.11-1221-gdccae6a). -## See also test 'dist-repeated.test'. +## Test for file existence because sometimes a single auxiliary file +## is distributed from several Makefiles at once (see automake bug#9546 +## and bug#9651, and the follow-up commits 'v1.11-1219-g326ecba', +## 'v1.11-1220-g851b1ae' and 'v1.11-1221-gdccae6a'). See also test +## 't/dist-repeated.sh'. test -f "$(distdir)/$$file" \ || cp -p $$d/$$file "$(distdir)/$$file" \ || exit 1; \ diff --git a/lib/am/java.am b/lib/am/java.am index 6c163b56f..289013c97 100644 --- a/lib/am/java.am +++ b/lib/am/java.am @@ -88,5 +88,5 @@ clean-%NDIR%JAVA: ## -------------- ## if %?DIST% -DIST_COMMON += %DISTVAR% +am__dist_common += %DISTVAR% endif %?DIST% diff --git a/lib/am/lisp.am b/lib/am/lisp.am index 72bcf9aeb..d5dfaac7a 100644 --- a/lib/am/lisp.am +++ b/lib/am/lisp.am @@ -145,5 +145,5 @@ clean-lisp: ## -------------- ## if %?DIST% -DIST_COMMON += %DISTVAR% +am__dist_common += %DISTVAR% endif %?DIST% diff --git a/lib/am/python.am b/lib/am/python.am index cab61294a..cf1d9b01a 100644 --- a/lib/am/python.am +++ b/lib/am/python.am @@ -125,5 +125,5 @@ endif %?INSTALL% ## -------------- ## if %?DIST% -DIST_COMMON += %DISTVAR% +am__dist_common += %DISTVAR% endif %?DIST% diff --git a/lib/am/scripts.am b/lib/am/scripts.am index 64e093e64..8bc8c0a52 100644 --- a/lib/am/scripts.am +++ b/lib/am/scripts.am @@ -94,7 +94,7 @@ endif %?INSTALL% ## -------------- ## if %?DIST% -DIST_COMMON += %DISTVAR% +am__dist_common += %DISTVAR% endif %?DIST% diff --git a/lib/am/texi-vers.am b/lib/am/texi-vers.am index a13b7adcd..4f2495c5a 100644 --- a/lib/am/texi-vers.am +++ b/lib/am/texi-vers.am @@ -14,7 +14,7 @@ ## You should have received a copy of the GNU General Public License ## along with this program. If not, see . -DIST_COMMON += %VTEXI% %STAMPVTI% +am__dist_common += %VTEXI% %STAMPVTI% ## Don't give this rule a command (even '@:'). ## %STAMPVTI% is always newer than %VTEXI%, so this rule is always diff --git a/syntax-checks.mk b/syntax-checks.mk index 86a1faef8..9f108eed9 100644 --- a/syntax-checks.mk +++ b/syntax-checks.mk @@ -34,6 +34,7 @@ xtests := $(shell \ xdefs = $(srcdir)/defs $(srcdir)/defs-static.in ams := $(shell find $(srcdir) -name '*.dir' -prune -o -name '*.am' -print) +pms := $(dist_perllib_DATA) # Some simple checks, and then ordinary check. These are only really # guaranteed to work on my machine. @@ -60,6 +61,9 @@ sc_tests_make_can_chain_suffix_rules \ sc_tests_make_dont_do_useless_vpath_rebuilds \ sc_no_dotmake_target \ sc_no_am_makeflags \ +sc_no_DISTFILES \ +sc_no_DIST_COMMON \ +sc_no_DIST_SOURCES \ sc_tests_no_make_e \ sc_docs_no_make_e \ sc_make_simple_include \ @@ -296,6 +300,25 @@ sc_no_am_makeflags: exit 1; \ fi +# Modern names for internal variables that had a bad name once. +modern_DISTFILES = am__dist_files +modern_DIST_COMMON = am__dist_common +modern_DIST_SOURCES = am__dist_sources + +sc_no_DISTFILES sc_no_DIST_COMMON sc_no_DIST_SOURCES: sc_no_% : + @files="\ + $(xtests) \ + $(pms) \ + $(ams) \ + $(srcdir)/automake.in \ + $(srcdir)/doc/*.texi \ + "; \ + if grep -F '$*' $$files; then \ + echo "'\$$($*)' is obsolete and no more used." >&2; \ + echo "You should use '$(modern_$*)' instead." >&2; \ + exit 1; \ + fi + ## "make -e" is brittle and unsafe, since it let *all* the environment ## win over the macro definitions in the Makefiles. We needed it when ## we couldn't assume GNU make, but now that the tide has turned, it's diff --git a/t/autodist-acconfig-no-subdir.sh b/t/autodist-acconfig-no-subdir.sh index d4ad1d960..18cd5f46a 100755 --- a/t/autodist-acconfig-no-subdir.sh +++ b/t/autodist-acconfig-no-subdir.sh @@ -40,8 +40,8 @@ cat > sub/Makefile.am <<'END' acconfig.h: echo target $@ should not be built >&2; exit 1 check-local: - echo $(DISTFILES) | grep 'acconfig\.h' && exit 1; : - echo $(DIST_COMMON) | grep 'acconfig\.h' && exit 1; : + echo $(am__dist_common) $(am__dist_files) \ + | grep 'acconfig\.h' && exit 1; : END : > sub/acconfig.h diff --git a/t/autodist-acconfig.sh b/t/autodist-acconfig.sh index 18b280c3c..55884f77f 100755 --- a/t/autodist-acconfig.sh +++ b/t/autodist-acconfig.sh @@ -28,7 +28,7 @@ cat > Makefile.am <<'END' .PHONY: test test: distdir ls -l $(distdir) - echo ' ' $(DIST_COMMON) ' ' | grep '[ /]acconfig\.h ' + echo ' ' $(am__dist_common) ' ' | grep '[ /]acconfig\.h ' test -f $(distdir)/acconfig.h END diff --git a/t/autodist-aclocal-m4.sh b/t/autodist-aclocal-m4.sh index 6108f5743..448634c54 100755 --- a/t/autodist-aclocal-m4.sh +++ b/t/autodist-aclocal-m4.sh @@ -34,8 +34,8 @@ cat > Makefile.am <<'END' test: distdir ls -l $(distdir) test ! -f $(distdir)/aclocal.m4 - echo $(DISTFILES) | grep 'aclocal\.m4' && exit 1; : - echo $(DIST_COMMON) | grep 'aclocal\.m4' && exit 1; : + echo $(am__dist_files) $(am__dist_common) \ + | grep 'aclocal\.m4' && exit 1; : check-local: test END diff --git a/t/autodist-config-headers.sh b/t/autodist-config-headers.sh index 65888f813..798284ae6 100755 --- a/t/autodist-config-headers.sh +++ b/t/autodist-config-headers.sh @@ -30,12 +30,12 @@ cat > Makefile.am <<'END' .PHONY: test test: distdir ls -l $(distdir) $(distdir)/sub - echo ' ' $(DIST_COMMON) ' ' | grep '[ /]config\.h\.bot ' - echo ' ' $(DIST_COMMON) ' ' | grep '[ /]config\.h\.top ' - echo ' ' $(DIST_COMMON) ' ' | grep '[ /]cfg2\.h\.bot ' - echo ' ' $(DIST_COMMON) ' ' | grep '[ /]cfg2\.h\.top ' - echo ' ' $(DIST_COMMON) ' ' | grep '[ /]sub/config\.h\.bot ' - echo ' ' $(DIST_COMMON) ' ' | grep '[ /]sub/config\.h\.top ' + echo ' ' $(am__dist_common) ' ' | grep '[ /]config\.h\.bot ' + echo ' ' $(am__dist_common) ' ' | grep '[ /]config\.h\.top ' + echo ' ' $(am__dist_common) ' ' | grep '[ /]cfg2\.h\.bot ' + echo ' ' $(am__dist_common) ' ' | grep '[ /]cfg2\.h\.top ' + echo ' ' $(am__dist_common) ' ' | grep '[ /]sub/config\.h\.bot ' + echo ' ' $(am__dist_common) ' ' | grep '[ /]sub/config\.h\.top ' test -f $(distdir)/config.h.bot test -f $(distdir)/config.h.top test -f $(distdir)/cfg2.h.bot diff --git a/t/autodist-configure-no-subdir.sh b/t/autodist-configure-no-subdir.sh index cc53cafcc..b97474838 100755 --- a/t/autodist-configure-no-subdir.sh +++ b/t/autodist-configure-no-subdir.sh @@ -52,8 +52,8 @@ configure.ac: configure.in: $(dontbuild) check-local: - echo $(DISTFILES) | grep 'configure' && exit 1; : - echo $(DIST_COMMON) | grep 'configure' && exit 1; : + echo $(am__dist_files) $(am__dist_common) \ + | grep 'configure' && exit 1; : END : > sub/configure.ac diff --git a/t/autodist-stamp-vti.sh b/t/autodist-stamp-vti.sh index 4db1f141e..33ceb1a70 100755 --- a/t/autodist-stamp-vti.sh +++ b/t/autodist-stamp-vti.sh @@ -30,7 +30,7 @@ info_TEXINFOS = foo.texi .PHONY: test test: all distdir ls -l $(distdir) - echo ' ' $(DIST_COMMON) ' ' | grep '[ /]stamp-vti ' + echo ' ' $(am__dist_common) ' ' | grep '[ /]stamp-vti ' test -f $(distdir)/stamp-vti END diff --git a/t/autodist-subdir.sh b/t/autodist-subdir.sh index 5e1f044e9..ad99d91a3 100755 --- a/t/autodist-subdir.sh +++ b/t/autodist-subdir.sh @@ -48,8 +48,8 @@ cat > Makefile.am <<'END' SUBDIRS = sub check-local: ## For debugging. - @echo DIST_COMMON: - @for f in $(DIST_COMMON); do echo " $$f"; done + @echo am__dist_common: + @for f in $(am__dist_common); do echo " $$f"; done @echo DISTDIR: @ls -l $(distdir) | sed 's/^/ /' ## Now the checks. @@ -66,8 +66,8 @@ cat > sub/Makefile.am <<'END' include distfiles.am check-local: ## For debugging. - @echo DIST_COMMON: - @for f in $(DIST_COMMON); do echo " $$f"; done + @echo am__dist_common: + @for f in $(am__dist_common); do echo " $$f"; done @echo DISTDIR: @ls -l $(distdir) | sed 's/^/ /' ## Now the checks. @@ -76,7 +76,7 @@ check-local: ## Some filenames might contain dots, but this won't cause spurious ## failures, and "spurious successes" are so unlikely that they're ## not worth worrying about. - echo ' ' $(DIST_COMMON) ' ' | grep "[ /]$$f " >/dev/null \ + echo ' ' $(am__dist_common) ' ' | grep "[ /]$$f " >/dev/null \ || { echo $$f: distcom fail >&2; exit 1; }; \ done END diff --git a/t/autodist.sh b/t/autodist.sh index e6435c54c..1b9764ded 100755 --- a/t/autodist.sh +++ b/t/autodist.sh @@ -47,8 +47,8 @@ cat > Makefile.am <<'END' include distfiles.am check-local: ## For debugging. - @echo DIST_COMMON: - @for f in $(DIST_COMMON); do echo " $$f"; done + @echo am__dist_common: + @for f in $(am__dist_common); do echo " $$f"; done @echo DISTDIR: @ls -l $(distdir) | sed 's/^/ /' ## Now the checks. @@ -59,7 +59,7 @@ check-local: ## Some filenames might contain dots, but this won't cause spurious ## failures, and "spurious successes" are so unlikely that they're ## not worth worrying about. - echo ' ' $(DIST_COMMON) ' ' | grep "[ /]$$f " >/dev/null \ + echo ' ' $(am__dist_common) ' ' | grep "[ /]$$f " >/dev/null \ || { echo $$f: distcom fail >&2; exit 1; }; \ done END diff --git a/t/colon5.sh b/t/colon5.sh index 5a0ef379b..6ce2e2b5d 100755 --- a/t/colon5.sh +++ b/t/colon5.sh @@ -39,7 +39,7 @@ test-grep: grep '=GrEp$(empty)Me_am=' Makefile grep '=GrEp$(empty)Me_dep=' Makefile test-distcommon: - echo ' ' $(DIST_COMMON) ' ' | grep '[ /]Makefile.dep ' + echo ' ' $(am__dist_common) ' ' | grep '[ /]Makefile.dep ' test-distdir: distdir test -f $(distdir)/Makefile.dep END diff --git a/t/colon7.sh b/t/colon7.sh index 1b84d8046..0d3cc1b9b 100755 --- a/t/colon7.sh +++ b/t/colon7.sh @@ -33,10 +33,10 @@ mkdir subdir : > Makefile.am : > subdir/foo cat > subdir/Makefile.am << 'END' -# DIST_COMMON should contain 'foo', not 'subdir/foo'. +# am__dist_common should contain 'foo', not 'subdir/foo'. test: - case '$(DIST_COMMON)' in *subdir/foo*) exit 1;; *) exit 0;; esac - echo ' ' $(DIST_COMMON) ' ' | grep '[ /]foo ' + case '$(am__dist_common)' in *subdir/foo*) exit 1;; *) exit 0;; esac + echo ' ' $(am__dist_common) ' ' | grep '[ /]foo ' .PHONY: test END diff --git a/t/confh.sh b/t/confh.sh index 9dc2f15b1..1ba8534c6 100755 --- a/t/confh.sh +++ b/t/confh.sh @@ -27,8 +27,8 @@ END cat > Makefile.am << 'END' .PHONY: test1 test2 test1: - @echo DIST_COMMON = $(DIST_COMMON) - echo ' ' $(DIST_COMMON) ' ' | grep '[ /]acconfig\.h ' + @echo am__dist_common = $(am__dist_common) + echo ' ' $(am__dist_common) ' ' | grep '[ /]acconfig\.h ' test2: distdir ls -l $(distdir)/* test -f $(distdir)/acconfig.h diff --git a/t/confh8.sh b/t/confh8.sh index 2feaae582..50bf0578b 100755 --- a/t/confh8.sh +++ b/t/confh8.sh @@ -27,11 +27,11 @@ END cat > Makefile.am << 'END' .PHONY: test0 test1 test2 test0: - @echo DIST_COMMON = $(DIST_COMMON) - echo ' ' $(DIST_COMMON) ' ' | grep '[ /]one\.h\.in ' - echo ' ' $(DIST_COMMON) ' ' | grep '[ /]two\.h\.in ' + @echo am__dist_common = $(am__dist_common) + echo ' ' $(am__dist_common) ' ' | grep '[ /]one\.h\.in ' + echo ' ' $(am__dist_common) ' ' | grep '[ /]two\.h\.in ' : Processed header files should not be distributed. - if echo ' ' $(DIST_COMMON) ' ' | grep '\.h '; then \ + if echo ' ' $(am__dist_common) ' ' | grep '\.h '; then \ exit 1; \ else \ exit 0; \ diff --git a/t/depdist.sh b/t/depdist.sh index e81e09783..39ad48eff 100755 --- a/t/depdist.sh +++ b/t/depdist.sh @@ -43,7 +43,7 @@ SUBDIRS = subdir check-local: test1 test2 .PHONY: test1 test2 test1: - echo ' ' $(DIST_COMMON) ' ' | grep '[ /]config/depcomp ' + echo ' ' $(am__dist_common) ' ' | grep '[ /]config/depcomp ' test2: distdir ls -l $(distdir)/* test -f $(distdir)/config/depcomp diff --git a/t/dist-auxfile.sh b/t/dist-auxfile.sh index 9f7e8eee7..b8db708eb 100755 --- a/t/dist-auxfile.sh +++ b/t/dist-auxfile.sh @@ -47,10 +47,10 @@ END SUBDIRS = subdir test: distdir ls -l $(distdir) $(distdir)/* ;: For debugging. - @echo DIST_COMMON = $(DIST_COMMON) ;: Likewise. - echo ' ' $(DIST_COMMON) ' ' | grep '[ /]$(auxdir)foo.txt ' - echo ' ' $(DIST_COMMON) ' ' | grep '[ /]$(auxdir)bar.sh ' - echo ' ' $(DIST_COMMON) ' ' | grep '[ /]$(auxdir)zardoz ' + @echo am__dist_common = $(am__dist_common) ;: Likewise. + echo ' ' $(am__dist_common) ' ' | grep '[ /]$(auxdir)foo.txt ' + echo ' ' $(am__dist_common) ' ' | grep '[ /]$(auxdir)bar.sh ' + echo ' ' $(am__dist_common) ' ' | grep '[ /]$(auxdir)zardoz ' test -f $(distdir)/$(auxdir)foo.txt test -f $(distdir)/$(auxdir)bar.sh test -f $(distdir)/$(auxdir)zardoz diff --git a/t/distcom-subdir.sh b/t/distcom-subdir.sh index 4da74d05c..46e516a63 100755 --- a/t/distcom-subdir.sh +++ b/t/distcom-subdir.sh @@ -52,7 +52,7 @@ test -f depcomp # FIXME: 'distcom*.test' files should be factored out in a common # FIXME: subroutine in 'defs'... sed -n -e " - /^DIST_COMMON =.*\\\\$/ { + /^am__dist_common =.*\\\\$/ { :loop p n diff --git a/t/distcom2.sh b/t/distcom2.sh index 4b86f928d..141cd79aa 100755 --- a/t/distcom2.sh +++ b/t/distcom2.sh @@ -14,7 +14,7 @@ # You should have received a copy of the GNU General Public License # along with this program. If not, see . -# Test to make sure that depcomp and compile are added to DIST_COMMON. +# Test to make sure that depcomp and compile are added to am__dist_common. # Report from Pavel Roskin. Report of problems with '--no-force' from # Scott James Remnant (Debian #206299) @@ -54,7 +54,7 @@ for opt in '' --no-force; do # FIXME: 'distcom*.test' files should be factored out in a common # FIXME: subroutine in 'defs'... sed -n -e " - /^DIST_COMMON =.*\\\\$/ { + /^am__dist_common =.*\\\\$/ { :loop p n @@ -73,7 +73,7 @@ for opt in '' --no-force; do cat subdir/dc.txt # Likewise. $FGREP ' $(top_srcdir)/depcomp ' subdir/dc.txt - # The 'compile' script will be listed in the DIST_COMMON of the top-level + # The 'compile' script will be listed in the am__dist_common of the top-level # Makefile because it's required in configure.ac (by AM_PROG_CC_C_O). $FGREP ' $(top_srcdir)/compile ' dc.txt || $FGREP ' compile ' dc.txt diff --git a/t/distcom3.sh b/t/distcom3.sh index 34ad7096e..8ed0809a4 100755 --- a/t/distcom3.sh +++ b/t/distcom3.sh @@ -36,7 +36,7 @@ $AUTOMAKE --add-missing --gnu >output 2>&1 || { cat output; Exit 1; } cat output grep README output && Exit 1 -sed -n -e '/^DIST_COMMON =.*\\$/ { +sed -n -e '/^am__dist_common =.*\\$/ { :loop p n @@ -46,7 +46,7 @@ sed -n -e '/^DIST_COMMON =.*\\$/ { t loop p n - }' -e '/^DIST_COMMON =/ p' Makefile.in | grep README + }' -e '/^am__dist_common =/ p' Makefile.in | grep README # Should warn about missing README. diff --git a/t/distcom4.sh b/t/distcom4.sh index 18f8b3385..c8cc2c5fd 100755 --- a/t/distcom4.sh +++ b/t/distcom4.sh @@ -45,7 +45,8 @@ mkdir tests cat > Makefile.am << 'END' .PHONY: test1 test 2 test1: - for x in $(DISTFILES); do echo $$x; done | grep 'tests/' > lst + for x in $(am__dist_files); do echo $$x; done \ + | grep 'tests/' > lst cat lst # For debugging. test `wc -l tests/Makefile.am <<'END' check-local: - for x in $(DISTFILES); do echo $$x; done | grep wrapper.in > lst + for x in $(am__dist_files); do echo $$x; done \ + | grep wrapper.in > lst cat lst # For debugging. test `wc -l Makefile.am << 'END' info_TEXINFOS = textutils.texi .PHONY: test1 test2 test1: - @echo DISTFILES = $(DISTFILES) - echo ' ' $(DISTFILES) ' ' | grep '[ /]texinfo\.tex ' + @echo am__dist_files = $(am__dist_files) + echo ' ' $(am__dist_files) ' ' | grep '[ /]texinfo\.tex ' test2: distdir ls -l $(distdir) test -f $(distdir)/texinfo.tex diff --git a/t/txinfo2.sh b/t/txinfo2.sh index 0daebd9a8..70a9e945d 100755 --- a/t/txinfo2.sh +++ b/t/txinfo2.sh @@ -27,8 +27,8 @@ cat > Makefile.am << 'END' info_TEXINFOS = textutils.texi .PHONY: test test: - @echo DISTFILES = $(DISTFILES) - case '$(DISTFILES)' in *'~'*) exit 1;; *) exit 0;; esac + @echo am__dist_files = $(am__dist_files) + case '$(am__dist_files)' in *'~'*) exit 1;; *) exit 0;; esac END : > texinfo.tex diff --git a/t/txinfo8.sh b/t/txinfo8.sh index 4b186bc38..6e5403ab1 100755 --- a/t/txinfo8.sh +++ b/t/txinfo8.sh @@ -32,8 +32,8 @@ cat > Makefile.am << 'END' info_TEXINFOS = textutils.texi .PHONY: test1 test2 test1: - @echo DISTFILES = $(DISTFILES) - echo ' ' $(DISTFILES) ' ' | grep '[ /]auxdir/texinfo\.tex ' + @echo am__dist_files = $(am__dist_files) + echo ' ' $(am__dist_files) ' ' | grep '[ /]auxdir/texinfo\.tex ' test2: distdir ls -l $(distdir)/* test -f $(distdir)/auxdir/texinfo.tex diff --git a/t/vtexi3.sh b/t/vtexi3.sh index 9dd3e6712..c8736eafe 100755 --- a/t/vtexi3.sh +++ b/t/vtexi3.sh @@ -41,7 +41,7 @@ cat > Makefile.am << 'END' info_TEXINFOS = foobar.texi quux.texi zardoz.texi .PHONY: echo-distfiles echo-distfiles: - @echo ' ' $(DISTFILES) ' ' + @echo ' ' $(am__dist_files) ' ' END cat > foobar.texi << 'END' @@ -94,7 +94,7 @@ do_check () vmonth=`grep '^@set UPDATED ' $srcdir/$vfile.texi | awk '{print $4, $5}'` grep "^@set UPDATED-MONTH $vmonth$" $srcdir/$vfile.texi # Check that the vers*.texi file is distributed according - # to $(DISTFILES). + # to $(am__dist_files). $MAKE echo-distfiles # For debugging. $MAKE -s echo-distfiles | grep "[ /]$vfile\\.texi" } diff --git a/t/vtexi4.sh b/t/vtexi4.sh index 6038444b5..8023de2ed 100755 --- a/t/vtexi4.sh +++ b/t/vtexi4.sh @@ -62,8 +62,8 @@ test-grepinfo: cat $(srcdir)/foo.info | grep 'GREPDATE=$(my_date_rx)=' cat $(srcdir)/foo.info | grep 'GREPMONTH=$(my_month_rx)=' test-distfiles: - @echo DISTFILES = $(DISTFILES) - echo ' ' $(DISTFILES) ' ' | grep '[ /]version.texi ' + @echo am__dist_files = $(am__dist_files) + echo ' ' $(am__dist_files) ' ' | grep '[ /]version.texi ' test-distdir: distdir ls -l $(distdir) diff $(srcdir)/version.texi $(distdir)/version.texi diff --git a/t/yacc-basic.sh b/t/yacc-basic.sh index 8bc8c4b92..732546147 100755 --- a/t/yacc-basic.sh +++ b/t/yacc-basic.sh @@ -34,7 +34,7 @@ bar_YFLAGS = -v .PHONY: echo-distcom echo-distcom: - @echo ' ' $(DIST_COMMON) ' ' + @echo ' ' $(am__dist_common) ' ' END cat > parse.y << 'END' diff --git a/t/yacc-cxx.sh b/t/yacc-cxx.sh index 80ac2ee29..246f1ad90 100755 --- a/t/yacc-cxx.sh +++ b/t/yacc-cxx.sh @@ -38,7 +38,7 @@ foo4_YFLAGS = $(foo3_YFLAGS) .PHONY: echo-distcom echo-distcom: - @echo ' ' $(DIST_COMMON) ' ' + @echo ' ' $(am__dist_common) ' ' END cat > parse1.yy << 'END' diff --git a/t/yacc-d-basic.sh b/t/yacc-d-basic.sh index e82f335f1..a374df0a4 100755 --- a/t/yacc-d-basic.sh +++ b/t/yacc-d-basic.sh @@ -39,7 +39,7 @@ bin_PROGRAMS = zardoz zardoz_SOURCES = parse.y main.c .PHONY: echo-distcom echo-distcom: - @echo ' ' $(DIST_COMMON) ' ' + @echo ' ' $(am__dist_common) ' ' END cp foo/Makefile.am bar/Makefile.am cp foo/Makefile.am baz/Makefile.am diff --git a/t/yacc-d-cxx.sh b/t/yacc-d-cxx.sh index 5ec199041..f1ec2c376 100755 --- a/t/yacc-d-cxx.sh +++ b/t/yacc-d-cxx.sh @@ -66,7 +66,7 @@ mkdir foo bar baz qux baz/sub cat > Makefile.am <<'END' .PHONY: echo-distcom echo-distcom: - @echo ' ' $(DIST_COMMON) ' ' + @echo ' ' $(am__dist_common) ' ' END cp Makefile.am foo/Makefile.am cp Makefile.am bar/Makefile.am -- 2.47.2