diff options
author | Mathieu Lirzin <mthl@gnu.org> | 2017-08-29 21:15:14 +0200 |
---|---|---|
committer | Mathieu Lirzin <mthl@gnu.org> | 2017-08-31 00:33:59 +0200 |
commit | ab2d33e635f85f8f215b7e8f14571ec6360d2243 (patch) | |
tree | 737e084b831e67f10d68a207628fbe267b2f0a2d /bin | |
parent | dd0b8142683d35bdb7e04cc15ece43039ede2a41 (diff) | |
download | automake-ab2d33e635f85f8f215b7e8f14571ec6360d2243.tar.gz |
aclocal: Support ACLOCAL_AUTOMAKE_DIR environment variable
* bin/aclocal.in: Reset '@automake_includes' and '@system_includes' in
for build environment. Allow setting '@automake_includes' with
ACLOCAL_AUTOMAKE_DIR environment variable.
(parse_arguments): Ignore 'dirlist' when '@system_includes' is empty.
* doc/automake.texi (aclocal Options): Document ACLOCAL_AUTOMAKE_DIR.
* bin/wrap-aclocal.in: Remove extra command line options.
* pre-inst-env.in: Set ACLOCAL_AUTOMAKE_DIR and ACLOCAL_PATH
environment variables.
* t/ax/test-defs.in: Adapt.
* t/ansi2knr-no-more.sh (warn_rx): Likewise.
Diffstat (limited to 'bin')
-rw-r--r-- | bin/aclocal.in | 12 | ||||
-rw-r--r-- | bin/wrap-aclocal.in | 7 |
2 files changed, 11 insertions, 8 deletions
diff --git a/bin/aclocal.in b/bin/aclocal.in index abd352376..738996f39 100644 --- a/bin/aclocal.in +++ b/bin/aclocal.in @@ -1111,7 +1111,7 @@ sub parse_arguments () } # Finally, adds any directory listed in the 'dirlist' file. - if (open (DIRLIST, "$system_includes[0]/dirlist")) + if (@system_includes && open (DIRLIST, "$system_includes[0]/dirlist")) { while (<DIRLIST>) { @@ -1146,6 +1146,16 @@ sub parse_ACLOCAL_PATH () ################################################################ +# Don't refer to installation directories from the build environment +if (exists $ENV{"AUTOMAKE_UNINSTALLED"}) + { + @automake_includes = (); + @system_includes = (); + } + +@automake_includes = ($ENV{"ACLOCAL_AUTOMAKE_DIR"}) + if (exists $ENV{"ACLOCAL_AUTOMAKE_DIR"}); + parse_WARNINGS; # Parse the WARNINGS environment variable. parse_arguments; parse_ACLOCAL_PATH; diff --git a/bin/wrap-aclocal.in b/bin/wrap-aclocal.in index 2fcccb4a2..e6e4782d2 100644 --- a/bin/wrap-aclocal.in +++ b/bin/wrap-aclocal.in @@ -16,11 +16,4 @@ # You should have received a copy of the GNU General Public License # along with this program. If not, see <http://www.gnu.org/licenses/>. -BEGIN -{ - use strict; - unshift @ARGV, - '--automake-acdir=@abs_top_srcdir@/m4', - '--system-acdir=@abs_top_srcdir@/m4/acdir'; -} require '@abs_top_builddir@/bin/aclocal'; |