"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "bin/aclocal.in" between
automake-1.16.2.tar.xz and automake-1.16.3.tar.xz

About: GNU Automake is a Makefile generator (input Makefile.am, output Makefile.in; intended for use with autoconf).

aclocal.in  (automake-1.16.2.tar.xz):aclocal.in  (automake-1.16.3.tar.xz)
#!@PERL@ -w #!@PERL@
# aclocal - create aclocal.m4 by scanning configure.ac -*- perl -*- # aclocal - create aclocal.m4 by scanning configure.ac -*- perl -*-
# @configure_input@ # @configure_input@
# Copyright (C) 1996-2020 Free Software Foundation, Inc. # Copyright (C) 1996-2020 Free Software Foundation, Inc.
# This program is free software; you can redistribute it and/or modify # 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 # it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2, or (at your option) # the Free Software Foundation; either version 2, or (at your option)
# any later version. # any later version.
# This program is distributed in the hope that it will be useful, # This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of # but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details. # GNU General Public License for more details.
# You should have received a copy of the GNU General Public License # You should have received a copy of the GNU General Public License
# along with this program. If not, see <https://www.gnu.org/licenses/>. # along with this program. If not, see <https://www.gnu.org/licenses/>.
# Written by Tom Tromey <tromey@redhat.com>, and # Written by Tom Tromey <tromey@redhat.com>, and
# Alexandre Duret-Lutz <adl@gnu.org>. # Alexandre Duret-Lutz <adl@gnu.org>.
use 5.006;
use strict;
use warnings FATAL => 'all';
BEGIN BEGIN
{ {
unshift (@INC, '@datadir@/@PACKAGE@-@APIVERSION@') unshift (@INC, '@datadir@/@PACKAGE@-@APIVERSION@')
unless $ENV{AUTOMAKE_UNINSTALLED}; unless $ENV{AUTOMAKE_UNINSTALLED};
} }
use strict; use File::Basename;
use File::Path ();
use Automake::Config; use Automake::Config;
use Automake::General; use Automake::General;
use Automake::Configure_ac; use Automake::Configure_ac;
use Automake::Channels; use Automake::Channels;
use Automake::ChannelDefs; use Automake::ChannelDefs;
use Automake::XFile; use Automake::XFile;
use Automake::FileUtils; use Automake::FileUtils;
use File::Basename;
use File::Path ();
# Some globals. # Some globals.
# Support AC_CONFIG_MACRO_DIRS also with older autoconf. # Support AC_CONFIG_MACRO_DIRS also with older autoconf.
# FIXME: To be removed in Automake 2.0, once we can assume autoconf # FIXME: To be removed in Automake 2.0, once we can assume autoconf
# 2.70 or later. # 2.70 or later.
# FIXME: keep in sync with 'internal/ac-config-macro-dirs.m4'. # FIXME: keep in sync with 'internal/ac-config-macro-dirs.m4'.
my $ac_config_macro_dirs_fallback = my $ac_config_macro_dirs_fallback =
'm4_ifndef([AC_CONFIG_MACRO_DIRS], [' . 'm4_ifndef([AC_CONFIG_MACRO_DIRS], [' .
'm4_defun([_AM_CONFIG_MACRO_DIRS], [])' . 'm4_defun([_AM_CONFIG_MACRO_DIRS], [])' .
skipping to change at line 287 skipping to change at line 290
{ {
msg 'note', "installing '$dest' from '$src'"; msg 'note', "installing '$dest' from '$src'";
} }
if (@diff_command) if (@diff_command)
{ {
if (! defined $diff_dest) if (! defined $diff_dest)
{ {
# $dest does not exist. We create an empty one just to # $dest does not exist. We create an empty one just to
# run diff, and we erase it afterward. Using the real # run diff, and we erase it afterward. Using the real
# the destination file (rather than a temporary file) is # destination file (rather than a temporary file) is
# good when diff is run with options that display the # good when diff is run with options that display the
# file name. # file name.
# #
# If creating $dest fails, fall back to /dev/null. At # If creating $dest fails, fall back to /dev/null. At
# least one diff implementation (Tru64's) cannot deal # least one diff implementation (Tru64's) cannot deal
# with /dev/null. However working around this is not # with /dev/null. However working around this is not
# worth the trouble since nobody run aclocal on a # worth the trouble since nobody run aclocal on a
# read-only tree anyway. # read-only tree anyway.
$erase_me = $dest; $erase_me = $dest;
my $f = new IO::File "> $dest"; my $f = new IO::File "> $dest";
skipping to change at line 762 skipping to change at line 765
delete $files{$configure_ac}; delete $files{$configure_ac};
return %files; return %files;
} }
sub trace_used_macros () sub trace_used_macros ()
{ {
my %files = map { $map{$_} => 1 } keys %macro_seen; my %files = map { $map{$_} => 1 } keys %macro_seen;
%files = strip_redundant_includes %files; %files = strip_redundant_includes %files;
# When AC_CONFIG_MACRO_DIRS is used, avoid possible spurious warnings # Suppress all warnings from this invocation of autom4te.
# from autom4te about macros being "m4_require'd but not m4_defun'd"; # In particular we want to avoid spurious warnings about
# for more background, see: # macros being "m4_require'd but not m4_defun'd" because
# https://lists.gnu.org/archive/html/autoconf-patches/2012-11/msg00004.html # aclocal.m4 is not yet available.
# as well as autoconf commit 'v2.69-44-g1ed0548', "warn: allow aclocal local $ENV{WARNINGS} = 'none';
# to silence m4_require warnings".
my $early_m4_code .= "m4_define([m4_require_silent_probe], [-])";
my $traces = ($ENV{AUTOM4TE} || '@am_AUTOM4TE@'); my $traces = ($ENV{AUTOM4TE} || '@am_AUTOM4TE@');
$traces .= " --language Autoconf-without-aclocal-m4 "; $traces .= " --language Autoconf-without-aclocal-m4 ";
$traces = "echo '$early_m4_code' | $traces - ";
# Support AC_CONFIG_MACRO_DIRS also with older autoconf. # Support AC_CONFIG_MACRO_DIRS also with older autoconf.
# Note that we can't use '$ac_config_macro_dirs_fallback' here, because # Note that we can't use '$ac_config_macro_dirs_fallback' here, because
# a bug in option parsing code of autom4te 2.68 and earlier will cause # a bug in option parsing code of autom4te 2.68 and earlier would cause
# it to read standard input last, even if the "-" argument is specified # it to read standard input last, even if the "-" argument was specified
# early. # early.
# FIXME: To be removed in Automake 2.0, once we can assume autoconf # FIXME: To be removed in Automake 2.0, once we can assume autoconf
# 2.70 or later. # 2.70 or later.
$traces .= "$automake_includes[0]/internal/ac-config-macro-dirs.m4 "; $traces .= "$automake_includes[0]/internal/ac-config-macro-dirs.m4 ";
# All candidate files. # All candidate files.
$traces .= join (' ', $traces .= join (' ',
(map { "'$_'" } (map { "'$_'" }
(grep { exists $files{$_} } @file_order))) . " "; (grep { exists $files{$_} } @file_order))) . " ";
skipping to change at line 807 skipping to change at line 807
# compatibility with older autoconf. Remove this in # compatibility with older autoconf. Remove this in
# Automake 2.0, when we can assume Autoconf 2.70 or # Automake 2.0, when we can assume Autoconf 2.70 or
# later. # later.
'AC_CONFIG_MACRO_DIR', 'AC_CONFIG_MACRO_DIR',
'_AM_CONFIG_MACRO_DIRS')), '_AM_CONFIG_MACRO_DIRS')),
# Do not trace $1 for all other macros as we do # Do not trace $1 for all other macros as we do
# not need it and it might contains harmful # not need it and it might contains harmful
# characters (like newlines). # characters (like newlines).
(map { "--trace='$_:\$f::\$n'" } (keys %macro_seen))); (map { "--trace='$_:\$f::\$n'" } (keys %macro_seen)));
verb "running $traces $configure_ac"; verb "running WARNINGS=$ENV{WARNINGS} $traces $configure_ac";
my $tracefh = new Automake::XFile ("$traces $configure_ac |"); my $tracefh = new Automake::XFile ("$traces $configure_ac |");
@ac_config_macro_dirs = (); @ac_config_macro_dirs = ();
my %traced = (); my %traced = ();
while ($_ = $tracefh->getline) while ($_ = $tracefh->getline)
{ {
chomp; chomp;
skipping to change at line 1048 skipping to change at line 1048
--force always update output file --force always update output file
--help print this help, then exit --help print this help, then exit
-I DIR add directory to search list for .m4 files -I DIR add directory to search list for .m4 files
--install copy third-party files to the first -I directory --install copy third-party files to the first -I directory
--output=FILE put output in FILE (default aclocal.m4) --output=FILE put output in FILE (default aclocal.m4)
--print-ac-dir print name of directory holding system-wide --print-ac-dir print name of directory holding system-wide
third-party m4 files, then exit third-party m4 files, then exit
--verbose don't be silent --verbose don't be silent
--version print version number, then exit --version print version number, then exit
-W, --warnings=CATEGORY report the warnings falling in CATEGORY -W, --warnings=CATEGORY report the warnings falling in CATEGORY
EOF
Warning categories include: print Automake::ChannelDefs::usage (), "\n";
syntax dubious syntactic constructs (default)
unsupported unknown macros (default)
all all the warnings (default)
no-CATEGORY turn off warnings in CATEGORY
none turn off all the warnings
error treat warnings as errors
print <<'EOF';
Report bugs to <@PACKAGE_BUGREPORT@>. Report bugs to <@PACKAGE_BUGREPORT@>.
GNU Automake home page: <@PACKAGE_URL@>. GNU Automake home page: <@PACKAGE_URL@>.
General help using GNU software: <https://www.gnu.org/gethelp/>. General help using GNU software: <https://www.gnu.org/gethelp/>.
EOF EOF
exit $status; exit $status;
} }
# Print version and exit. # Print version and exit.
sub version () sub version ()
{ {
skipping to change at line 1085 skipping to change at line 1081
and Alexandre Duret-Lutz <adl\@gnu.org>. and Alexandre Duret-Lutz <adl\@gnu.org>.
EOF EOF
exit 0; exit 0;
} }
# Parse command line. # Parse command line.
sub parse_arguments () sub parse_arguments ()
{ {
my $print_and_exit = 0; my $print_and_exit = 0;
my $diff_command; my $diff_command;
my @warnings = ();
my %cli_options = my %cli_options =
( (
'help' => sub { usage(0); }, 'help' => sub { usage(0); },
'version' => \&version, 'version' => \&version,
'system-acdir=s' => sub { shift; @system_includes = @_; }, 'system-acdir=s' => sub { shift; @system_includes = @_; },
'automake-acdir=s' => sub { shift; @automake_includes = @_; }, 'automake-acdir=s' => sub { shift; @automake_includes = @_; },
'diff:s' => \$diff_command, 'diff:s' => \$diff_command,
'dry-run' => \$dry_run, 'dry-run' => \$dry_run,
'force' => \$force_output, 'force' => \$force_output,
'I=s' => \@user_includes, 'I=s' => \@user_includes,
'install' => \$install, 'install' => \$install,
'output=s' => \$output_file, 'output=s' => \$output_file,
'print-ac-dir' => \$print_and_exit, 'print-ac-dir' => \$print_and_exit,
'verbose' => sub { setup_channel 'verb', silent => 0; }, 'verbose' => sub { setup_channel 'verb', silent => 0; },
'W|warnings=s' => \&parse_warnings, 'W|warnings=s' => \@warnings,
); );
use Automake::Getopt (); use Automake::Getopt ();
Automake::Getopt::parse_options %cli_options; Automake::Getopt::parse_options %cli_options;
parse_warnings @warnings;
if (@ARGV > 0) if (@ARGV > 0)
{ {
fatal ("non-option arguments are not accepted: '$ARGV[0]'.\n" fatal ("non-option arguments are not accepted: '$ARGV[0]'.\n"
. "Try '$0 --help' for more information."); . "Try '$0 --help' for more information.");
} }
if ($print_and_exit) if ($print_and_exit)
{ {
print "@system_includes\n"; print "@system_includes\n";
 End of changes. 15 change blocks. 
24 lines changed or deleted 22 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)