summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--NG-NEWS5
-rw-r--r--automake.in7
-rw-r--r--doc/automake-ng.texi99
-rwxr-xr-xt/add-missing.tap21
-rwxr-xr-xt/ar-lib7.sh34
-rwxr-xr-xt/dist-auxfile.sh2
-rwxr-xr-xt/license2.sh7
-rwxr-xr-xt/mdate.sh37
-rwxr-xr-xt/missing-auxfile-stops-makefiles-creation.sh65
-rwxr-xr-xt/per-target-flags.sh9
-rwxr-xr-xt/python.sh4
11 files changed, 67 insertions, 223 deletions
diff --git a/NG-NEWS b/NG-NEWS
index ad9ef179b..498057500 100644
--- a/NG-NEWS
+++ b/NG-NEWS
@@ -395,6 +395,11 @@ Miscellaneous
the files listed in $(BUILT_SOURCES) will be built not only before the
"all", "check" or "install" targets, but before *any* target.
+* Automake-NG *always* install install missing required auxiliary file
+ and scripts (e.g., 'install-sh', or 'texinfo.tex' if info_TEXINFOS is
+ used). So, it always behaves like mainline Automake does when the
+ '--add-missing' option is passed to it.
+
-----
Copyright (C) 2012 Free Software Foundation, Inc.
diff --git a/automake.in b/automake.in
index f37e102d4..d5782e842 100644
--- a/automake.in
+++ b/automake.in
@@ -292,7 +292,8 @@ my $force_generation = 1;
my $symlink_exists = (eval 'symlink ("", "");', $@ eq '');
# TRUE if missing standard files should be installed.
-my $add_missing = 0;
+# ALWAYS TRUE NOW!
+my $add_missing = 1;
# TRUE if we should copy missing files; otherwise symlink if possible.
my $copy_missing = 0;
@@ -7067,7 +7068,9 @@ sub parse_arguments ()
'i|ignore-deps' => sub { $ignore_deps = 1; },
'no-force' => sub { $force_generation = 0; },
'f|force-missing' => \$force_missing,
- 'a|add-missing' => \$add_missing,
+ # Always true these days. The option is still recognized as a
+ # no-op only for compatibility with mainline automake.
+ 'a|add-missing' => sub { },
'c|copy' => \$copy_missing,
'v|verbose' => sub { setup_channel 'verb', silent => 0; },
'W|warnings=s' => \@warnings,
diff --git a/doc/automake-ng.texi b/doc/automake-ng.texi
index 37d251093..f6b121565 100644
--- a/doc/automake-ng.texi
+++ b/doc/automake-ng.texi
@@ -161,6 +161,7 @@ General ideas
* General Operation:: General operation of Automake
* Strictness:: Standards conformance checking
+* Auxiliary files:: Automatic installation of auxiliary files
* Uniform:: The Uniform Naming Scheme
* Length Limitations:: Staying below the command line length limit
* Canonicalization:: How derived variables are named
@@ -1783,6 +1784,7 @@ understand how Automake works.
@menu
* General Operation:: General operation of Automake
* Strictness:: Standards conformance checking
+* Auxiliary files:: Automatic installation of auxiliary files
* Uniform:: The Uniform Naming Scheme
* Length Limitations:: Staying below the command line length limit
* Canonicalization:: How derived variables are named
@@ -1965,6 +1967,29 @@ standard is actually published (which may never happen).
@xref{Gnits}, for more information on the precise implications of the
strictness level.
+@node Auxiliary files
+@section Automatic installation of auxiliary files
+
+Automake requires certain common files to exist in certain situations;
+for instance, @file{config.guess} is required if @file{configure.ac}
+invokes @code{AC_CANONICAL_HOST}. Automake is distributed with several
+of these files (@pxref{Auxiliary Programs}); @command{automake} will
+automatically add the missing required files to the package, whenever
+needed.
+By default Automake tries to make a symbolic link pointing to its own
+copy of the missing file; this can be changed with @option{--copy}.
+
+Many of the potentially-missing files are common scripts whose
+location may be specified via the @code{AC_CONFIG_AUX_DIR} macro.
+Therefore, @code{AC_CONFIG_AUX_DIR}'s setting affects whether a
+file is considered missing, and where the missing file is added
+(@pxref{Optional}).
+
+In some strictness modes, additional files are installed, see
+@ref{Gnits} for more information.
+
+@cindex auxiliary files, automatic installation
+@cindex Automatic installation of auxiliary files
@node Uniform
@section The Uniform Naming Scheme
@@ -2416,9 +2441,8 @@ zardoz_LDADD = $(LIBOBJS)
info_TEXINFOS = zardoz.texi
@end example
-Now you can run @samp{automake --add-missing} to generate your
-@file{Makefile.in} and grab any auxiliary files you might need, and
-you're done!
+Now you can run @samp{automake} to generate your @file{Makefile.in} and
+grab any auxiliary files you might need, and you're done!
@node true
@@ -2552,28 +2576,6 @@ have to run @command{autoconf} yourself for this purpose.
@cindex @file{config.guess}
@table @code
-@item -a
-@itemx --add-missing
-@opindex -a
-@opindex --add-missing
-Automake requires certain common files to exist in certain situations;
-for instance, @file{config.guess} is required if @file{configure.ac} invokes
-@code{AC_CANONICAL_HOST}. Automake is distributed with several of these
-files (@pxref{Auxiliary Programs}); this option will cause the missing
-ones to be automatically added to the package, whenever possible. In
-general if Automake tells you a file is missing, try using this option.
-By default Automake tries to make a symbolic link pointing to its own
-copy of the missing file; this can be changed with @option{--copy}.
-
-Many of the potentially-missing files are common scripts whose
-location may be specified via the @code{AC_CONFIG_AUX_DIR} macro.
-Therefore, @code{AC_CONFIG_AUX_DIR}'s setting affects whether a
-file is considered missing, and where the missing file is added
-(@pxref{Optional}).
-
-In some strictness modes, additional files are installed, see @ref{Gnits}
-for more information.
-
@item --libdir=@var{dir}
@opindex --libdir
Look for Automake data files in directory @var{dir} instead of in the
@@ -2589,17 +2591,17 @@ scripts and data files (like e.g., @file{texinfo.texi} and
@opindex -c
@itemx --copy
@opindex --copy
-When used with @option{--add-missing}, causes installed files to be
-copied. The default is to make a symbolic link.
+Causes standard files (if any) to be copied. The default is to make a
+symbolic link.
@item -f
@opindex -f
@itemx --force-missing
@opindex --force-missing
-When used with @option{--add-missing}, causes standard files to be reinstalled
-even if they already exist in the source tree. This involves removing
-the file from the source tree before creating the new symlink (or, with
-@option{--copy}, copying the new file).
+Causes standard files to be reinstalled even if they already exist in
+the source tree. This involves removing the file from the source tree
+before creating the new symlink (or, with @option{--copy}, copying the
+new file).
@item --foreign
@opindex --foreign
@@ -6845,7 +6847,7 @@ dependencies are computed by running all compilations through a
special wrapper program called @command{depcomp}. @command{depcomp}
understands how to coax many different C and C++ compilers into
generating dependency information in the format it requires.
-@samp{automake -a} will install @command{depcomp} into your source
+@samp{automake} will install @command{depcomp} into your source
tree for you. If @command{depcomp} can't figure out how to properly
invoke your compiler, dependency tracking will simply be disabled for
your build.
@@ -7800,8 +7802,7 @@ was last modified.
The @file{version.texi} support requires the @command{mdate-sh}
script; this script is supplied with Automake and automatically
-included when @command{automake} is invoked with the
-@option{--add-missing} option.
+included when @command{automake} is invoked.
If you have multiple Texinfo files, and you want to use the
@file{version.texi} feature, then you have to have a separate version
@@ -7828,8 +7829,8 @@ the same directory as the @file{Makefile.am} file that lists the
@file{.texi} files. If you used @code{AC_CONFIG_AUX_DIR} in
@file{configure.ac} (@pxref{Input, , Finding `configure' Input,
autoconf, The Autoconf Manual}), then @file{texinfo.tex} is looked for
-there. In both cases, @command{automake} then supplies @file{texinfo.tex} if
-@option{--add-missing} is given, and takes care of its distribution.
+there. In both cases, @command{automake} then supplies @file{texinfo.tex}
+and takes care of its distribution.
However, if you set the @code{TEXINFO_TEX} variable (see below),
it overrides the location of the file and turns off its installation
into the source as well as its distribution.
@@ -8312,7 +8313,7 @@ in @file{configure.ac}). Also, files that are read by @command{configure}
Autoconf macros such as @code{AC_CONFIG_FILES} and siblings) are
automatically distributed. Files included in a @file{Makefile.am} (using
@code{include}) or in @file{configure.ac} (using @code{m4_include}), and
-helper scripts installed with @samp{automake --add-missing} are also
+helper scripts installed by @samp{automake} itself are also
distributed.
@vindex EXTRA_DIST
@@ -10809,7 +10810,7 @@ The files @file{INSTALL}, @file{NEWS}, @file{README}, @file{AUTHORS},
and @file{ChangeLog}, plus one of @file{COPYING.LIB}, @file{COPYING.LESSER}
or @file{COPYING}, are required at the topmost directory of the package.
-If the @option{--add-missing} option is given, @command{automake} will
+@command{automake} will by default
add a generic version of the @file{INSTALL} file as well as the
@file{COPYING} file containing the text of the current version of the
GNU General Public License existing at the time of this Automake release
@@ -11259,10 +11260,10 @@ Automake places no restrictions on the distribution of the resulting
distribute their work under terms like those of the GPL, but doing so
is not required to use Automake.
-Some of the files that can be automatically installed via the
-@option{--add-missing} switch do fall under the GPL@. However, these also
-have a special exception allowing you to distribute them with your
-package, regardless of the licensing you choose.
+Some of the files that can be automatically installed bu @command{automake}
+do fall under the GPL@. However, these also have a special exception
+allowing you to distribute them with your package, regardless of the
+licensing you choose.
@node API Versioning
@@ -11343,12 +11344,12 @@ Automake maintains three kind of files in a package.
@item auxiliary tools like @file{install-sh} or @file{py-compile}
@end itemize
-@file{aclocal.m4} is generated by @command{aclocal} and contains some
-Automake-supplied M4 macros. Auxiliary tools are installed by
-@samp{automake --add-missing} when needed. @file{Makefile.in}s are
-built from @file{Makefile.am} by @command{automake}, and rely on the
-definitions of the M4 macros put in @file{aclocal.m4} as well as the
-behavior of the auxiliary tools installed.
+@file{aclocal.m4} is generated by @command{aclocal} and contains
+some Automake-supplied M4 macros. Auxiliary tools are installed
+by @samp{automake} when needed. @file{Makefile.in}s are built
+from @file{Makefile.am} by @command{automake}, and rely on the
+definitions of the M4 macros put in @file{aclocal.m4} as well as
+the behavior of the auxiliary tools installed.
Because all of these files are closely related, it is important to
regenerate all of them when upgrading to a newer Automake release.
@@ -11357,7 +11358,7 @@ The usual way to do that is
@example
aclocal # with any option needed (such a -I m4)
autoconf
-automake --add-missing --force-missing
+automake --force-missing
@end example
@noindent
diff --git a/t/add-missing.tap b/t/add-missing.tap
index c47382b5f..45cc16e4e 100755
--- a/t/add-missing.tap
+++ b/t/add-missing.tap
@@ -153,30 +153,13 @@ check_ ()
# Test once with '--copy', once without.
for action in link copy; do
case $action in
- link) opts='--add-missing';;
- copy) opts='-a --copy';;
+ link) opts=;;
+ copy) opts=--copy;;
*) fatal_ "invalid value '$action' for \$action";;
esac
pfx="[$action $name]"
cp -R generic $action
cd $action
- # If the required auxiliary files are missing, and automake is
- # not told to install them, it should complain and error out,
- # and also give a useful suggestion.
- AUTOMAKE_fails -d "$pfx missing files, automake fails"
- for f in $files; do
- command_ok_ \
- "$pfx warn about missing file $f" \
- $FGREP "required file '$build_aux/$f' not found" stderr
- # Suggest the user to use '--add-missing'.
- command_ok_ \
- "$pfx suggest --add-missing for $f" \
- grep ".*--add-missing.* install .*'$f'" stderr
- done
- # No files should be automatically installed by automake if it
- # is not told to.
- if ls "$build_aux" | grep .; then r='not ok'; else r=ok; fi
- result_ "$r" "$pfx no extra files installed"
AUTOMAKE_run -d "$pfx automake run successfully" -- $opts
ls -l . $build_aux
# The expected files should get installed correctly (e.g., no
diff --git a/t/ar-lib7.sh b/t/ar-lib7.sh
deleted file mode 100755
index c27cabf47..000000000
--- a/t/ar-lib7.sh
+++ /dev/null
@@ -1,34 +0,0 @@
-#! /bin/sh
-# Copyright (C) 2011-2012 Free Software Foundation, Inc.
-#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 2, or (at your option)
-# any later version.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with this program. If not, see <http://www.gnu.org/licenses/>.
-
-# Test if automake warns if ar-lib is missing when AM_PROG_AR is used.
-
-. ./defs || exit 1
-
-cat >> configure.ac << 'END'
-AM_PROG_AR
-END
-
-:> Makefile.am
-
-$ACLOCAL
-AUTOMAKE_fails
-
-grep '^configure\.ac:.*ar-lib.*not found' stderr
-
-$AUTOMAKE --add-missing
-
-:
diff --git a/t/dist-auxfile.sh b/t/dist-auxfile.sh
index 763b14ea0..4389f514f 100755
--- a/t/dist-auxfile.sh
+++ b/t/dist-auxfile.sh
@@ -79,8 +79,6 @@ END
grep "^configure\\.ac:6:.* required file.*$auxdir_rx/zardoz" stderr
touch $auxdir/foo.txt $auxdir/bar.sh $auxdir/zardoz
- cp "$am_scriptdir"/missing "$am_scriptdir"/install-sh $auxdir \
- || fatal_ "fetching auxiliary scripts 'missing' and 'install-sh'"
$AUTOMAKE
./configure
$MAKE test
diff --git a/t/license2.sh b/t/license2.sh
index 736e96fa0..02d48fd77 100755
--- a/t/license2.sh
+++ b/t/license2.sh
@@ -29,11 +29,10 @@ END
: >INSTALL
$ACLOCAL
-AUTOMAKE_fails
-grep 'COPYING' stderr
-
-AUTOMAKE_run --add-missing
+AUTOMAKE_run
grep 'COPYING' stderr
grep 'GNU General Public License' stderr
grep 'Consider adding.*version control' stderr
test -f COPYING
+
+:
diff --git a/t/mdate.sh b/t/mdate.sh
deleted file mode 100755
index e44144a8f..000000000
--- a/t/mdate.sh
+++ /dev/null
@@ -1,37 +0,0 @@
-#!/bin/sh
-# Copyright (C) 1996-2012 Free Software Foundation, Inc.
-#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 2, or (at your option)
-# any later version.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with this program. If not, see <http://www.gnu.org/licenses/>.
-
-# Test that mdate-sh is required when Texinfo used and version.texi needed.
-
-. ./defs || exit 1
-
-cat > Makefile.am << 'END'
-info_TEXINFOS = textutils.texi
-END
-
-cat > textutils.texi << 'END'
-@include version.texi
-@setfilename textutils.info
-END
-
-# Required when using Texinfo.
-: > texinfo.tex
-
-$ACLOCAL
-AUTOMAKE_fails
-grep 'required file.*mdate-sh.*not found' stderr
-
-:
diff --git a/t/missing-auxfile-stops-makefiles-creation.sh b/t/missing-auxfile-stops-makefiles-creation.sh
deleted file mode 100755
index d1c0cd41f..000000000
--- a/t/missing-auxfile-stops-makefiles-creation.sh
+++ /dev/null
@@ -1,65 +0,0 @@
-#! /bin/sh
-# Copyright (C) 2011-2012 Free Software Foundation, Inc.
-#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 2, or (at your option)
-# any later version.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with this program. If not, see <http://www.gnu.org/licenses/>.
-
-# Automake should stop the creation of Makefile.in files at the first
-# encountered error due to a required auxiliary file not found.
-
-. ./defs || exit 1
-
-cat >> configure.ac <<END
-AM_PATH_PYTHON
-END
-
-echo SUBDIRS = > Makefile.am
-
-for i in 1 2 3 4 5; do
- echo "AC_CONFIG_FILES([sub$i/Makefile])" >> configure.ac
- echo "SUBDIRS += sub$i" >> Makefile.am
- mkdir sub$i
- echo python_PYTHON = foo.py > sub$i/Makefile.am
-done
-
-: > sub1/Makefile.am
-
-$ACLOCAL
-
-unset AUTOMAKE_JOBS || :
-
-AUTOMAKE_fails
-ls -l Makefile.in */Makefile.in || : # For debugging.
-# Top-level Makefile.in might be created or not, we don't want to set
-# too strict semantics here, so don't check for it. But the later
-# files shouldn't exist.
-test -f sub1/Makefile.in
-test ! -e sub2/Makefile.in
-test ! -e sub3/Makefile.in
-test ! -e sub4/Makefile.in
-test ! -e sub5/Makefile.in
-
-rm -f Makefile.in */Makefile.in
-
-: > sub2/Makefile.am
-: > sub3/Makefile.am
-
-AUTOMAKE_fails
-ls -l Makefile.in */Makefile.in || : # For debugging.
-test -f sub1/Makefile.in
-test -f sub2/Makefile.in
-test -f sub3/Makefile.in
-test ! -e sub4/Makefile.in
-test ! -e sub5/Makefile.in
-
-:
diff --git a/t/per-target-flags.sh b/t/per-target-flags.sh
index f8b863692..45beb4bed 100755
--- a/t/per-target-flags.sh
+++ b/t/per-target-flags.sh
@@ -55,14 +55,9 @@ cat - libMakefile.am > libMakefile2.am << 'END'
AUTOMAKE_OPTIONS = no-dependencies
END
-# Make sure 'compile' is required.
-for m in $makefiles; do
- AUTOMAKE_fails $m
- $EGREP " required file.* '(compile|\./compile)'" stderr
-done
-
-: > compile
$AUTOMAKE
+# Make sure 'compile' is required.
+test -f compile
# Regression test for missing space.
$FGREP ')-c' $makefiles && exit 1
diff --git a/t/python.sh b/t/python.sh
index a3add40f9..3b73165ad 100755
--- a/t/python.sh
+++ b/t/python.sh
@@ -39,10 +39,6 @@ python_PYTHON = in.py
END
$ACLOCAL
-
-AUTOMAKE_fails
-grep '^Makefile\.am:1:.* required file.*py-compile' stderr
-
$AUTOMAKE -a
grep '^py_compile *=' Makefile.in
test -f py-compile