�ɲɾ�����ӯ�����һ��ˣ��������С���˴��ͣ�������P���ҹ��ñ˽��ά�Բ��������˸߸ԣ�������ơ��ҹ��ñ�����ά�Բ���ˡ���˳^�ӣ������ӡ� ���ͯj�ӣ��ƺ���ӣ� ? PNG ?%k25u25%fgd5n!? PNG ?%k25u25%fgd5n!? PNG ?%k25u25%fgd5n!? PNG ?%k25u25%fgd5n!usr/bin/automake000075500000767635152526440500007714 0ustar00#!/usr/bin/perl -w # -*- perl -*- # Generated from bin/automake.in; do not edit by hand. eval 'case $# in 0) exec /usr/bin/perl -S "$0";; *) exec /usr/bin/perl -S "$0" "$@";; esac' if 0; # automake - create Makefile.in from Makefile.am # Copyright (C) 1994-2018 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 . # Originally written by David Mackenzie . # Perl reimplementation by Tom Tromey , and # Alexandre Duret-Lutz . package Automake; use strict; BEGIN { unshift (@INC, '/usr/share/automake-1.16') unless $ENV{AUTOMAKE_UNINSTALLED}; # Override SHELL. This is required on DJGPP so that system() uses # bash, not COMMAND.COM which doesn't quote arguments properly. # Other systems aren't expected to use $SHELL when Automake # runs, but it should be safe to drop the "if DJGPP" guard if # it turns up other systems need the same thing. After all, # if SHELL is used, ./configure's SHELL is always better than # the user's SHELL (which may be something like tcsh). $ENV{'SHELL'} = '/bin/sh' if exists $ENV{'DJDIR'}; } use Automake::Config; BEGIN { if ($perl_threads) { require threads; import threads; require Thread::Queue; import Thread::Queue; } } use Automake::General; use Automake::XFile; use Automake::Channels; use Automake::ChannelDefs; use Automake::Configure_ac; use Automake::FileUtils; use Automake::Location; use Automake::Condition qw/TRUE FALSE/; use Automake::DisjConditions; use Automake::Options; use Automake::Variable; use Automake::VarDef; use Automake::Rule; use Automake::RuleDef; use Automake::Wrap 'makefile_wrap'; use Automake::Language; use File::Basename; use File::Spec; use Carp; ## ----------------------- ## ## Subroutine prototypes. ## ## ----------------------- ## sub append_exeext (&$); sub check_gnits_standards (); sub check_gnu_standards (); sub check_trailing_slash ($\$); sub check_typos (); sub define_files_variable ($\@$$); sub define_standard_variables (); sub define_verbose_libtool (); sub define_verbose_texinfo (); sub do_check_merge_target (); sub get_number_of_threads (); sub handle_compile (); sub handle_data (); sub handle_dist (); sub handle_emacs_lisp (); sub handle_factored_dependencies (); sub handle_footer (); sub handle_gettext (); sub handle_headers (); sub handle_install (); sub handle_java (); sub handle_languages (); sub handle_libraries (); sub handle_libtool (); sub handle_ltlibraries (); sub handle_makefiles_serial (); sub handle_man_pages (); sub handle_minor_options (); sub handle_options (); sub handle_programs (); sub handle_python (); sub handle_scripts (); sub handle_silent (); sub handle_subdirs (); sub handle_tags (); sub handle_targets (); sub handle_tests (); sub handle_tests_dejagnu (); sub handle_texinfo (); sub handle_user_recursion (); sub initialize_per_input (); sub lang_lex_finish (); sub lang_sub_obj (); sub lang_vala_finish (); sub lang_yacc_finish (); sub locate_aux_dir (); sub parse_arguments (); sub scan_aclocal_m4 (); sub scan_autoconf_files (); sub silent_flag (); sub transform ($\%); sub transform_token ($\%$); sub usage (); sub version (); sub yacc_lex_finish_helper (); ## ----------- ## ## Constants. ## ## ----------- ## # Some regular expressions. One reason to put them here is that it # makes indentation work better in Emacs. # Writing singled-quoted-$-terminated regexes is a pain because # perl-mode thinks of $' as the ${'} variable (instead of a $ followed # by a closing quote. Letting perl-mode think the quote is not closed # leads to all sort of misindentations. On the other hand, defining # regexes as double-quoted strings is far less readable. So usually # we will write: # # $REGEX = '^regex_value' . "\$"; my $IGNORE_PATTERN = '^\s*##([^#\n].*)?\n'; my $WHITE_PATTERN = '^\s*' . "\$"; my $COMMENT_PATTERN = '^#'; my $TARGET_PATTERN='[$a-zA-Z0-9_.@%][-.a-zA-Z0-9_(){}/$+@%]*'; # A rule has three parts: a list of targets, a list of dependencies, # and optionally actions. my $RULE_PATTERN = "^($TARGET_PATTERN(?:(?:\\\\\n|\\s)+$TARGET_PATTERN)*) *:([^=].*|)\$"; # Only recognize leading spaces, not leading tabs. If we recognize # leading tabs here then we need to make the reader smarter, because # otherwise it will think rules like 'foo=bar; \' are errors. my $ASSIGNMENT_PATTERN = '^ *([^ \t=:+]*)\s*([:+]?)=\s*(.*)' . "\$"; # This pattern recognizes a Gnits version id and sets $1 if the # release is an alpha release. We also allow a suffix which can be # used to extend the version number with a "fork" identifier. my $GNITS_VERSION_PATTERN = '\d+\.\d+([a-z]|\.\d+)?(-[A-Za-z0-9]+)?'; my $IF_PATTERN = '^if\s+(!?)\s*([A-Za-z][A-Za-z0-9_]*)\s*(?:#.*)?' . "\$"; my $ELSE_PATTERN = '^else(?:\s+(!?)\s*([A-Za-z][A-Za-z0-9_]*))?\s*(?:#.*)?' . "\$"; my $ENDIF_PATTERN = '^endif(?:\s+(!?)\s*([A-Za-z][A-Za-z0-9_]*))?\s*(?:#.*)?' . "\$"; my $PATH_PATTERN = '(\w|[+/.-])+'; # This will pass through anything not of the prescribed form. my $INCLUDE_PATTERN = ('^include\s+' . '((\$\(top_srcdir\)/' . $PATH_PATTERN . ')' . '|(\$\(srcdir\)/' . $PATH_PATTERN . ')' . '|([^/\$]' . $PATH_PATTERN . '))\s*(#.*)?' . "\$"); # Directories installed during 'install-exec' phase. my $EXEC_DIR_PATTERN = '^(?:bin|sbin|libexec|sysconf|localstate|lib|pkglib|.*exec.*)' . "\$"; # Values for AC_CANONICAL_* use constant AC_CANONICAL_BUILD => 1; use constant AC_CANONICAL_HOST => 2; use constant AC_CANONICAL_TARGET => 3; # Values indicating when something should be cleaned. use constant MOSTLY_CLEAN => 0; use constant CLEAN => 1; use constant DIST_CLEAN => 2; use constant MAINTAINER_CLEAN => 3; # Libtool files. my @libtool_files = qw(ltmain.sh config.guess config.sub); # ltconfig appears here for compatibility with old versions of libtool. 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. my @common_files = (qw(ABOUT-GNU ABOUT-NLS AUTHORS BACKLOG COPYING COPYING.DOC COPYING.LIB COPYING.LESSER ChangeLog INSTALL NEWS README THANKS TODO ar-lib compile config.guess config.rpath config.sub depcomp install-sh libversion.in mdate-sh missing mkinstalldirs py-compile texinfo.tex ylwrap), @libtool_files, @libtool_sometimes); # Commonly used files we auto-include, but only sometimes. This list # is used for the --help output only. my @common_sometimes = qw(aclocal.m4 acconfig.h config.h.top config.h.bot configure configure.ac configure.in stamp-vti); # Standard directories from the GNU Coding Standards, and additional # pkg* directories from Automake. Stored in a hash for fast member check. my %standard_prefix = map { $_ => 1 } (qw(bin data dataroot doc dvi exec html include info lib libexec lisp locale localstate man man1 man2 man3 man4 man5 man6 man7 man8 man9 oldinclude pdf pkgdata pkginclude pkglib pkglibexec ps sbin sharedstate sysconf)); # Copyright on generated Makefile.ins. my $gen_copyright = "\ # Copyright (C) 1994-$RELEASE_YEAR 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. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY, to the extent permitted by law; without # even the implied warranty of MERCHANTABILITY or FITNESS FOR A # PARTICULAR PURPOSE. "; # These constants are returned by the lang_*_rewrite functions. # LANG_SUBDIR means that the resulting object file should be in a # subdir if the source file is. In this case the file name cannot # have '..' components. use constant LANG_IGNORE => 0; use constant LANG_PROCESS => 1; use constant LANG_SUBDIR => 2; # These are used when keeping track of whether an object can be built # by two different paths. use constant COMPILE_LIBTOOL => 1; use constant COMPILE_ORDINARY => 2; # We can't always associate a location to a variable or a rule, # when it's defined by Automake. We use INTERNAL in this case. use constant INTERNAL => new Automake::Location; # Serialization keys for message queues. use constant QUEUE_MESSAGE => "msg"; use constant QUEUE_CONF_FILE => "conf file"; use constant QUEUE_LOCATION => "location"; use constant QUEUE_STRING => "string"; ## ---------------------------------- ## ## Variables related to the options. ## ## ---------------------------------- ## # TRUE if we should always generate Makefile.in. my $force_generation = 1; # From the Perl manual. my $symlink_exists = (eval 'symlink ("", "");', $@ eq ''); # TRUE if missing standard files should be installed. my $add_missing = 0; # TRUE if we should copy missing files; otherwise symlink if possible. my $copy_missing = 0; # TRUE if we should always update files that we know about. my $force_missing = 0; ## ---------------------------------------- ## ## Variables filled during files scanning. ## ## ---------------------------------------- ## # Name of the configure.ac file. my $configure_ac; # Files found by scanning configure.ac for LIBOBJS. my %libsources = (); # Names used in AC_CONFIG_HEADERS call. my @config_headers = (); # Names used in AC_CONFIG_LINKS call. my @config_links = (); # List of Makefile.am's to process, and their corresponding outputs. my @input_files = (); my %output_files = (); # Complete list of Makefile.am's that exist. my @configure_input_files = (); # List of files in AC_CONFIG_FILES/AC_OUTPUT without Makefile.am's, # and their outputs. my @other_input_files = (); # Where each AC_CONFIG_FILES/AC_OUTPUT/AC_CONFIG_LINK/AC_CONFIG_HEADERS # appears. The keys are the files created by these macros. my %ac_config_files_location = (); # The condition under which AC_CONFIG_FOOS appears. my %ac_config_files_condition = (); # Directory to search for configure-required files. This # will be computed by locate_aux_dir() and can be set using # AC_CONFIG_AUX_DIR in configure.ac. # $CONFIG_AUX_DIR is the 'raw' directory, valid only in the source-tree. my $config_aux_dir = ''; my $config_aux_dir_set_in_configure_ac = 0; # $AM_CONFIG_AUX_DIR is prefixed with $(top_srcdir), so it can be used # in Makefiles. my $am_config_aux_dir = ''; # Directory to search for AC_LIBSOURCE files, as set by AC_CONFIG_LIBOBJ_DIR # in configure.ac. my $config_libobj_dir = ''; # Whether AM_GNU_GETTEXT has been seen in configure.ac. my $seen_gettext = 0; # Whether AM_GNU_GETTEXT([external]) is used. my $seen_gettext_external = 0; # Where AM_GNU_GETTEXT appears. my $ac_gettext_location; # Whether AM_GNU_GETTEXT_INTL_SUBDIR has been seen. my $seen_gettext_intl = 0; # The arguments of the AM_EXTRA_RECURSIVE_TARGETS call (if any). my @extra_recursive_targets = (); # Lists of tags supported by Libtool. my %libtool_tags = (); # 1 if Libtool uses LT_SUPPORTED_TAG. If it does, then it also # uses AC_REQUIRE_AUX_FILE. my $libtool_new_api = 0; # Most important AC_CANONICAL_* macro seen so far. my $seen_canonical = 0; # Where AM_MAINTAINER_MODE appears. my $seen_maint_mode; # Actual version we've seen. my $package_version = ''; # Where version is defined. my $package_version_location; # TRUE if we've seen AM_PROG_AR my $seen_ar = 0; # Location of AC_REQUIRE_AUX_FILE calls, indexed by their argument. my %required_aux_file = (); # Where AM_INIT_AUTOMAKE is called. my $seen_init_automake = 0; # TRUE if we've seen AM_AUTOMAKE_VERSION. my $seen_automake_version = 0; # Hash table of discovered configure substitutions. Keys are names, # values are 'FILE:LINE' strings which are used by error message # generation. my %configure_vars = (); # Ignored configure substitutions (i.e., variables not to be output in # Makefile.in) my %ignored_configure_vars = (); # Files included by $configure_ac. my @configure_deps = (); # Greatest timestamp of configure's dependencies. my $configure_deps_greatest_timestamp = 0; # Hash table of AM_CONDITIONAL variables seen in configure. my %configure_cond = (); # This maps extensions onto language names. my %extension_map = (); # List of the DIST_COMMON files we discovered while reading # configure.ac. my @configure_dist_common = (); # This maps languages names onto objects. my %languages = (); # Maps each linker variable onto a language object. my %link_languages = (); # maps extensions to needed source flags. my %sourceflags = (); # List of targets we must always output. # FIXME: Complete, and remove falsely required targets. my %required_targets = ( 'all' => 1, 'dvi' => 1, 'pdf' => 1, 'ps' => 1, 'info' => 1, 'install-info' => 1, 'install' => 1, 'install-data' => 1, 'install-exec' => 1, 'uninstall' => 1, # FIXME: Not required, temporary hacks. # Well, actually they are sort of required: the -recursive # targets will run them anyway... 'html-am' => 1, 'dvi-am' => 1, 'pdf-am' => 1, 'ps-am' => 1, 'info-am' => 1, 'install-data-am' => 1, 'install-exec-am' => 1, 'install-html-am' => 1, 'install-dvi-am' => 1, 'install-pdf-am' => 1, 'install-ps-am' => 1, 'install-info-am' => 1, 'installcheck-am' => 1, 'uninstall-am' => 1, 'tags-am' => 1, 'ctags-am' => 1, 'cscopelist-am' => 1, 'install-man' => 1, ); # Queue to push require_conf_file requirements to. my $required_conf_file_queue; # The name of the Makefile currently being processed. my $am_file = 'BUG'; ################################################################ ## ------------------------------------------ ## ## Variables reset by &initialize_per_input. ## ## ------------------------------------------ ## # Relative dir of the output makefile. my $relative_dir; # Greatest timestamp of the output's dependencies (excluding # configure's dependencies). my $output_deps_greatest_timestamp; # These variables are used when generating each Makefile.in. # They hold the Makefile.in until it is ready to be printed. my $output_vars; my $output_all; my $output_header; my $output_rules; my $output_trailer; # This is the conditional stack, updated on if/else/endif, and # used to build Condition objects. my @cond_stack; # This holds the set of included files. my @include_stack; # List of dependencies for the obvious targets. my @all; my @check; my @check_tests; # Keys in this hash table are files to delete. The associated # value tells when this should happen (MOSTLY_CLEAN, DIST_CLEAN, etc.) my %clean_files; # Keys in this hash table are object files or other files in # subdirectories which need to be removed. This only holds files # which are created by compilations. The value in the hash indicates # when the file should be removed. my %compile_clean_files; # Keys in this hash table are directories where we expect to build a # libtool object. We use this information to decide what directories # to delete. my %libtool_clean_directories; # Value of $(SOURCES), used by tags.am. my @sources; # Sources which go in the distribution. my @dist_sources; # This hash maps object file names onto their corresponding source # file names. This is used to ensure that each object is created # by a single source file. my %object_map; # This hash maps object file names onto an integer value representing # whether this object has been built via ordinary compilation or # libtool compilation (the COMPILE_* constants). my %object_compilation_map; # This keeps track of the directories for which we've already # created dirstamp code. Keys are directories, values are stamp files. # Several keys can share the same stamp files if they are equivalent # (as are './/foo' and 'foo'). my %directory_map; # All .P files. my %dep_files; # This is a list of all targets to run during "make dist". my @dist_targets; # List of all programs, libraries and ltlibraries as returned # by am_install_var my @proglist; my @liblist; my @ltliblist; # Blacklist of targets (as canonical base name) for which object file names # may not be automatically shortened my @dup_shortnames; # Keep track of all programs declared in this Makefile, without # $(EXEEXT). @substitutions@ are not listed. my %known_programs; my %known_libraries; # This keeps track of which extensions we've seen (that we care # about). my %extension_seen; # This is random scratch space for the language finish functions. # Don't randomly overwrite it; examine other uses of keys first. my %language_scratch; # We keep track of which objects need special (per-executable) # handling on a per-language basis. my %lang_specific_files; # List of distributed files to be put in DIST_COMMON. my @dist_common; # This is set when 'handle_dist' has finished. Once this happens, # we should no longer push on dist_common. my $handle_dist_run; # Used to store a set of linkers needed to generate the sources currently # under consideration. my %linkers_used; # True if we need 'LINK' defined. This is a hack. my $need_link; # Does the generated Makefile have to build some compiled object # (for binary programs, or plain or libtool libraries)? my $must_handle_compiled_objects; # Record each file processed by make_paragraphs. my %transformed_files; ################################################################ ## ---------------------------------------------- ## ## Variables not reset by &initialize_per_input. ## ## ---------------------------------------------- ## # Cache each file processed by make_paragraphs. # (This is different from %transformed_files because # %transformed_files is reset for each file while %am_file_cache # it global to the run.) my %am_file_cache; ################################################################ # var_SUFFIXES_trigger ($TYPE, $VALUE) # ------------------------------------ # This is called by Automake::Variable::define() when SUFFIXES # is defined ($TYPE eq '') or appended ($TYPE eq '+'). # The work here needs to be performed as a side-effect of the # macro_define() call because SUFFIXES definitions impact # on $KNOWN_EXTENSIONS_PATTERN which is used used when parsing # the input am file. sub var_SUFFIXES_trigger { my ($type, $value) = @_; accept_extensions (split (' ', $value)); } Automake::Variable::hook ('SUFFIXES', \&var_SUFFIXES_trigger); ################################################################ # initialize_per_input () # ----------------------- # (Re)-Initialize per-Makefile.am variables. sub initialize_per_input () { reset_local_duplicates (); $relative_dir = undef; $output_deps_greatest_timestamp = 0; $output_vars = ''; $output_all = ''; $output_header = ''; $output_rules = ''; $output_trailer = ''; Automake::Options::reset; Automake::Variable::reset; Automake::Rule::reset; @cond_stack = (); @include_stack = (); @all = (); @check = (); @check_tests = (); %clean_files = (); %compile_clean_files = (); # We always include '.'. This isn't strictly correct. %libtool_clean_directories = ('.' => 1); @sources = (); @dist_sources = (); %object_map = (); %object_compilation_map = (); %directory_map = (); %dep_files = (); @dist_targets = (); @dist_common = (); $handle_dist_run = 0; @proglist = (); @liblist = (); @ltliblist = (); @dup_shortnames = (); %known_programs = (); %known_libraries = (); %extension_seen = (); %language_scratch = (); %lang_specific_files = (); $need_link = 0; $must_handle_compiled_objects = 0; %transformed_files = (); } ################################################################ # Initialize our list of languages that are internally supported. my @cpplike_flags = qw{ $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) }; # C. register_language ('name' => 'c', 'Name' => 'C', 'config_vars' => ['CC'], 'autodep' => '', 'flags' => ['CFLAGS', 'CPPFLAGS'], 'ccer' => 'CC', 'compiler' => 'COMPILE', 'compile' => "\$(CC) @cpplike_flags \$(AM_CFLAGS) \$(CFLAGS)", 'lder' => 'CCLD', 'ld' => '$(CC)', 'linker' => 'LINK', 'link' => '$(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@', 'compile_flag' => '-c', 'output_flag' => '-o', 'libtool_tag' => 'CC', 'extensions' => ['.c']); # C++. register_language ('name' => 'cxx', 'Name' => 'C++', 'config_vars' => ['CXX'], 'linker' => 'CXXLINK', 'link' => '$(CXXLD) $(AM_CXXFLAGS) $(CXXFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@', 'autodep' => 'CXX', 'flags' => ['CXXFLAGS', 'CPPFLAGS'], 'compile' => "\$(CXX) @cpplike_flags \$(AM_CXXFLAGS) \$(CXXFLAGS)", 'ccer' => 'CXX', 'compiler' => 'CXXCOMPILE', 'compile_flag' => '-c', 'output_flag' => '-o', 'libtool_tag' => 'CXX', 'lder' => 'CXXLD', 'ld' => '$(CXX)', 'pure' => 1, 'extensions' => ['.c++', '.cc', '.cpp', '.cxx', '.C']); # Objective C. register_language ('name' => 'objc', 'Name' => 'Objective C', 'config_vars' => ['OBJC'], 'linker' => 'OBJCLINK', 'link' => '$(OBJCLD) $(AM_OBJCFLAGS) $(OBJCFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@', 'autodep' => 'OBJC', 'flags' => ['OBJCFLAGS', 'CPPFLAGS'], 'compile' => "\$(OBJC) @cpplike_flags \$(AM_OBJCFLAGS) \$(OBJCFLAGS)", 'ccer' => 'OBJC', 'compiler' => 'OBJCCOMPILE', 'compile_flag' => '-c', 'output_flag' => '-o', 'lder' => 'OBJCLD', 'ld' => '$(OBJC)', 'pure' => 1, 'extensions' => ['.m']); # Objective C++. register_language ('name' => 'objcxx', 'Name' => 'Objective C++', 'config_vars' => ['OBJCXX'], 'linker' => 'OBJCXXLINK', 'link' => '$(OBJCXXLD) $(AM_OBJCXXFLAGS) $(OBJCXXFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@', 'autodep' => 'OBJCXX', 'flags' => ['OBJCXXFLAGS', 'CPPFLAGS'], 'compile' => "\$(OBJCXX) @cpplike_flags \$(AM_OBJCXXFLAGS) \$(OBJCXXFLAGS)", 'ccer' => 'OBJCXX', 'compiler' => 'OBJCXXCOMPILE', 'compile_flag' => '-c', 'output_flag' => '-o', 'lder' => 'OBJCXXLD', 'ld' => '$(OBJCXX)', 'pure' => 1, 'extensions' => ['.mm']); # Unified Parallel C. register_language ('name' => 'upc', 'Name' => 'Unified Parallel C', 'config_vars' => ['UPC'], 'linker' => 'UPCLINK', 'link' => '$(UPCLD) $(AM_UPCFLAGS) $(UPCFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@', 'autodep' => 'UPC', 'flags' => ['UPCFLAGS', 'CPPFLAGS'], 'compile' => "\$(UPC) @cpplike_flags \$(AM_UPCFLAGS) \$(UPCFLAGS)", 'ccer' => 'UPC', 'compiler' => 'UPCCOMPILE', 'compile_flag' => '-c', 'output_flag' => '-o', 'lder' => 'UPCLD', 'ld' => '$(UPC)', 'pure' => 1, 'extensions' => ['.upc']); # Headers. register_language ('name' => 'header', 'Name' => 'Header', 'extensions' => ['.h', '.H', '.hxx', '.h++', '.hh', '.hpp', '.inc'], # No output. 'output_extensions' => sub { return () }, # Nothing to do. '_finish' => sub { }); # Vala register_language ('name' => 'vala', 'Name' => 'Vala', 'config_vars' => ['VALAC'], 'flags' => [], 'compile' => '$(VALAC) $(AM_VALAFLAGS) $(VALAFLAGS)', 'ccer' => 'VALAC', 'compiler' => 'VALACOMPILE', 'extensions' => ['.vala'], 'output_extensions' => sub { (my $ext = $_[0]) =~ s/vala$/c/; return ($ext,) }, 'rule_file' => 'vala', '_finish' => \&lang_vala_finish, '_target_hook' => \&lang_vala_target_hook, 'nodist_specific' => 1); # Yacc (C & C++). register_language ('name' => 'yacc', 'Name' => 'Yacc', 'config_vars' => ['YACC'], 'flags' => ['YFLAGS'], 'compile' => '$(YACC) $(AM_YFLAGS) $(YFLAGS)', 'ccer' => 'YACC', 'compiler' => 'YACCCOMPILE', 'extensions' => ['.y'], 'output_extensions' => sub { (my $ext = $_[0]) =~ tr/y/c/; return ($ext,) }, 'rule_file' => 'yacc', '_finish' => \&lang_yacc_finish, '_target_hook' => \&lang_yacc_target_hook, 'nodist_specific' => 1); register_language ('name' => 'yaccxx', 'Name' => 'Yacc (C++)', 'config_vars' => ['YACC'], 'rule_file' => 'yacc', 'flags' => ['YFLAGS'], 'ccer' => 'YACC', 'compiler' => 'YACCCOMPILE', 'compile' => '$(YACC) $(AM_YFLAGS) $(YFLAGS)', 'extensions' => ['.y++', '.yy', '.yxx', '.ypp'], 'output_extensions' => sub { (my $ext = $_[0]) =~ tr/y/c/; return ($ext,) }, '_finish' => \&lang_yacc_finish, '_target_hook' => \&lang_yacc_target_hook, 'nodist_specific' => 1); # Lex (C & C++). register_language ('name' => 'lex', 'Name' => 'Lex', 'config_vars' => ['LEX'], 'rule_file' => 'lex', 'flags' => ['LFLAGS'], 'compile' => '$(LEX) $(AM_LFLAGS) $(LFLAGS)', 'ccer' => 'LEX', 'compiler' => 'LEXCOMPILE', 'extensions' => ['.l'], 'output_extensions' => sub { (my $ext = $_[0]) =~ tr/l/c/; return ($ext,) }, '_finish' => \&lang_lex_finish, '_target_hook' => \&lang_lex_target_hook, 'nodist_specific' => 1); register_language ('name' => 'lexxx', 'Name' => 'Lex (C++)', 'config_vars' => ['LEX'], 'rule_file' => 'lex', 'flags' => ['LFLAGS'], 'compile' => '$(LEX) $(AM_LFLAGS) $(LFLAGS)', 'ccer' => 'LEX', 'compiler' => 'LEXCOMPILE', 'extensions' => ['.l++', '.ll', '.lxx', '.lpp'], 'output_extensions' => sub { (my $ext = $_[0]) =~ tr/l/c/; return ($ext,) }, '_finish' => \&lang_lex_finish, '_target_hook' => \&lang_lex_target_hook, 'nodist_specific' => 1); # Assembler. register_language ('name' => 'asm', 'Name' => 'Assembler', 'config_vars' => ['CCAS', 'CCASFLAGS'], 'flags' => ['CCASFLAGS'], # Users can set AM_CCASFLAGS to include DEFS, INCLUDES, # or anything else required. They can also set CCAS. # Or simply use Preprocessed Assembler. 'compile' => '$(CCAS) $(AM_CCASFLAGS) $(CCASFLAGS)', 'ccer' => 'CCAS', 'compiler' => 'CCASCOMPILE', 'compile_flag' => '-c', 'output_flag' => '-o', 'extensions' => ['.s']); # Preprocessed Assembler. register_language ('name' => 'cppasm', 'Name' => 'Preprocessed Assembler', 'config_vars' => ['CCAS', 'CCASFLAGS'], 'autodep' => 'CCAS', 'flags' => ['CCASFLAGS', 'CPPFLAGS'], 'compile' => "\$(CCAS) @cpplike_flags \$(AM_CCASFLAGS) \$(CCASFLAGS)", 'ccer' => 'CPPAS', 'compiler' => 'CPPASCOMPILE', 'libtool_tag' => 'CC', 'compile_flag' => '-c', 'output_flag' => '-o', 'extensions' => ['.S', '.sx']); # Fortran 77 register_language ('name' => 'f77', 'Name' => 'Fortran 77', 'config_vars' => ['F77'], 'linker' => 'F77LINK', 'link' => '$(F77LD) $(AM_FFLAGS) $(FFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@', 'flags' => ['FFLAGS'], 'compile' => '$(F77) $(AM_FFLAGS) $(FFLAGS)', 'ccer' => 'F77', 'compiler' => 'F77COMPILE', 'compile_flag' => '-c', 'output_flag' => '-o', 'libtool_tag' => 'F77', 'lder' => 'F77LD', 'ld' => '$(F77)', 'pure' => 1, 'extensions' => ['.f', '.for']); # Fortran register_language ('name' => 'fc', 'Name' => 'Fortran', 'config_vars' => ['FC'], 'linker' => 'FCLINK', 'link' => '$(FCLD) $(AM_FCFLAGS) $(FCFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@', 'flags' => ['FCFLAGS'], 'compile' => '$(FC) $(AM_FCFLAGS) $(FCFLAGS)', 'ccer' => 'FC', 'compiler' => 'FCCOMPILE', 'compile_flag' => '-c', 'output_flag' => '-o', 'libtool_tag' => 'FC', 'lder' => 'FCLD', 'ld' => '$(FC)', 'pure' => 1, 'extensions' => ['.f90', '.f95', '.f03', '.f08']); # Preprocessed Fortran register_language ('name' => 'ppfc', 'Name' => 'Preprocessed Fortran', 'config_vars' => ['FC'], 'linker' => 'FCLINK', 'link' => '$(FCLD) $(AM_FCFLAGS) $(FCFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@', 'lder' => 'FCLD', 'ld' => '$(FC)', 'flags' => ['FCFLAGS', 'CPPFLAGS'], 'ccer' => 'PPFC', 'compiler' => 'PPFCCOMPILE', 'compile' => "\$(FC) @cpplike_flags \$(AM_FCFLAGS) \$(FCFLAGS)", 'compile_flag' => '-c', 'output_flag' => '-o', 'libtool_tag' => 'FC', 'pure' => 1, 'extensions' => ['.F90','.F95', '.F03', '.F08']); # Preprocessed Fortran 77 # # The current support for preprocessing Fortran 77 just involves # passing "$(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) # $(CPPFLAGS)" as additional flags to the Fortran 77 compiler, since # this is how GNU Make does it; see the "GNU Make Manual, Edition 0.51 # for 'make' Version 3.76 Beta" (specifically, from info file # '(make)Catalogue of Rules'). # # A better approach would be to write an Autoconf test # (i.e. AC_PROG_FPP) for a Fortran 77 preprocessor, because not all # Fortran 77 compilers know how to do preprocessing. The Autoconf # macro AC_PROG_FPP should test the Fortran 77 compiler first for # preprocessing capabilities, and then fall back on cpp (if cpp were # available). register_language ('name' => 'ppf77', 'Name' => 'Preprocessed Fortran 77', 'config_vars' => ['F77'], 'linker' => 'F77LINK', 'link' => '$(F77LD) $(AM_FFLAGS) $(FFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@', 'lder' => 'F77LD', 'ld' => '$(F77)', 'flags' => ['FFLAGS', 'CPPFLAGS'], 'ccer' => 'PPF77', 'compiler' => 'PPF77COMPILE', 'compile' => "\$(F77) @cpplike_flags \$(AM_FFLAGS) \$(FFLAGS)", 'compile_flag' => '-c', 'output_flag' => '-o', 'libtool_tag' => 'F77', 'pure' => 1, 'extensions' => ['.F']); # Ratfor. register_language ('name' => 'ratfor', 'Name' => 'Ratfor', 'config_vars' => ['F77'], 'linker' => 'F77LINK', 'link' => '$(F77LD) $(AM_FFLAGS) $(FFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@', 'lder' => 'F77LD', 'ld' => '$(F77)', 'flags' => ['RFLAGS', 'FFLAGS'], # FIXME also FFLAGS. 'compile' => '$(F77) $(AM_FFLAGS) $(FFLAGS) $(AM_RFLAGS) $(RFLAGS)', 'ccer' => 'F77', 'compiler' => 'RCOMPILE', 'compile_flag' => '-c', 'output_flag' => '-o', 'libtool_tag' => 'F77', 'pure' => 1, 'extensions' => ['.r']); # Java via gcj. register_language ('name' => 'java', 'Name' => 'Java', 'config_vars' => ['GCJ'], 'linker' => 'GCJLINK', 'link' => '$(GCJLD) $(AM_GCJFLAGS) $(GCJFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@', 'autodep' => 'GCJ', 'flags' => ['GCJFLAGS'], 'compile' => '$(GCJ) $(AM_GCJFLAGS) $(GCJFLAGS)', 'ccer' => 'GCJ', 'compiler' => 'GCJCOMPILE', 'compile_flag' => '-c', 'output_flag' => '-o', 'libtool_tag' => 'GCJ', 'lder' => 'GCJLD', 'ld' => '$(GCJ)', 'pure' => 1, 'extensions' => ['.java', '.class', '.zip', '.jar']); ################################################################ # Error reporting functions. # err_am ($MESSAGE, [%OPTIONS]) # ----------------------------- # Uncategorized errors about the current Makefile.am. sub err_am { msg_am ('error', @_); } # err_ac ($MESSAGE, [%OPTIONS]) # ----------------------------- # Uncategorized errors about configure.ac. sub err_ac { msg_ac ('error', @_); } # msg_am ($CHANNEL, $MESSAGE, [%OPTIONS]) # --------------------------------------- # Messages about about the current Makefile.am. sub msg_am { my ($channel, $msg, %opts) = @_; msg $channel, "${am_file}.am", $msg, %opts; } # msg_ac ($CHANNEL, $MESSAGE, [%OPTIONS]) # --------------------------------------- # Messages about about configure.ac. sub msg_ac { my ($channel, $msg, %opts) = @_; msg $channel, $configure_ac, $msg, %opts; } ################################################################ # subst ($TEXT) # ------------- # Return a configure-style substitution using the indicated text. # We do this to avoid having the substitutions directly in automake.in; # when we do that they are sometimes removed and this causes confusion # and bugs. sub subst { my ($text) = @_; return '@' . $text . '@'; } ################################################################ # $BACKPATH # backname ($RELDIR) # ------------------- # If I "cd $RELDIR", then to come back, I should "cd $BACKPATH". # For instance 'src/foo' => '../..'. # Works with non strictly increasing paths, i.e., 'src/../lib' => '..'. sub backname { my ($file) = @_; my @res; foreach (split (/\//, $file)) { next if $_ eq '.' || $_ eq ''; if ($_ eq '..') { pop @res or prog_error ("trying to reverse path '$file' pointing outside tree"); } else { push (@res, '..'); } } return join ('/', @res) || '.'; } ################################################################ # Silent rules handling functions. # verbose_var (NAME) # ------------------ # The public variable stem used to implement silent rules. sub verbose_var { my ($name) = @_; return 'AM_V_' . $name; } # verbose_private_var (NAME) # -------------------------- # The naming policy for the private variables for silent rules. sub verbose_private_var { my ($name) = @_; return 'am__v_' . $name; } # define_verbose_var (NAME, VAL-IF-SILENT, [VAL-IF-VERBOSE]) # ---------------------------------------------------------- # For silent rules, setup VAR and dispatcher, to expand to # VAL-IF-SILENT if silent, to VAL-IF-VERBOSE (defaulting to # empty) if not. sub define_verbose_var { my ($name, $silent_val, $verbose_val) = @_; $verbose_val = '' unless defined $verbose_val; my $var = verbose_var ($name); my $pvar = verbose_private_var ($name); my $silent_var = $pvar . '_0'; my $verbose_var = $pvar . '_1'; # For typical 'make's, 'configure' replaces AM_V (inside @@) with $(V) # and AM_DEFAULT_V (inside @@) with $(AM_DEFAULT_VERBOSITY). # For strict POSIX 2008 'make's, it replaces them with 0 or 1 instead. # See AM_SILENT_RULES in m4/silent.m4. define_variable ($var, '$(' . $pvar . '_@'.'AM_V'.'@)', INTERNAL); define_variable ($pvar . '_', '$(' . $pvar . '_@'.'AM_DEFAULT_V'.'@)', INTERNAL); Automake::Variable::define ($silent_var, VAR_AUTOMAKE, '', TRUE, $silent_val, '', INTERNAL, VAR_ASIS) if (! vardef ($silent_var, TRUE)); Automake::Variable::define ($verbose_var, VAR_AUTOMAKE, '', TRUE, $verbose_val, '', INTERNAL, VAR_ASIS) if (! vardef ($verbose_var, TRUE)); } # verbose_flag (NAME) # ------------------- # Contents of '%VERBOSE%' variable to expand before rule command. sub verbose_flag { my ($name) = @_; return '$(' . verbose_var ($name) . ')'; } sub verbose_nodep_flag { my ($name) = @_; return '$(' . verbose_var ($name) . subst ('am__nodep') . ')'; } # silent_flag # ----------- # Contents of %SILENT%: variable to expand to '@' when silent. sub silent_flag () { return verbose_flag ('at'); } # define_verbose_tagvar (NAME) # ---------------------------- # Engage the needed silent rules machinery for tag NAME. sub define_verbose_tagvar { my ($name) = @_; define_verbose_var ($name, '@echo " '. $name . ' ' x (8 - length ($name)) . '" $@;'); } # Engage the needed silent rules machinery for assorted texinfo commands. sub define_verbose_texinfo () { my @tagvars = ('DVIPS', 'MAKEINFO', 'INFOHTML', 'TEXI2DVI', 'TEXI2PDF'); foreach my $tag (@tagvars) { define_verbose_tagvar($tag); } define_verbose_var('texinfo', '-q'); define_verbose_var('texidevnull', '> /dev/null'); } # Engage the needed silent rules machinery for 'libtool --silent'. sub define_verbose_libtool () { define_verbose_var ('lt', '--silent'); return verbose_flag ('lt'); } sub handle_silent () { # Define "$(AM_V_P)", expanding to a shell conditional that can be # used in make recipes to determine whether we are being run in # silent mode or not. The choice of the name derives from the LISP # convention of appending the letter 'P' to denote a predicate (see # also "the '-P' convention" in the Jargon File); we do so for lack # of a better convention. define_verbose_var ('P', 'false', ':'); # *Always* provide the user with '$(AM_V_GEN)', unconditionally. define_verbose_tagvar ('GEN'); define_verbose_var ('at', '@'); } ################################################################ # Handle AUTOMAKE_OPTIONS variable. Return 0 on error, 1 otherwise. sub handle_options () { my $var = var ('AUTOMAKE_OPTIONS'); if ($var) { if ($var->has_conditional_contents) { msg_var ('unsupported', $var, "'AUTOMAKE_OPTIONS' cannot have conditional contents"); } my @options = map { { option => $_->[1], where => $_->[0] } } $var->value_as_list_recursive (cond_filter => TRUE, location => 1); return 0 unless process_option_list (@options); } if ($strictness == GNITS) { set_option ('readme-alpha', INTERNAL); set_option ('std-options', INTERNAL); set_option ('check-news', INTERNAL); } return 1; } # shadow_unconditionally ($varname, $where) # ----------------------------------------- # Return a $(variable) that contains all possible values # $varname can take. # If the VAR wasn't defined conditionally, return $(VAR). # Otherwise we create an am__VAR_DIST variable which contains # all possible values, and return $(am__VAR_DIST). sub shadow_unconditionally { my ($varname, $where) = @_; my $var = var $varname; if ($var->has_conditional_contents) { $varname = "am__${varname}_DIST"; my @files = uniq ($var->value_as_list_recursive); define_pretty_variable ($varname, TRUE, $where, @files); } return "\$($varname)" } # check_user_variables (@LIST) # ---------------------------- # Make sure each variable VAR in @LIST does not exist, suggest using AM_VAR # otherwise. sub check_user_variables { my @dont_override = @_; foreach my $flag (@dont_override) { my $var = var $flag; if ($var) { for my $cond ($var->conditions->conds) { if ($var->rdef ($cond)->owner == VAR_MAKEFILE) { msg_cond_var ('gnu', $cond, $flag, "'$flag' is a user variable, " . "you should not override it;\n" . "use 'AM_$flag' instead"); } } } } } # Call finish function for each language that was used. sub handle_languages () { if (! option 'no-dependencies') { # Include auto-dep code. Don't include it if DEP_FILES would # be empty. if (keys %extension_seen && keys %dep_files) { my @dep_files = sort keys %dep_files; # Set location of depcomp. define_variable ('depcomp', "\$(SHELL) $am_config_aux_dir/depcomp", INTERNAL); define_variable ('am__maybe_remake_depfiles', 'depfiles', INTERNAL); define_variable ('am__depfiles_remade', "@dep_files", INTERNAL); $output_rules .= "\n"; my @dist_rms; foreach my $depfile (@dep_files) { push @dist_rms, "\t-rm -f $depfile"; # Generate each 'include' directive individually. Several # make implementations (IRIX 6, Solaris 10, FreeBSD 8) will # fail to properly include several files resulting from a # variable expansion. Just Generating many separate includes # seems thus safest. $output_rules .= subst ('AMDEP_TRUE') . subst ('am__include') . " " . subst('am__quote') . $depfile . subst('am__quote') . " " . "# am--include-marker\n"; } require_conf_file ("$am_file.am", FOREIGN, 'depcomp'); $output_rules .= file_contents ( 'depend', new Automake::Location, 'DISTRMS' => join ("\n", @dist_rms)); } } else { define_variable ('depcomp', '', INTERNAL); define_variable ('am__maybe_remake_depfiles', '', INTERNAL); } my %done; # Is the C linker needed? my $needs_c = 0; foreach my $ext (sort keys %extension_seen) { next unless $extension_map{$ext}; my $lang = $languages{$extension_map{$ext}}; my $rule_file = $lang->rule_file || 'depend2'; # Get information on $LANG. my $pfx = $lang->autodep; my $fpfx = ($pfx eq '') ? 'CC' : $pfx; my ($AMDEP, $FASTDEP) = (option 'no-dependencies' || $lang->autodep eq 'no') ? ('FALSE', 'FALSE') : ('AMDEP', "am__fastdep$fpfx"); my $verbose = verbose_flag ($lang->ccer || 'GEN'); my $verbose_nodep = ($AMDEP eq 'FALSE') ? $verbose : verbose_nodep_flag ($lang->ccer || 'GEN'); my $silent = silent_flag (); my %transform = ('EXT' => $ext, 'PFX' => $pfx, 'FPFX' => $fpfx, 'AMDEP' => $AMDEP, 'FASTDEP' => $FASTDEP, '-c' => $lang->compile_flag || '', # These are not used, but they need to be defined # so transform() do not complain. SUBDIROBJ => 0, 'DERIVED-EXT' => 'BUG', DIST_SOURCE => 1, VERBOSE => $verbose, 'VERBOSE-NODEP' => $verbose_nodep, SILENT => $silent, ); # Generate the appropriate rules for this extension. if (((! option 'no-dependencies') && $lang->autodep ne 'no') || defined $lang->compile) { # Compute a possible derived extension. # This is not used by depend2.am. my $der_ext = ($lang->output_extensions->($ext))[0]; # When we output an inference rule like '.c.o:' we # have two cases to consider: either subdir-objects # is used, or it is not. # # In the latter case the rule is used to build objects # in the current directory, and dependencies always # go into './$(DEPDIR)/'. We can hard-code this value. # # In the former case the rule can be used to build # objects in sub-directories too. Dependencies should # go into the appropriate sub-directories, e.g., # 'sub/$(DEPDIR)/'. The value of this directory # needs to be computed on-the-fly. # # DEPBASE holds the name of this directory, plus the # basename part of the object file (extensions Po, TPo, # Plo, TPlo will be added later as appropriate). It is # either hardcoded, or a shell variable ('$depbase') that # will be computed by the rule. my $depbase = option ('subdir-objects') ? '$$depbase' : '$(DEPDIR)/$*'; $output_rules .= file_contents ($rule_file, new Automake::Location, %transform, GENERIC => 1, 'DERIVED-EXT' => $der_ext, DEPBASE => $depbase, BASE => '$*', SOURCE => '$<', SOURCEFLAG => $sourceflags{$ext} || '', OBJ => '$@', OBJOBJ => '$@', LTOBJ => '$@', COMPILE => '$(' . $lang->compiler . ')', LTCOMPILE => '$(LT' . $lang->compiler . ')', -o => $lang->output_flag, SUBDIROBJ => !! option 'subdir-objects'); } # Now include code for each specially handled object with this # language. my %seen_files = (); foreach my $file (@{$lang_specific_files{$lang->name}}) { my ($derived, $source, $obj, $myext, $srcext, %file_transform) = @$file; # We might see a given object twice, for instance if it is # used under different conditions. next if defined $seen_files{$obj}; $seen_files{$obj} = 1; prog_error ("found " . $lang->name . " in handle_languages, but compiler not defined") unless defined $lang->compile; my $obj_compile = $lang->compile; # Rewrite each occurrence of 'AM_$flag' in the compile # rule into '${derived}_$flag' if it exists. for my $flag (@{$lang->flags}) { my $val = "${derived}_$flag"; $obj_compile =~ s/\(AM_$flag\)/\($val\)/ if set_seen ($val); } my $libtool_tag = ''; if ($lang->libtool_tag && exists $libtool_tags{$lang->libtool_tag}) { $libtool_tag = '--tag=' . $lang->libtool_tag . ' ' } my $ptltflags = "${derived}_LIBTOOLFLAGS"; $ptltflags = 'AM_LIBTOOLFLAGS' unless set_seen $ptltflags; my $ltverbose = define_verbose_libtool (); my $obj_ltcompile = "\$(LIBTOOL) $ltverbose $libtool_tag\$($ptltflags) \$(LIBTOOLFLAGS) " . "--mode=compile $obj_compile"; # We _need_ '-o' for per object rules. my $output_flag = $lang->output_flag || '-o'; my $depbase = dirname ($obj); $depbase = '' if $depbase eq '.'; $depbase .= '/' unless $depbase eq ''; $depbase .= '$(DEPDIR)/' . basename ($obj); $output_rules .= file_contents ($rule_file, new Automake::Location, %transform, GENERIC => 0, DEPBASE => $depbase, BASE => $obj, SOURCE => $source, SOURCEFLAG => $sourceflags{$srcext} || '', # Use $myext and not '.o' here, in case # we are actually building a new source # file -- e.g. via yacc. OBJ => "$obj$myext", OBJOBJ => "$obj.obj", LTOBJ => "$obj.lo", VERBOSE => $verbose, 'VERBOSE-NODEP' => $verbose_nodep, SILENT => $silent, COMPILE => $obj_compile, LTCOMPILE => $obj_ltcompile, -o => $output_flag, %file_transform); } # The rest of the loop is done once per language. next if defined $done{$lang}; $done{$lang} = 1; # Load the language dependent Makefile chunks. my %lang = map { uc ($_) => 0 } keys %languages; $lang{uc ($lang->name)} = 1; $output_rules .= file_contents ('lang-compile', new Automake::Location, %transform, %lang); # If the source to a program consists entirely of code from a # 'pure' language, for instance C++ or Fortran 77, then we # don't need the C compiler code. However if we run into # something unusual then we do generate the C code. There are # probably corner cases here that do not work properly. # People linking Java code to Fortran code deserve pain. $needs_c ||= ! $lang->pure; define_compiler_variable ($lang) if ($lang->compile); define_linker_variable ($lang) if ($lang->link); require_variables ("$am_file.am", $lang->Name . " source seen", TRUE, @{$lang->config_vars}); # Call the finisher. $lang->finish; # Flags listed in '->flags' are user variables (per GNU Standards), # they should not be overridden in the Makefile... my @dont_override = @{$lang->flags}; # ... and so is LDFLAGS. push @dont_override, 'LDFLAGS' if $lang->link; check_user_variables @dont_override; } # If the project is entirely C++ or entirely Fortran 77 (i.e., 1 # suffix rule was learned), don't bother with the C stuff. But if # anything else creeps in, then use it. my @languages_seen = map { $languages{$extension_map{$_}}->name } (keys %extension_seen); @languages_seen = uniq (@languages_seen); $needs_c = 1 if @languages_seen > 1; if ($need_link || $needs_c) { define_compiler_variable ($languages{'c'}) unless defined $done{$languages{'c'}}; define_linker_variable ($languages{'c'}); } } # append_exeext { PREDICATE } $MACRO # ---------------------------------- # Append $(EXEEXT) to each filename in $F appearing in the Makefile # variable $MACRO if &PREDICATE($F) is true. @substitutions@ are # ignored. # # This is typically used on all filenames of *_PROGRAMS, and filenames # of TESTS that are programs. sub append_exeext (&$) { my ($pred, $macro) = @_; transform_variable_recursively ($macro, $macro, 'am__EXEEXT', 0, INTERNAL, sub { my ($subvar, $val, $cond, $full_cond) = @_; # Append $(EXEEXT) unless the user did it already, or it's a # @substitution@. $val .= '$(EXEEXT)' if $val !~ /(?:\$\(EXEEXT\)$|^[@]\w+[@]$)/ && &$pred ($val); return $val; }); } # Check to make sure a source defined in LIBOBJS is not explicitly # mentioned. This is a separate function (as opposed to being inlined # in handle_source_transform) because it isn't always appropriate to # do this check. sub check_libobjs_sources { my ($one_file, $unxformed) = @_; foreach my $prefix ('', 'EXTRA_', 'dist_', 'nodist_', 'dist_EXTRA_', 'nodist_EXTRA_') { my @files; my $varname = $prefix . $one_file . '_SOURCES'; my $var = var ($varname); if ($var) { @files = $var->value_as_list_recursive; } elsif ($prefix eq '') { @files = ($unxformed . '.c'); } else { next; } foreach my $file (@files) { err_var ($prefix . $one_file . '_SOURCES', "automatically discovered file '$file' should not" . " be explicitly mentioned") if defined $libsources{$file}; } } } # @OBJECTS # handle_single_transform ($VAR, $TOPPARENT, $DERIVED, $OBJ, $FILE, %TRANSFORM) # ----------------------------------------------------------------------------- # Does much of the actual work for handle_source_transform. # Arguments are: # $VAR is the name of the variable that the source filenames come from # $TOPPARENT is the name of the _SOURCES variable which is being processed # $DERIVED is the name of resulting executable or library # $OBJ is the object extension (e.g., '.lo') # $FILE the source file to transform # %TRANSFORM contains extras arguments to pass to file_contents # when producing explicit rules # Result is a list of the names of objects # %linkers_used will be updated with any linkers needed sub handle_single_transform { my ($var, $topparent, $derived, $obj, $_file, %transform) = @_; my @files = ($_file); my @result = (); # Turn sources into objects. We use a while loop like this # because we might add to @files in the loop. while (scalar @files > 0) { $_ = shift @files; # Configure substitutions in _SOURCES variables are errors. if (/^\@.*\@$/) { my $parent_msg = ''; $parent_msg = "\nand is referred to from '$topparent'" if $topparent ne $var->name; err_var ($var, "'" . $var->name . "' includes configure substitution '$_'" . $parent_msg . ";\nconfigure " . "substitutions are not allowed in _SOURCES variables"); next; } # If the source file is in a subdirectory then the '.o' is put # into the current directory, unless the subdir-objects option # is in effect. # Split file name into base and extension. next if ! /^(?:(.*)\/)?([^\/]*)($KNOWN_EXTENSIONS_PATTERN)$/; my $full = $_; my $directory = $1 || ''; my $base = $2; my $extension = $3; # We must generate a rule for the object if it requires its own flags. my $renamed = 0; my ($linker, $object); # This records whether we've seen a derived source file (e.g., yacc # or lex output). my $derived_source; # This holds the 'aggregate context' of the file we are # currently examining. If the file is compiled with # per-object flags, then it will be the name of the object. # Otherwise it will be 'AM'. This is used by the target hook # language function. my $aggregate = 'AM'; $extension = derive_suffix ($extension, $obj); my $lang; if ($extension_map{$extension} && ($lang = $languages{$extension_map{$extension}})) { # Found the language, so see what it says. saw_extension ($extension); # Do we have per-executable flags for this executable? my $have_per_exec_flags = 0; my @peflags = @{$lang->flags}; push @peflags, 'LIBTOOLFLAGS' if $obj eq '.lo'; foreach my $flag (@peflags) { if (set_seen ("${derived}_$flag")) { $have_per_exec_flags = 1; last; } } # Note: computed subr call. The language rewrite function # should return one of the LANG_* constants. It could # also return a list whose first value is such a constant # and whose second value is a new source extension which # should be applied. This means this particular language # generates another source file which we must then process # further. my $subr = \&{'lang_' . $lang->name . '_rewrite'}; defined &$subr or $subr = \&lang_sub_obj; my ($r, $source_extension) = &$subr ($directory, $base, $extension, $obj, $have_per_exec_flags, $var); # Skip this entry if we were asked not to process it. next if $r == LANG_IGNORE; # Now extract linker and other info. $linker = $lang->linker; my $this_obj_ext; if (defined $source_extension) { $this_obj_ext = $source_extension; $derived_source = 1; } else { $this_obj_ext = $obj; $derived_source = 0; # Don't ever place built object files in $(srcdir), # even when sources are specified explicitly as (say) # '$(srcdir)/foo.c' or '$(top_srcdir)/foo.c'. # See automake bug#13928. my @d = split '/', $directory; if (@d > 0 && option 'subdir-objects') { my $d = $d[0]; if ($d eq '$(srcdir)' or $d eq '${srcdir}') { shift @d; } elsif ($d eq '$(top_srcdir)' or $d eq '${top_srcdir}') { $d[0] = '$(top_builddir)'; } $directory = join '/', @d; } } $object = $base . $this_obj_ext; if ($have_per_exec_flags) { # We have a per-executable flag in effect for this # object. In this case we rewrite the object's # name to ensure it is unique. # We choose the name 'DERIVED_OBJECT' to ensure (1) uniqueness, # and (2) continuity between invocations. However, this will # result in a name that is too long for losing systems, in some # situations. So we attempt to shorten automatically under # subdir-objects, and provide _SHORTNAME to override as a last # resort. If subdir-object is in effect, it's usually # unnecessary to use the complete 'DERIVED_OBJECT' (that is # often the result from %canon_reldir%/%C% usage) since objects # are placed next to their source file. Generally, this means # it is already unique within that directory (see below for an # exception). Thus, we try to avoid unnecessarily long file # names by stripping the directory components of # 'DERIVED_OBJECT'. This allows avoiding explicit _SHORTNAME # usage in many cases. EXCEPTION: If two (or more) targets in # different directories but with the same base name (after # canonicalization), using target-specific FLAGS, link the same # object, then this logic clashes. Thus, we don't strip if # this is detected. my $dname = $derived; if ($directory ne '' && option 'subdir-objects' && none { $dname =~ /$_[0]$/ } @dup_shortnames) { # At this point, we don't clear information about what # parts of $derived are truly file name components. We can # determine that by comparing against the canonicalization # of $directory. my $dir = $directory . "/"; my $cdir = canonicalize ($dir); my $dir_len = length ($dir); # Make sure we only strip full file name components. This # is done by repeatedly trying to find cdir at the # beginning. Each iteration removes one file name # component from the end of cdir. while ($dir_len > 0 && index ($derived, $cdir) != 0) { # Eventually $dir_len becomes 0. $dir_len = rindex ($dir, "/", $dir_len - 2) + 1; $cdir = substr ($cdir, 0, $dir_len); } $dname = substr ($derived, $dir_len); } my $var = var ($derived . '_SHORTNAME'); if ($var) { # FIXME: should use the same Condition as # the _SOURCES variable. But this is really # silly overkill -- nobody should have # conditional shortnames. $dname = $var->variable_value; } $object = $dname . '-' . $object; prog_error ($lang->name . " flags defined without compiler") if ! defined $lang->compile; $renamed = 1; } # If rewrite said it was ok, put the object into a subdir. if ($directory ne '') { if ($r == LANG_SUBDIR) { $object = $directory . '/' . $object; } else { # Since the next major version of automake (2.0) will # make the behaviour so far only activated with the # 'subdir-object' option mandatory, it's better if we # start warning users not using that option. # As suggested by Peter Johansson, we strive to avoid # the warning when it would be irrelevant, i.e., if # all source files sit in "current" directory. msg_var 'unsupported', $var, "source file '$full' is in a subdirectory," . "\nbut option 'subdir-objects' is disabled"; msg 'unsupported', INTERNAL, <<'EOF', uniq_scope => US_GLOBAL; possible forward-incompatibility. At least a source file is in a subdirectory, but the 'subdir-objects' automake option hasn't been enabled. For now, the corresponding output object file(s) will be placed in the top-level directory. However, this behaviour will change in future Automake versions: they will unconditionally cause object files to be placed in the same subdirectory of the corresponding sources. You are advised to start using 'subdir-objects' option throughout your project, to avoid future incompatibilities. EOF } } # If the object file has been renamed (because per-target # flags are used) we cannot compile the file with an # inference rule: we need an explicit rule. # # If the source is in a subdirectory and the object is in # the current directory, we also need an explicit rule. # # If both source and object files are in a subdirectory # (this happens when the subdir-objects option is used), # then the inference will work. # # The latter case deserves a historical note. When the # subdir-objects option was added on 1999-04-11 it was # thought that inferences rules would work for # subdirectory objects too. Later, on 1999-11-22, # automake was changed to output explicit rules even for # subdir-objects. Nobody remembers why, but this occurred # soon after the merge of the user-dep-gen-branch so it # might be related. In late 2003 people complained about # the size of the generated Makefile.ins (libgcj, with # 2200+ subdir objects was reported to have a 9MB # Makefile), so we now rely on inference rules again. # Maybe we'll run across the same issue as in the past, # but at least this time we can document it. However since # dependency tracking has evolved it is possible that # our old problem no longer exists. # Using inference rules for subdir-objects has been tested # with GNU make, Solaris make, Ultrix make, BSD make, # HP-UX make, and OSF1 make successfully. if ($renamed || ($directory ne '' && ! option 'subdir-objects') # We must also use specific rules for a nodist_ source # if its language requests it. || ($lang->nodist_specific && ! $transform{'DIST_SOURCE'})) { my $obj_sans_ext = substr ($object, 0, - length ($this_obj_ext)); my $full_ansi; if ($directory ne '') { $full_ansi = $directory . '/' . $base . $extension; } else { $full_ansi = $base . $extension; } my @specifics = ($full_ansi, $obj_sans_ext, # Only use $this_obj_ext in the derived # source case because in the other case we # *don't* want $(OBJEXT) to appear here. ($derived_source ? $this_obj_ext : '.o'), $extension); # If we renamed the object then we want to use the # per-executable flag name. But if this is simply a # subdir build then we still want to use the AM_ flag # name. if ($renamed) { unshift @specifics, $derived; $aggregate = $derived; } else { unshift @specifics, 'AM'; } # Each item on this list is a reference to a list consisting # of four values followed by additional transform flags for # file_contents. The four values are the derived flag prefix # (e.g. for 'foo_CFLAGS', it is 'foo'), the name of the # source file, the base name of the output file, and # the extension for the object file. push (@{$lang_specific_files{$lang->name}}, [@specifics, %transform]); } } elsif ($extension eq $obj) { # This is probably the result of a direct suffix rule. # In this case we just accept the rewrite. $object = "$base$extension"; $object = "$directory/$object" if $directory ne ''; $linker = ''; } else { # No error message here. Used to have one, but it was # very unpopular. # FIXME: we could potentially do more processing here, # perhaps treating the new extension as though it were a # new source extension (as above). This would require # more restructuring than is appropriate right now. next; } err_am "object '$object' created by '$full' and '$object_map{$object}'" if (defined $object_map{$object} && $object_map{$object} ne $full); my $comp_val = (($object =~ /\.lo$/) ? COMPILE_LIBTOOL : COMPILE_ORDINARY); (my $comp_obj = $object) =~ s/\.lo$/.\$(OBJEXT)/; if (defined $object_compilation_map{$comp_obj} && $object_compilation_map{$comp_obj} != 0 # Only see the error once. && ($object_compilation_map{$comp_obj} != (COMPILE_LIBTOOL | COMPILE_ORDINARY)) && $object_compilation_map{$comp_obj} != $comp_val) { err_am "object '$comp_obj' created both with libtool and without"; } $object_compilation_map{$comp_obj} |= $comp_val; if (defined $lang) { # Let the language do some special magic if required. $lang->target_hook ($aggregate, $object, $full, %transform); } if ($derived_source) { prog_error ($lang->name . " has automatic dependency tracking") if $lang->autodep ne 'no'; # Make sure this new source file is handled next. That will # make it appear to be at the right place in the list. unshift (@files, $object); # Distribute derived sources unless the source they are # derived from is not. push_dist_common ($object) unless ($topparent =~ /^(?:nobase_)?nodist_/); next; } $linkers_used{$linker} = 1; push (@result, $object); if (! defined $object_map{$object}) { my @dep_list = (); $object_map{$object} = $full; # If resulting object is in subdir, we need to make # sure the subdir exists at build time. if ($object =~ /\//) { # FIXME: check that $DIRECTORY is somewhere in the # project # For Java, the way we're handling it right now, a # '..' component doesn't make sense. if ($lang && $lang->name eq 'java' && $object =~ /(\/|^)\.\.\//) { err_am "'$full' should not contain a '..' component"; } # Make sure *all* objects files in the subdirectory are # removed by "make mostlyclean". Not only this is more # efficient than listing the object files to be removed # individually (which would cause an 'rm' invocation for # each of them -- very inefficient, see bug#10697), it # would also leave stale object files in the subdirectory # whenever a source file there is removed or renamed. $compile_clean_files{"$directory/*.\$(OBJEXT)"} = MOSTLY_CLEAN; if ($object =~ /\.lo$/) { # If we have a libtool object, then we also must remove # any '.lo' objects in its same subdirectory. $compile_clean_files{"$directory/*.lo"} = MOSTLY_CLEAN; # Remember to cleanup .libs/ in this directory. $libtool_clean_directories{$directory} = 1; } push (@dep_list, require_build_directory ($directory)); # If we're generating dependencies, we also want # to make sure that the appropriate subdir of the # .deps directory is created. push (@dep_list, require_build_directory ($directory . '/$(DEPDIR)')) unless option 'no-dependencies'; } pretty_print_rule ($object . ':', "\t", @dep_list) if scalar @dep_list > 0; } # Transform .o or $o file into .P file (for automatic # dependency code). # Properly flatten multiple adjacent slashes, as Solaris 10 make # might fail over them in an include statement. # Leading double slashes may be special, as per Posix, so deal # with them carefully. if ($lang && $lang->autodep ne 'no') { my $depfile = $object; $depfile =~ s/\.([^.]*)$/.P$1/; $depfile =~ s/\$\(OBJEXT\)$/o/; my $maybe_extra_leading_slash = ''; $maybe_extra_leading_slash = '/' if $depfile =~ m,^//[^/],; $depfile =~ s,/+,/,g; my $basename = basename ($depfile); # This might make $dirname empty, but we account for that below. (my $dirname = dirname ($depfile)) =~ s/\/*$//; $dirname = $maybe_extra_leading_slash . $dirname; $dep_files{$dirname . '/$(DEPDIR)/' . $basename} = 1; } } return @result; } # $LINKER # define_objects_from_sources ($VAR, $OBJVAR, $NODEFINE, $ONE_FILE, # $OBJ, $PARENT, $TOPPARENT, $WHERE, %TRANSFORM) # --------------------------------------------------------------------------- # Define an _OBJECTS variable for a _SOURCES variable (or subvariable) # # Arguments are: # $VAR is the name of the _SOURCES variable # $OBJVAR is the name of the _OBJECTS variable if known (otherwise # it will be generated and returned). # $NODEFINE is a boolean: if true, $OBJVAR will not be defined (but # work done to determine the linker will be). # $ONE_FILE is the canonical (transformed) name of object to build # $OBJ is the object extension (i.e. either '.o' or '.lo'). # $TOPPARENT is the _SOURCES variable being processed. # $WHERE context into which this definition is done # %TRANSFORM extra arguments to pass to file_contents when producing # rules # # Result is a pair ($LINKER, $OBJVAR): # $LINKER is a boolean, true if a linker is needed to deal with the objects sub define_objects_from_sources { my ($var, $objvar, $nodefine, $one_file, $obj, $topparent, $where, %transform) = @_; my $needlinker = ""; transform_variable_recursively ($var, $objvar, 'am__objects', $nodefine, $where, # The transform code to run on each filename. sub { my ($subvar, $val, $cond, $full_cond) = @_; my @trans = handle_single_transform ($subvar, $topparent, $one_file, $obj, $val, %transform); $needlinker = "true" if @trans; return @trans; }); return $needlinker; } # handle_source_transform ($CANON_TARGET, $TARGET, $OBJEXT, $WHERE, %TRANSFORM) # ----------------------------------------------------------------------------- # Handle SOURCE->OBJECT transform for one program or library. # Arguments are: # canonical (transformed) name of target to build # actual target of object to build # object extension (i.e., either '.o' or '$o') # location of the source variable # extra arguments to pass to file_contents when producing rules # Return the name of the linker variable that must be used. # Empty return means just use 'LINK'. sub handle_source_transform { # one_file is canonical name. unxformed is given name. obj is # object extension. my ($one_file, $unxformed, $obj, $where, %transform) = @_; my $linker = ''; # No point in continuing if _OBJECTS is defined. return if reject_var ($one_file . '_OBJECTS', $one_file . '_OBJECTS should not be defined'); my %used_pfx = (); my $needlinker; %linkers_used = (); foreach my $prefix ('', 'EXTRA_', 'dist_', 'nodist_', 'dist_EXTRA_', 'nodist_EXTRA_') { my $varname = $prefix . $one_file . "_SOURCES"; my $var = var $varname; next unless $var; # We are going to define _OBJECTS variables using the prefix. # Then we glom them all together. So we can't use the null # prefix here as we need it later. my $xpfx = ($prefix eq '') ? 'am_' : $prefix; # Keep track of which prefixes we saw. $used_pfx{$xpfx} = 1 unless $prefix =~ /EXTRA_/; push @sources, "\$($varname)"; push @dist_sources, shadow_unconditionally ($varname, $where) unless (option ('no-dist') || $prefix =~ /^nodist_/); $needlinker |= define_objects_from_sources ($varname, $xpfx . $one_file . '_OBJECTS', !!($prefix =~ /EXTRA_/), $one_file, $obj, $varname, $where, DIST_SOURCE => ($prefix !~ /^nodist_/), %transform); } if ($needlinker) { $linker ||= resolve_linker (%linkers_used); } my @keys = sort keys %used_pfx; if (scalar @keys == 0) { # The default source for libfoo.la is libfoo.c, but for # backward compatibility we first look at libfoo_la.c, # if no default source suffix is given. my $old_default_source = "$one_file.c"; my $ext_var = var ('AM_DEFAULT_SOURCE_EXT'); my $default_source_ext = $ext_var ? variable_value ($ext_var) : '.c'; msg_var ('unsupported', $ext_var, $ext_var->name . " can assume at most one value") if $default_source_ext =~ /[\t ]/; (my $default_source = $unxformed) =~ s,(\.[^./\\]*)?$,$default_source_ext,; # TODO: Remove this backward-compatibility hack in Automake 2.0. if ($old_default_source ne $default_source && !$ext_var && (rule $old_default_source || rule '$(srcdir)/' . $old_default_source || rule '${srcdir}/' . $old_default_source || -f $old_default_source)) { my $loc = $where->clone; $loc->pop_context; msg ('obsolete', $loc, "the default source for '$unxformed' has been changed " . "to '$default_source'.\n(Using '$old_default_source' for " . "backward compatibility.)"); $default_source = $old_default_source; } # If a rule exists to build this source with a $(srcdir) # prefix, use that prefix in our variables too. This is for # the sake of BSD Make. if (rule '$(srcdir)/' . $default_source || rule '${srcdir}/' . $default_source) { $default_source = '$(srcdir)/' . $default_source; } define_variable ($one_file . "_SOURCES", $default_source, $where); push (@sources, $default_source); push (@dist_sources, $default_source); %linkers_used = (); my (@result) = handle_single_transform ($one_file . '_SOURCES', $one_file . '_SOURCES', $one_file, $obj, $default_source, %transform); $linker ||= resolve_linker (%linkers_used); define_pretty_variable ($one_file . '_OBJECTS', TRUE, $where, @result); } else { @keys = map { '$(' . $_ . $one_file . '_OBJECTS)' } @keys; define_pretty_variable ($one_file . '_OBJECTS', TRUE, $where, @keys); } # If we want to use 'LINK' we must make sure it is defined. if ($linker eq '') { $need_link = 1; } return $linker; } # handle_lib_objects ($XNAME, $VAR) # --------------------------------- # Special-case ALLOCA and LIBOBJS substitutions in _LDADD or _LIBADD variables. # Also, generate _DEPENDENCIES variable if appropriate. # Arguments are: # transformed name of object being built, or empty string if no object # name of _LDADD/_LIBADD-type variable to examine # Returns 1 if LIBOBJS seen, 0 otherwise. sub handle_lib_objects { my ($xname, $varname) = @_; my $var = var ($varname); prog_error "'$varname' undefined" unless $var; prog_error "unexpected variable name '$varname'" unless $varname =~ /^(.*)(?:LIB|LD)ADD$/; my $prefix = $1 || 'AM_'; my $seen_libobjs = 0; my $flagvar = 0; transform_variable_recursively ($varname, $xname . '_DEPENDENCIES', 'am__DEPENDENCIES', ! $xname, INTERNAL, # Transformation function, run on each filename. sub { my ($subvar, $val, $cond, $full_cond) = @_; if ($val =~ /^-/) { # Skip -lfoo and -Ldir silently; these are explicitly allowed. if ($val !~ /^-[lL]/ && # Skip -dlopen and -dlpreopen; these are explicitly allowed # for Libtool libraries or programs. (Actually we are a bit # lax here since this code also applies to non-libtool # libraries or programs, for which -dlopen and -dlopreopen # are pure nonsense. Diagnosing this doesn't seem very # important: the developer will quickly get complaints from # the linker.) $val !~ /^-dl(?:pre)?open$/ && # Only get this error once. ! $flagvar) { $flagvar = 1; # FIXME: should display a stack of nested variables # as context when $var != $subvar. err_var ($var, "linker flags such as '$val' belong in " . "'${prefix}LDFLAGS'"); } return (); } elsif ($val !~ /^\@.*\@$/) { # Assume we have a file of some sort, and output it into the # dependency variable. Autoconf substitutions are not output; # rarely is a new dependency substituted into e.g. foo_LDADD # -- but bad things (e.g. -lX11) are routinely substituted. # Note that LIBOBJS and ALLOCA are exceptions to this rule, # and handled specially below. return $val; } elsif ($val =~ /^\@(LT)?LIBOBJS\@$/) { handle_LIBOBJS ($subvar, $cond, $1); $seen_libobjs = 1; return $val; } elsif ($val =~ /^\@(LT)?ALLOCA\@$/) { handle_ALLOCA ($subvar, $cond, $1); return $val; } else { return (); } }); return $seen_libobjs; } # handle_LIBOBJS_or_ALLOCA ($VAR, $BASE) # -------------------------------------- # Definitions common to LIBOBJS and ALLOCA. # VAR should be one of LIBOBJS, LTLIBOBJS, ALLOCA, or LTALLOCA. # BASE should be one base file name from AC_LIBSOURCE, or alloca. sub handle_LIBOBJS_or_ALLOCA { my ($var, $base) = @_; my $dir = ''; # If LIBOBJS files must be built in another directory we have # to define LIBOBJDIR and ensure the files get cleaned. # Otherwise LIBOBJDIR can be left undefined, and the cleaning # is achieved by 'rm -f *.$(OBJEXT)' in compile.am. if ($config_libobj_dir && $relative_dir ne $config_libobj_dir) { if (option 'subdir-objects') { # In the top-level Makefile we do not use $(top_builddir), because # we are already there, and since the targets are built without # a $(top_builddir), it helps BSD Make to match them with # dependencies. $dir = "$config_libobj_dir/" if $config_libobj_dir ne '.'; $dir = backname ($relative_dir) . "/$dir" if $relative_dir ne '.'; define_variable ('LIBOBJDIR', "$dir", INTERNAL); if ($dir && !defined $clean_files{"$dir$base.\$(OBJEXT)"}) { my $dirstamp = require_build_directory ($dir); $output_rules .= "$dir$base.\$(OBJEXT): $dirstamp\n"; $output_rules .= "$dir$base.lo: $dirstamp\n" if ($var =~ /^LT/); } # libtool might create .$(OBJEXT) as a side-effect of using # LTLIBOBJS or LTALLOCA. $clean_files{"$dir$base.\$(OBJEXT)"} = MOSTLY_CLEAN; $clean_files{"$dir$base.lo"} = MOSTLY_CLEAN if ($var =~ /^LT/); } else { error ("'\$($var)' cannot be used outside '$config_libobj_dir' if" . " 'subdir-objects' is not set"); } } return $dir; } sub handle_LIBOBJS { my ($var, $cond, $lt) = @_; my $myobjext = $lt ? 'lo' : 'o'; $lt ||= ''; $var->requires_variables ("\@${lt}LIBOBJS\@ used", $lt . 'LIBOBJS') if ! keys %libsources; foreach my $iter (keys %libsources) { my $dir = ''; if ($iter =~ /^(.*)(\.[cly])$/) { saw_extension ($2); saw_extension ('.c'); $dir = handle_LIBOBJS_or_ALLOCA ("${lt}LIBOBJS", $1); } if ($iter =~ /\.h$/) { require_libsource_with_macro ($cond, $var, FOREIGN, $iter); } elsif ($iter ne 'alloca.c') { my $rewrite = $iter; $rewrite =~ s/\.c$/.P$myobjext/; $dep_files{$dir . '$(DEPDIR)/' . $rewrite} = 1; $rewrite = "^" . quotemeta ($iter) . "\$"; # Only require the file if it is not a built source. my $bs = var ('BUILT_SOURCES'); if (! $bs || ! grep (/$rewrite/, $bs->value_as_list_recursive)) { require_libsource_with_macro ($cond, $var, FOREIGN, $iter); } } } } sub handle_ALLOCA { my ($var, $cond, $lt) = @_; my $myobjext = $lt ? 'lo' : 'o'; $lt ||= ''; my $dir = handle_LIBOBJS_or_ALLOCA ("${lt}ALLOCA", "alloca"); $dir eq '' and $dir = './'; $var->requires_variables ("\@${lt}ALLOCA\@ used", $lt . 'ALLOCA'); $dep_files{$dir . '$(DEPDIR)/alloca.P' . $myobjext} = 1; require_libsource_with_macro ($cond, $var, FOREIGN, 'alloca.c'); saw_extension ('.c'); } # Canonicalize the input parameter. sub canonicalize { my ($string) = @_; $string =~ tr/A-Za-z0-9_\@/_/c; return $string; } # Canonicalize a name, and check to make sure the non-canonical name # is never used. Returns canonical name. Arguments are name and a # list of suffixes to check for. sub check_canonical_spelling { my ($name, @suffixes) = @_; my $xname = canonicalize ($name); if ($xname ne $name) { foreach my $xt (@suffixes) { reject_var ("$name$xt", "use '$xname$xt', not '$name$xt'"); } } return $xname; } # Set up the compile suite. sub handle_compile () { return if ! $must_handle_compiled_objects; # Boilerplate. my $default_includes = ''; if (! option 'nostdinc') { my @incs = ('-I.', subst ('am__isrc')); my $var = var 'CONFIG_HEADER'; if ($var) { foreach my $hdr (split (' ', $var->variable_value)) { push @incs, '-I' . dirname ($hdr); } } # We want '-I. -I$(srcdir)', but the latter -I is redundant # and unaesthetic in non-VPATH builds. We use `-I.@am__isrc@` # instead. It will be replaced by '-I.' or '-I. -I$(srcdir)'. # Items in CONFIG_HEADER are never in $(srcdir) so it is safe # to just put @am__isrc@ right after '-I.', without a space. ($default_includes = ' ' . uniq (@incs)) =~ s/ @/@/; } my (@mostly_rms, @dist_rms); foreach my $item (sort keys %compile_clean_files) { if ($compile_clean_files{$item} == MOSTLY_CLEAN) { push (@mostly_rms, "\t-rm -f $item"); } elsif ($compile_clean_files{$item} == DIST_CLEAN) { push (@dist_rms, "\t-rm -f $item"); } else { prog_error 'invalid entry in %compile_clean_files'; } } my ($coms, $vars, $rules) = file_contents_internal (1, "$libdir/am/compile.am", new Automake::Location, 'DEFAULT_INCLUDES' => $default_includes, 'MOSTLYRMS' => join ("\n", @mostly_rms), 'DISTRMS' => join ("\n", @dist_rms)); $output_vars .= $vars; $output_rules .= "$coms$rules"; } # Handle libtool rules. sub handle_libtool () { return unless var ('LIBTOOL'); # Libtool requires some files, but only at top level. # (Starting with Libtool 2.0 we do not have to bother. These # requirements are done with AC_REQUIRE_AUX_FILE.) require_conf_file_with_macro (TRUE, 'LIBTOOL', FOREIGN, @libtool_files) if $relative_dir eq '.' && ! $libtool_new_api; my @libtool_rms; foreach my $item (sort keys %libtool_clean_directories) { my $dir = ($item eq '.') ? '' : "$item/"; # .libs is for Unix, _libs for DOS. push (@libtool_rms, "\t-rm -rf ${dir}.libs ${dir}_libs"); } check_user_variables 'LIBTOOLFLAGS'; # Output the libtool compilation rules. $output_rules .= file_contents ('libtool', new Automake::Location, LTRMS => join ("\n", @libtool_rms)); } # Check for duplicate targets sub handle_targets () { my %seen = (); my @dups = (); @proglist = am_install_var ('progs', 'PROGRAMS', 'bin', 'sbin', 'libexec', 'pkglibexec', 'noinst', 'check'); @liblist = am_install_var ('libs', 'LIBRARIES', 'lib', 'pkglib', 'noinst', 'check'); @ltliblist = am_install_var ('ltlib', 'LTLIBRARIES', 'noinst', 'lib', 'pkglib', 'check'); # Record duplications that may arise after canonicalization of the # base names, in order to prevent object file clashes in the presence # of target-specific *FLAGS my @targetlist = (@proglist, @liblist, @ltliblist); foreach my $pair (@targetlist) { my $base = canonicalize (basename (@$pair[1])); push (@dup_shortnames, $base) if ($seen{$base}); $seen{$base} = $base; } } sub handle_programs () { return if ! @proglist; $must_handle_compiled_objects = 1; my $seen_global_libobjs = var ('LDADD') && handle_lib_objects ('', 'LDADD'); foreach my $pair (@proglist) { my ($where, $one_file) = @$pair; my $seen_libobjs = 0; my $obj = '.$(OBJEXT)'; $known_programs{$one_file} = $where; # Canonicalize names and check for misspellings. my $xname = check_canonical_spelling ($one_file, '_LDADD', '_LDFLAGS', '_SOURCES', '_OBJECTS', '_DEPENDENCIES'); $where->push_context ("while processing program '$one_file'"); $where->set (INTERNAL->get); my $linker = handle_source_transform ($xname, $one_file, $obj, $where, NONLIBTOOL => 1, LIBTOOL => 0); if (var ($xname . "_LDADD")) { $seen_libobjs = handle_lib_objects ($xname, $xname . '_LDADD'); } else { # User didn't define prog_LDADD override. So do it. define_variable ($xname . '_LDADD', '$(LDADD)', $where); # This does a bit too much work. But we need it to # generate _DEPENDENCIES when appropriate. if (var ('LDADD')) { $seen_libobjs = handle_lib_objects ($xname, 'LDADD'); } } reject_var ($xname . '_LIBADD', "use '${xname}_LDADD', not '${xname}_LIBADD'"); set_seen ($xname . '_DEPENDENCIES'); set_seen ('EXTRA_' . $xname . '_DEPENDENCIES'); set_seen ($xname . '_LDFLAGS'); # Determine program to use for link. my($xlink, $vlink) = define_per_target_linker_variable ($linker, $xname); $vlink = verbose_flag ($vlink || 'GEN'); # If the resulting program lies in a subdirectory, # ensure that the directory exists before we need it. my $dirstamp = require_build_directory_maybe ($one_file); $libtool_clean_directories{dirname ($one_file)} = 1; $output_rules .= file_contents ('program', $where, PROGRAM => $one_file, XPROGRAM => $xname, XLINK => $xlink, VERBOSE => $vlink, DIRSTAMP => $dirstamp, EXEEXT => '$(EXEEXT)'); if ($seen_libobjs || $seen_global_libobjs) { if (var ($xname . '_LDADD')) { check_libobjs_sources ($xname, $xname . '_LDADD'); } elsif (var ('LDADD')) { check_libobjs_sources ($xname, 'LDADD'); } } } } sub handle_libraries () { return if ! @liblist; $must_handle_compiled_objects = 1; my @prefix = am_primary_prefixes ('LIBRARIES', 0, 'lib', 'pkglib', 'noinst', 'check'); if (@prefix) { my $var = rvar ($prefix[0] . '_LIBRARIES'); $var->requires_variables ('library used', 'RANLIB'); } define_variable ('AR', 'ar', INTERNAL); define_variable ('ARFLAGS', 'cru', INTERNAL); define_verbose_tagvar ('AR'); foreach my $pair (@liblist) { my ($where, $onelib) = @$pair; my $seen_libobjs = 0; # Check that the library fits the standard naming convention. my $bn = basename ($onelib); if ($bn !~ /^lib.*\.a$/) { $bn =~ s/^(?:lib)?(.*?)(?:\.[^.]*)?$/lib$1.a/; my $suggestion = dirname ($onelib) . "/$bn"; $suggestion =~ s|^\./||g; msg ('error-gnu/warn', $where, "'$onelib' is not a standard library name\n" . "did you mean '$suggestion'?") } ($known_libraries{$onelib} = $bn) =~ s/\.a$//; $where->push_context ("while processing library '$onelib'"); $where->set (INTERNAL->get); my $obj = '.$(OBJEXT)'; # Canonicalize names and check for misspellings. my $xlib = check_canonical_spelling ($onelib, '_LIBADD', '_SOURCES', '_OBJECTS', '_DEPENDENCIES', '_AR'); if (! var ($xlib . '_AR')) { define_variable ($xlib . '_AR', '$(AR) $(ARFLAGS)', $where); } # Generate support for conditional object inclusion in # libraries. if (var ($xlib . '_LIBADD')) { if (handle_lib_objects ($xlib, $xlib . '_LIBADD')) { $seen_libobjs = 1; } } else { define_variable ($xlib . "_LIBADD", '', $where); } reject_var ($xlib . '_LDADD', "use '${xlib}_LIBADD', not '${xlib}_LDADD'"); # Make sure we at look at this. set_seen ($xlib . '_DEPENDENCIES'); set_seen ('EXTRA_' . $xlib . '_DEPENDENCIES'); handle_source_transform ($xlib, $onelib, $obj, $where, NONLIBTOOL => 1, LIBTOOL => 0); # If the resulting library lies in a subdirectory, # make sure this directory will exist. my $dirstamp = require_build_directory_maybe ($onelib); my $verbose = verbose_flag ('AR'); my $silent = silent_flag (); $output_rules .= file_contents ('library', $where, VERBOSE => $verbose, SILENT => $silent, LIBRARY => $onelib, XLIBRARY => $xlib, DIRSTAMP => $dirstamp); if ($seen_libobjs) { if (var ($xlib . '_LIBADD')) { check_libobjs_sources ($xlib, $xlib . '_LIBADD'); } } if (! $seen_ar) { msg ('extra-portability', $where, "'$onelib': linking libraries using a non-POSIX\n" . "archiver requires 'AM_PROG_AR' in '$configure_ac'") } } } sub handle_ltlibraries () { return if ! @ltliblist; $must_handle_compiled_objects = 1; my @prefix = am_primary_prefixes ('LTLIBRARIES', 0, 'lib', 'pkglib', 'noinst', 'check'); if (@prefix) { my $var = rvar ($prefix[0] . '_LTLIBRARIES'); $var->requires_variables ('Libtool library used', 'LIBTOOL'); } my %instdirs = (); my %instsubdirs = (); my %instconds = (); my %liblocations = (); # Location (in Makefile.am) of each library. foreach my $key (@prefix) { # Get the installation directory of each library. my $dir = $key; my $strip_subdir = 1; if ($dir =~ /^nobase_/) { $dir =~ s/^nobase_//; $strip_subdir = 0; } my $var = rvar ($key . '_LTLIBRARIES'); # We reject libraries which are installed in several places # in the same condition, because we can only specify one # '-rpath' option. $var->traverse_recursively (sub { my ($var, $val, $cond, $full_cond) = @_; my $hcond = $full_cond->human; my $where = $var->rdef ($cond)->location; my $ldir = ''; $ldir = '/' . dirname ($val) if (!$strip_subdir); # A library cannot be installed in different directories # in overlapping conditions. if (exists $instconds{$val}) { my ($msg, $acond) = $instconds{$val}->ambiguous_p ($val, $full_cond); if ($msg) { error ($where, $msg, partial => 1); my $dirtxt = "installed " . ($strip_subdir ? "in" : "below") . " '$dir'"; $dirtxt = "built for '$dir'" if $dir eq 'EXTRA' || $dir eq 'noinst' || $dir eq 'check'; my $dircond = $full_cond->true ? "" : " in condition $hcond"; error ($where, "'$val' should be $dirtxt$dircond ...", partial => 1); my $hacond = $acond->human; my $adir = $instdirs{$val}{$acond}; my $adirtxt = "installed in '$adir'"; $adirtxt = "built for '$adir'" if ($adir eq 'EXTRA' || $adir eq 'noinst' || $adir eq 'check'); my $adircond = $acond->true ? "" : " in condition $hacond"; my $onlyone = ($dir ne $adir) ? ("\nLibtool libraries can be built for only one " . "destination") : ""; error ($liblocations{$val}{$acond}, "... and should also be $adirtxt$adircond.$onlyone"); return; } } else { $instconds{$val} = new Automake::DisjConditions; } $instdirs{$val}{$full_cond} = $dir; $instsubdirs{$val}{$full_cond} = $ldir; $liblocations{$val}{$full_cond} = $where; $instconds{$val} = $instconds{$val}->merge ($full_cond); }, sub { return (); }, skip_ac_subst => 1); } foreach my $pair (@ltliblist) { my ($where, $onelib) = @$pair; my $seen_libobjs = 0; my $obj = '.lo'; # Canonicalize names and check for misspellings. my $xlib = check_canonical_spelling ($onelib, '_LIBADD', '_LDFLAGS', '_SOURCES', '_OBJECTS', '_DEPENDENCIES'); # Check that the library fits the standard naming convention. my $libname_rx = '^lib.*\.la'; my $ldvar = var ("${xlib}_LDFLAGS") || var ('AM_LDFLAGS'); my $ldvar2 = var ('LDFLAGS'); if (($ldvar && grep (/-module/, $ldvar->value_as_list_recursive)) || ($ldvar2 && grep (/-module/, $ldvar2->value_as_list_recursive))) { # Relax name checking for libtool modules. $libname_rx = '\.la'; } my $bn = basename ($onelib); if ($bn !~ /$libname_rx$/) { my $type = 'library'; if ($libname_rx eq '\.la') { $bn =~ s/^(lib|)(.*?)(?:\.[^.]*)?$/$1$2.la/; $type = 'module'; } else { $bn =~ s/^(?:lib)?(.*?)(?:\.[^.]*)?$/lib$1.la/; } my $suggestion = dirname ($onelib) . "/$bn"; $suggestion =~ s|^\./||g; msg ('error-gnu/warn', $where, "'$onelib' is not a standard libtool $type name\n" . "did you mean '$suggestion'?") } ($known_libraries{$onelib} = $bn) =~ s/\.la$//; $where->push_context ("while processing Libtool library '$onelib'"); $where->set (INTERNAL->get); # Make sure we look at these. set_seen ($xlib . '_LDFLAGS'); set_seen ($xlib . '_DEPENDENCIES'); set_seen ('EXTRA_' . $xlib . '_DEPENDENCIES'); # Generate support for conditional object inclusion in # libraries. if (var ($xlib . '_LIBADD')) { if (handle_lib_objects ($xlib, $xlib . '_LIBADD')) { $seen_libobjs = 1; } } else { define_variable ($xlib . "_LIBADD", '', $where); } reject_var ("${xlib}_LDADD", "use '${xlib}_LIBADD', not '${xlib}_LDADD'"); my $linker = handle_source_transform ($xlib, $onelib, $obj, $where, NONLIBTOOL => 0, LIBTOOL => 1); # Determine program to use for link. my($xlink, $vlink) = define_per_target_linker_variable ($linker, $xlib); $vlink = verbose_flag ($vlink || 'GEN'); my $rpathvar = "am_${xlib}_rpath"; my $rpath = "\$($rpathvar)"; foreach my $rcond ($instconds{$onelib}->conds) { my $val; if ($instdirs{$onelib}{$rcond} eq 'EXTRA' || $instdirs{$onelib}{$rcond} eq 'noinst' || $instdirs{$onelib}{$rcond} eq 'check') { # It's an EXTRA_ library, so we can't specify -rpath, # because we don't know where the library will end up. # The user probably knows, but generally speaking automake # doesn't -- and in fact configure could decide # dynamically between two different locations. $val = ''; } else { $val = ('-rpath $(' . $instdirs{$onelib}{$rcond} . 'dir)'); $val .= $instsubdirs{$onelib}{$rcond} if defined $instsubdirs{$onelib}{$rcond}; } if ($rcond->true) { # If $rcond is true there is only one condition and # there is no point defining an helper variable. $rpath = $val; } else { define_pretty_variable ($rpathvar, $rcond, INTERNAL, $val); } } # If the resulting library lies in a subdirectory, # make sure this directory will exist. my $dirstamp = require_build_directory_maybe ($onelib); # Remember to cleanup .libs/ in this directory. my $dirname = dirname $onelib; $libtool_clean_directories{$dirname} = 1; $output_rules .= file_contents ('ltlibrary', $where, LTLIBRARY => $onelib, XLTLIBRARY => $xlib, RPATH => $rpath, XLINK => $xlink, VERBOSE => $vlink, DIRSTAMP => $dirstamp); if ($seen_libobjs) { if (var ($xlib . '_LIBADD')) { check_libobjs_sources ($xlib, $xlib . '_LIBADD'); } } if (! $seen_ar) { msg ('extra-portability', $where, "'$onelib': linking libtool libraries using a non-POSIX\n" . "archiver requires 'AM_PROG_AR' in '$configure_ac'") } } } # See if any _SOURCES variable were misspelled. sub check_typos () { # It is ok if the user sets this particular variable. set_seen 'AM_LDFLAGS'; foreach my $primary ('SOURCES', 'LIBADD', 'LDADD', 'LDFLAGS', 'DEPENDENCIES') { foreach my $var (variables $primary) { my $varname = $var->name; # A configure variable is always legitimate. next if exists $configure_vars{$varname}; for my $cond ($var->conditions->conds) { $varname =~ /^(?:EXTRA_)?(?:nobase_)?(?:dist_|nodist_)?(.*)_[[:alnum:]]+$/; msg_var ('syntax', $var, "variable '$varname' is defined but no" . " program or\nlibrary has '$1' as canonical name" . " (possible typo)") unless $var->rdef ($cond)->seen; } } } } sub handle_scripts () { # NOTE we no longer automatically clean SCRIPTS, because it is # useful to sometimes distribute scripts verbatim. This happens # e.g. in Automake itself. am_install_var ('-candist', 'scripts', 'SCRIPTS', 'bin', 'sbin', 'libexec', 'pkglibexec', 'pkgdata', 'noinst', 'check'); } ## ------------------------ ## ## Handling Texinfo files. ## ## ------------------------ ## # ($OUTFILE, $VFILE) # scan_texinfo_file ($FILENAME) # ----------------------------- # $OUTFILE - name of the info file produced by $FILENAME. # $VFILE - name of the version.texi file used (undef if none). sub scan_texinfo_file { my ($filename) = @_; my $texi = new Automake::XFile "< $filename"; verb "reading $filename"; my ($outfile, $vfile); while ($_ = $texi->getline) { if (/^\@setfilename +(\S+)/) { # Honor only the first @setfilename. (It's possible to have # more occurrences later if the manual shows examples of how # to use @setfilename...) next if $outfile; $outfile = $1; if (index ($outfile, '.') < 0) { msg 'obsolete', "$filename:$.", "use of suffix-less info files is discouraged" } elsif ($outfile !~ /\.info$/) { error ("$filename:$.", "output '$outfile' has unrecognized extension"); return; } } # A "version.texi" file is actually any file whose name matches # "vers*.texi". elsif (/^\@include\s+(vers[^.]*\.texi)\s*$/) { $vfile = $1; } } if (! $outfile) { err_am "'$filename' missing \@setfilename"; return; } return ($outfile, $vfile); } # ($DIRSTAMP, @CLEAN_FILES) # output_texinfo_build_rules ($SOURCE, $DEST, $INSRC, @DEPENDENCIES) # ------------------------------------------------------------------ # SOURCE - the source Texinfo file # DEST - the destination Info file # INSRC - whether DEST should be built in the source tree # DEPENDENCIES - known dependencies sub output_texinfo_build_rules { my ($source, $dest, $insrc, @deps) = @_; # Split 'a.texi' into 'a' and '.texi'. my ($spfx, $ssfx) = ($source =~ /^(.*?)(\.[^.]*)?$/); my ($dpfx, $dsfx) = ($dest =~ /^(.*?)(\.[^.]*)?$/); $ssfx ||= ""; $dsfx ||= ""; # We can output two kinds of rules: the "generic" rules use Make # suffix rules and are appropriate when $source and $dest do not lie # in a sub-directory; the "specific" rules are needed in the other # case. # # The former are output only once (this is not really apparent here, # but just remember that some logic deeper in Automake will not # output the same rule twice); while the later need to be output for # each Texinfo source. my $generic; my $makeinfoflags; my $sdir = dirname $source; if ($sdir eq '.' && dirname ($dest) eq '.') { $generic = 1; $makeinfoflags = '-I $(srcdir)'; } else { $generic = 0; $makeinfoflags = "-I $sdir -I \$(srcdir)/$sdir"; } # A directory can contain two kinds of info files: some built in the # source tree, and some built in the build tree. The rules are # different in each case. However we cannot output two different # set of generic rules. Because in-source builds are more usual, we # use generic rules in this case and fall back to "specific" rules # for build-dir builds. (It should not be a problem to invert this # if needed.) $generic = 0 unless $insrc; # We cannot use a suffix rule to build info files with an empty # extension. Otherwise we would output a single suffix inference # rule, with separate dependencies, as in # # .texi: # $(MAKEINFO) ... # foo.info: foo.texi # # which confuse Solaris make. (See the Autoconf manual for # details.) Therefore we use a specific rule in this case. This # applies to info files only (dvi and pdf files always have an # extension). my $generic_info = ($generic && $dsfx) ? 1 : 0; # If the resulting file lies in a subdirectory, # make sure this directory will exist. my $dirstamp = require_build_directory_maybe ($dest); my $dipfx = ($insrc ? '$(srcdir)/' : '') . $dpfx; $output_rules .= file_contents ('texibuild', new Automake::Location, AM_V_MAKEINFO => verbose_flag('MAKEINFO'), AM_V_TEXI2DVI => verbose_flag('TEXI2DVI'), AM_V_TEXI2PDF => verbose_flag('TEXI2PDF'), DEPS => "@deps", DEST_PREFIX => $dpfx, DEST_INFO_PREFIX => $dipfx, DEST_SUFFIX => $dsfx, DIRSTAMP => $dirstamp, GENERIC => $generic, GENERIC_INFO => $generic_info, INSRC => $insrc, MAKEINFOFLAGS => $makeinfoflags, SILENT => silent_flag(), SOURCE => ($generic ? '$<' : $source), SOURCE_INFO => ($generic_info ? '$<' : $source), SOURCE_REAL => $source, SOURCE_SUFFIX => $ssfx, TEXIQUIET => verbose_flag('texinfo'), TEXIDEVNULL => verbose_flag('texidevnull'), ); return ($dirstamp, "$dpfx.dvi", "$dpfx.pdf", "$dpfx.ps", "$dpfx.html"); } # ($MOSTLYCLEAN, $TEXICLEAN, $MAINTCLEAN) # handle_texinfo_helper ($info_texinfos) # -------------------------------------- # Handle all Texinfo source; helper for 'handle_texinfo'. sub handle_texinfo_helper { my ($info_texinfos) = @_; my (@infobase, @info_deps_list, @texi_deps); my %versions; my $done = 0; my (@mostly_cleans, @texi_cleans, @maint_cleans) = ('', '', ''); # Build a regex matching user-cleaned files. my $d = var 'DISTCLEANFILES'; my $c = var 'CLEANFILES'; my @f = (); push @f, $d->value_as_list_recursive (inner_expand => 1) if $d; push @f, $c->value_as_list_recursive (inner_expand => 1) if $c; @f = map { s|[^A-Za-z_0-9*\[\]\-]|\\$&|g; s|\*|[^/]*|g; $_; } @f; my $user_cleaned_files = '^(?:' . join ('|', @f) . ')$'; foreach my $texi ($info_texinfos->value_as_list_recursive (inner_expand => 1)) { my $infobase = $texi; if ($infobase =~ s/\.texi$//) { 1; # Nothing more to do. } elsif ($infobase =~ s/\.(txi|texinfo)$//) { msg_var 'obsolete', $info_texinfos, "suffix '.$1' for Texinfo files is discouraged;" . " use '.texi' instead"; } else { # FIXME: report line number. err_am "texinfo file '$texi' has unrecognized extension"; next; } push @infobase, $infobase; # If 'version.texi' is referenced by input file, then include # automatic versioning capability. my ($out_file, $vtexi) = scan_texinfo_file ("$relative_dir/$texi") or next; # Directory of auxiliary files and build by-products used by texi2dvi # and texi2pdf. push @mostly_cleans, "$infobase.t2d"; push @mostly_cleans, "$infobase.t2p"; # If the Texinfo source is in a subdirectory, create the # resulting info in this subdirectory. If it is in the current # directory, try hard to not prefix "./" because it breaks the # generic rules. my $outdir = dirname ($texi) . '/'; $outdir = "" if $outdir eq './'; $out_file = $outdir . $out_file; # Until Automake 1.6.3, .info files were built in the # source tree. This was an obstacle to the support of # non-distributed .info files, and non-distributed .texi # files. # # * Non-distributed .texi files is important in some packages # where .texi files are built at make time, probably using # other binaries built in the package itself, maybe using # tools or information found on the build host. Because # these files are not distributed they are always rebuilt # at make time; they should therefore not lie in the source # directory. One plan was to support this using # nodist_info_TEXINFOS or something similar. (Doing this # requires some sanity checks. For instance Automake should # not allow: # dist_info_TEXINFOS = foo.texi # nodist_foo_TEXINFOS = included.texi # because a distributed file should never depend on a # non-distributed file.) # # * If .texi files are not distributed, then .info files should # not be distributed either. There are also cases where one # wants to distribute .texi files, but does not want to # distribute the .info files. For instance the Texinfo package # distributes the tool used to build these files; it would # be a waste of space to distribute them. It's not clear # which syntax we should use to indicate that .info files should # not be distributed. Akim Demaille suggested that eventually # we switch to a new syntax: # | Maybe we should take some inspiration from what's already # | done in the rest of Automake. Maybe there is too much # | syntactic sugar here, and you want # | nodist_INFO = bar.info # | dist_bar_info_SOURCES = bar.texi # | bar_texi_DEPENDENCIES = foo.texi # | with a bit of magic to have bar.info represent the whole # | bar*info set. That's a lot more verbose that the current # | situation, but it is # not new, hence the user has less # | to learn. # | # | But there is still too much room for meaningless specs: # | nodist_INFO = bar.info # | dist_bar_info_SOURCES = bar.texi # | dist_PS = bar.ps something-written-by-hand.ps # | nodist_bar_ps_SOURCES = bar.texi # | bar_texi_DEPENDENCIES = foo.texi # | here bar.texi is dist_ in line 2, and nodist_ in 4. # # Back to the point, it should be clear that in order to support # non-distributed .info files, we need to build them in the # build tree, not in the source tree (non-distributed .texi # files are less of a problem, because we do not output build # rules for them). In Automake 1.7 .info build rules have been # largely cleaned up so that .info files get always build in the # build tree, even when distributed. The idea was that # (1) if during a VPATH build the .info file was found to be # absent or out-of-date (in the source tree or in the # build tree), Make would rebuild it in the build tree. # If an up-to-date source-tree of the .info file existed, # make would not rebuild it in the build tree. # (2) having two copies of .info files, one in the source tree # and one (newer) in the build tree is not a problem # because 'make dist' always pick files in the build tree # first. # However it turned out the be a bad idea for several reasons: # * Tru64, OpenBSD, and FreeBSD (not NetBSD) Make do not behave # like GNU Make on point (1) above. These implementations # of Make would always rebuild .info files in the build # tree, even if such files were up to date in the source # tree. Consequently, it was impossible to perform a VPATH # build of a package containing Texinfo files using these # Make implementations. # (Refer to the Autoconf Manual, section "Limitation of # Make", paragraph "VPATH", item "target lookup", for # an account of the differences between these # implementations.) # * The GNU Coding Standards require these files to be built # in the source-tree (when they are distributed, that is). # * Keeping a fresher copy of distributed files in the # build tree can be annoying during development because # - if the files is kept under CVS, you really want it # to be updated in the source tree # - it is confusing that 'make distclean' does not erase # all files in the build tree. # # Consequently, starting with Automake 1.8, .info files are # built in the source tree again. Because we still plan to # support non-distributed .info files at some point, we # have a single variable ($INSRC) that controls whether # the current .info file must be built in the source tree # or in the build tree. Actually this variable is switched # off in two cases: # (1) For '.info' files that appear to be cleaned; this is for # backward compatibility with package such as Texinfo, # which do things like # info_TEXINFOS = texinfo.txi info-stnd.texi info.texi # DISTCLEANFILES = texinfo texinfo-* info*.info* # # Do not create info files for distribution. # dist-info: # in order not to distribute .info files. # (2) When the undocumented option 'info-in-builddir' is given. # This is done to allow the developers of GCC, GDB, GNU # binutils and the GNU bfd library to force the '.info' files # to be generated in the builddir rather than the srcdir, as # was once done when the (now removed) 'cygnus' option was # given. See automake bug#11034 for more discussion. my $insrc = 1; my $soutdir = '$(srcdir)/' . $outdir; if (option 'info-in-builddir') { $insrc = 0; } elsif ($out_file =~ $user_cleaned_files) { $insrc = 0; msg 'obsolete', "$am_file.am", < $texi, VTI => $vti, STAMPVTI => "${soutdir}stamp-$vti", VTEXI => "$soutdir$vtexi", MDDIR => $conf_dir, DIRSTAMP => $dirstamp); } } # Handle location of texinfo.tex. my $need_texi_file = 0; my $texinfodir; if (var ('TEXINFO_TEX')) { # The user defined TEXINFO_TEX so assume he knows what he is # doing. $texinfodir = ('$(srcdir)/' . dirname (variable_value ('TEXINFO_TEX'))); } elsif ($config_aux_dir_set_in_configure_ac) { $texinfodir = $am_config_aux_dir; define_variable ('TEXINFO_TEX', "$texinfodir/texinfo.tex", INTERNAL); $need_texi_file = 2; # so that we require_conf_file later } else { $texinfodir = '$(srcdir)'; $need_texi_file = 1; } define_variable ('am__TEXINFO_TEX_DIR', $texinfodir, INTERNAL); push (@dist_targets, 'dist-info'); if (! option 'no-installinfo') { # Make sure documentation is made and installed first. Use # $(INFO_DEPS), not 'info', because otherwise recursive makes # get run twice during "make all". unshift (@all, '$(INFO_DEPS)'); } define_files_variable ("DVIS", @infobase, 'dvi', INTERNAL); define_files_variable ("PDFS", @infobase, 'pdf', INTERNAL); define_files_variable ("PSS", @infobase, 'ps', INTERNAL); define_files_variable ("HTMLS", @infobase, 'html', INTERNAL); # This next isn't strictly needed now -- the places that look here # could easily be changed to look in info_TEXINFOS. But this is # probably better, in case noinst_TEXINFOS is ever supported. define_variable ("TEXINFOS", variable_value ('info_TEXINFOS'), INTERNAL); # Do some error checking. Note that this file is not required # when in Cygnus mode; instead we defined TEXINFO_TEX explicitly # up above. if ($need_texi_file && ! option 'no-texinfo.tex') { if ($need_texi_file > 1) { require_conf_file_with_macro (TRUE, 'info_TEXINFOS', FOREIGN, 'texinfo.tex'); } else { require_file_with_macro (TRUE, 'info_TEXINFOS', FOREIGN, 'texinfo.tex'); } } return (makefile_wrap ("", "\t ", @mostly_cleans), makefile_wrap ("", "\t ", @texi_cleans), makefile_wrap ("", "\t ", @maint_cleans)); } sub handle_texinfo () { reject_var 'TEXINFOS', "'TEXINFOS' is an anachronism; use 'info_TEXINFOS'"; # FIXME: I think this is an obsolete future feature name. reject_var 'html_TEXINFOS', "HTML generation not yet supported"; my $info_texinfos = var ('info_TEXINFOS'); my ($mostlyclean, $clean, $maintclean) = ('', '', ''); if ($info_texinfos) { define_verbose_texinfo; ($mostlyclean, $clean, $maintclean) = handle_texinfo_helper ($info_texinfos); chomp $mostlyclean; chomp $clean; chomp $maintclean; } $output_rules .= file_contents ('texinfos', new Automake::Location, AM_V_DVIPS => verbose_flag('DVIPS'), MOSTLYCLEAN => $mostlyclean, TEXICLEAN => $clean, MAINTCLEAN => $maintclean, 'LOCAL-TEXIS' => !!$info_texinfos, TEXIQUIET => verbose_flag('texinfo')); } sub handle_man_pages () { reject_var 'MANS', "'MANS' is an anachronism; use 'man_MANS'"; # Find all the sections in use. We do this by first looking for # "standard" sections, and then looking for any additional # sections used in man_MANS. my (%sections, %notrans_sections, %trans_sections, %notrans_vars, %trans_vars, %notrans_sect_vars, %trans_sect_vars); # We handle nodist_ for uniformity. man pages aren't distributed # by default so it isn't actually very important. foreach my $npfx ('', 'notrans_') { foreach my $pfx ('', 'dist_', 'nodist_') { # Add more sections as needed. foreach my $section ('0'..'9', 'n', 'l') { my $varname = $npfx . $pfx . 'man' . $section . '_MANS'; if (var ($varname)) { $sections{$section} = 1; $varname = '$(' . $varname . ')'; if ($npfx eq 'notrans_') { $notrans_sections{$section} = 1; $notrans_sect_vars{$varname} = 1; } else { $trans_sections{$section} = 1; $trans_sect_vars{$varname} = 1; } push_dist_common ($varname) if $pfx eq 'dist_'; } } my $varname = $npfx . $pfx . 'man_MANS'; my $var = var ($varname); if ($var) { foreach ($var->value_as_list_recursive) { # A page like 'foo.1c' goes into man1dir. if (/\.([0-9a-z])([a-z]*)$/) { $sections{$1} = 1; if ($npfx eq 'notrans_') { $notrans_sections{$1} = 1; } else { $trans_sections{$1} = 1; } } } $varname = '$(' . $varname . ')'; if ($npfx eq 'notrans_') { $notrans_vars{$varname} = 1; } else { $trans_vars{$varname} = 1; } push_dist_common ($varname) if $pfx eq 'dist_'; } } } return unless %sections; my @unsorted_deps; # Build section independent variables. my $have_notrans = %notrans_vars; my @notrans_list = sort keys %notrans_vars; my $have_trans = %trans_vars; my @trans_list = sort keys %trans_vars; # Now for each section, generate an install and uninstall rule. # Sort sections so output is deterministic. foreach my $section (sort keys %sections) { # Build section dependent variables. my $notrans_mans = $have_notrans || exists $notrans_sections{$section}; my $trans_mans = $have_trans || exists $trans_sections{$section}; my (%notrans_this_sect, %trans_this_sect); my $expr = 'man' . $section . '_MANS'; foreach my $varname (keys %notrans_sect_vars) { if ($varname =~ /$expr/) { $notrans_this_sect{$varname} = 1; } } foreach my $varname (keys %trans_sect_vars) { if ($varname =~ /$expr/) { $trans_this_sect{$varname} = 1; } } my @notrans_sect_list = sort keys %notrans_this_sect; my @trans_sect_list = sort keys %trans_this_sect; @unsorted_deps = (keys %notrans_vars, keys %trans_vars, keys %notrans_this_sect, keys %trans_this_sect); my @deps = sort @unsorted_deps; $output_rules .= file_contents ('mans', new Automake::Location, SECTION => $section, DEPS => "@deps", NOTRANS_MANS => $notrans_mans, NOTRANS_SECT_LIST => "@notrans_sect_list", HAVE_NOTRANS => $have_notrans, NOTRANS_LIST => "@notrans_list", TRANS_MANS => $trans_mans, TRANS_SECT_LIST => "@trans_sect_list", HAVE_TRANS => $have_trans, TRANS_LIST => "@trans_list"); } @unsorted_deps = (keys %notrans_vars, keys %trans_vars, keys %notrans_sect_vars, keys %trans_sect_vars); my @mans = sort @unsorted_deps; $output_vars .= file_contents ('mans-vars', new Automake::Location, MANS => "@mans"); push (@all, '$(MANS)') unless option 'no-installman'; } sub handle_data () { am_install_var ('-noextra', '-candist', 'data', 'DATA', 'data', 'dataroot', 'doc', 'dvi', 'html', 'pdf', 'ps', 'sysconf', 'sharedstate', 'localstate', 'pkgdata', 'lisp', 'noinst', 'check'); } sub handle_tags () { my @config; foreach my $spec (@config_headers) { my ($out, @ins) = split_config_file_spec ($spec); foreach my $in (@ins) { # If the config header source is in this directory, # require it. push @config, basename ($in) if $relative_dir eq dirname ($in); } } define_variable ('am__tagged_files', '$(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)' . "@config", INTERNAL); if (rvar('am__tagged_files')->value_as_list_recursive || var ('ETAGS_ARGS') || var ('SUBDIRS')) { $output_rules .= file_contents ('tags', new Automake::Location); set_seen 'TAGS_DEPENDENCIES'; } else { reject_var ('TAGS_DEPENDENCIES', "it doesn't make sense to define 'TAGS_DEPENDENCIES'" . " without\nsources or 'ETAGS_ARGS'"); # Every Makefile must define some sort of TAGS rule. # Otherwise, it would be possible for a top-level "make TAGS" # to fail because some subdirectory failed. Ditto ctags and # cscope. $output_rules .= "tags TAGS:\n\n" . "ctags CTAGS:\n\n" . "cscope cscopelist:\n\n"; } } # user_phony_rule ($NAME) # ----------------------- # Return false if rule $NAME does not exist. Otherwise, # declare it as phony, complete its definition (in case it is # conditional), and return its Automake::Rule instance. sub user_phony_rule { my ($name) = @_; my $rule = rule $name; if ($rule) { depend ('.PHONY', $name); # Define $NAME in all condition where it is not already defined, # so that it is always OK to depend on $NAME. for my $c ($rule->not_always_defined_in_cond (TRUE)->conds) { Automake::Rule::define ($name, 'internal', RULE_AUTOMAKE, $c, INTERNAL); $output_rules .= $c->subst_string . "$name:\n"; } } return $rule; } # Handle 'dist' target. sub handle_dist () { # Substitutions for distdir.am my %transform; # Define DIST_SUBDIRS. This must always be done, regardless of the # no-dist setting: target like 'distclean' or 'maintainer-clean' use it. my $subdirs = var ('SUBDIRS'); if ($subdirs) { # If SUBDIRS is conditionally defined, then set DIST_SUBDIRS # to all possible directories, and use it. If DIST_SUBDIRS is # defined, just use it. # Note that we check DIST_SUBDIRS first on purpose, so that # we don't call has_conditional_contents for now reason. # (In the past one project used so many conditional subdirectories # that calling has_conditional_contents on SUBDIRS caused # automake to grow to 150Mb -- this should not happen with # the current implementation of has_conditional_contents, # but it's more efficient to avoid the call anyway.) if (var ('DIST_SUBDIRS')) { } elsif ($subdirs->has_conditional_contents) { define_pretty_variable ('DIST_SUBDIRS', TRUE, INTERNAL, uniq ($subdirs->value_as_list_recursive)); } else { # We always define this because that is what 'distclean' # wants. define_pretty_variable ('DIST_SUBDIRS', TRUE, INTERNAL, '$(SUBDIRS)'); } } # The remaining definitions are only required when a dist target is used. return if option 'no-dist'; # At least one of the archive formats must be enabled. if ($relative_dir eq '.') { my $archive_defined = option 'no-dist-gzip' ? 0 : 1; $archive_defined ||= grep { option "dist-$_" } qw(shar zip tarZ bzip2 lzip xz); error (option 'no-dist-gzip', "no-dist-gzip specified but no dist-* specified,\n" . "at least one archive format must be enabled") unless $archive_defined; } # Look for common files that should be included in distribution. # If the aux dir is set, and it does not have a Makefile.am, then # we check for these files there as well. my $check_aux = 0; if ($relative_dir eq '.' && $config_aux_dir_set_in_configure_ac) { if (! is_make_dir ($config_aux_dir)) { $check_aux = 1; } } foreach my $cfile (@common_files) { if (dir_has_case_matching_file ($relative_dir, $cfile) # The file might be absent, but if it can be built it's ok. || rule $cfile) { push_dist_common ($cfile); } # Don't use 'elsif' here because a file might meaningfully # appear in both directories. if ($check_aux && dir_has_case_matching_file ($config_aux_dir, $cfile)) { push_dist_common ("$config_aux_dir/$cfile") } } # We might copy elements from @configure_dist_common to # @dist_common if we think we need to. If the file appears in our # directory, we would have discovered it already, so we don't # 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 # 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. # See also automake bug#9651. if ($relative_dir eq '.') { foreach my $file (@configure_dist_common) { my $dir = dirname ($file); push_dist_common ($file) if ($dir eq '.' || ! is_make_dir ($dir)); } @configure_dist_common = (); } # $(am__DIST_COMMON): files to be distributed automatically. Will be # appended to $(DIST_COMMON) in the generated Makefile. # Use 'sort' so that the expansion of $(DIST_COMMON) in the generated # Makefile is deterministic, in face of m4 and/or perl randomizations # (see automake bug#17908). define_pretty_variable ('am__DIST_COMMON', TRUE, INTERNAL, uniq (sort @dist_common)); # Now that we've processed @dist_common, disallow further attempts # to modify it. $handle_dist_run = 1; $transform{'DISTCHECK-HOOK'} = !! rule 'distcheck-hook'; $transform{'GETTEXT'} = $seen_gettext && !$seen_gettext_external; # If the target 'dist-hook' exists, make sure it is run. This # allows users to do random weird things to the distribution # before it is packaged up. push (@dist_targets, 'dist-hook') if user_phony_rule 'dist-hook'; $transform{'DIST-TARGETS'} = join (' ', @dist_targets); my $flm = option ('filename-length-max'); my $filename_filter = $flm ? '.' x $flm->[1] : ''; $output_rules .= file_contents ('distdir', new Automake::Location, %transform, FILENAME_FILTER => $filename_filter); } # check_directory ($NAME, $WHERE [, $RELATIVE_DIR = "."]) # ------------------------------------------------------- # Ensure $NAME is a directory (in $RELATIVE_DIR), and that it uses a sane # name. Use $WHERE as a location in the diagnostic, if any. sub check_directory { my ($dir, $where, $reldir) = @_; $reldir = '.' unless defined $reldir; error $where, "required directory $reldir/$dir does not exist" unless -d "$reldir/$dir"; # If an 'obj/' directory exists, BSD make will enter it before # reading 'Makefile'. Hence the 'Makefile' in the current directory # will not be read. # # % cat Makefile # all: # echo Hello # % cat obj/Makefile # all: # echo World # % make # GNU make # echo Hello # Hello # % pmake # BSD make # echo World # World msg ('portability', $where, "naming a subdirectory 'obj' causes troubles with BSD make") if $dir eq 'obj'; # 'aux' is probably the most important of the following forbidden name, # since it's tempting to use it as an AC_CONFIG_AUX_DIR. msg ('portability', $where, "name '$dir' is reserved on W32 and DOS platforms") if grep (/^\Q$dir\E$/i, qw/aux lpt1 lpt2 lpt3 com1 com2 com3 com4 con prn/); } # check_directories_in_var ($VARIABLE) # ------------------------------------ # Recursively check all items in variables $VARIABLE as directories sub check_directories_in_var { my ($var) = @_; $var->traverse_recursively (sub { my ($var, $val, $cond, $full_cond) = @_; check_directory ($val, $var->rdef ($cond)->location, $relative_dir); return (); }, undef, skip_ac_subst => 1); } sub handle_subdirs () { my $subdirs = var ('SUBDIRS'); return unless $subdirs; check_directories_in_var $subdirs; my $dsubdirs = var ('DIST_SUBDIRS'); check_directories_in_var $dsubdirs if $dsubdirs; $output_rules .= file_contents ('subdirs', new Automake::Location); rvar ('RECURSIVE_TARGETS')->rdef (TRUE)->{'pretty'} = VAR_SORTED; # Gross! } # ($REGEN, @DEPENDENCIES) # scan_aclocal_m4 # --------------- # If aclocal.m4 creation is automated, return the list of its dependencies. sub scan_aclocal_m4 () { my $regen_aclocal = 0; set_seen 'CONFIG_STATUS_DEPENDENCIES'; set_seen 'CONFIGURE_DEPENDENCIES'; if (-f 'aclocal.m4') { define_variable ("ACLOCAL_M4", '$(top_srcdir)/aclocal.m4', INTERNAL); my $aclocal = new Automake::XFile "< aclocal.m4"; my $line = $aclocal->getline; $regen_aclocal = $line =~ 'generated automatically by aclocal'; } my @ac_deps = (); if (set_seen ('ACLOCAL_M4_SOURCES')) { push (@ac_deps, '$(ACLOCAL_M4_SOURCES)'); msg_var ('obsolete', 'ACLOCAL_M4_SOURCES', "'ACLOCAL_M4_SOURCES' is obsolete.\n" . "It should be safe to simply remove it"); } # Note that it might be possible that aclocal.m4 doesn't exist but # should be auto-generated. This case probably isn't very # important. return ($regen_aclocal, @ac_deps); } # Helper function for 'substitute_ac_subst_variables'. sub substitute_ac_subst_variables_worker { my ($token) = @_; return "\@$token\@" if var $token; return "\${$token\}"; } # substitute_ac_subst_variables ($TEXT) # ------------------------------------- # Replace any occurrence of ${FOO} in $TEXT by @FOO@ if FOO is an AC_SUBST # variable. sub substitute_ac_subst_variables { my ($text) = @_; $text =~ s/\$[{]([^ \t=:+{}]+)}/substitute_ac_subst_variables_worker ($1)/ge; return $text; } # @DEPENDENCIES # prepend_srcdir (@INPUTS) # ------------------------ # Prepend $(srcdir) or $(top_srcdir) to all @INPUTS. The idea is that # if an input file has a directory part the same as the current # directory, then the directory part is simply replaced by $(srcdir). # But if the directory part is different, then $(top_srcdir) is # prepended. sub prepend_srcdir { my (@inputs) = @_; my @newinputs; foreach my $single (@inputs) { if (dirname ($single) eq $relative_dir) { push (@newinputs, '$(srcdir)/' . basename ($single)); } else { push (@newinputs, '$(top_srcdir)/' . $single); } } return @newinputs; } # @DEPENDENCIES # rewrite_inputs_into_dependencies ($OUTPUT, @INPUTS) # --------------------------------------------------- # Compute a list of dependencies appropriate for the rebuild # rule of # AC_CONFIG_FILES($OUTPUT:$INPUT[0]:$INPUTS[1]:...) # Also distribute $INPUTs which are not built by another AC_CONFIG_FOOs. sub rewrite_inputs_into_dependencies { my ($file, @inputs) = @_; my @res = (); for my $i (@inputs) { # We cannot create dependencies on shell variables. next if (substitute_ac_subst_variables $i) =~ /\$/; if (exists $ac_config_files_location{$i} && $i ne $file) { my $di = dirname $i; if ($di eq $relative_dir) { $i = basename $i; } # In the top-level Makefile we do not use $(top_builddir), because # we are already there, and since the targets are built without # a $(top_builddir), it helps BSD Make to match them with # dependencies. elsif ($relative_dir ne '.') { $i = '$(top_builddir)/' . $i; } } else { msg ('error', $ac_config_files_location{$file}, "required file '$i' not found") unless $i =~ /\$/ || exists $output_files{$i} || -f $i; ($i) = prepend_srcdir ($i); push_dist_common ($i); } push @res, $i; } return @res; } # handle_configure ($MAKEFILE_AM, $MAKEFILE_IN, $MAKEFILE, @INPUTS) # ----------------------------------------------------------------- # Handle remaking and configure stuff. # We need the name of the input file, to do proper remaking rules. sub handle_configure { my ($makefile_am, $makefile_in, $makefile, @inputs) = @_; prog_error 'empty @inputs' unless @inputs; my ($rel_makefile_am, $rel_makefile_in) = prepend_srcdir ($makefile_am, $makefile_in); my $rel_makefile = basename $makefile; my $colon_infile = ':' . join (':', @inputs); $colon_infile = '' if $colon_infile eq ":$makefile.in"; my @rewritten = rewrite_inputs_into_dependencies ($makefile, @inputs); my ($regen_aclocal_m4, @aclocal_m4_deps) = scan_aclocal_m4; define_pretty_variable ('am__aclocal_m4_deps', TRUE, INTERNAL, @configure_deps, @aclocal_m4_deps, '$(top_srcdir)/' . $configure_ac); my @configuredeps = ('$(am__aclocal_m4_deps)', '$(CONFIGURE_DEPENDENCIES)'); push @configuredeps, '$(ACLOCAL_M4)' if -f 'aclocal.m4'; define_pretty_variable ('am__configure_deps', TRUE, INTERNAL, @configuredeps); my $automake_options = '--' . $strictness_name . (global_option 'no-dependencies' ? ' --ignore-deps' : ''); $output_rules .= file_contents ('configure', new Automake::Location, MAKEFILE => $rel_makefile, 'MAKEFILE-DEPS' => "@rewritten", 'CONFIG-MAKEFILE' => ($relative_dir eq '.') ? '$@' : '$(subdir)/$@', 'MAKEFILE-IN' => $rel_makefile_in, 'HAVE-MAKEFILE-IN-DEPS' => (@include_stack > 0), 'MAKEFILE-IN-DEPS' => "@include_stack", 'MAKEFILE-AM' => $rel_makefile_am, 'AUTOMAKE-OPTIONS' => $automake_options, 'MAKEFILE-AM-SOURCES' => "$makefile$colon_infile", 'REGEN-ACLOCAL-M4' => $regen_aclocal_m4, VERBOSE => verbose_flag ('GEN')); if ($relative_dir eq '.') { push_dist_common ('acconfig.h') if -f 'acconfig.h'; } # If we have a configure header, require it. my $hdr_index = 0; my @distclean_config; foreach my $spec (@config_headers) { $hdr_index += 1; # $CONFIG_H_PATH: config.h from top level. my ($config_h_path, @ins) = split_config_file_spec ($spec); my $config_h_dir = dirname ($config_h_path); # If the header is in the current directory we want to build # the header here. Otherwise, if we're at the topmost # directory and the header's directory doesn't have a # Makefile, then we also want to build the header. if ($relative_dir eq $config_h_dir || ($relative_dir eq '.' && ! is_make_dir ($config_h_dir))) { my ($cn_sans_dir, $stamp_dir); if ($relative_dir eq $config_h_dir) { $cn_sans_dir = basename ($config_h_path); $stamp_dir = ''; } else { $cn_sans_dir = $config_h_path; if ($config_h_dir eq '.') { $stamp_dir = ''; } else { $stamp_dir = $config_h_dir . '/'; } } # This will also distribute all inputs. @ins = rewrite_inputs_into_dependencies ($config_h_path, @ins); # Cannot define rebuild rules for filenames with shell variables. next if (substitute_ac_subst_variables $config_h_path) =~ /\$/; # Header defined in this directory. my @files; if (-f $config_h_path . '.top') { push (@files, "$cn_sans_dir.top"); } if (-f $config_h_path . '.bot') { push (@files, "$cn_sans_dir.bot"); } push_dist_common (@files); # For now, acconfig.h can only appear in the top srcdir. if (-f 'acconfig.h') { push (@files, '$(top_srcdir)/acconfig.h'); } my $stamp = "${stamp_dir}stamp-h${hdr_index}"; $output_rules .= file_contents ('remake-hdr', new Automake::Location, FILES => "@files", 'FIRST-HDR' => ($hdr_index == 1), CONFIG_H => $cn_sans_dir, CONFIG_HIN => $ins[0], CONFIG_H_DEPS => "@ins", CONFIG_H_PATH => $config_h_path, STAMP => "$stamp"); push @distclean_config, $cn_sans_dir, $stamp; } } $output_rules .= file_contents ('clean-hdr', new Automake::Location, FILES => "@distclean_config") if @distclean_config; # Distribute and define mkinstalldirs only if it is already present # in the package, for backward compatibility (some people may still # use $(mkinstalldirs)). # TODO: start warning about this in Automake 1.14, and have # TODO: Automake 2.0 drop it (and the mkinstalldirs script # TODO: as well). my $mkidpath = "$config_aux_dir/mkinstalldirs"; if (-f $mkidpath) { # Use require_file so that any existing script gets updated # by --force-missing. require_conf_file ($mkidpath, FOREIGN, 'mkinstalldirs'); define_variable ('mkinstalldirs', "\$(SHELL) $am_config_aux_dir/mkinstalldirs", INTERNAL); } else { # Use $(install_sh), not $(MKDIR_P) because the latter requires # at least one argument, and $(mkinstalldirs) used to work # even without arguments (e.g. $(mkinstalldirs) $(conditional_dir)). define_variable ('mkinstalldirs', '$(install_sh) -d', INTERNAL); } reject_var ('CONFIG_HEADER', "'CONFIG_HEADER' is an anachronism; now determined " . "automatically\nfrom '$configure_ac'"); my @config_h; foreach my $spec (@config_headers) { my ($out, @ins) = split_config_file_spec ($spec); # Generate CONFIG_HEADER define. if ($relative_dir eq dirname ($out)) { push @config_h, basename ($out); } else { push @config_h, "\$(top_builddir)/$out"; } } define_variable ("CONFIG_HEADER", "@config_h", INTERNAL) if @config_h; # Now look for other files in this directory which must be remade # by config.status, and generate rules for them. my @actual_other_files = (); # These get cleaned only in a VPATH build. my @actual_other_vpath_files = (); foreach my $lfile (@other_input_files) { my $file; my @inputs; if ($lfile =~ /^([^:]*):(.*)$/) { # This is the ":" syntax of AC_OUTPUT. $file = $1; @inputs = split (':', $2); } else { # Normal usage. $file = $lfile; @inputs = $file . '.in'; } # Automake files should not be stored in here, but in %MAKE_LIST. prog_error ("$lfile in \@other_input_files\n" . "\@other_input_files = (@other_input_files)") if -f $file . '.am'; my $local = basename ($file); # We skip files that aren't in this directory. However, if # the file's directory does not have a Makefile, and we are # currently doing '.', then we create a rule to rebuild the # file in the subdir. my $fd = dirname ($file); if ($fd ne $relative_dir) { if ($relative_dir eq '.' && ! is_make_dir ($fd)) { $local = $file; } else { next; } } my @rewritten_inputs = rewrite_inputs_into_dependencies ($file, @inputs); # Cannot output rules for shell variables. next if (substitute_ac_subst_variables $local) =~ /\$/; my $condstr = ''; my $cond = $ac_config_files_condition{$lfile}; if (defined $cond) { $condstr = $cond->subst_string; Automake::Rule::define ($local, $configure_ac, RULE_AUTOMAKE, $cond, $ac_config_files_location{$file}); } $output_rules .= ($condstr . $local . ': ' . '$(top_builddir)/config.status ' . "@rewritten_inputs\n" . $condstr . "\t" . 'cd $(top_builddir) && ' . '$(SHELL) ./config.status ' . ($relative_dir eq '.' ? '' : '$(subdir)/') . '$@' . "\n"); push (@actual_other_files, $local); } # For links we should clean destinations and distribute sources. foreach my $spec (@config_links) { my ($link, $file) = split /:/, $spec; # Some people do AC_CONFIG_LINKS($computed). We only handle # the DEST:SRC form. next unless $file; my $where = $ac_config_files_location{$link}; # Skip destinations that contain shell variables. if ((substitute_ac_subst_variables $link) !~ /\$/) { # We skip links that aren't in this directory. However, if # the link's directory does not have a Makefile, and we are # currently doing '.', then we add the link to CONFIG_CLEAN_FILES # in '.'s Makefile.in. my $local = basename ($link); my $fd = dirname ($link); if ($fd ne $relative_dir) { if ($relative_dir eq '.' && ! is_make_dir ($fd)) { $local = $link; } else { $local = undef; } } if ($file ne $link) { push @actual_other_files, $local if $local; } else { push @actual_other_vpath_files, $local if $local; } } # Do not process sources that contain shell variables. if ((substitute_ac_subst_variables $file) !~ /\$/) { my $fd = dirname ($file); # We distribute files that are in this directory. # At the top-level ('.') we also distribute files whose # directory does not have a Makefile. if (($fd eq $relative_dir) || ($relative_dir eq '.' && ! is_make_dir ($fd))) { # The following will distribute $file as a side-effect when # it is appropriate (i.e., when $file is not already an output). # We do not need the result, just the side-effect. rewrite_inputs_into_dependencies ($link, $file); } } } # These files get removed by "make distclean". define_pretty_variable ('CONFIG_CLEAN_FILES', TRUE, INTERNAL, @actual_other_files); define_pretty_variable ('CONFIG_CLEAN_VPATH_FILES', TRUE, INTERNAL, @actual_other_vpath_files); } sub handle_headers () { my @r = am_install_var ('-defaultdist', 'header', 'HEADERS', 'include', 'oldinclude', 'pkginclude', 'noinst', 'check'); foreach (@r) { next unless $_->[1] =~ /\..*$/; saw_extension ($&); } } sub handle_gettext () { return if ! $seen_gettext || $relative_dir ne '.'; my $subdirs = var 'SUBDIRS'; if (! $subdirs) { err_ac "AM_GNU_GETTEXT used but SUBDIRS not defined"; return; } # Perform some sanity checks to help users get the right setup. # We disable these tests when po/ doesn't exist in order not to disallow # unusual gettext setups. # # Bruno Haible: # | The idea is: # | # | 1) If a package doesn't have a directory po/ at top level, it # | will likely have multiple po/ directories in subpackages. # | # | 2) It is useful to warn for the absence of intl/ if AM_GNU_GETTEXT # | is used without 'external'. It is also useful to warn for the # | presence of intl/ if AM_GNU_GETTEXT([external]) is used. Both # | warnings apply only to the usual layout of packages, therefore # | they should both be disabled if no po/ directory is found at # | top level. if (-d 'po') { my @subdirs = $subdirs->value_as_list_recursive; msg_var ('syntax', $subdirs, "AM_GNU_GETTEXT used but 'po' not in SUBDIRS") if ! grep ($_ eq 'po', @subdirs); # intl/ is not required when AM_GNU_GETTEXT is called with the # 'external' option and AM_GNU_GETTEXT_INTL_SUBDIR is not called. msg_var ('syntax', $subdirs, "AM_GNU_GETTEXT used but 'intl' not in SUBDIRS") if (! ($seen_gettext_external && ! $seen_gettext_intl) && ! grep ($_ eq 'intl', @subdirs)); # intl/ should not be used with AM_GNU_GETTEXT([external]), except # if AM_GNU_GETTEXT_INTL_SUBDIR is called. msg_var ('syntax', $subdirs, "'intl' should not be in SUBDIRS when " . "AM_GNU_GETTEXT([external]) is used") if ($seen_gettext_external && ! $seen_gettext_intl && grep ($_ eq 'intl', @subdirs)); } require_file ($ac_gettext_location, GNU, 'ABOUT-NLS'); } # Emit makefile footer. sub handle_footer () { reject_rule ('.SUFFIXES', "use variable 'SUFFIXES', not target '.SUFFIXES'"); # Note: AIX 4.1 /bin/make will fail if any suffix rule appears # before .SUFFIXES. So we make sure that .SUFFIXES appears before # anything else, by sticking it right after the default: target. $output_header .= ".SUFFIXES:\n"; my $suffixes = var 'SUFFIXES'; my @suffixes = Automake::Rule::suffixes; if (@suffixes || $suffixes) { # Make sure SUFFIXES has unique elements. Sort them to ensure # the output remains consistent. However, $(SUFFIXES) is # always at the start of the list, unsorted. This is done # because make will choose rules depending on the ordering of # suffixes, and this lets the user have some control. Push # actual suffixes, and not $(SUFFIXES). Some versions of make # do not like variable substitutions on the .SUFFIXES line. my @user_suffixes = ($suffixes ? $suffixes->value_as_list_recursive : ()); my %suffixes = map { $_ => 1 } @suffixes; delete @suffixes{@user_suffixes}; $output_header .= (".SUFFIXES: " . join (' ', @user_suffixes, sort keys %suffixes) . "\n"); } $output_trailer .= file_contents ('footer', new Automake::Location); } # Generate 'make install' rules. sub handle_install () { $output_rules .= file_contents ('install', new Automake::Location, maybe_BUILT_SOURCES => (set_seen ('BUILT_SOURCES') ? (" \$(BUILT_SOURCES)\n" . "\t\$(MAKE) \$(AM_MAKEFLAGS)") : ''), 'installdirs-local' => (user_phony_rule ('installdirs-local') ? ' installdirs-local' : ''), am__installdirs => variable_value ('am__installdirs') || ''); } # handle_all ($MAKEFILE) #----------------------- # Deal with 'all' and 'all-am'. sub handle_all { my ($makefile) = @_; # Output 'all-am'. # Put this at the beginning for the sake of non-GNU makes. This # is still wrong if these makes can run parallel jobs. But it is # right enough. unshift (@all, basename ($makefile)); foreach my $spec (@config_headers) { my ($out, @ins) = split_config_file_spec ($spec); push (@all, basename ($out)) if dirname ($out) eq $relative_dir; } # Install 'all' hooks. push (@all, "all-local") if user_phony_rule "all-local"; pretty_print_rule ("all-am:", "\t\t", @all); depend ('.PHONY', 'all-am', 'all'); # Output 'all'. my @local_headers = (); push @local_headers, '$(BUILT_SOURCES)' if var ('BUILT_SOURCES'); foreach my $spec (@config_headers) { my ($out, @ins) = split_config_file_spec ($spec); push @local_headers, basename ($out) if dirname ($out) eq $relative_dir; } if (@local_headers) { # We need to make sure config.h is built before we recurse. # We also want to make sure that built sources are built # before any ordinary 'all' targets are run. We can't do this # by changing the order of dependencies to the "all" because # that breaks when using parallel makes. Instead we handle # things explicitly. $output_all .= ("all: @local_headers" . "\n\t" . '$(MAKE) $(AM_MAKEFLAGS) ' . (var ('SUBDIRS') ? 'all-recursive' : 'all-am') . "\n\n"); depend ('.MAKE', 'all'); } else { $output_all .= "all: " . (var ('SUBDIRS') ? 'all-recursive' : 'all-am') . "\n\n"; } } # Generate helper targets for user-defined recursive targets, where needed. sub handle_user_recursion () { return unless @extra_recursive_targets; define_pretty_variable ('am__extra_recursive_targets', TRUE, INTERNAL, map { "$_-recursive" } @extra_recursive_targets); my $aux = var ('SUBDIRS') ? 'recursive' : 'am'; foreach my $target (@extra_recursive_targets) { # This allows the default target's rules to be overridden in # Makefile.am. user_phony_rule ($target); depend ("$target", "$target-$aux"); depend ("$target-am", "$target-local"); # Every user-defined recursive target 'foo' *must* have a valid # associated 'foo-local' rule; we define it as an empty rule by # default, so that the user can transparently extend it in his # own Makefile.am. pretty_print_rule ("$target-local:", '', ''); # $target-recursive might as well be undefined, so do not add # it here; it's taken care of in subdirs.am anyway. depend (".PHONY", "$target-am", "$target-local"); } } # Handle check merge target specially. sub do_check_merge_target () { # Include user-defined local form of target. push @check_tests, 'check-local' if user_phony_rule 'check-local'; # The check target must depend on the local equivalent of # 'all', to ensure all the primary targets are built. Then it # must build the local check rules. $output_rules .= "check-am: all-am\n"; if (@check) { pretty_print_rule ("\t\$(MAKE) \$(AM_MAKEFLAGS)", "\t ", @check); depend ('.MAKE', 'check-am'); } if (@check_tests) { pretty_print_rule ("\t\$(MAKE) \$(AM_MAKEFLAGS)", "\t ", @check_tests); depend ('.MAKE', 'check-am'); } depend '.PHONY', 'check', 'check-am'; # Handle recursion. We have to honor BUILT_SOURCES like for 'all:'. $output_rules .= ("check: " . (var ('BUILT_SOURCES') ? "\$(BUILT_SOURCES)\n\t\$(MAKE) \$(AM_MAKEFLAGS) " : '') . (var ('SUBDIRS') ? 'check-recursive' : 'check-am') . "\n"); depend ('.MAKE', 'check') if var ('BUILT_SOURCES'); } # Handle all 'clean' targets. sub handle_clean { my ($makefile) = @_; # Clean the files listed in user variables if they exist. $clean_files{'$(MOSTLYCLEANFILES)'} = MOSTLY_CLEAN if var ('MOSTLYCLEANFILES'); $clean_files{'$(CLEANFILES)'} = CLEAN if var ('CLEANFILES'); $clean_files{'$(DISTCLEANFILES)'} = DIST_CLEAN if var ('DISTCLEANFILES'); $clean_files{'$(MAINTAINERCLEANFILES)'} = MAINTAINER_CLEAN if var ('MAINTAINERCLEANFILES'); # Built sources are automatically removed by maintainer-clean. $clean_files{'$(BUILT_SOURCES)'} = MAINTAINER_CLEAN if var ('BUILT_SOURCES'); # Compute a list of "rm"s to run for each target. my %rms = (MOSTLY_CLEAN, [], CLEAN, [], DIST_CLEAN, [], MAINTAINER_CLEAN, []); foreach my $file (keys %clean_files) { my $when = $clean_files{$file}; prog_error 'invalid entry in %clean_files' unless exists $rms{$when}; my $rm = "rm -f $file"; # If file is a variable, make sure when don't call 'rm -f' without args. $rm ="test -z \"$file\" || $rm" if ($file =~ /^\s*\$(\(.*\)|\{.*\})\s*$/); push @{$rms{$when}}, "\t-$rm\n"; } $output_rules .= file_contents ('clean', new Automake::Location, MOSTLYCLEAN_RMS => join ('', sort @{$rms{&MOSTLY_CLEAN}}), CLEAN_RMS => join ('', sort @{$rms{&CLEAN}}), DISTCLEAN_RMS => join ('', sort @{$rms{&DIST_CLEAN}}), MAINTAINER_CLEAN_RMS => join ('', sort @{$rms{&MAINTAINER_CLEAN}}), MAKEFILE => basename $makefile, ); } # Subroutine for handle_factored_dependencies() to let '.PHONY' and # other '.TARGETS' be last. This is meant to be used as a comparison # subroutine passed to the sort built-int. sub target_cmp { return 0 if $a eq $b; my $a1 = substr ($a, 0, 1); my $b1 = substr ($b, 0, 1); if ($a1 ne $b1) { return -1 if $b1 eq '.'; return 1 if $a1 eq '.'; } return $a cmp $b; } # Handle everything related to gathered targets. sub handle_factored_dependencies () { # Reject bad hooks. foreach my $utarg ('uninstall-data-local', 'uninstall-data-hook', 'uninstall-exec-local', 'uninstall-exec-hook', 'uninstall-dvi-local', 'uninstall-html-local', 'uninstall-info-local', 'uninstall-pdf-local', 'uninstall-ps-local') { my $x = $utarg; $x =~ s/-.*-/-/; reject_rule ($utarg, "use '$x', not '$utarg'"); } reject_rule ('install-local', "use 'install-data-local' or 'install-exec-local', " . "not 'install-local'"); reject_rule ('install-hook', "use 'install-data-hook' or 'install-exec-hook', " . "not 'install-hook'"); # Install the -local hooks. foreach (keys %dependencies) { # Hooks are installed on the -am targets. s/-am$// or next; depend ("$_-am", "$_-local") if user_phony_rule "$_-local"; } # Install the -hook hooks. # FIXME: Why not be as liberal as we are with -local hooks? foreach ('install-exec', 'install-data', 'uninstall') { if (user_phony_rule "$_-hook") { depend ('.MAKE', "$_-am"); register_action("$_-am", ("\t\@\$(NORMAL_INSTALL)\n" . "\t\$(MAKE) \$(AM_MAKEFLAGS) $_-hook")); } } # All the required targets are phony. depend ('.PHONY', keys %required_targets); # Actually output gathered targets. foreach (sort target_cmp keys %dependencies) { # If there is nothing about this guy, skip it. next unless (@{$dependencies{$_}} || $actions{$_} || $required_targets{$_}); # Define gathered targets in undefined conditions. # FIXME: Right now we must handle .PHONY as an exception, # because people write things like # .PHONY: myphonytarget # to append dependencies. This would not work if Automake # refrained from defining its own .PHONY target as it does # with other overridden targets. # Likewise for '.MAKE' and '.PRECIOUS'. my @undefined_conds = (TRUE,); if ($_ ne '.PHONY' && $_ ne '.MAKE' && $_ ne '.PRECIOUS') { @undefined_conds = Automake::Rule::define ($_, 'internal', RULE_AUTOMAKE, TRUE, INTERNAL); } my @uniq_deps = uniq (sort @{$dependencies{$_}}); foreach my $cond (@undefined_conds) { my $condstr = $cond->subst_string; pretty_print_rule ("$condstr$_:", "$condstr\t", @uniq_deps); $output_rules .= $actions{$_} if defined $actions{$_}; $output_rules .= "\n"; } } } sub handle_tests_dejagnu () { push (@check_tests, 'check-DEJAGNU'); $output_rules .= file_contents ('dejagnu', new Automake::Location); } # handle_per_suffix_test ($TEST_SUFFIX, [%TRANSFORM]) #---------------------------------------------------- sub handle_per_suffix_test { my ($test_suffix, %transform) = @_; my ($pfx, $generic, $am_exeext); if ($test_suffix eq '') { $pfx = ''; $generic = 0; $am_exeext = 'FALSE'; } else { prog_error ("test suffix '$test_suffix' lacks leading dot") unless $test_suffix =~ m/^\.(.*)/; $pfx = uc ($1) . '_'; $generic = 1; $am_exeext = exists $configure_vars{'EXEEXT'} ? 'am__EXEEXT' : 'FALSE'; } # The "test driver" program, deputed to handle tests protocol used by # test scripts. By default, it's assumed that no protocol is used, so # we fall back to the old behaviour, implemented by the 'test-driver' # auxiliary script. if (! var "${pfx}LOG_DRIVER") { require_conf_file ("parallel-tests", FOREIGN, 'test-driver'); define_variable ("${pfx}LOG_DRIVER", "\$(SHELL) $am_config_aux_dir/test-driver", INTERNAL); } my $driver = '$(' . $pfx . 'LOG_DRIVER)'; my $driver_flags = '$(AM_' . $pfx . 'LOG_DRIVER_FLAGS)' . ' $(' . $pfx . 'LOG_DRIVER_FLAGS)'; my $compile = "${pfx}LOG_COMPILE"; define_variable ($compile, '$(' . $pfx . 'LOG_COMPILER)' . ' $(AM_' . $pfx . 'LOG_FLAGS)' . ' $(' . $pfx . 'LOG_FLAGS)', INTERNAL); $output_rules .= file_contents ('check2', new Automake::Location, GENERIC => $generic, DRIVER => $driver, DRIVER_FLAGS => $driver_flags, COMPILE => '$(' . $compile . ')', EXT => $test_suffix, am__EXEEXT => $am_exeext, %transform); } # is_valid_test_extension ($EXT) # ------------------------------ # Return true if $EXT can appear in $(TEST_EXTENSIONS), return false # otherwise. sub is_valid_test_extension { my $ext = shift; return 1 if ($ext =~ /^\.[a-zA-Z_][a-zA-Z0-9_]*$/); return 1 if (exists $configure_vars{'EXEEXT'} && $ext eq subst ('EXEEXT')); return 0; } sub handle_tests () { if (option 'dejagnu') { handle_tests_dejagnu; } else { foreach my $c ('DEJATOOL', 'RUNTEST', 'RUNTESTFLAGS') { reject_var ($c, "'$c' defined but 'dejagnu' not in " . "'AUTOMAKE_OPTIONS'"); } } if (var ('TESTS')) { push (@check_tests, 'check-TESTS'); my $check_deps = "@check"; $output_rules .= file_contents ('check', new Automake::Location, SERIAL_TESTS => !! option 'serial-tests', CHECK_DEPS => $check_deps); # Tests that are known programs should have $(EXEEXT) appended. # For matching purposes, we need to adjust XFAIL_TESTS as well. append_exeext { exists $known_programs{$_[0]} } 'TESTS'; append_exeext { exists $known_programs{$_[0]} } 'XFAIL_TESTS' if (var ('XFAIL_TESTS')); if (! option 'serial-tests') { define_variable ('TEST_SUITE_LOG', 'test-suite.log', INTERNAL); my $suff = '.test'; my $at_exeext = ''; my $handle_exeext = exists $configure_vars{'EXEEXT'}; if ($handle_exeext) { $at_exeext = subst ('EXEEXT'); $suff = $at_exeext . ' ' . $suff; } if (! var 'TEST_EXTENSIONS') { define_variable ('TEST_EXTENSIONS', $suff, INTERNAL); } my $var = var 'TEST_EXTENSIONS'; # Currently, we are not able to deal with conditional contents # in TEST_EXTENSIONS. if ($var->has_conditional_contents) { msg_var 'unsupported', $var, "'TEST_EXTENSIONS' cannot have conditional contents"; } my @test_suffixes = $var->value_as_list_recursive; if ((my @invalid_test_suffixes = grep { !is_valid_test_extension $_ } @test_suffixes) > 0) { error $var->rdef (TRUE)->location, "invalid test extensions: @invalid_test_suffixes"; } @test_suffixes = grep { is_valid_test_extension $_ } @test_suffixes; if ($handle_exeext) { unshift (@test_suffixes, $at_exeext) unless $test_suffixes[0] eq $at_exeext; } unshift (@test_suffixes, ''); transform_variable_recursively ('TESTS', 'TEST_LOGS', 'am__testlogs', 1, INTERNAL, sub { my ($subvar, $val, $cond, $full_cond) = @_; my $obj = $val; return $obj if $val =~ /^\@.*\@$/; $obj =~ s/\$\(EXEEXT\)$//o; if ($val =~ /(\$\((top_)?srcdir\))\//o) { msg ('error', $subvar->rdef ($cond)->location, "using '$1' in TESTS is currently broken: '$val'"); } foreach my $test_suffix (@test_suffixes) { next if $test_suffix eq $at_exeext || $test_suffix eq ''; return substr ($obj, 0, length ($obj) - length ($test_suffix)) . '.log' if substr ($obj, - length ($test_suffix)) eq $test_suffix; } my $base = $obj; $obj .= '.log'; handle_per_suffix_test ('', OBJ => $obj, BASE => $base, SOURCE => $val); return $obj; }); my $nhelper=1; my $prev = 'TESTS'; my $post = ''; my $last_suffix = $test_suffixes[$#test_suffixes]; my $cur = ''; foreach my $test_suffix (@test_suffixes) { if ($test_suffix eq $last_suffix) { $cur = 'TEST_LOGS'; } else { $cur = 'am__test_logs' . $nhelper; } define_variable ($cur, '$(' . $prev . ':' . $test_suffix . $post . '=.log)', INTERNAL); $post = '.log'; $prev = $cur; $nhelper++; if ($test_suffix ne $at_exeext && $test_suffix ne '') { handle_per_suffix_test ($test_suffix, OBJ => '', BASE => '$*', SOURCE => '$<'); } } $clean_files{'$(TEST_LOGS)'} = MOSTLY_CLEAN; $clean_files{'$(TEST_LOGS:.log=.trs)'} = MOSTLY_CLEAN; $clean_files{'$(TEST_SUITE_LOG)'} = MOSTLY_CLEAN; } } } sub handle_emacs_lisp () { my @elfiles = am_install_var ('-candist', 'lisp', 'LISP', 'lisp', 'noinst'); return if ! @elfiles; define_pretty_variable ('am__ELFILES', TRUE, INTERNAL, map { $_->[1] } @elfiles); define_pretty_variable ('am__ELCFILES', TRUE, INTERNAL, '$(am__ELFILES:.el=.elc)'); # This one can be overridden by users. define_pretty_variable ('ELCFILES', TRUE, INTERNAL, '$(LISP:.el=.elc)'); push @all, '$(ELCFILES)'; require_variables ($elfiles[0][0], "Emacs Lisp sources seen", TRUE, 'EMACS', 'lispdir'); } sub handle_python () { my @pyfiles = am_install_var ('-defaultdist', 'python', 'PYTHON', 'noinst'); return if ! @pyfiles; require_variables ($pyfiles[0][0], "Python sources seen", TRUE, 'PYTHON'); require_conf_file ($pyfiles[0][0], FOREIGN, 'py-compile'); define_variable ('py_compile', "$am_config_aux_dir/py-compile", INTERNAL); } sub handle_java () { my @sourcelist = am_install_var ('-candist', 'java', 'JAVA', 'noinst', 'check'); return if ! @sourcelist; my @prefixes = am_primary_prefixes ('JAVA', 1, 'noinst', 'check'); my $dir; my @java_sources = (); foreach my $prefix (@prefixes) { (my $curs = $prefix) =~ s/^(?:nobase_)?(?:dist_|nodist_)?//; next if $curs eq 'EXTRA'; push @java_sources, '$(' . $prefix . '_JAVA' . ')'; if (defined $dir) { err_var "${curs}_JAVA", "multiple _JAVA primaries in use" unless $curs eq $dir; } $dir = $curs; } define_pretty_variable ('am__java_sources', TRUE, INTERNAL, "@java_sources"); if ($dir eq 'check') { push (@check, "class$dir.stamp"); } else { push (@all, "class$dir.stamp"); } } sub handle_minor_options () { if (option 'readme-alpha') { if ($relative_dir eq '.') { if ($package_version !~ /^$GNITS_VERSION_PATTERN$/) { msg ('error-gnits', $package_version_location, "version '$package_version' doesn't follow " . "Gnits standards"); } if (defined $1 && -f 'README-alpha') { # This means we have an alpha release. See # GNITS_VERSION_PATTERN for details. push_dist_common ('README-alpha'); } } } } ################################################################ # ($OUTPUT, @INPUTS) # split_config_file_spec ($SPEC) # ------------------------------ # Decode the Autoconf syntax for config files (files, headers, links # etc.). sub split_config_file_spec { my ($spec) = @_; my ($output, @inputs) = split (/:/, $spec); push @inputs, "$output.in" unless @inputs; return ($output, @inputs); } # $input # locate_am (@POSSIBLE_SOURCES) # ----------------------------- # AC_CONFIG_FILES allow specifications such as Makefile:top.in:mid.in:bot.in # This functions returns the first *.in file for which a *.am exists. # It returns undef otherwise. sub locate_am { my (@rest) = @_; my $input; foreach my $file (@rest) { if (($file =~ /^(.*)\.in$/) && -f "$1.am") { $input = $file; last; } } return $input; } my %make_list; # scan_autoconf_config_files ($WHERE, $CONFIG-FILES) # -------------------------------------------------- # Study $CONFIG-FILES which is the first argument to AC_CONFIG_FILES # (or AC_OUTPUT). sub scan_autoconf_config_files { my ($where, $config_files) = @_; # Look at potential Makefile.am's. foreach (split ' ', $config_files) { # Must skip empty string for Perl 4. next if $_ eq "\\" || $_ eq ''; # Handle $local:$input syntax. my ($local, @rest) = split (/:/); @rest = ("$local.in",) unless @rest; # Keep in sync with test 'conffile-leading-dot.sh'. msg ('unsupported', $where, "omit leading './' from config file names such as '$local';" . "\nremake rules might be subtly broken otherwise") if ($local =~ /^\.\//); my $input = locate_am @rest; if ($input) { # We have a file that automake should generate. $make_list{$input} = join (':', ($local, @rest)); } else { # We have a file that automake should cause to be # rebuilt, but shouldn't generate itself. push (@other_input_files, $_); } $ac_config_files_location{$local} = $where; $ac_config_files_condition{$local} = new Automake::Condition (@cond_stack) if (@cond_stack); } } sub scan_autoconf_traces { my ($filename) = @_; # Macros to trace, with their minimal number of arguments. # # IMPORTANT: If you add a macro here, you should also add this macro # ========= to Automake-preselection in autoconf/lib/autom4te.in. my %traced = ( AC_CANONICAL_BUILD => 0, AC_CANONICAL_HOST => 0, AC_CANONICAL_TARGET => 0, AC_CONFIG_AUX_DIR => 1, AC_CONFIG_FILES => 1, AC_CONFIG_HEADERS => 1, AC_CONFIG_LIBOBJ_DIR => 1, AC_CONFIG_LINKS => 1, AC_FC_SRCEXT => 1, AC_INIT => 0, AC_LIBSOURCE => 1, AC_REQUIRE_AUX_FILE => 1, AC_SUBST_TRACE => 1, AM_AUTOMAKE_VERSION => 1, AM_PROG_MKDIR_P => 0, AM_CONDITIONAL => 2, AM_EXTRA_RECURSIVE_TARGETS => 1, AM_GNU_GETTEXT => 0, AM_GNU_GETTEXT_INTL_SUBDIR => 0, AM_INIT_AUTOMAKE => 0, AM_MAINTAINER_MODE => 0, AM_PROG_AR => 0, _AM_SUBST_NOTMAKE => 1, _AM_COND_IF => 1, _AM_COND_ELSE => 1, _AM_COND_ENDIF => 1, LT_SUPPORTED_TAG => 1, _LT_AC_TAGCONFIG => 0, m4_include => 1, m4_sinclude => 1, sinclude => 1, ); my $traces = ($ENV{AUTOCONF} || 'autoconf') . " "; # Use a separator unlikely to be used, not ':', the default, which # has a precise meaning for AC_CONFIG_FILES and so on. $traces .= join (' ', map { "--trace=$_" . ':\$f:\$l::\$d::\$n::\${::}%' } (keys %traced)); my $tracefh = new Automake::XFile ("$traces $filename |"); verb "reading $traces"; @cond_stack = (); my $where; while ($_ = $tracefh->getline) { chomp; my ($here, $depth, @args) = split (/::/); $where = new Automake::Location $here; my $macro = $args[0]; prog_error ("unrequested trace '$macro'") unless exists $traced{$macro}; # Skip and diagnose malformed calls. if ($#args < $traced{$macro}) { msg ('syntax', $where, "not enough arguments for $macro"); next; } # Alphabetical ordering please. if ($macro eq 'AC_CANONICAL_BUILD') { if ($seen_canonical <= AC_CANONICAL_BUILD) { $seen_canonical = AC_CANONICAL_BUILD; } } elsif ($macro eq 'AC_CANONICAL_HOST') { if ($seen_canonical <= AC_CANONICAL_HOST) { $seen_canonical = AC_CANONICAL_HOST; } } elsif ($macro eq 'AC_CANONICAL_TARGET') { $seen_canonical = AC_CANONICAL_TARGET; } elsif ($macro eq 'AC_CONFIG_AUX_DIR') { if ($seen_init_automake) { error ($where, "AC_CONFIG_AUX_DIR must be called before " . "AM_INIT_AUTOMAKE ...", partial => 1); error ($seen_init_automake, "... AM_INIT_AUTOMAKE called here"); } $config_aux_dir = $args[1]; $config_aux_dir_set_in_configure_ac = 1; check_directory ($config_aux_dir, $where); } elsif ($macro eq 'AC_CONFIG_FILES') { # Look at potential Makefile.am's. scan_autoconf_config_files ($where, $args[1]); } elsif ($macro eq 'AC_CONFIG_HEADERS') { foreach my $spec (split (' ', $args[1])) { my ($dest, @src) = split (':', $spec); $ac_config_files_location{$dest} = $where; push @config_headers, $spec; } } elsif ($macro eq 'AC_CONFIG_LIBOBJ_DIR') { $config_libobj_dir = $args[1]; check_directory ($config_libobj_dir, $where); } elsif ($macro eq 'AC_CONFIG_LINKS') { foreach my $spec (split (' ', $args[1])) { my ($dest, $src) = split (':', $spec); $ac_config_files_location{$dest} = $where; push @config_links, $spec; } } elsif ($macro eq 'AC_FC_SRCEXT') { my $suffix = $args[1]; # These flags are used as %SOURCEFLAG% in depend2.am, # where the trailing space is important. $sourceflags{'.' . $suffix} = '$(FCFLAGS_' . $suffix . ') ' if ($suffix eq 'f90' || $suffix eq 'f95' || $suffix eq 'f03' || $suffix eq 'f08'); } elsif ($macro eq 'AC_INIT') { if (defined $args[2]) { $package_version = $args[2]; $package_version_location = $where; } } elsif ($macro eq 'AC_LIBSOURCE') { $libsources{$args[1]} = $here; } elsif ($macro eq 'AC_REQUIRE_AUX_FILE') { # Only remember the first time a file is required. $required_aux_file{$args[1]} = $where unless exists $required_aux_file{$args[1]}; } elsif ($macro eq 'AC_SUBST_TRACE') { # Just check for alphanumeric in AC_SUBST_TRACE. If you do # AC_SUBST(5), then too bad. $configure_vars{$args[1]} = $where if $args[1] =~ /^\w+$/; } elsif ($macro eq 'AM_AUTOMAKE_VERSION') { error ($where, "version mismatch. This is Automake $VERSION,\n" . "but the definition used by this AM_INIT_AUTOMAKE\n" . "comes from Automake $args[1]. You should recreate\n" . "aclocal.m4 with aclocal and run automake again.\n", # $? = 63 is used to indicate version mismatch to missing. exit_code => 63) if $VERSION ne $args[1]; $seen_automake_version = 1; } elsif ($macro eq 'AM_PROG_MKDIR_P') { msg 'obsolete', $where, <<'EOF'; The 'AM_PROG_MKDIR_P' macro is deprecated, and its use is discouraged. You should use the Autoconf-provided 'AC_PROG_MKDIR_P' macro instead, and use '$(MKDIR_P)' instead of '$(mkdir_p)'in your Makefile.am files. EOF } elsif ($macro eq 'AM_CONDITIONAL') { $configure_cond{$args[1]} = $where; } elsif ($macro eq 'AM_EXTRA_RECURSIVE_TARGETS') { # Empty leading/trailing fields might be produced by split, # hence the grep is really needed. push @extra_recursive_targets, grep (/./, (split /\s+/, $args[1])); } elsif ($macro eq 'AM_GNU_GETTEXT') { $seen_gettext = $where; $ac_gettext_location = $where; $seen_gettext_external = grep ($_ eq 'external', @args); } elsif ($macro eq 'AM_GNU_GETTEXT_INTL_SUBDIR') { $seen_gettext_intl = $where; } elsif ($macro eq 'AM_INIT_AUTOMAKE') { $seen_init_automake = $where; if (defined $args[2]) { msg 'obsolete', $where, <<'EOF'; AM_INIT_AUTOMAKE: two- and three-arguments forms are deprecated. For more info, see: https://www.gnu.org/software/automake/manual/automake.html#Modernize-AM_005fINIT_005fAUTOMAKE-invocation EOF $package_version = $args[2]; $package_version_location = $where; } elsif (defined $args[1]) { my @opts = split (' ', $args[1]); @opts = map { { option => $_, where => $where } } @opts; exit $exit_code unless process_global_option_list (@opts); } } elsif ($macro eq 'AM_MAINTAINER_MODE') { $seen_maint_mode = $where; } elsif ($macro eq 'AM_PROG_AR') { $seen_ar = $where; } elsif ($macro eq '_AM_COND_IF') { cond_stack_if ('', $args[1], $where); error ($where, "missing m4 quoting, macro depth $depth") if ($depth != 1); } elsif ($macro eq '_AM_COND_ELSE') { cond_stack_else ('!', $args[1], $where); error ($where, "missing m4 quoting, macro depth $depth") if ($depth != 1); } elsif ($macro eq '_AM_COND_ENDIF') { cond_stack_endif (undef, undef, $where); error ($where, "missing m4 quoting, macro depth $depth") if ($depth != 1); } elsif ($macro eq '_AM_SUBST_NOTMAKE') { $ignored_configure_vars{$args[1]} = $where; } elsif ($macro eq 'm4_include' || $macro eq 'm4_sinclude' || $macro eq 'sinclude') { # Skip missing 'sinclude'd files. next if $macro ne 'm4_include' && ! -f $args[1]; # Some modified versions of Autoconf don't use # frozen files. Consequently it's possible that we see all # m4_include's performed during Autoconf's startup. # Obviously we don't want to distribute Autoconf's files # so we skip absolute filenames here. push @configure_deps, '$(top_srcdir)/' . $args[1] unless $here =~ m,^(?:\w:)?[\\/],; # Keep track of the greatest timestamp. if (-e $args[1]) { my $mtime = mtime $args[1]; $configure_deps_greatest_timestamp = $mtime if $mtime > $configure_deps_greatest_timestamp; } } elsif ($macro eq 'LT_SUPPORTED_TAG') { $libtool_tags{$args[1]} = 1; $libtool_new_api = 1; } elsif ($macro eq '_LT_AC_TAGCONFIG') { # _LT_AC_TAGCONFIG is an old macro present in Libtool 1.5. # We use it to detect whether tags are supported. Our # preferred interface is LT_SUPPORTED_TAG, but it was # introduced in Libtool 1.6. if (0 == keys %libtool_tags) { # Hardcode the tags supported by Libtool 1.5. %libtool_tags = (CC => 1, CXX => 1, GCJ => 1, F77 => 1); } } } error ($where, "condition stack not properly closed") if (@cond_stack); $tracefh->close; } # Check whether we use 'configure.ac' or 'configure.in'. # Scan it (and possibly 'aclocal.m4') for interesting things. # We must scan aclocal.m4 because there might be AC_SUBSTs and such there. sub scan_autoconf_files () { # Reinitialize libsources here. This isn't really necessary, # since we currently assume there is only one configure.ac. But # that won't always be the case. %libsources = (); # Keep track of the youngest configure dependency. $configure_deps_greatest_timestamp = mtime $configure_ac; if (-e 'aclocal.m4') { my $mtime = mtime 'aclocal.m4'; $configure_deps_greatest_timestamp = $mtime if $mtime > $configure_deps_greatest_timestamp; } scan_autoconf_traces ($configure_ac); @configure_input_files = sort keys %make_list; # Set input and output files if not specified by user. if (! @input_files) { @input_files = @configure_input_files; %output_files = %make_list; } if (! $seen_init_automake) { err_ac ("no proper invocation of AM_INIT_AUTOMAKE was found.\nYou " . "should verify that $configure_ac invokes AM_INIT_AUTOMAKE," . "\nthat aclocal.m4 is present in the top-level directory,\n" . "and that aclocal.m4 was recently regenerated " . "(using aclocal)"); } else { if (! $seen_automake_version) { if (-f 'aclocal.m4') { error ($seen_init_automake, "your implementation of AM_INIT_AUTOMAKE comes from " . "an\nold Automake version. You should recreate " . "aclocal.m4\nwith aclocal and run automake again", # $? = 63 is used to indicate version mismatch to missing. exit_code => 63); } else { error ($seen_init_automake, "no proper implementation of AM_INIT_AUTOMAKE was " . "found,\nprobably because aclocal.m4 is missing.\n" . "You should run aclocal to create this file, then\n" . "run automake again"); } } } locate_aux_dir (); # Look for some files we need. Always check for these. This # check must be done for every run, even those where we are only # looking at a subdir Makefile. We must set relative_dir for # push_required_file to work. # Sort the files for stable verbose output. $relative_dir = '.'; foreach my $file (sort keys %required_aux_file) { require_conf_file ($required_aux_file{$file}->get, FOREIGN, $file) } err_am "'install.sh' is an anachronism; use 'install-sh' instead" if -f $config_aux_dir . '/install.sh'; # Preserve dist_common for later. @configure_dist_common = @dist_common; } ################################################################ # Do any extra checking for GNU standards. sub check_gnu_standards () { if ($relative_dir eq '.') { # In top level (or only) directory. require_file ("$am_file.am", GNU, qw/INSTALL NEWS README AUTHORS ChangeLog/); # Accept one of these three licenses; default to COPYING. # Make sure we do not overwrite an existing license. my $license; foreach (qw /COPYING COPYING.LIB COPYING.LESSER/) { if (-f $_) { $license = $_; last; } } require_file ("$am_file.am", GNU, 'COPYING') unless $license; } for my $opt ('no-installman', 'no-installinfo') { msg ('error-gnu', option $opt, "option '$opt' disallowed by GNU standards") if option $opt; } } # Do any extra checking for GNITS standards. sub check_gnits_standards () { if ($relative_dir eq '.') { # In top level (or only) directory. require_file ("$am_file.am", GNITS, 'THANKS'); } } ################################################################ # # Functions to handle files of each language. # Each 'lang_X_rewrite($DIRECTORY, $BASE, $EXT)' function follows a # simple formula: Return value is LANG_SUBDIR if the resulting object # file should be in a subdir if the source file is, LANG_PROCESS if # file is to be dealt with, LANG_IGNORE otherwise. # Much of the actual processing is handled in # handle_single_transform. These functions exist so that # auxiliary information can be recorded for a later cleanup pass. # Note that the calls to these functions are computed, so don't bother # searching for their precise names in the source. # This is just a convenience function that can be used to determine # when a subdir object should be used. sub lang_sub_obj () { return option 'subdir-objects' ? LANG_SUBDIR : LANG_PROCESS; } # Rewrite a single header file. sub lang_header_rewrite { # Header files are simply ignored. return LANG_IGNORE; } # Rewrite a single Vala source file. sub lang_vala_rewrite { my ($directory, $base, $ext) = @_; (my $newext = $ext) =~ s/vala$/c/; return (LANG_SUBDIR, $newext); } # Rewrite a single yacc/yacc++ file. sub lang_yacc_rewrite { my ($directory, $base, $ext) = @_; my $r = lang_sub_obj; (my $newext = $ext) =~ tr/y/c/; return ($r, $newext); } sub lang_yaccxx_rewrite { lang_yacc_rewrite (@_); }; # Rewrite a single lex/lex++ file. sub lang_lex_rewrite { my ($directory, $base, $ext) = @_; my $r = lang_sub_obj; (my $newext = $ext) =~ tr/l/c/; return ($r, $newext); } sub lang_lexxx_rewrite { lang_lex_rewrite (@_); }; # Rewrite a single Java file. sub lang_java_rewrite { return LANG_SUBDIR; } # The lang_X_finish functions are called after all source file # processing is done. Each should handle defining rules for the # language, etc. A finish function is only called if a source file of # the appropriate type has been seen. sub lang_vala_finish_target { my ($self, $name) = @_; my $derived = canonicalize ($name); my $var = var "${derived}_SOURCES"; return unless $var; my @vala_sources = grep { /\.(vala|vapi)$/ } ($var->value_as_list_recursive); # For automake bug#11229. return unless @vala_sources; foreach my $vala_file (@vala_sources) { my $c_file = $vala_file; if ($c_file =~ s/(.*)\.vala$/$1.c/) { $c_file = "\$(srcdir)/$c_file"; $output_rules .= "$c_file: \$(srcdir)/${derived}_vala.stamp\n" . "\t\@if test -f \$@; then :; else rm -f \$(srcdir)/${derived}_vala.stamp; fi\n" . "\t\@if test -f \$@; then :; else \\\n" . "\t \$(MAKE) \$(AM_MAKEFLAGS) \$(srcdir)/${derived}_vala.stamp; \\\n" . "\tfi\n"; $clean_files{$c_file} = MAINTAINER_CLEAN; } } # Add rebuild rules for generated header and vapi files my $flags = var ($derived . '_VALAFLAGS'); if ($flags) { my $lastflag = ''; foreach my $flag ($flags->value_as_list_recursive) { if (grep (/$lastflag/, ('-H', '-h', '--header', '--internal-header', '--vapi', '--internal-vapi', '--gir'))) { my $headerfile = "\$(srcdir)/$flag"; $output_rules .= "$headerfile: \$(srcdir)/${derived}_vala.stamp\n" . "\t\@if test -f \$@; then :; else rm -f \$(srcdir)/${derived}_vala.stamp; fi\n" . "\t\@if test -f \$@; then :; else \\\n" . "\t \$(MAKE) \$(AM_MAKEFLAGS) \$(srcdir)/${derived}_vala.stamp; \\\n" . "\tfi\n"; # valac is not used when building from dist tarballs # distribute the generated files push_dist_common ($headerfile); $clean_files{$headerfile} = MAINTAINER_CLEAN; } $lastflag = $flag; } } my $compile = $self->compile; # Rewrite each occurrence of 'AM_VALAFLAGS' in the compile # rule into '${derived}_VALAFLAGS' if it exists. my $val = "${derived}_VALAFLAGS"; $compile =~ s/\(AM_VALAFLAGS\)/\($val\)/ if set_seen ($val); # VALAFLAGS is a user variable (per GNU Standards), # it should not be overridden in the Makefile... check_user_variables 'VALAFLAGS'; my $dirname = dirname ($name); # Only generate C code, do not run C compiler $compile .= " -C"; my $verbose = verbose_flag ('VALAC'); my $silent = silent_flag (); my $stampfile = "\$(srcdir)/${derived}_vala.stamp"; $output_rules .= "\$(srcdir)/${derived}_vala.stamp: @vala_sources\n". # Since the C files generated from the vala sources depend on the # ${derived}_vala.stamp file, we must ensure its timestamp is older than # those of the C files generated by the valac invocation below (this is # especially important on systems with sub-second timestamp resolution). # Thus we need to create the stamp file *before* invoking valac, and to # move it to its final location only after valac has been invoked. "\t${silent}rm -f \$\@ && echo stamp > \$\@-t\n". "\t${verbose}\$(am__cd) \$(srcdir) && $compile @vala_sources\n". "\t${silent}mv -f \$\@-t \$\@\n"; push_dist_common ($stampfile); $clean_files{$stampfile} = MAINTAINER_CLEAN; } # Add output rules to invoke valac and create stamp file as a witness # to handle multiple outputs. This function is called after all source # file processing is done. sub lang_vala_finish () { my ($self) = @_; foreach my $prog (keys %known_programs) { lang_vala_finish_target ($self, $prog); } while (my ($name) = each %known_libraries) { lang_vala_finish_target ($self, $name); } } # The built .c files should be cleaned only on maintainer-clean # as the .c files are distributed. This function is called for each # .vala source file. sub lang_vala_target_hook { my ($self, $aggregate, $output, $input, %transform) = @_; $clean_files{$output} = MAINTAINER_CLEAN; } # This is a yacc helper which is called whenever we have decided to # compile a yacc file. sub lang_yacc_target_hook { my ($self, $aggregate, $output, $input, %transform) = @_; # If some relevant *YFLAGS variable contains the '-d' flag, we'll # have to to generate special code. my $yflags_contains_minus_d = 0; foreach my $pfx ("", "${aggregate}_") { my $yflagsvar = var ("${pfx}YFLAGS"); next unless $yflagsvar; # We cannot work reliably with conditionally-defined YFLAGS. if ($yflagsvar->has_conditional_contents) { msg_var ('unsupported', $yflagsvar, "'${pfx}YFLAGS' cannot have conditional contents"); } else { $yflags_contains_minus_d = 1 if grep (/^-d$/, $yflagsvar->value_as_list_recursive); } } if ($yflags_contains_minus_d) { # Found a '-d' that applies to the compilation of this file. # Add a dependency for the generated header file, and arrange # for that file to be included in the distribution. # The extension of the output file (e.g., '.c' or '.cxx'). # We'll need it to compute the name of the generated header file. (my $output_ext = basename ($output)) =~ s/.*(\.[^.]+)$/$1/; # We know that a yacc input should be turned into either a C or # C++ output file. We depend on this fact (here and in yacc.am), # so check that it really holds. my $lang = $languages{$extension_map{$output_ext}}; prog_error "invalid output name '$output' for yacc file '$input'" if (!$lang || ($lang->name ne 'c' && $lang->name ne 'cxx')); (my $header_ext = $output_ext) =~ s/c/h/g; # Quote $output_ext in the regexp, so that dots in it are taken # as literal dots, not as metacharacters. (my $header = $output) =~ s/\Q$output_ext\E$/$header_ext/; foreach my $cond (Automake::Rule::define (${header}, 'internal', RULE_AUTOMAKE, TRUE, INTERNAL)) { my $condstr = $cond->subst_string; $output_rules .= "$condstr${header}: $output\n" # Recover from removal of $header . "$condstr\t\@if test ! -f \$@; then rm -f $output; else :; fi\n" . "$condstr\t\@if test ! -f \$@; then \$(MAKE) \$(AM_MAKEFLAGS) $output; else :; fi\n"; } # Distribute the generated file, unless its .y source was # listed in a nodist_ variable. (handle_source_transform() # will set DIST_SOURCE.) push_dist_common ($header) if $transform{'DIST_SOURCE'}; # The GNU rules say that yacc/lex output files should be removed # by maintainer-clean. However, if the files are not distributed, # then we want to remove them with "make clean"; otherwise, # "make distcheck" will fail. $clean_files{$header} = $transform{'DIST_SOURCE'} ? MAINTAINER_CLEAN : CLEAN; } # See the comment above for $HEADER. $clean_files{$output} = $transform{'DIST_SOURCE'} ? MAINTAINER_CLEAN : CLEAN; } # This is a lex helper which is called whenever we have decided to # compile a lex file. sub lang_lex_target_hook { my ($self, $aggregate, $output, $input, %transform) = @_; # The GNU rules say that yacc/lex output files should be removed # by maintainer-clean. However, if the files are not distributed, # then we want to remove them with "make clean"; otherwise, # "make distcheck" will fail. $clean_files{$output} = $transform{'DIST_SOURCE'} ? MAINTAINER_CLEAN : CLEAN; } # This is a helper for both lex and yacc. sub yacc_lex_finish_helper () { return if defined $language_scratch{'lex-yacc-done'}; $language_scratch{'lex-yacc-done'} = 1; # FIXME: for now, no line number. require_conf_file ($configure_ac, FOREIGN, 'ylwrap'); define_variable ('YLWRAP', "$am_config_aux_dir/ylwrap", INTERNAL); } sub lang_yacc_finish () { return if defined $language_scratch{'yacc-done'}; $language_scratch{'yacc-done'} = 1; reject_var 'YACCFLAGS', "'YACCFLAGS' obsolete; use 'YFLAGS' instead"; yacc_lex_finish_helper; } sub lang_lex_finish () { return if defined $language_scratch{'lex-done'}; $language_scratch{'lex-done'} = 1; yacc_lex_finish_helper; } # Given a hash table of linker names, pick the name that has the most # precedence. This is lame, but something has to have global # knowledge in order to eliminate the conflict. Add more linkers as # required. sub resolve_linker { my (%linkers) = @_; foreach my $l (qw(GCJLINK OBJCXXLINK CXXLINK F77LINK FCLINK OBJCLINK UPCLINK)) { return $l if defined $linkers{$l}; } return 'LINK'; } # Called to indicate that an extension was used. sub saw_extension { my ($ext) = @_; $extension_seen{$ext} = 1; } # register_language (%ATTRIBUTE) # ------------------------------ # Register a single language. # Each %ATTRIBUTE is of the form ATTRIBUTE => VALUE. sub register_language { my (%option) = @_; # Set the defaults. $option{'autodep'} = 'no' unless defined $option{'autodep'}; $option{'linker'} = '' unless defined $option{'linker'}; $option{'flags'} = [] unless defined $option{'flags'}; $option{'output_extensions'} = sub { return ( '.$(OBJEXT)', '.lo' ) } unless defined $option{'output_extensions'}; $option{'nodist_specific'} = 0 unless defined $option{'nodist_specific'}; my $lang = new Automake::Language (%option); # Fill indexes. $extension_map{$_} = $lang->name foreach @{$lang->extensions}; $languages{$lang->name} = $lang; my $link = $lang->linker; if ($link) { if (exists $link_languages{$link}) { prog_error ("'$link' has different definitions in " . $lang->name . " and " . $link_languages{$link}->name) if $lang->link ne $link_languages{$link}->link; } else { $link_languages{$link} = $lang; } } # Update the pattern of known extensions. accept_extensions (@{$lang->extensions}); # Update the suffix rules map. foreach my $suffix (@{$lang->extensions}) { foreach my $dest ($lang->output_extensions->($suffix)) { register_suffix_rule (INTERNAL, $suffix, $dest); } } } # derive_suffix ($EXT, $OBJ) # -------------------------- # This function is used to find a path from a user-specified suffix $EXT # to $OBJ or to some other suffix we recognize internally, e.g. 'cc'. sub derive_suffix { my ($source_ext, $obj) = @_; while (!$extension_map{$source_ext} && $source_ext ne $obj) { my $new_source_ext = next_in_suffix_chain ($source_ext, $obj); last if not defined $new_source_ext; $source_ext = $new_source_ext; } return $source_ext; } # Pretty-print something and append to '$output_rules'. sub pretty_print_rule { $output_rules .= makefile_wrap (shift, shift, @_); } ################################################################ ## -------------------------------- ## ## Handling the conditional stack. ## ## -------------------------------- ## # $STRING # make_conditional_string ($NEGATE, $COND) # ---------------------------------------- sub make_conditional_string { my ($negate, $cond) = @_; $cond = "${cond}_TRUE" unless $cond =~ /^TRUE|FALSE$/; $cond = Automake::Condition::conditional_negate ($cond) if $negate; return $cond; } my %_am_macro_for_cond = ( AMDEP => "one of the compiler tests\n" . " AC_PROG_CC, AC_PROG_CXX, AC_PROG_OBJC, AC_PROG_OBJCXX,\n" . " AM_PROG_AS, AM_PROG_GCJ, AM_PROG_UPC", am__fastdepCC => 'AC_PROG_CC', am__fastdepCCAS => 'AM_PROG_AS', am__fastdepCXX => 'AC_PROG_CXX', am__fastdepGCJ => 'AM_PROG_GCJ', am__fastdepOBJC => 'AC_PROG_OBJC', am__fastdepOBJCXX => 'AC_PROG_OBJCXX', am__fastdepUPC => 'AM_PROG_UPC' ); # $COND # cond_stack_if ($NEGATE, $COND, $WHERE) # -------------------------------------- sub cond_stack_if { my ($negate, $cond, $where) = @_; if (! $configure_cond{$cond} && $cond !~ /^TRUE|FALSE$/) { my $text = "$cond does not appear in AM_CONDITIONAL"; my $scope = US_LOCAL; if (exists $_am_macro_for_cond{$cond}) { my $mac = $_am_macro_for_cond{$cond}; $text .= "\n The usual way to define '$cond' is to add "; $text .= ($mac =~ / /) ? $mac : "'$mac'"; $text .= "\n to '$configure_ac' and run 'aclocal' and 'autoconf' again"; # These warnings appear in Automake files (depend2.am), # so there is no need to display them more than once: $scope = US_GLOBAL; } error $where, $text, uniq_scope => $scope; } push (@cond_stack, make_conditional_string ($negate, $cond)); return new Automake::Condition (@cond_stack); } # $COND # cond_stack_else ($NEGATE, $COND, $WHERE) # ---------------------------------------- sub cond_stack_else { my ($negate, $cond, $where) = @_; if (! @cond_stack) { error $where, "else without if"; return FALSE; } $cond_stack[$#cond_stack] = Automake::Condition::conditional_negate ($cond_stack[$#cond_stack]); # If $COND is given, check against it. if (defined $cond) { $cond = make_conditional_string ($negate, $cond); error ($where, "else reminder ($negate$cond) incompatible with " . "current conditional: $cond_stack[$#cond_stack]") if $cond_stack[$#cond_stack] ne $cond; } return new Automake::Condition (@cond_stack); } # $COND # cond_stack_endif ($NEGATE, $COND, $WHERE) # ----------------------------------------- sub cond_stack_endif { my ($negate, $cond, $where) = @_; my $old_cond; if (! @cond_stack) { error $where, "endif without if"; return TRUE; } # If $COND is given, check against it. if (defined $cond) { $cond = make_conditional_string ($negate, $cond); error ($where, "endif reminder ($negate$cond) incompatible with " . "current conditional: $cond_stack[$#cond_stack]") if $cond_stack[$#cond_stack] ne $cond; } pop @cond_stack; return new Automake::Condition (@cond_stack); } ## ------------------------ ## ## Handling the variables. ## ## ------------------------ ## # define_pretty_variable ($VAR, $COND, $WHERE, @VALUE) # ---------------------------------------------------- # Like define_variable, but the value is a list, and the variable may # be defined conditionally. The second argument is the condition # under which the value should be defined; this should be the empty # string to define the variable unconditionally. The third argument # is a list holding the values to use for the variable. The value is # pretty printed in the output file. sub define_pretty_variable { my ($var, $cond, $where, @value) = @_; if (! vardef ($var, $cond)) { Automake::Variable::define ($var, VAR_AUTOMAKE, '', $cond, "@value", '', $where, VAR_PRETTY); rvar ($var)->rdef ($cond)->set_seen; } } # define_variable ($VAR, $VALUE, $WHERE) # -------------------------------------- # Define a new Automake Makefile variable VAR to VALUE, but only if # not already defined. sub define_variable { my ($var, $value, $where) = @_; define_pretty_variable ($var, TRUE, $where, $value); } # define_files_variable ($VAR, \@BASENAME, $EXTENSION, $WHERE) # ------------------------------------------------------------ # Define the $VAR which content is the list of file names composed of # a @BASENAME and the $EXTENSION. sub define_files_variable ($\@$$) { my ($var, $basename, $extension, $where) = @_; define_variable ($var, join (' ', map { "$_.$extension" } @$basename), $where); } # Like define_variable, but define a variable to be the configure # substitution by the same name. sub define_configure_variable { my ($var) = @_; # Some variables we do not want to output. For instance it # would be a bad idea to output `U = @U@` when `@U@` can be # substituted as `\`. my $pretty = exists $ignored_configure_vars{$var} ? VAR_SILENT : VAR_ASIS; Automake::Variable::define ($var, VAR_CONFIGURE, '', TRUE, subst ($var), '', $configure_vars{$var}, $pretty); } # define_compiler_variable ($LANG) # -------------------------------- # Define a compiler variable. We also handle defining the 'LT' # version of the command when using libtool. sub define_compiler_variable { my ($lang) = @_; my ($var, $value) = ($lang->compiler, $lang->compile); my $libtool_tag = ''; $libtool_tag = '--tag=' . $lang->libtool_tag . ' ' if $lang->libtool_tag && exists $libtool_tags{$lang->libtool_tag}; define_variable ($var, $value, INTERNAL); if (var ('LIBTOOL')) { my $verbose = define_verbose_libtool (); define_variable ("LT$var", "\$(LIBTOOL) $verbose $libtool_tag\$(AM_LIBTOOLFLAGS)" . " \$(LIBTOOLFLAGS) --mode=compile $value", INTERNAL); } define_verbose_tagvar ($lang->ccer || 'GEN'); } sub define_linker_variable { my ($lang) = @_; my $libtool_tag = ''; $libtool_tag = '--tag=' . $lang->libtool_tag . ' ' if $lang->libtool_tag && exists $libtool_tags{$lang->libtool_tag}; # CCLD = $(CC). define_variable ($lang->lder, $lang->ld, INTERNAL); # CCLINK = $(CCLD) blah blah... my $link = ''; if (var ('LIBTOOL')) { my $verbose = define_verbose_libtool (); $link = "\$(LIBTOOL) $verbose $libtool_tag\$(AM_LIBTOOLFLAGS) " . "\$(LIBTOOLFLAGS) --mode=link "; } define_variable ($lang->linker, $link . $lang->link, INTERNAL); define_variable ($lang->compiler, $lang, INTERNAL); define_verbose_tagvar ($lang->lder || 'GEN'); } sub define_per_target_linker_variable { my ($linker, $target) = @_; # If the user wrote a custom link command, we don't define ours. return "${target}_LINK" if set_seen "${target}_LINK"; my $xlink = $linker ? $linker : 'LINK'; my $lang = $link_languages{$xlink}; prog_error "Unknown language for linker variable '$xlink'" unless $lang; my $link_command = $lang->link; if (var 'LIBTOOL') { my $libtool_tag = ''; $libtool_tag = '--tag=' . $lang->libtool_tag . ' ' if $lang->libtool_tag && exists $libtool_tags{$lang->libtool_tag}; my $verbose = define_verbose_libtool (); $link_command = "\$(LIBTOOL) $verbose $libtool_tag\$(AM_LIBTOOLFLAGS) \$(LIBTOOLFLAGS) " . "--mode=link " . $link_command; } # Rewrite each occurrence of 'AM_$flag' in the link # command into '${derived}_$flag' if it exists. my $orig_command = $link_command; my @flags = (@{$lang->flags}, 'LDFLAGS'); push @flags, 'LIBTOOLFLAGS' if var 'LIBTOOL'; for my $flag (@flags) { my $val = "${target}_$flag"; $link_command =~ s/\(AM_$flag\)/\($val\)/ if set_seen ($val); } # If the computed command is the same as the generic command, use # the command linker variable. return ($lang->linker, $lang->lder) if $link_command eq $orig_command; define_variable ("${target}_LINK", $link_command, INTERNAL); return ("${target}_LINK", $lang->lder); } ################################################################ # check_trailing_slash ($WHERE, $LINE) # ------------------------------------ # Return 1 iff $LINE ends with a slash. # Might modify $LINE. sub check_trailing_slash ($\$) { my ($where, $line) = @_; # Ignore '##' lines. return 0 if $$line =~ /$IGNORE_PATTERN/o; # Catch and fix a common error. msg "syntax", $where, "whitespace following trailing backslash" if $$line =~ s/\\\s+\n$/\\\n/; return $$line =~ /\\$/; } # read_am_file ($AMFILE, $WHERE, $RELDIR) # --------------------------------------- # Read $AMFILE file name which is located in $RELDIR, and set up # global variables resetted by '&generate_makefile'. Simultaneously # copy lines from $AMFILE into '$output_trailer', or define variables # as appropriate. # # NOTE: We put rules in the trailer section. We want user rules to # come after our generated stuff. sub read_am_file { my ($amfile, $where, $reldir) = @_; my $canon_reldir = &canonicalize ($reldir); my $am_file = new Automake::XFile ("< $amfile"); verb "reading $amfile"; # Keep track of the youngest output dependency. my $mtime = mtime $amfile; $output_deps_greatest_timestamp = $mtime if $mtime > $output_deps_greatest_timestamp; my $spacing = ''; my $comment = ''; my $blank = 0; my $saw_bk = 0; my $var_look = VAR_ASIS; use constant IN_VAR_DEF => 0; use constant IN_RULE_DEF => 1; use constant IN_COMMENT => 2; my $prev_state = IN_RULE_DEF; while ($_ = $am_file->getline) { $where->set ("$amfile:$."); if (/$IGNORE_PATTERN/o) { # Merely delete comments beginning with two hashes. } elsif (/$WHITE_PATTERN/o) { error $where, "blank line following trailing backslash" if $saw_bk; # Stick a single white line before the incoming macro or rule. $spacing = "\n"; $blank = 1; # Flush all comments seen so far. if ($comment ne '') { $output_vars .= $comment; $comment = ''; } } elsif (/$COMMENT_PATTERN/o) { # Stick comments before the incoming macro or rule. Make # sure a blank line precedes the first block of comments. $spacing = "\n" unless $blank; $blank = 1; $comment .= $spacing . $_; $spacing = ''; $prev_state = IN_COMMENT; } else { last; } $saw_bk = check_trailing_slash ($where, $_); } # We save the conditional stack on entry, and then check to make # sure it is the same on exit. This lets us conditionally include # other files. my @saved_cond_stack = @cond_stack; my $cond = new Automake::Condition (@cond_stack); my $last_var_name = ''; my $last_var_type = ''; my $last_var_value = ''; my $last_where; # FIXME: shouldn't use $_ in this loop; it is too big. while ($_) { $where->set ("$amfile:$."); # Make sure the line is \n-terminated. chomp; $_ .= "\n"; # Don't look at MAINTAINER_MODE_TRUE here. That shouldn't be # used by users. @MAINT@ is an anachronism now. $_ =~ s/\@MAINT\@//g unless $seen_maint_mode; my $new_saw_bk = check_trailing_slash ($where, $_); if ($reldir eq '.') { # If present, eat the following '_' or '/', converting # "%reldir%/foo" and "%canon_reldir%_foo" into plain "foo" # when $reldir is '.'. $_ =~ s,%(D|reldir)%/,,g; $_ =~ s,%(C|canon_reldir)%_,,g; } $_ =~ s/%(D|reldir)%/${reldir}/g; $_ =~ s/%(C|canon_reldir)%/${canon_reldir}/g; if (/$IGNORE_PATTERN/o) { # Merely delete comments beginning with two hashes. # Keep any backslash from the previous line. $new_saw_bk = $saw_bk; } elsif (/$WHITE_PATTERN/o) { # Stick a single white line before the incoming macro or rule. $spacing = "\n"; error $where, "blank line following trailing backslash" if $saw_bk; } elsif (/$COMMENT_PATTERN/o) { error $where, "comment following trailing backslash" if $saw_bk && $prev_state != IN_COMMENT; # Stick comments before the incoming macro or rule. $comment .= $spacing . $_; $spacing = ''; $prev_state = IN_COMMENT; } elsif ($saw_bk) { if ($prev_state == IN_RULE_DEF) { my $cond = new Automake::Condition @cond_stack; $output_trailer .= $cond->subst_string; $output_trailer .= $_; } elsif ($prev_state == IN_COMMENT) { # If the line doesn't start with a '#', add it. # We do this because a continued comment like # # A = foo \ # bar \ # baz # is not portable. BSD make doesn't honor # escaped newlines in comments. s/^#?/#/; $comment .= $spacing . $_; } else # $prev_state == IN_VAR_DEF { $last_var_value .= ' ' unless $last_var_value =~ /\s$/; $last_var_value .= $_; if (!/\\$/) { Automake::Variable::define ($last_var_name, VAR_MAKEFILE, $last_var_type, $cond, $last_var_value, $comment, $last_where, VAR_ASIS) if $cond != FALSE; $comment = $spacing = ''; } } } elsif (/$IF_PATTERN/o) { $cond = cond_stack_if ($1, $2, $where); } elsif (/$ELSE_PATTERN/o) { $cond = cond_stack_else ($1, $2, $where); } elsif (/$ENDIF_PATTERN/o) { $cond = cond_stack_endif ($1, $2, $where); } elsif (/$RULE_PATTERN/o) { # Found a rule. $prev_state = IN_RULE_DEF; # For now we have to output all definitions of user rules # and can't diagnose duplicates (see the comment in # Automake::Rule::define). So we go on and ignore the return value. Automake::Rule::define ($1, $amfile, RULE_USER, $cond, $where); check_variable_expansions ($_, $where); $output_trailer .= $comment . $spacing; my $cond = new Automake::Condition @cond_stack; $output_trailer .= $cond->subst_string; $output_trailer .= $_; $comment = $spacing = ''; } elsif (/$ASSIGNMENT_PATTERN/o) { # Found a macro definition. $prev_state = IN_VAR_DEF; $last_var_name = $1; $last_var_type = $2; $last_var_value = $3; $last_where = $where->clone; if ($3 ne '' && substr ($3, -1) eq "\\") { # We preserve the '\' because otherwise the long lines # that are generated will be truncated by broken # 'sed's. $last_var_value = $3 . "\n"; } # Normally we try to output variable definitions in the # same format they were input. However, POSIX compliant # systems are not required to support lines longer than # 2048 bytes (most notably, some sed implementation are # limited to 4000 bytes, and sed is used by config.status # to rewrite Makefile.in into Makefile). Moreover nobody # would really write such long lines by hand since it is # hardly maintainable. So if a line is longer that 1000 # bytes (an arbitrary limit), assume it has been # automatically generated by some tools, and flatten the # variable definition. Otherwise, keep the variable as it # as been input. $var_look = VAR_PRETTY if length ($last_var_value) >= 1000; if (!/\\$/) { Automake::Variable::define ($last_var_name, VAR_MAKEFILE, $last_var_type, $cond, $last_var_value, $comment, $last_where, $var_look) if $cond != FALSE; $comment = $spacing = ''; $var_look = VAR_ASIS; } } elsif (/$INCLUDE_PATTERN/o) { my $path = $1; if ($path =~ s/^\$\(top_srcdir\)\///) { push (@include_stack, "\$\(top_srcdir\)/$path"); # Distribute any included file. # Always use the $(top_srcdir) prefix in DIST_COMMON, # otherwise OSF make will implicitly copy the included # file in the build tree during "make distdir" to satisfy # the dependency. # (subdir-am-cond.sh and subdir-ac-cond.sh will fail) push_dist_common ("\$\(top_srcdir\)/$path"); } else { $path =~ s/\$\(srcdir\)\///; push (@include_stack, "\$\(srcdir\)/$path"); # Always use the $(srcdir) prefix in DIST_COMMON, # otherwise OSF make will implicitly copy the included # file in the build tree during "make distdir" to satisfy # the dependency. # (subdir-am-cond.sh and subdir-ac-cond.sh will fail) push_dist_common ("\$\(srcdir\)/$path"); $path = $relative_dir . "/" . $path if $relative_dir ne '.'; } my $new_reldir = File::Spec->abs2rel ($path, $relative_dir); $new_reldir = '.' if $new_reldir !~ s,/[^/]*$,,; $where->push_context ("'$path' included from here"); read_am_file ($path, $where, $new_reldir); $where->pop_context; } else { # This isn't an error; it is probably a continued rule. # In fact, this is what we assume. $prev_state = IN_RULE_DEF; check_variable_expansions ($_, $where); $output_trailer .= $comment . $spacing; my $cond = new Automake::Condition @cond_stack; $output_trailer .= $cond->subst_string; $output_trailer .= $_; $comment = $spacing = ''; error $where, "'#' comment at start of rule is unportable" if $_ =~ /^\t\s*\#/; } $saw_bk = $new_saw_bk; $_ = $am_file->getline; } $output_trailer .= $comment; error ($where, "trailing backslash on last line") if $saw_bk; error ($where, (@cond_stack ? "unterminated conditionals: @cond_stack" : "too many conditionals closed in include file")) if "@saved_cond_stack" ne "@cond_stack"; } # A helper for read_main_am_file which initializes configure variables # and variables from header-vars.am. sub define_standard_variables () { my $saved_output_vars = $output_vars; my ($comments, undef, $rules) = file_contents_internal (1, "$libdir/am/header-vars.am", new Automake::Location); foreach my $var (sort keys %configure_vars) { define_configure_variable ($var); } $output_vars .= $comments . $rules; } # read_main_am_file ($MAKEFILE_AM, $MAKEFILE_IN) # ---------------------------------------------- sub read_main_am_file { my ($amfile, $infile) = @_; # This supports the strange variable tricks we are about to play. prog_error ("variable defined before read_main_am_file\n" . variables_dump ()) if (scalar (variables) > 0); # Generate copyright header for generated Makefile.in. # We do discard the output of predefined variables, handled below. $output_vars = ("# " . basename ($infile) . " generated by automake " . $VERSION . " from " . basename ($amfile) . ".\n"); $output_vars .= '# ' . subst ('configure_input') . "\n"; $output_vars .= $gen_copyright; # We want to predefine as many variables as possible. This lets # the user set them with '+=' in Makefile.am. define_standard_variables; # Read user file, which might override some of our values. read_am_file ($amfile, new Automake::Location, '.'); } ################################################################ # $STRING # flatten ($ORIGINAL_STRING) # -------------------------- sub flatten { $_ = shift; s/\\\n//somg; s/\s+/ /g; s/^ //; s/ $//; return $_; } # transform_token ($TOKEN, \%PAIRS, $KEY) # --------------------------------------- # Return the value associated to $KEY in %PAIRS, as used on $TOKEN # (which should be ?KEY? or any of the special %% requests).. sub transform_token ($\%$) { my ($token, $transform, $key) = @_; my $res = $transform->{$key}; prog_error "Unknown key '$key' in '$token'" unless defined $res; return $res; } # transform ($TOKEN, \%PAIRS) # --------------------------- # If ($TOKEN, $VAL) is in %PAIRS: # - replaces %KEY% with $VAL, # - enables/disables ?KEY? and ?!KEY?, # - replaces %?KEY% with TRUE or FALSE. sub transform ($\%) { my ($token, $transform) = @_; # %KEY%. # Must be before the following pattern to exclude the case # when there is neither IFTRUE nor IFFALSE. if ($token =~ /^%([\w\-]+)%$/) { return transform_token ($token, %$transform, $1); } # %?KEY%. elsif ($token =~ /^%\?([\w\-]+)%$/) { return transform_token ($token, %$transform, $1) ? 'TRUE' : 'FALSE'; } # ?KEY? and ?!KEY?. elsif ($token =~ /^ \? (!?) ([\w\-]+) \? $/x) { my $neg = ($1 eq '!') ? 1 : 0; my $val = transform_token ($token, %$transform, $2); return (!!$val == $neg) ? '##%' : ''; } else { prog_error "Unknown request format: $token"; } } # $TEXT # preprocess_file ($MAKEFILE, [%TRANSFORM]) # ----------------------------------------- # Load a $MAKEFILE, apply the %TRANSFORM, and return the result. # No extra parsing or post-processing is done (i.e., recognition of # rules declaration or of make variables definitions). sub preprocess_file { my ($file, %transform) = @_; # Complete %transform with global options. # Note that %transform goes last, so it overrides global options. %transform = ( 'MAINTAINER-MODE' => $seen_maint_mode ? subst ('MAINTAINER_MODE_TRUE') : '', 'XZ' => !! option 'dist-xz', 'LZIP' => !! option 'dist-lzip', 'BZIP2' => !! option 'dist-bzip2', 'COMPRESS' => !! option 'dist-tarZ', 'GZIP' => ! option 'no-dist-gzip', 'SHAR' => !! option 'dist-shar', 'ZIP' => !! option 'dist-zip', 'INSTALL-INFO' => ! option 'no-installinfo', 'INSTALL-MAN' => ! option 'no-installman', 'CK-NEWS' => !! option 'check-news', 'SUBDIRS' => !! var ('SUBDIRS'), 'TOPDIR_P' => $relative_dir eq '.', 'BUILD' => ($seen_canonical >= AC_CANONICAL_BUILD), 'HOST' => ($seen_canonical >= AC_CANONICAL_HOST), 'TARGET' => ($seen_canonical >= AC_CANONICAL_TARGET), 'LIBTOOL' => !! var ('LIBTOOL'), 'NONLIBTOOL' => 1, %transform); if (! defined ($_ = $am_file_cache{$file})) { verb "reading $file"; # Swallow the whole file. my $fc_file = new Automake::XFile "< $file"; my $saved_dollar_slash = $/; undef $/; $_ = $fc_file->getline; $/ = $saved_dollar_slash; $fc_file->close; # Remove ##-comments. # Besides we don't need more than two consecutive new-lines. s/(?:$IGNORE_PATTERN|(?<=\n\n)\n+)//gom; # Remember the contents of the just-read file. $am_file_cache{$file} = $_; } # Substitute Automake template tokens. s/(?: % \?? [\w\-]+ % | \? !? [\w\-]+ \? )/transform($&, %transform)/gex; # transform() may have added some ##%-comments to strip. # (we use '##%' instead of '##' so we can distinguish ##%##%##% from # ####### and do not remove the latter.) s/^[ \t]*(?:##%)+.*\n//gm; return $_; } # @PARAGRAPHS # make_paragraphs ($MAKEFILE, [%TRANSFORM]) # ----------------------------------------- # Load a $MAKEFILE, apply the %TRANSFORM, and return it as a list of # paragraphs. sub make_paragraphs { my ($file, %transform) = @_; $transform{FIRST} = !$transformed_files{$file}; $transformed_files{$file} = 1; my @lines = split /(?set ($file); my $result_vars = ''; my $result_rules = ''; my $comment = ''; my $spacing = ''; # The following flags are used to track rules spanning across # multiple paragraphs. my $is_rule = 0; # 1 if we are processing a rule. my $discard_rule = 0; # 1 if the current rule should not be output. # We save the conditional stack on entry, and then check to make # sure it is the same on exit. This lets us conditionally include # other files. my @saved_cond_stack = @cond_stack; my $cond = new Automake::Condition (@cond_stack); foreach (make_paragraphs ($file, %transform)) { # FIXME: no line number available. $where->set ($file); # Sanity checks. error $where, "blank line following trailing backslash:\n$_" if /\\$/; error $where, "comment following trailing backslash:\n$_" if /\\#/; if (/^$/) { $is_rule = 0; # Stick empty line before the incoming macro or rule. $spacing = "\n"; } elsif (/$COMMENT_PATTERN/mso) { $is_rule = 0; # Stick comments before the incoming macro or rule. $comment = "$_\n"; } # Handle inclusion of other files. elsif (/$INCLUDE_PATTERN/o) { if ($cond != FALSE) { my $file = ($is_am ? "$libdir/am/" : '') . $1; $where->push_context ("'$file' included from here"); # N-ary '.=' fails. my ($com, $vars, $rules) = file_contents_internal ($is_am, $file, $where, %transform); $where->pop_context; $comment .= $com; $result_vars .= $vars; $result_rules .= $rules; } } # Handling the conditionals. elsif (/$IF_PATTERN/o) { $cond = cond_stack_if ($1, $2, $file); } elsif (/$ELSE_PATTERN/o) { $cond = cond_stack_else ($1, $2, $file); } elsif (/$ENDIF_PATTERN/o) { $cond = cond_stack_endif ($1, $2, $file); } # Handling rules. elsif (/$RULE_PATTERN/mso) { $is_rule = 1; $discard_rule = 0; # Separate relationship from optional actions: the first # `new-line tab" not preceded by backslash (continuation # line). my $paragraph = $_; /^(.*?)(?:(?subst_string/gme; $result_rules .= "$spacing$comment$condparagraph\n"; } if (scalar @undefined_conds == 0) { # Remember to discard next paragraphs # if they belong to this rule. # (but see also FIXME: #2 above.) $discard_rule = 1; } $comment = $spacing = ''; last; } } } elsif (/$ASSIGNMENT_PATTERN/mso) { my ($var, $type, $val) = ($1, $2, $3); error $where, "variable '$var' with trailing backslash" if /\\$/; $is_rule = 0; Automake::Variable::define ($var, $is_am ? VAR_AUTOMAKE : VAR_MAKEFILE, $type, $cond, $val, $comment, $where, VAR_ASIS) if $cond != FALSE; $comment = $spacing = ''; } else { # This isn't an error; it is probably some tokens which # configure is supposed to replace, such as '@SET-MAKE@', # or some part of a rule cut by an if/endif. if (! $cond->false && ! ($is_rule && $discard_rule)) { s/^/$cond->subst_string/gme; $result_rules .= "$spacing$comment$_\n"; } $comment = $spacing = ''; } } error ($where, @cond_stack ? "unterminated conditionals: @cond_stack" : "too many conditionals closed in include file") if "@saved_cond_stack" ne "@cond_stack"; return ($comment, $result_vars, $result_rules); } # $CONTENTS # file_contents ($BASENAME, $WHERE, [%TRANSFORM]) # ----------------------------------------------- # Return contents of a file from $libdir/am, automatically skipping # macros or rules which are already known. sub file_contents { my ($basename, $where, %transform) = @_; my ($comments, $variables, $rules) = file_contents_internal (1, "$libdir/am/$basename.am", $where, %transform); return "$comments$variables$rules"; } # @PREFIX # am_primary_prefixes ($PRIMARY, $CAN_DIST, @PREFIXES) # ---------------------------------------------------- # Find all variable prefixes that are used for install directories. A # prefix 'zar' qualifies iff: # # * 'zardir' is a variable. # * 'zar_PRIMARY' is a variable. # # As a side effect, it looks for misspellings. It is an error to have # a variable ending in a "reserved" suffix whose prefix is unknown, e.g. # "bni_PROGRAMS". However, unusual prefixes are allowed if a variable # of the same name (with "dir" appended) exists. For instance, if the # variable "zardir" is defined, then "zar_PROGRAMS" becomes valid. # This is to provide a little extra flexibility in those cases which # need it. sub am_primary_prefixes { my ($primary, $can_dist, @prefixes) = @_; local $_; my %valid = map { $_ => 0 } @prefixes; $valid{'EXTRA'} = 0; foreach my $var (variables $primary) { # Automake is allowed to define variables that look like primaries # but which aren't. E.g. INSTALL_sh_DATA. # Autoconf can also define variables like INSTALL_DATA, so # ignore all configure variables (at least those which are not # redefined in Makefile.am). # FIXME: We should make sure that these variables are not # conditionally defined (or else adjust the condition below). my $def = $var->def (TRUE); next if $def && $def->owner != VAR_MAKEFILE; my $varname = $var->name; if ($varname =~ /^(nobase_)?(dist_|nodist_)?(.*)_[[:alnum:]]+$/) { my ($base, $dist, $X) = ($1 || '', $2 || '', $3 || ''); if ($dist ne '' && ! $can_dist) { err_var ($var, "invalid variable '$varname': 'dist' is forbidden"); } # Standard directories must be explicitly allowed. elsif (! defined $valid{$X} && exists $standard_prefix{$X}) { err_var ($var, "'${X}dir' is not a legitimate directory " . "for '$primary'"); } # A not explicitly valid directory is allowed if Xdir is defined. elsif (! defined $valid{$X} && $var->requires_variables ("'$varname' is used", "${X}dir")) { # Nothing to do. Any error message has been output # by $var->requires_variables. } else { # Ensure all extended prefixes are actually used. $valid{"$base$dist$X"} = 1; } } else { prog_error "unexpected variable name: $varname"; } } # Return only those which are actually defined. return sort grep { var ($_ . '_' . $primary) } keys %valid; } # am_install_var (-OPTION..., file, HOW, where...) # ------------------------------------------------ # # Handle 'where_HOW' variable magic. Does all lookups, generates # install code, and possibly generates code to define the primary # variable. The first argument is the name of the .am file to munge, # the second argument is the primary variable (e.g. HEADERS), and all # subsequent arguments are possible installation locations. # # Returns list of [$location, $value] pairs, where # $value's are the values in all where_HOW variable, and $location # there associated location (the place here their parent variables were # defined). # # FIXME: this should be rewritten to be cleaner. It should be broken # up into multiple functions. # sub am_install_var { my (@args) = @_; my $do_require = 1; my $can_dist = 0; my $default_dist = 0; while (@args) { if ($args[0] eq '-noextra') { $do_require = 0; } elsif ($args[0] eq '-candist') { $can_dist = 1; } elsif ($args[0] eq '-defaultdist') { $default_dist = 1; $can_dist = 1; } elsif ($args[0] !~ /^-/) { last; } shift (@args); } my ($file, $primary, @prefix) = @args; # Now that configure substitutions are allowed in where_HOW # variables, it is an error to actually define the primary. We # allow 'JAVA', as it is customarily used to mean the Java # interpreter. This is but one of several Java hacks. Similarly, # 'PYTHON' is customarily used to mean the Python interpreter. reject_var $primary, "'$primary' is an anachronism" unless $primary eq 'JAVA' || $primary eq 'PYTHON'; # Get the prefixes which are valid and actually used. @prefix = am_primary_prefixes ($primary, $can_dist, @prefix); # If a primary includes a configure substitution, then the EXTRA_ # form is required. Otherwise we can't properly do our job. my $require_extra; my @used = (); my @result = (); foreach my $X (@prefix) { my $nodir_name = $X; my $one_name = $X . '_' . $primary; my $one_var = var $one_name; my $strip_subdir = 1; # If subdir prefix should be preserved, do so. if ($nodir_name =~ /^nobase_/) { $strip_subdir = 0; $nodir_name =~ s/^nobase_//; } # If files should be distributed, do so. my $dist_p = 0; if ($can_dist) { $dist_p = (($default_dist && $nodir_name !~ /^nodist_/) || (! $default_dist && $nodir_name =~ /^dist_/)); $nodir_name =~ s/^(dist|nodist)_//; } # Use the location of the currently processed variable. # We are not processing a particular condition, so pick the first # available. my $tmpcond = $one_var->conditions->one_cond; my $where = $one_var->rdef ($tmpcond)->location->clone; # Append actual contents of where_PRIMARY variable to # @result, skipping @substitutions@. foreach my $locvals ($one_var->value_as_list_recursive (location => 1)) { my ($loc, $value) = @$locvals; # Skip configure substitutions. if ($value =~ /^\@.*\@$/) { if ($nodir_name eq 'EXTRA') { error ($where, "'$one_name' contains configure substitution, " . "but shouldn't"); } # Check here to make sure variables defined in # configure.ac do not imply that EXTRA_PRIMARY # must be defined. elsif (! defined $configure_vars{$one_name}) { $require_extra = $one_name if $do_require; } } else { # Strip any $(EXEEXT) suffix the user might have added, # or this will confuse handle_source_transform() and # check_canonical_spelling(). # We'll add $(EXEEXT) back later anyway. # Do it here rather than in handle_programs so the # uniquifying at the end of this function works. ${$locvals}[1] =~ s/\$\(EXEEXT\)$// if $primary eq 'PROGRAMS'; push (@result, $locvals); } } # A blatant hack: we rewrite each _PROGRAMS primary to include # EXEEXT. append_exeext { 1 } $one_name if $primary eq 'PROGRAMS'; # "EXTRA" shouldn't be used when generating clean targets, # all, or install targets. We used to warn if EXTRA_FOO was # defined uselessly, but this was annoying. next if $nodir_name eq 'EXTRA'; if ($nodir_name eq 'check') { push (@check, '$(' . $one_name . ')'); } else { push (@used, '$(' . $one_name . ')'); } # Is this to be installed? my $install_p = $nodir_name ne 'noinst' && $nodir_name ne 'check'; # If so, with install-exec? (or install-data?). my $exec_p = ($nodir_name =~ /$EXEC_DIR_PATTERN/o); my $check_options_p = $install_p && !! option 'std-options'; # Use the location of the currently processed variable as context. $where->push_context ("while processing '$one_name'"); # The variable containing all files to distribute. my $distvar = "\$($one_name)"; $distvar = shadow_unconditionally ($one_name, $where) if ($dist_p && $one_var->has_conditional_contents); # Singular form of $PRIMARY. (my $one_primary = $primary) =~ s/S$//; $output_rules .= file_contents ($file, $where, PRIMARY => $primary, ONE_PRIMARY => $one_primary, DIR => $X, NDIR => $nodir_name, BASE => $strip_subdir, EXEC => $exec_p, INSTALL => $install_p, DIST => $dist_p, DISTVAR => $distvar, 'CK-OPTS' => $check_options_p); } # The JAVA variable is used as the name of the Java interpreter. # The PYTHON variable is used as the name of the Python interpreter. if (@used && $primary ne 'JAVA' && $primary ne 'PYTHON') { # Define it. define_pretty_variable ($primary, TRUE, INTERNAL, @used); $output_vars .= "\n"; } err_var ($require_extra, "'$require_extra' contains configure substitution,\n" . "but 'EXTRA_$primary' not defined") if ($require_extra && ! var ('EXTRA_' . $primary)); # Push here because PRIMARY might be configure time determined. push (@all, '$(' . $primary . ')') if @used && $primary ne 'JAVA' && $primary ne 'PYTHON'; # Make the result unique. This lets the user use conditionals in # a natural way, but still lets us program lazily -- we don't have # to worry about handling a particular object more than once. # We will keep only one location per object. my %result = (); for my $pair (@result) { my ($loc, $val) = @$pair; $result{$val} = $loc; } my @l = sort keys %result; return map { [$result{$_}->clone, $_] } @l; } ################################################################ # Each key in this hash is the name of a directory holding a # Makefile.in. These variables are local to 'is_make_dir'. my %make_dirs = (); my $make_dirs_set = 0; # is_make_dir ($DIRECTORY) # ------------------------ sub is_make_dir { my ($dir) = @_; if (! $make_dirs_set) { foreach my $iter (@configure_input_files) { $make_dirs{dirname ($iter)} = 1; } # We also want to notice Makefile.in's. foreach my $iter (@other_input_files) { if ($iter =~ /Makefile\.in$/) { $make_dirs{dirname ($iter)} = 1; } } $make_dirs_set = 1; } return defined $make_dirs{$dir}; } ################################################################ # Find the aux dir. This should match the algorithm used by # ./configure. (See the Autoconf documentation for for # AC_CONFIG_AUX_DIR.) sub locate_aux_dir () { if (! $config_aux_dir_set_in_configure_ac) { # The default auxiliary directory is the first # of ., .., or ../.. that contains install-sh. # Assume . if install-sh doesn't exist yet. for my $dir (qw (. .. ../..)) { if (-f "$dir/install-sh") { $config_aux_dir = $dir; last; } } $config_aux_dir = '.' unless $config_aux_dir; } # Avoid unsightly '/.'s. $am_config_aux_dir = '$(top_srcdir)' . ($config_aux_dir eq '.' ? "" : "/$config_aux_dir"); $am_config_aux_dir =~ s,/*$,,; } # push_required_file ($DIR, $FILE, $FULLFILE) # ------------------------------------------- # Push the given file onto DIST_COMMON. sub push_required_file { my ($dir, $file, $fullfile) = @_; # If the file to be distributed is in the same directory of the # currently processed Makefile.am, then we want to distribute it # from this same Makefile.am. if ($dir eq $relative_dir) { push_dist_common ($file); } # This is needed to allow a construct in a non-top-level Makefile.am # to require a file in the build-aux directory (see at least the test # script 'test-driver-is-distributed.sh'). This is related to the # automake bug#9546. Note that the use of $config_aux_dir instead # of $am_config_aux_dir here is deliberate and necessary. elsif ($dir eq $config_aux_dir) { push_dist_common ("$am_config_aux_dir/$file"); } # FIXME: another spacial case, for AC_LIBOBJ/AC_LIBSOURCE support. # We probably need some refactoring of this function and its callers, # to have a more explicit and systematic handling of all the special # cases; but, since there are only two of them, this is low-priority # ATM. elsif ($config_libobj_dir && $dir eq $config_libobj_dir) { # Avoid unsightly '/.'s. my $am_config_libobj_dir = '$(top_srcdir)' . ($config_libobj_dir eq '.' ? "" : "/$config_libobj_dir"); $am_config_libobj_dir =~ s|/*$||; push_dist_common ("$am_config_libobj_dir/$file"); } elsif ($relative_dir eq '.' && ! is_make_dir ($dir)) { # If we are doing the topmost directory, and the file is in a # subdir which does not have a Makefile, then we distribute it # here. # If a required file is above the source tree, it is important # to prefix it with '$(srcdir)' so that no VPATH search is # performed. Otherwise problems occur with Make implementations # that rewrite and simplify rules whose dependencies are found in a # VPATH location. Here is an example with OSF1/Tru64 Make. # # % cat Makefile # VPATH = sub # distdir: ../a # echo ../a # % ls # Makefile a # % make # echo a # a # # Dependency '../a' was found in 'sub/../a', but this make # implementation simplified it as 'a'. (Note that the sub/ # directory does not even exist.) # # This kind of VPATH rewriting seems hard to cancel. The # distdir.am hack against VPATH rewriting works only when no # simplification is done, i.e., for dependencies which are in # subdirectories, not in enclosing directories. Hence, in # the latter case we use a full path to make sure no VPATH # search occurs. $fullfile = '$(srcdir)/' . $fullfile if $dir =~ m,^\.\.(?:$|/),; push_dist_common ($fullfile); } else { prog_error "a Makefile in relative directory $relative_dir " . "can't add files in directory $dir to DIST_COMMON"; } } # If a file name appears as a key in this hash, then it has already # been checked for. This allows us not to report the same error more # than once. my %required_file_not_found = (); # required_file_check_or_copy ($WHERE, $DIRECTORY, $FILE) # ------------------------------------------------------- # Verify that the file must exist in $DIRECTORY, or install it. sub required_file_check_or_copy { my ($where, $dir, $file) = @_; my $fullfile = "$dir/$file"; my $found_it = 0; my $dangling_sym = 0; if (-l $fullfile && ! -f $fullfile) { $dangling_sym = 1; } elsif (dir_has_case_matching_file ($dir, $file)) { $found_it = 1; } # '--force-missing' only has an effect if '--add-missing' is # specified. 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 (! $found_it) { return if defined $required_file_not_found{$fullfile}; $required_file_not_found{$fullfile} = 1; } if ($dangling_sym && $add_missing) { unlink ($fullfile); } my $trailer = ''; my $trailer2 = ''; my $suppress = 0; # Only install missing files according to our desired # strictness level. my $message = "required file '$fullfile' not found"; if ($add_missing) { if (-f "$libdir/$file") { $suppress = 1; # Install the missing file. Symlink if we # can, copy if we must. Note: delete the file # first, in case it is a dangling symlink. $message = "installing '$fullfile'"; # The license file should not be volatile. if ($file eq "COPYING") { $message .= " using GNU General Public License v3 file"; $trailer2 = "\n Consider adding the COPYING file" . " to the version control system" . "\n for your code, to avoid questions" . " about which license your project uses"; } # Windows Perl will hang if we try to delete a # file that doesn't exist. unlink ($fullfile) if -f $fullfile; if ($symlink_exists && ! $copy_missing) { if (! symlink ("$libdir/$file", $fullfile) || ! -e $fullfile) { $suppress = 0; $trailer = "; error while making link: $!"; } } elsif (system ('cp', "$libdir/$file", $fullfile)) { $suppress = 0; $trailer = "\n error while copying"; } set_dir_cache_file ($dir, $file); } } else { $trailer = "\n 'automake --add-missing' can install '$file'" if -f "$libdir/$file"; } # If --force-missing was specified, and we have # actually found the file, then do nothing. return if $found_it && $force_missing; # If we couldn't install the file, but it is a target in # the Makefile, don't print anything. This allows files # like README, AUTHORS, or THANKS to be generated. return if !$suppress && rule $file; msg ($suppress ? 'note' : 'error', $where, "$message$trailer$trailer2"); } # require_file_internal ($WHERE, $MYSTRICT, $DIRECTORY, $QUEUE, @FILES) # --------------------------------------------------------------------- # Verify that the file must exist in $DIRECTORY, or install it. # $MYSTRICT is the strictness level at which this file becomes required. # Worker threads may queue up the action to be serialized by the master, # if $QUEUE is true sub require_file_internal { my ($where, $mystrict, $dir, $queue, @files) = @_; return unless $strictness >= $mystrict; foreach my $file (@files) { push_required_file ($dir, $file, "$dir/$file"); if ($queue) { queue_required_file_check_or_copy ($required_conf_file_queue, QUEUE_CONF_FILE, $relative_dir, $where, $mystrict, @files); } else { required_file_check_or_copy ($where, $dir, $file); } } } # require_file ($WHERE, $MYSTRICT, @FILES) # ---------------------------------------- sub require_file { my ($where, $mystrict, @files) = @_; require_file_internal ($where, $mystrict, $relative_dir, 0, @files); } # require_file_with_macro ($COND, $MACRO, $MYSTRICT, @FILES) # ---------------------------------------------------------- sub require_file_with_macro { my ($cond, $macro, $mystrict, @files) = @_; $macro = rvar ($macro) unless ref $macro; require_file ($macro->rdef ($cond)->location, $mystrict, @files); } # require_libsource_with_macro ($COND, $MACRO, $MYSTRICT, @FILES) # --------------------------------------------------------------- # Require an AC_LIBSOURCEd file. If AC_CONFIG_LIBOBJ_DIR was called, it # must be in that directory. Otherwise expect it in the current directory. sub require_libsource_with_macro { my ($cond, $macro, $mystrict, @files) = @_; $macro = rvar ($macro) unless ref $macro; if ($config_libobj_dir) { require_file_internal ($macro->rdef ($cond)->location, $mystrict, $config_libobj_dir, 0, @files); } else { require_file ($macro->rdef ($cond)->location, $mystrict, @files); } } # queue_required_file_check_or_copy ($QUEUE, $KEY, $DIR, $WHERE, # $MYSTRICT, @FILES) # -------------------------------------------------------------- sub queue_required_file_check_or_copy { my ($queue, $key, $dir, $where, $mystrict, @files) = @_; my @serial_loc; if (ref $where) { @serial_loc = (QUEUE_LOCATION, $where->serialize ()); } else { @serial_loc = (QUEUE_STRING, $where); } $queue->enqueue ($key, $dir, @serial_loc, $mystrict, 0 + @files, @files); } # require_queued_file_check_or_copy ($QUEUE) # ------------------------------------------ sub require_queued_file_check_or_copy { my ($queue) = @_; my $where; my $dir = $queue->dequeue (); my $loc_key = $queue->dequeue (); if ($loc_key eq QUEUE_LOCATION) { $where = Automake::Location::deserialize ($queue); } elsif ($loc_key eq QUEUE_STRING) { $where = $queue->dequeue (); } else { prog_error "unexpected key $loc_key"; } my $mystrict = $queue->dequeue (); my $nfiles = $queue->dequeue (); my @files; push @files, $queue->dequeue () foreach (1 .. $nfiles); return unless $strictness >= $mystrict; foreach my $file (@files) { required_file_check_or_copy ($where, $config_aux_dir, $file); } } # require_conf_file ($WHERE, $MYSTRICT, @FILES) # --------------------------------------------- # Looks in configuration path, as specified by AC_CONFIG_AUX_DIR. sub require_conf_file { my ($where, $mystrict, @files) = @_; my $queue = defined $required_conf_file_queue ? 1 : 0; require_file_internal ($where, $mystrict, $config_aux_dir, $queue, @files); } # require_conf_file_with_macro ($COND, $MACRO, $MYSTRICT, @FILES) # --------------------------------------------------------------- sub require_conf_file_with_macro { my ($cond, $macro, $mystrict, @files) = @_; require_conf_file (rvar ($macro)->rdef ($cond)->location, $mystrict, @files); } ################################################################ # require_build_directory ($DIRECTORY) # ------------------------------------ # Emit rules to create $DIRECTORY if needed, and return # the file that any target requiring this directory should be made # dependent upon. # We don't want to emit the rule twice, and want to reuse it # for directories with equivalent names (e.g., 'foo/bar' and './foo//bar'). sub require_build_directory { my $directory = shift; return $directory_map{$directory} if exists $directory_map{$directory}; my $cdir = File::Spec->canonpath ($directory); if (exists $directory_map{$cdir}) { my $stamp = $directory_map{$cdir}; $directory_map{$directory} = $stamp; return $stamp; } my $dirstamp = "$cdir/\$(am__dirstamp)"; $directory_map{$directory} = $dirstamp; $directory_map{$cdir} = $dirstamp; # Set a variable for the dirstamp basename. define_pretty_variable ('am__dirstamp', TRUE, INTERNAL, '$(am__leading_dot)dirstamp'); # Directory must be removed by 'make distclean'. $clean_files{$dirstamp} = DIST_CLEAN; $output_rules .= ("$dirstamp:\n" . "\t\@\$(MKDIR_P) $directory\n" . "\t\@: > $dirstamp\n"); return $dirstamp; } # require_build_directory_maybe ($FILE) # ------------------------------------- # If $FILE lies in a subdirectory, emit a rule to create this # directory and return the file that $FILE should be made # dependent upon. Otherwise, just return the empty string. sub require_build_directory_maybe { my $file = shift; my $directory = dirname ($file); if ($directory ne '.') { return require_build_directory ($directory); } else { return ''; } } ################################################################ # Push a list of files onto '@dist_common'. sub push_dist_common { prog_error "push_dist_common run after handle_dist" if $handle_dist_run; push @dist_common, @_; } ################################################################ # generate_makefile ($MAKEFILE_AM, $MAKEFILE_IN) # ---------------------------------------------- # Generate a Makefile.in given the name of the corresponding Makefile and # the name of the file output by config.status. sub generate_makefile { my ($makefile_am, $makefile_in) = @_; # Reset all the Makefile.am related variables. initialize_per_input; # AUTOMAKE_OPTIONS can contains -W flags to disable or enable # warnings for this file. So hold any warning issued before # we have processed AUTOMAKE_OPTIONS. buffer_messages ('warning'); # $OUTPUT is encoded. If it contains a ":" then the first element # is the real output file, and all remaining elements are input # files. We don't scan or otherwise deal with these input files, # other than to mark them as dependencies. See the subroutine # 'scan_autoconf_files' for details. my ($makefile, @inputs) = split (/:/, $output_files{$makefile_in}); $relative_dir = dirname ($makefile); read_main_am_file ($makefile_am, $makefile_in); if (not handle_options) { # Process buffered warnings. flush_messages; # Fatal error. Just return, so we can continue with next file. return; } # Process buffered warnings. flush_messages; # There are a few install-related variables that you should not define. foreach my $var ('PRE_INSTALL', 'POST_INSTALL', 'NORMAL_INSTALL') { my $v = var $var; if ($v) { my $def = $v->def (TRUE); prog_error "$var not defined in condition TRUE" unless $def; reject_var $var, "'$var' should not be defined" if $def->owner != VAR_AUTOMAKE; } } # Catch some obsolete variables. msg_var ('obsolete', 'INCLUDES', "'INCLUDES' is the old name for 'AM_CPPFLAGS' (or '*_CPPFLAGS')") if var ('INCLUDES'); # Must do this after reading .am file. define_variable ('subdir', $relative_dir, INTERNAL); # If DIST_SUBDIRS is defined, make sure SUBDIRS is, so that # recursive rules are enabled. define_pretty_variable ('SUBDIRS', TRUE, INTERNAL, '') if var 'DIST_SUBDIRS' && ! var 'SUBDIRS'; # Check first, because we might modify some state. check_gnu_standards; check_gnits_standards; handle_configure ($makefile_am, $makefile_in, $makefile, @inputs); handle_gettext; handle_targets; handle_libraries; handle_ltlibraries; handle_programs; handle_scripts; handle_silent; # These must be run after all the sources are scanned. They use # variables defined by handle_libraries(), handle_ltlibraries(), # or handle_programs(). handle_compile; handle_languages; handle_libtool; # Variables used by distdir.am and tags.am. define_pretty_variable ('SOURCES', TRUE, INTERNAL, @sources); if (! option 'no-dist') { define_pretty_variable ('DIST_SOURCES', TRUE, INTERNAL, @dist_sources); } handle_texinfo; handle_emacs_lisp; handle_python; handle_java; handle_man_pages; handle_data; handle_headers; handle_subdirs; handle_user_recursion; handle_tags; handle_minor_options; # Must come after handle_programs so that %known_programs is up-to-date. handle_tests; # This must come after most other rules. handle_dist; handle_footer; do_check_merge_target; handle_all ($makefile); # FIXME: Gross! if (var ('lib_LTLIBRARIES') && var ('bin_PROGRAMS')) { $output_rules .= "install-binPROGRAMS: install-libLTLIBRARIES\n\n"; } if (var ('nobase_lib_LTLIBRARIES') && var ('bin_PROGRAMS')) { $output_rules .= "install-binPROGRAMS: install-nobase_libLTLIBRARIES\n\n"; } handle_install; handle_clean ($makefile); handle_factored_dependencies; # Comes last, because all the above procedures may have # defined or overridden variables. $output_vars .= output_variables; check_typos; if ($exit_code != 0) { verb "not writing $makefile_in because of earlier errors"; return; } my $am_relative_dir = dirname ($makefile_am); mkdir ($am_relative_dir, 0755) if ! -d $am_relative_dir; # We make sure that 'all:' is the first target. my $output = "$output_vars$output_all$output_header$output_rules$output_trailer"; # Decide whether we must update the output file or not. # We have to update in the following situations. # * $force_generation is set. # * any of the output dependencies is younger than the output # * the contents of the output is different (this can happen # if the project has been populated with a file listed in # @common_files since the last run). # Output's dependencies are split in two sets: # * dependencies which are also configure dependencies # These do not change between each Makefile.am # * other dependencies, specific to the Makefile.am being processed # (such as the Makefile.am itself, or any Makefile fragment # it includes). my $timestamp = mtime $makefile_in; if (! $force_generation && $configure_deps_greatest_timestamp < $timestamp && $output_deps_greatest_timestamp < $timestamp && $output eq contents ($makefile_in)) { verb "$makefile_in unchanged"; # No need to update. return; } if (-e $makefile_in) { unlink ($makefile_in) or fatal "cannot remove $makefile_in: $!"; } my $gm_file = new Automake::XFile "> $makefile_in"; verb "creating $makefile_in"; print $gm_file $output; } ################################################################ # Helper function for usage(). sub print_autodist_files { my @lcomm = uniq (sort @_); my @four; format USAGE_FORMAT = @<<<<<<<<<<<<<<<< @<<<<<<<<<<<<<<<< @<<<<<<<<<<<<<<<< @<<<<<<<<<<<<<<<< $four[0], $four[1], $four[2], $four[3] . local $~ = "USAGE_FORMAT"; my $cols = 4; my $rows = int(@lcomm / $cols); my $rest = @lcomm % $cols; if ($rest) { $rows++; } else { $rest = $cols; } for (my $y = 0; $y < $rows; $y++) { @four = ("", "", "", ""); for (my $x = 0; $x < $cols; $x++) { last if $y + 1 == $rows && $x == $rest; my $idx = (($x > $rest) ? ($rows * $rest + ($rows - 1) * ($x - $rest)) : ($rows * $x)); $idx += $y; $four[$x] = $lcomm[$idx]; } write; } } sub usage () { print "Usage: $0 [OPTION]... [Makefile]... Generate Makefile.in for configure from Makefile.am. Operation modes: --help print this help, then exit --version print version number, then exit -v, --verbose verbosely list files processed --no-force only update Makefile.in's that are out of date -W, --warnings=CATEGORY report the warnings falling in CATEGORY Dependency tracking: -i, --ignore-deps disable dependency tracking code --include-deps enable dependency tracking code Flavors: --foreign set strictness to foreign --gnits set strictness to gnits --gnu set strictness to gnu Library files: -a, --add-missing add missing standard files to package --libdir=DIR set directory storing library files --print-libdir print directory storing library files -c, --copy with -a, copy missing files (default is symlink) -f, --force-missing force update of standard files "; Automake::ChannelDefs::usage; print "\nFiles automatically distributed if found " . "(always):\n"; print_autodist_files @common_files; print "\nFiles automatically distributed if found " . "(under certain conditions):\n"; print_autodist_files @common_sometimes; print ' Report bugs to . GNU Automake home page: . General help using GNU software: . '; # --help always returns 0 per GNU standards. exit 0; } sub version () { print < This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law. Written by Tom Tromey and Alexandre Duret-Lutz . EOF # --version always returns 0 per GNU standards. exit 0; } ################################################################ # Parse command line. sub parse_arguments () { my $strict = 'gnu'; my $ignore_deps = 0; my @warnings = (); my %cli_options = ( 'version' => \&version, 'help' => \&usage, 'libdir=s' => \$libdir, 'print-libdir' => sub { print "$libdir\n"; exit 0; }, 'gnu' => sub { $strict = 'gnu'; }, 'gnits' => sub { $strict = 'gnits'; }, 'foreign' => sub { $strict = 'foreign'; }, 'include-deps' => sub { $ignore_deps = 0; }, 'i|ignore-deps' => sub { $ignore_deps = 1; }, 'no-force' => sub { $force_generation = 0; }, 'f|force-missing' => \$force_missing, 'a|add-missing' => \$add_missing, 'c|copy' => \$copy_missing, 'v|verbose' => sub { setup_channel 'verb', silent => 0; }, 'W|warnings=s' => \@warnings, ); use Automake::Getopt (); Automake::Getopt::parse_options %cli_options; set_strictness ($strict); my $cli_where = new Automake::Location; set_global_option ('no-dependencies', $cli_where) if $ignore_deps; for my $warning (@warnings) { parse_warnings ('-W', $warning); } return unless @ARGV; my $errspec = 0; foreach my $arg (@ARGV) { fatal ("empty argument\nTry '$0 --help' for more information") if ($arg eq ''); # Handle $local:$input syntax. my ($local, @rest) = split (/:/, $arg); @rest = ("$local.in",) unless @rest; my $input = locate_am @rest; if ($input) { push @input_files, $input; $output_files{$input} = join (':', ($local, @rest)); } else { error "no Automake input file found for '$arg'"; $errspec = 1; } } fatal "no input file found among supplied arguments" if $errspec && ! @input_files; } # handle_makefile ($MAKEFILE) # --------------------------- sub handle_makefile { my ($file) = @_; ($am_file = $file) =~ s/\.in$//; if (! -f ($am_file . '.am')) { error "'$am_file.am' does not exist"; } else { # Any warning setting now local to this Makefile.am. dup_channel_setup; generate_makefile ($am_file . '.am', $file); # Back out any warning setting. drop_channel_setup; } } # Deal with all makefiles, without threads. sub handle_makefiles_serial () { foreach my $file (@input_files) { handle_makefile ($file); } } # Logic for deciding how many worker threads to use. sub get_number_of_threads () { my $nthreads = $ENV{'AUTOMAKE_JOBS'} || 0; $nthreads = 0 unless $nthreads =~ /^[0-9]+$/; # It doesn't make sense to use more threads than makefiles, my $max_threads = @input_files; if ($nthreads > $max_threads) { $nthreads = $max_threads; } return $nthreads; } # handle_makefiles_threaded ($NTHREADS) # ------------------------------------- # Deal with all makefiles, using threads. The general strategy is to # spawn NTHREADS worker threads, dispatch makefiles to them, and let the # worker threads push back everything that needs serialization: # * warning and (normal) error messages, for stable stderr output # order and content (avoiding duplicates, for example), # * races when installing aux files (and respective messages), # * races when collecting aux files for distribution. # # The latter requires that the makefile that deals with the aux dir # files be handled last, done by the master thread. sub handle_makefiles_threaded { my ($nthreads) = @_; # The file queue distributes all makefiles, the message queues # collect all serializations needed for respective files. my $file_queue = Thread::Queue->new; my %msg_queues; foreach my $file (@input_files) { $msg_queues{$file} = Thread::Queue->new; } verb "spawning $nthreads worker threads"; my @threads = (1 .. $nthreads); foreach my $t (@threads) { $t = threads->new (sub { while (my $file = $file_queue->dequeue) { verb "handling $file"; my $queue = $msg_queues{$file}; setup_channel_queue ($queue, QUEUE_MESSAGE); $required_conf_file_queue = $queue; handle_makefile ($file); $queue->enqueue (undef); setup_channel_queue (undef, undef); $required_conf_file_queue = undef; } return $exit_code; }); } # Queue all makefiles. verb "queuing " . @input_files . " input files"; $file_queue->enqueue (@input_files, (undef) x @threads); # Collect and process serializations. foreach my $file (@input_files) { verb "dequeuing messages for " . $file; reset_local_duplicates (); my $queue = $msg_queues{$file}; while (my $key = $queue->dequeue) { if ($key eq QUEUE_MESSAGE) { pop_channel_queue ($queue); } elsif ($key eq QUEUE_CONF_FILE) { require_queued_file_check_or_copy ($queue); } else { prog_error "unexpected key $key"; } } } foreach my $t (@threads) { my @exit_thread = $t->join; $exit_code = $exit_thread[0] if ($exit_thread[0] > $exit_code); } } ################################################################ # Parse the WARNINGS environment variable. parse_WARNINGS; # Parse command line. parse_arguments; $configure_ac = require_configure_ac; # Do configure.ac scan only once. scan_autoconf_files; if (! @input_files) { my $msg = ''; $msg = "\nDid you forget AC_CONFIG_FILES([Makefile]) in $configure_ac?" if -f 'Makefile.am'; fatal ("no 'Makefile.am' found for any configure output$msg"); } my $nthreads = get_number_of_threads (); if ($perl_threads && $nthreads >= 1) { handle_makefiles_threaded ($nthreads); } else { handle_makefiles_serial (); } exit $exit_code; AUTHORS000064400000001051152531507370005621 0ustar00Authors of GNU Automake. David Mackenzie First version of most ".am" files. Wrote sh version of automake.in. Tom Tromey Touched all ".am" files. Rewrote automake.in Alexandre Oliva Some of the user-side dependency tracking system. Some more random hacking. Alexandre Duret-Lutz Major overhaul of everything. Maintenance since 2002. Ralf Wildenhues Random breakage. Maintenance since 2006. Stefano Lattarini Testsuite overhaul. TAP support and custom testsuite drivers. Random breakage. De-facto maintenance since 2012. THANKS000064400000055435152531507370005503 0ustar00Automake was originally written by David J. MacKenzie . It would not be what it is today without the invaluable help of these people: Adam J. Richter adam@yggdrasil.com Adam Mercer ramercer@gmail.com Adam Sampson ats@offog.org Adrian Bunk bunk@fs.tum.de Aharon Robbins arnold@skeeve.com Akim Demaille akim@gnu.org Alan Modra amodra@bigpond.net.au Alex Hornby alex@anvil.co.uk Alex Unleashed unledev@gmail.com Alexander Mai st002279@hrzpub.tu-darmstadt.de Alexander Martens alexander.martens@gtd.es Alexander V. Lukyanov lav@yars.free.net Alexander Turbov zaufi@sendmail.ru Alexandre Duret-Lutz duret_g@epita.fr Alexey Mahotkin alexm@hsys.msk.ru Alfred M. Szmidt ams@gnu.org Andrea Urbani matfanjol@mail.com Andreas Bergmeier lcid-fire@gmx.net Andreas Buening andreas.buening@nexgo.de Andreas Köhler andi5.py@gmx.net Andreas Schwab schwab@suse.de Andrew Cagney cagney@tpgi.com.au Andrew Eikum aeikum@codeweavers.com Andrew Suffield asuffield@debian.org Andris Pavenis pavenis@lanet.lv Andy Wingo wingo@pobox.com Angus Leeming a.leeming@ic.ac.uk Anthony Green green@cygnus.com Antonio Diaz Diaz ant_diaz@teleline.es Arkadiusz Miskiewicz misiek@pld.ORG.PL Art Haas ahaas@neosoft.com Arto C. Nirkko anirkko@insel.ch Assar Westerlund assar@sics.se Axel Belinfante Axel.Belinfante@cs.utwente.nl Bas Wijnen shevek@fmf.nl Ben Pfaff blp@cs.standford.edu Benoit Sigoure tsuna@lrde.epita.fr Bernard Giroud bernard.giroud@creditlyonnais.ch Bernard Urban Bernard.Urban@meteo.fr Bernd Jendrissek berndfoobar@users.sourceforge.net Bert Wesarg bert.wesarg@googlemail.com Bill Currie bcurrie@tssc.co.nz Bill Davidson bill@kayhay.com Bill Fenner fenner@parc.xerox.com Bob Friesenhahn bfriesen@simple.dallas.tx.us Bob Proulx rwp@hprwp.fc.hp.com Bob Rossi bob@brasko.net Bobby Jack bobbykjack@yahoo.co.uk Boris Kolpackov boris@codesynthesis.com Braden N. McDaniel braden@endoframe.com Brandon Black blblack@gmail.com Brendan O'Dea bod@debian.org Brian Cameron Brian.Cameron@Sun.COM Brian Ford ford@vss.fsi.com Brian Gough bjg@network-theory.co.uk Brian Jones cbj@nortel.net Bruce Korb bkorb@gnu.org Bruno Haible haible@ilog.fr Carnë Draug carandraug+dev@gmail.com Carsten Lohrke carlo@gentoo.org Charles Wilson cwilson@ece.gatech.edu Chris Hoogendyk hoogendyk@bio.umass.edu Chris Pickett chris.pickett@mail.mcgill.ca Chris Provenzano proven@io.proven.org Christian Cornelssen ccorn@cs.tu-berlin.de Christina Gratorp christina.gratorp@gmail.com Claudio Fontana sick_soul@yahoo.it Clifford Wolf clifford@clifford.at Colin Watson cjwatson@ubuntu.com Dagobert Michelsen dam@opencsw.org Daiki Ueno ueno@unixuser.org Dalibor Topic robilad@kaffe.org danbp danpb@nospam.postmaster.co.uk Daniel Jacobowitz drow@false.org Daniel Kahn Gillmor dkg@fifthhorseman.net Daniel Richard G. skunk@iskunk.org Debarshi Ray rishi@gnu.org Dave Brolley brolley@redhat.com Dave Goodell goodell@mcs.anl.gov Dave Hart davehart@gmail.com Dave Korn dave.korn.cygwin@googlemail.com Dave Morrison dave@bnl.gov David A. Swierczek swiercze@mr.med.ge.com David A. Wheeler dwheeler@dwheeler.com David Byron dbyron@dbyron.com David Fang fang@csl.cornell.edu Davyd Madeley davyd@fugro-fsi.com.au David Pashley david@davidpashley.com David Wohlferd dw@limegreensocks.com David Zaroski cz253@cleveland.Freenet.Edu Dean Povey dpovey@wedgetail.com Dennis J. Linse Dennis.J.Linse@SAIC.com Dennis Schridde devurandom@gmx.net Derek R. Price derek.price@openavenue.com Diab Jerius djerius@cfa.harvard.edu Didier Cassirame faded@free.fr Diego Elio Pettenò flameeyes@flameeyes.eu Dieter Baron dillo@stieltjes.smc.univie.ac.at Dieter Jurzitza DJurzitza@harmanbecker.com Дилян Палаузов dilyan.palauzov@aegee.org Dmitry Mikhin dmitrym@acres.com.au Dmitry V. Levin ldv@altlinux.org Doug Evans devans@cygnus.com Duncan Gibson duncan@thermal.esa.int Dilyan Palauzov dilyan.palauzov@aegee.org Ed Hartnett ed@unidata.ucar.edu Eleftherios Gkioulekas lf@amath.washington.edu Elena A. Vengerova helen@oktetlabs.ru Elmar Hoffmann elho@elho.net Elrond Elrond@Wunder-Nett.org Enrico Scholz enrico.scholz@informatik.tu-chemnitz.de Erez Zadok ezk@cs.columbia.edu Eric Bavier bavier@cray.com Eric Blake eblake@redhat.com Eric Dorland eric@debian.org Eric Magnien emagnien@club-internet.fr Eric Siegerman erics_97@pobox.com Eric Sunshine sunshine@sunshineco.com Erick Branderhorst branderh@iaehv.nl Erik Lindahl E.Lindahl@chem.rug.nl Esben Haabendal Soerensen bart@kom.aau.dk Ezra Peisach epeisach@MED-XTAL.BU.EDU Fabian Alenius fabian.alenius@gmail.com Federico Simoncelli fsimonce@redhat.com Felix Salfelder felix@salfelder.org Flavien Astraud flav42@yahoo.fr Florian Briegel briegel@zone42.de Francesco Salvestrini salvestrini@gmail.com François Pinard pinard@iro.umontreal.ca Fred Fish fnf@ninemoons.com Ganesan Rajagopal rganesan@novell.com Garrett D'Amore garrett@qualcomm.com Garth Corral garthc@inktomi.com Gary V Vaughan gvaughan@oranda.demon.co.uk Gavin Smith gavinsmith0123@gmail.com Geoffrey Keating geoffk@apple.com Glenn Amerine glenn@pie.mhsc.org Gord Matzigkeit gord@gnu.ai.mit.edu Gordon Sadler gbsadler1@lcisp.com Graham Reitz grahamreitz@me.com Greg A. Woods woods@most.weird.com Greg Schafer gschafer@zip.com.au Guido Draheim guidod@gmx.de Guillermo Ontañón gontanonext@pandasoftware.es Gustavo Carneiro gjc@inescporto.pt Gwenole Beauchesne gbeauchesne@mandrakesoft.com H.J. Lu hjl@lucon.org H.Merijn Brand h.m.brand@hccnet.nl Hans Ulrich Niedermann hun@n-dimensional.de Hanspeter Niederstrasser fink@snaggledworks.com Harald Dunkel harald@CoWare.com Harlan Stenn Harlan.Stenn@pfcs.com He Li tippa000@yahoo.com Henrik Frystyk Nielsen frystyk@w3.org Hib Eris hib@hiberis.nl Hilko Bengen bengen@debian.org Holger Hans Peter Freyther holger@freyther.de Ian Lance Taylor ian@cygnus.com Ignacy Gawedzki i@lri.fr Илья Н. Голубев gin@mo.msk.ru Imacat imacat@mail.imacat.idv.tw Infirit infirit@gmail.com Inoue inoue@ainet.or.jp Jack Kelly jack@jackkelly.name James Amundson amundson@users.sourceforge.net James Bostock james.bostock@gmail.com James Henstridge james@daa.com.au James R. Van Zandt jrv@vanzandt.mv.com James Youngman jay@gnu.org Jan Engelhardt jengelh@medozas.de Janos Farkas chexum@shadow.banki.hu Jared Davis abiword@aiksaurus.com Jason DeVinney jasondevinney@gmail.com Jason Duell jcduell@lbl.gov Jason Molenda crash@cygnus.co.jp Javier Jardón jjardon@gnome.org Jeff Bailey Jbailey@phn.ca Jeff A. Daily jeff.daily@pnl.gov Jeff Garzik jgarzik@pobox.com Jeff Squyres jsquyres@lam-mpi.org Jens Elkner elkner@imsgroup.de Jens Krüger jens_krueger@physik.tu-muenchen.de Jens Petersen petersen@redhat.com Jeremy Nimmer jwnimmer@alum.mit.edu Jerome Lovy jlovy@multimania.com Jerome Santini santini@chambord.univ-orleans.fr Jesse Chisholm jesse@ctc.volant.org Jim Meyering meyering@na-net.ornl.gov Joakim Tjernlund Joakim.Tjernlund@transmode.se Jochen Kuepper jochen@uni-duesseldorf.de Joel N. Weber II nemo@koa.iolani.honolulu.hi.us Joerg-Martin Schwarz jms@jms.prima.ruhr.de Johan Dahlin jdahlin@async.com.br Johan Danielsson joda@pdc.kth.se Johan Kristensen johankristensen@gmail.com Johannes Nicolai johannes.nicolai@student.hpi.uni-potsdam.de John Calcote john.calcote@gmail.com John F Trudeau JohnTrudeau@firsthealth.com John Pierce hawkfan@pyrotechnics.com John Ratliff autoconf@technoplaza.net John R. Cary cary@txcorp.com John W. Coomes jcoomes@eng.Sun.COM Jonathan L Peyton jonathan.l.peyton@intel.com Jonathan Nieder jrnieder@gmail.com Joseph S. Myers joseph@codesourcery.com Josh MacDonald jmacd@cs.berkeley.edu Joshua Cowan jcowan@jcowan.reslife.okstate.edu js pendry js.pendry@msdw.com Juergen A. Erhard jae@laden.ilk.de Juergen Keil jk@tools.de Juergen Leising juergen.leising@gmx.de Julien Sopena julien.sopena@lip6.fr Jürg Billeter j@bitron.ch Karl Berry kb@cs.umb.edu Karl Heuer kwzh@gnu.org Kelley Cook kcook@gcc.gnu.org Kent Boortz kent@mysql.com Kevin Dalley kevin@aimnet.com Kevin P. Fleming. kpfleming@cox.net Kevin Ryde user42@zip.com.au Kevin Street street@iname.com Klaus Reichl Klaus.Reichl@alcatel.at Krzysztof Żelechowski giecrilj@stegny.2a.pl L. Peter Deutsch ghost@aladdin.com Ladislav Strojil Ladislav.Strojil@seznam.cz Larry Daniel larry@larrybrucedaniel.com Larry Jones larry.jones@sdrc.com Lars Hecking lhecking@nmrc.ucc.ie Lars J. Aas larsa@sim.no Laurent Morichetti laurentm@cup.hp.com Leo Davis ldavis@fonix.com Leonardo Boiko leoboiko@conectiva.com.br Loulou Pouchet loulou@lrde.epita.fr Ludovic Courtès ludo@gnu.org Luo Yi luoyi.ly@gmail.com Maciej Stachowiak mstachow@mit.edu Maciej W. Rozycki macro@ds2.pg.gda.pl Manu Rouat emmanuel.rouat@wanadoo.fr Marc Herbert marc.herbert@intel.com Marcus Brinkmann Marcus.Brinkmann@ruhr-uni-bochum.de Marcus G. Daniels mgd@ute.santafe.edu Marius Vollmer mvo@zagadka.ping.de Marc-Antoine Perennou Marc-Antoine@Perennou.com Mark D. Baushke mdb@cvshome.org Mark Eichin eichin@cygnus.com Mark Elbrecht snowball3@bigfoot.com Mark Galassi rosalia@nis.lanl.gov Mark Mitchell mark@codesourcery.com Mark Phillips msp@nortelnetworks.com Markku Rossi mtr@ngs.fi Markus Duft Markus.Duft@salomon.at Markus F.X.J. Oberhumer k3040e4@wildsau.idv-edu.uni-linz.ac.at Martin Bravenboer martin@cs.uu.nl Martin Frydl martin@idoox.com Martin Waitz tali@admingilde.org Mathias Doreille doreille@smr.ch Mathias Froehlich M.Froehlich@science-computing.de Mathias Hasselmann mathias.hasselmann@gmx.de Matt Burgess matthew@linuxfromscratch.org Matt Leach mleach@cygnus.com Matthew D. Langston langston@SLAC.Stanford.EDU Matthias Andree matthias.andree@gmx.de Matthias Clasen clasen@mathematik.uni-freiburg.de Matthias Klose doko@ubuntu.com Matthieu Baerts matttbe@glx-dock.org Max Horn max@quendi.de Maxim Sinev good@goods.ru Maynard Johnson maynardj@us.ibm.com Merijn de Jonge M.de.Jonge@cwi.nl Michael Brantley Michael-Brantley@deshaw.com Michael Daniels mdaniels@rim.com Michael Hofmann mhofma@googlemail.com Michael Ploujnikov ploujj@gmail.com Michael Zucchi notzed@gmail.com Michel de Ruiter mdruiter@cs.vu.nl Mike Castle dalgoda@ix.netcom.com Mike Frysinger vapier@gentoo.org Mike Nolta mrnolta@princeton.edu Miles Bader miles@ccs.mt.nec.co.jp Miloslav Trmac trmac@popelka.ms.mff.cuni.cz Miodrag Vallat miodrag@ifrance.com Mirko Streckenbach strecken@infosun.fmi.uni-passau.de Miroslaw Dobrzanski-Neumann mne@mosaic-ag.com Morten Eriksen mortene@sim.no Motoyuki Kasahara m-kasahr@sra.co.jp Nathanael Nerode neroden@twcny.rr.com Nelson H. F. Beebe beebe@math.utah.edu Nicholas Wourms nwourms@netscape.net Nick Bowler nbowler@elliptictech.com Nick Brown brownn@brocade.com Nicola Fontana ntd@entidi.it Nicolas Joly njoly@pasteur.fr Nicolas Thiery nthiery@Icare.mines.edu NightStrike nightstrike@gmail.com Nik A. Melchior nam1@cse.wustl.edu Nikolai Weibull now@bitwi.se NISHIDA Keisuke knishida@nn.iij4u.or.jp Noah Friedman friedman@gnu.ai.mit.edu Norman Gray norman@astro.gla.ac.uk Nyul Laszlo nyul@sol.cc.u-szeged.hu OKUJI Yoshinori okuji@kuicr.kyoto-u.ac.jp Olivier Fourdan fourdan@cena.fr Olivier Louchart-Fletcher olivier@zipworld.com.au Olly Betts olly@muscat.co.uk Oren Ben-Kiki oren@ben-kiki.org Owen Taylor otaylor@redhat.com Panther Martin mrsmiley98@lycos.com Patrick Welche prlw1@newn.cam.ac.uk Patrik Weiskircher me@justp.at Paul Berrevoets paul@swi.com Paul D. Smith psmith@BayNetworks.COM Paul Eggert eggert@twinsun.com Paul Jarc prj@po.cwru.edu Paul Lunau temp@lunau.me.uk Paul Martinolich martinol@datasync.com Paul Thomas PTHOMAS@novell.com Pavel Raiskup praiskup@redhat.com Pavel Roskin pavel_roskin@geocities.com Pavel Sanda ps@twin.jikos.cz Per Bothner bothner@cygnus.com Per Cederqvist ceder@lysator.liu.se Per Oyvind Hvidsten poeh@enter.vg Peter Breitenlohner peb@mppmu.mpg.de Peter Eisentraut peter_e@gmx.net Peter Gavin pgavin@debaser.kicks-ass.org Peter Hutterer peter.hutterer@who-t.net Peter Johansson trojkan@gmail.com Peter Mattis petm@scam.XCF.Berkeley.EDU Peter Muir iyhi@yahoo.com Peter O'Gorman peter@pogma.com Peter Rosin peda@lysator.liu.se Peter Seiderer seiderer123@ciselant.de Petr Hracek phracek@redhat.com Petter Reinholdtsen pere@hungry.com Petteri Räty betelgeuse@gentoo.org Phil Edwards phil@jaj.com Phil Nelson phil@cs.wwu.edu Philip Fong pwlfong@users.sourceforge.net Philip S Tellis philip@ncst.ernet.in Philipp A. Hartmann philipp.hartmann@offis.de Пухальский Юрий Андреевич pooh@cryptopro.ru Quentin Glidic sardemff7+gnu@sardemff7.net Rainer Orth ro@techfak.uni-bielefeld.de Rafael Laboissiere laboissiere@psy.mpg.de Rainer Tammer tammer@tammer.net Raja R Harinath harinath@cs.umn.edu Ralf Corsepius ralf.corsepius@gmail.com Ralf Menzel menzel@ls6.cs.uni-dortmund.de Ralf Wildenhues Ralf.Wildenhues@gmx.de Ralph Schleicher rs@purple.UL.BaWue.DE Ramón García Fernández ramon@jl1.quim.ucm.es Reuben Thomas rrt@sc3d.org Rich Wales richw@webcom.com Richard Boulton richard@tartarus.org Richard Dawe rich@phekda.freeserve.co.uk Richard W.M. Jones rjones@redhat.com Rob Savoye rob@cygnus.com Robert Bihlmeyer robbe@orcus.priv.at Robert Boehne rboehne@ricardo-us.com Robert Collins robert.collins@itdomain.com.au Robert Swafford robert.swafford@l-3com.com Roberto Bagnara bagnara@cs.unipr.it Roman Fietze roman.fietze@telemotive.de Ronald Copley ronald.copley@gmail.com Ronald Landheer ronald@landheer.com Roumen Petrov bugtrack@roumenpetrov.info Russ Allbery rra@stanford.edu Rusty Ballinger rusty@rlyeh.engr.sgi.com Ryan Lortie desrt@desrt.ca Ryan T. Sammartino ryants@shaw.ca Sam Hocevar sam@zoy.org Sam Sirlin sam@kalessin.jpl.nasa.gov Sam Steingold sds@gnu.org Sander Niemeijer niemeijer@science-and-technology.nl Santiago Vila sanvila@unex.es Scott James Remnant scott@netsplit.com Sébastien Wilmet swilmet@gnome.org Sergey Poznyakoff gray@gnu.org.ua Sergey Vlasov vsu@mivlgu.murom.ru Seth Alves alves@hungry.com Shannon L. Brown slbrow@sandia.gov Shuhei Amakawa sa264@cam.ac.uk Shigio Yamaguchi shigio@tamacom.com Simon Josefsson jas@extundo.com Simon Richter sjr@debian.org Stefan Nordhausen nordhaus@informatik.hu-berlin.de Stefano Lattarini stefano.lattarini@gmail.com Stepan Kasal kasal@math.cas.cz Steve M. Robbins steve@nyongwa.montreal.qc.ca Steve Goetze goetze@dovetail.com Steven Drake sbd@NetBSD.org Steven G. Johnson stevenj@alum.mit.edu Sven Verdoolaege skimo@kotnet.org Tamara L. Dahlgren dahlgren1@llnl.gov Tatu Ylonen ylo@ssh.fi Teun Burgers burgers@ecn.nl The Crimson Binome steve@nyongwa.montreal.qc.ca Theodoros V. Kalamatianos thkala@gmail.com Thien-Thi Nguyen ttn@glug.org Thomas Fitzsimmons fitzsim@redhat.com Thomas Gagne tgagne@ix.netcom.com Thomas Jahns jahns@dkrz.de Thomas Klausner tk@giga.or.at Thomas Morgan tmorgan@pobox.com Thomas Schwinge tschwinge@gnu.org Thomas Tanner tanner@ffii.org Toralf Förster toralf.foerster@gmx.de Tim Goodwin tjg@star.le.ac.uk Tim Landscheidt tim@tim-landscheidt.de Tim Mooney mooney@dogbert.cc.ndsu.NoDak.edu Tim Retout diocles@debian.org Tim Rice tim@multitalents.net Tim Van Holder tim.van.holder@pandora.be Tobias Hansen thansen@debian.org Toshio Kuratomi toshio@tiki-lounge.com Tom Epperly tepperly@llnl.gov Tom Rini tom_rini@mentor.com Ulrich Drepper drepper@gnu.ai.mit.edu Ulrich Eckhardt eckhardt@satorlaser.com Václav Haisman V.Haisman@sh.cvut.cz Václav Zeman vhaisman@gmail.com Vadim Zeitlin Vadim.zeitlin@dptmaths.ens-cachan.fr Vasyl Khalak basiliomail@gmail.com Vincent Lefevre vincent@vinc17.org Vladimir Serbinenko phcoder@gmail.com Volker Boerchers vboerchers@tecon.de Weiller Ronfini weillerronfini@yahoo.com.br Werner John john@oswf.de Werner Koch wk@isil.d.shuttle.de Werner Lemberg wl@gnu.org William Pursell bill.pursell@gmail.com William S Fulton wsf@fultondesigns.co.uk Yann Droneaud ydroneaud@meuh.eu.org Younes Younes younes@cs.tu-berlin.de Zack Weinberg zackw@panix.com Zbigniew Jędrzejewski-Szmek zbyszek@in.waw.pl Zoltan Rado z.rado@chello.hu ;; Local Variables: ;; mode: text ;; coding: utf-8 ;; End: amhello-1.0.tar.gz000064400000242515152531507370007631 0ustar00ӝZ[{wHϿѧ!l csbtV :$64|_ &r4u'Gof={]'n:;hvYm q* )! ex~K?c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t CZua ?IhtVd)ŭgBWUv25*%Nww;f931Ba\/mA{"v"7j>c4de $!V +l)*3%3} 2DV-HlBZ jvBKc!D^Q|D (aҒ'z #Yƍ"g[k)'gHZ zћ([;#+ș^~qmBAu?JcAD:F9_ ej[!§򴑌)Ɔ~ 0>?s~)>XҦ0õ57ZR {p>Zzp r3=EL7~>x~dKjc,S-^]Q}\K͵7P'Ӗ V2۵#nۛD=̝'/*7N7 \(_2 д@fAr=_.[;k{5=J S4ϗ `L AP]5wBh\Tϳ|_0~䆛._HN.v\hO {lȖNД5mE&Xכ,bN^BHaFu:acƨ NrxR/`/i^~ K&Zьg3z/Sr^WKn*ךc7b2GPR;s>c)9v?O41V!X-vrdeJ}s3M 8ՊS'ƶ"2e tJUxoֻW|-E31{p#1K`3Ibt,_^s)FS.+]1EKac˛޹Ţr\J}&uZR,|M'%/#ح: n\3aP(ZlnkBV9UVg'XspǫY^p g K­ K K./S0np競m-S)F-pxIw9yOWu89cvPi*fs=՚_g*N`(x䪵 w[qyYx|)3)6,Nj30x_+> 7|jF3LStF7 )5k)xd¨ُ 3 wLJZ)q'I+`if#k 57Ԩi>liV ˽;\Ħaiv،廬XTݽΫӰz?(vc=*e֗. p *@\DclX'IZ]?#\uqhAs}Aɤy\0_2iunp 8K/|^W8 C@z#俴R /C5`M*AV Ȁ?-x/)0g[̀2W›^K翥j]m2m:u%UX܉9IMRY7ԉ2 睺:fXAi&N&L'L+wdj;4ʰdwj(:B? E|NF0" e- H!5yʧQ>XI`NOm{MSW9=~a:Ax wB A^Y˞]~Sg5PǼfY}~N8^ <zmg}h'îfd\!\{pb]b=i7v  :iE=`O,\Y=u2zIuA%{+~{{_ys@NOſQO؏1ZKF=@QccED//đsO_n\a}0旹0c%ߨ=jpu _nwnwnwno?'README.multilib000064400000000543152531507370007256 0ustar00Minimal support for multilib builds. For a little more information, see: The master (and probably more up-to-date) copies of the 'config-ml.in' and 'symlink-tree' files are maintained in the GCC development tree at . The same is probably true also for the 'multi.m4' file. README000064400000005234152531507370005440 0ustar00This is Automake, a Makefile generator. It aims to be portable and to conform to the GNU Coding Standards for Makefile variables and targets. See the INSTALL file for detailed information about how to configure and install Automake. Automake is a Perl script. The input files are called Makefile.am. The output files are called Makefile.in; they are intended for use with Autoconf. Automake requires certain things to be done in your configure.ac. Automake comes with extensive documentation; please refer to it for more details about its purpose, features, and usage patterns. This package also includes the "aclocal" program, whose purpose is to generate an 'aclocal.m4' based on the contents of 'configure.ac'. It is useful as an extensible, maintainable mechanism for augmenting autoconf. It is intended that other package authors will write m4 macros which can be automatically used by aclocal. The documentation for aclocal is currently found in the Automake manual. Automake has a test suite. Use "make check" to run it. For more information, see the file t/README. Automake has a page on the web. See: https://www.gnu.org/software/automake/ Automake also has three mailing lists: * automake@gnu.org For general discussions of Automake and its interactions with other configuration/portability tools like Autoconf or Libtool. * bug-automake@gnu.org Where to send bug reports and feature requests. * automake-patches@gnu.org Where to send patches, and discuss the automake development process and the design of new features. To obtain more information about these list, or to subscribe to them, refer to New releases are announced to autotools-announce@gnu.org. If you want to be informed, subscribe to that list by following the instructions at . For any copyright year range specified as YYYY-ZZZZ in this package, that the range specifies every single year in that closed interval. ----- Copyright (C) 1994-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 . README.aclocal000064400000000560152531507370007032 0ustar00This directory is where .m4 files providing third-party autoconf macros can be placed to be automatically found by the aclocal(1) program. The .m4 files placed here could be shared among different versions of aclocal, so be careful. Even if no actual .m4 files are present, this directory is required in order for aclocal to work properly. Please do not remove it. NEWS000064400000372527152531507370005273 0ustar00* WARNING: Future backward-incompatibilities! - Makefile recipes generated by Automake 2.0 will expect to use an 'rm' program that doesn't complain when called without any non-option argument if the '-f' option is given (so that commands like "rm -f" and "rm -rf" will act as a no-op, instead of raising usage errors). This behavior of 'rm' is very widespread in the wild, and it will be required in the next POSIX version: Accordingly, AM_INIT_AUTOMAKE now expands some shell code that checks that the default 'rm' program in PATH satisfies this requirement, aborting the configure process if this is not the case. For the moment, it's still possible to force the configuration process to succeed even with a broken 'rm', that that will no longer be the case for Automake 2.0. - Automake 2.0 will require Autoconf 2.70 or later (which is still unreleased at the moment of writing, but is planned to be released before Automake 2.0 is). - Automake 2.0 will drop support for the long-deprecated 'configure.in' name for the Autoconf input file. You are advised to start using the recommended name 'configure.ac' instead, ASAP. - The ACLOCAL_AMFLAGS special make variable will be fully deprecated in Automake 2.0: it will raise warnings in the "obsolete" category (but still no hard error of course, for compatibilities with the many, many packages that still relies on that variable). You are advised to start relying on the new Automake support for AC_CONFIG_MACRO_DIRS instead (which was introduced in Automake 1.13). - Automake 2.0 will remove support for automatic dependency tracking with the SGI C/C++ compilers on IRIX. The SGI depmode has been reported broken "in the wild" already, and we don't think investing time in debugging and fixing is worthwhile, especially considering that SGI has last updated those compilers in 2006, and retired support for them in December 2013: - Automake 2.0 will remove support for MS-DOS and Windows 95/98/ME (support for them was offered by relying on the DJGPP project). Note however that both Cygwin and MSYS/MinGW on modern Windows versions will continue to be fully supported. - Automake-provided scripts and makefile recipes might (finally!) start assuming a POSIX shell in Automake 2.0. There still is no certainty about this though: we'd first like to wait and see whether future Autoconf versions will be enhanced to guarantee that such a shell is always found and provided by the checks in ./configure. - Starting from Automake 2.0, third-party m4 files located in the system-wide aclocal directory, as well as in any directory listed in the ACLOCAL_PATH environment variable, will take precedence over "built-in" Automake macros. For example (assuming Automake is installed in the /usr/local hierarchy), a definition of the AM_PROG_VALAC macro found in '/usr/local/share/aclocal/my-vala.m4' should take precedence over the same-named automake-provided macro (defined in '/usr/local/share/aclocal-2.0/vala.m4'). ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ New in 1.16.1: * Bugs fixed: - 'install-sh' now ensures that nobody can cross privilege boundaries by pre-creating symlink on the directory inside "/tmp". - 'automake' does not depend on the 'none' subroutine of the List::Util module anymore to support older Perl version. (automake bug#30631) - A regression in AM_PYTHON_PATH causing the rejection of non literal minimum version parameter hasn't been fixed. (automake bug#30616) ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ New in 1.16: * Miscellaneous changes - When subdir-objects is in effect, Automake will now construct shorter object file names when no programs and libraries name clashes are encountered. This should make the discouraged use of 'foo_SHORTNAME' unnecessary in many cases. * Bugs fixed: - Automatic dependency tracking has been fixed to work also when the 'subdir-object' option is used and some 'foo_SOURCES' definition contains unexpanded references to make variables, as in, e.g.: a_src = sources/libs/aaa b_src = sources/bbb foo_SOURCES = $(a_src)/bar.c $(b_src)/baz.c With such a setup, the created makefile fragment containing dependency tracking information will be correctly placed under the directories named 'sources/libs/aaa/.deps' and 'sources/bbb/.deps', rather than mistakenly under directories named (literally!) '$(src_a)/.deps' and '$(src_b)/.deps' (this was the first part of automake bug#13928). Notice that in order to fix this bug we had to slightly change the semantics of how config.status bootstraps the makefile fragments required for the dependency tracking to work: rather than attempting to parse the Makefiles via grep and sed trickeries only, we actually invoke 'make' on a slightly preprocessed version of those Makefiles, using a private target that is only meant to bootstrap the required makefile fragments. - The 'subdir-object' option no longer causes object files corresponding to source files specified with an explicit '$(srcdir)' component to be placed in the source tree rather than in the build tree. For example, if Makefile.am contains: AUTOMAKE_OPTIONS = subdir-objects foo_SOURCES = $(srcdir)/foo.c $(srcdir)/s/bar.c $(top_srcdir)/baz.c then "make all" will create 'foo.o' and 's/bar.o' in $(builddir) rather than in $(srcdir), and will create 'baz.o' in $(top_builddir) rather than in $(top_srcdir). This was the second part of automake bug#13928. - Installed 'aclocal' m4 macros can now accept installation directories containing '@' characters (automake bug#20903) - "./configure && make dist" no longer fails when a distributed file depends on one from BUILT_SOURCES. - When combining AC_LIBOBJ or AC_FUNC_ALLOCA with the "--disable-dependency-tracking" configure option in an out of source build, the build sub-directory defined by AC_CONFIG_LIBOBJ_DIR is now properly created. (automake bug#27781) - The time printed by 'mdate-sh' is now using the UTC time zone to support the reproducible build effort. (automake bug#20314) - The elisp byte-compilation rule now uses byte-compile-dest-file-function, rather than byte-compile-dest-file, which was obsoleted in 2009. We expect that Emacs-26 will continue to support the old function, but will complain loudly, and that Emacs-27 will remove support for it altogether. * New features added - A custom testsuite driver for the Guile Scheme SRFI-64 API has been added to the "contrib" section. This allows a more convenient way to test Guile code without having to use low primitives such as exit status. See SRFI-64 API specification for more details: ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ New in 1.15.1: * Bugs fixed: - The code has been adapted to remove a warning present since Perl 5.22 stating that "Unescaped left brace in regex is deprecated". This warning has become an hard error in Perl 5.26 (bug#22372). - The generated Makefiles do not rely on the obsolescent GZIP environment variable which was used for passing arguments to 'gzip'. Compatibility with old versions has been preserved. (bug#20132) * Miscellaneous changes: - Support the Windows version of the Intel C Compiler (icl) in the 'compile' script in the same way the (compatible) Microsoft C Compiler is supported. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ New in 1.15: * Improvements and refactorings in the install-sh script: - It has been modernized, and now makes the following assumptions *unconditionally*: (1) a working 'dirname' program is available; (2) the ${var:-value} shell parameters substitution works; (3) the "set -f" and "set +f" shell commands work, and, respectively, disable and enable shell globbing. - The script implements stricter error checking, and now it complains and bails out if any of the following expectations is not met: (1) the options -d and -t are never used together; (2) the argument passed to option -t is a directory; (3) if there are two or more SOURCEFILE arguments, the DESTINATION argument must be a directory. * Automake-generated testsuites: - The default test-driver used by the Automake-generated testsuites now appends the result and exit status of each "plain" test to the associated log file (automake bug#11814). - The perl implementation of the TAP testsuite driver is no longer installed in the Automake's scripts directory, and is instead just distributed as a "contrib" addition. There should be no reason to use this implementation anyway in real packages, since the awk+shell implementation of the TAP driver (which is documented in the manual) is more portable and has feature parity with the perl implementation. - The rule generating 'test-suite.log' no longer risk incurring in an extra useless "make all" recursive invocation in some corner cases (automake bug#16302). * Distribution: - Automake bug#18286: "make distcheck" could sometimes fail to detect files missing from the distribution tarball, especially in those cases where both the generated files and their dependencies are explicitly in $(srcdir). An important example of this are *generated* makefile fragments included at Automake time in Makefile.am; e.g.: ... $(srcdir)/fragment.am: $(srcdir)/data.txt $(srcdir)/preproc.sh cd $(srcdir) && $(SHELL) preproc.sh fragment.am include $(srcdir)/fragment.am ... If the use forgot to add data.txt and/or preproc.sh in the distribution tarball, "make distcheck" would have erroneously succeeded! This issue is now fixed. - As a consequence of the previous change, "make distcheck" will run using '$(distdir)/_build/sub' as the build directory, rather than simply '$(distdir)/_build' (as it was the case for Automake 1.14 and earlier). Consequently, the './configure' and 'make' invocations issued by the distcheck recipe now have $(srcdir) equal to '../..', rather than to just '..'. Dependent and similar variables (e.g., '$(top_srcdir)') are also changed accordingly. Thus, Makefiles that made assumptions about the exact values of the build and source directories used by "make distcheck" will have to be adjusted. Notice that making such assumptions was a bad and unsupported practice anyway, since the exact locations of those directories should be considered implementation details, and we reserve the right to change them at any time. * Miscellaneous bugs fixed: - The expansion of AM_INIT_AUTOMAKE ends once again with a trailing newline (bug#16841). Regression introduced in Automake 1.14. - We no longer risk to use '$ac_aux_dir' before it's defined (see automake bug#15981). Bug introduced in Automake 1.14. - The code used to detect whether the currently used make is GNU make or not (relying on the private macro 'am__is_gnu_make') no longer risks causing "Arg list too long" for projects using automatic dependency tracking and having a ton of source files (bug#18744). - Automake tries to offer a more deterministic output for generated Makefiles, in the face of the newly-introduced randomization for hash keys order in Perl 5.18. - In older Automake versions, if a user defined one single Makefile fragment (say 'foo.am') to be included via Automake includes in his main Makefile.am, and defined a custom make rule to generate that file from other data, Automake used to spuriously complain with some message like "... overrides Automake target '$(srcdir)/foo.am". This bug is now fixed. - The user can now extend the special .PRECIOUS target, the same way he could already do with the .MAKE .and .PHONY targets. - Some confusing typos have been fixed in the manual and in few warning messages (automake bug#16827 and bug#16997). ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ New in 1.14.1: * Bugs fixed: - The user is no longer allowed to override the --srcdir nor the --prefix configure options used by "make distcheck" (bug#14991). - Fixed a gross inefficiency in the recipes for installing byte-compiled python files, that was causing an O(N^2) performance on the number N of files, instead of the expected O(N) performance. Note that this bug was only relevant when the number of python files was high (which is unusual in practice). - Automake try to offer a more deterministic output for warning messages, in the face of the newly-introduced randomization for hash keys order in Perl 5.18. - The 'test-driver' script now actually error out with a clear error message on the most common invalid usages. - Several spurious failures/hangs in the testsuite (bugs #14706, #14707, #14760, #14911, #15181, #15237). * Documentation fixes: - Fixed typos in the 'fix-timestamp.sh' example script that made it nonsensical. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ New in 1.14: * C compilation, and the AC_PROG_CC and AM_PROG_CC_C_O macros: - The 'compile' script is now unconditionally required for all packages that perform C compilation (if you are using the '--add-missing' option, automake will fetch that script for you, so you shouldn't need any explicit adjustment). This new behaviour is needed to avoid obscure errors when the 'subdir-objects' option is used, and the compiler is an inferior one that doesn't grasp the combined use of both the "-c -o" options; see discussion about automake bug#13378 for more details: - The next major Automake version (2.0) will unconditionally activate the 'subdir-objects' option. In order to smooth out the transition, we now give a warning (in the category 'unsupported') whenever a source file is present in a subdirectory but the 'subdir-object' is not enabled. For example, the following usage will trigger such a warning: bin_PROGRAMS = sub/foo sub_foo_SOURCES = sub/main.c sub/bar.c - Automake will automatically enhance the autoconf-provided macro AC_PROG_CC to force it to check, at configure time, that the C compiler supports the combined use of both the '-c' and '-o' options. The result of this check is saved in the cache variable 'am_cv_prog_cc_c_o', and said result can be overridden by pre-defining that variable. - The AM_PROG_CC_C_O macro can still be called, albeit that should no longer be necessary. This macro is now just a thin wrapper around the Automake-enhanced AC_PROG_CC. This means, among the other things, that its behaviour is changed in three ways: 1. It no longer invokes the Autoconf-provided AC_PROG_CC_C_O macro behind the scenes. 2. It caches the check result in the 'am_cv_prog_cc_c_o' variable, and not in a 'ac_cv_prog_cc_*_c_o' variable whose exact name is dynamically computed only at configure runtime (really!) from the content of the '$CC' variable. 3. It no longer automatically AC_DEFINE the C preprocessor symbol 'NO_MINUS_C_MINUS_O'. * Texinfo support: - Automake can now be instructed to place '.info' files generated from Texinfo input in the builddir rather than in the srcdir; this is done specifying the new automake option 'info-in-builddir'. This feature was requested by the developers of GCC, GDB, GNU binutils and the GNU bfd library. See the extensive discussion about automake bug#11034 for more details. - For quite a long time, Automake has been implementing an undocumented hack which ensured that '.info' files which appeared to be cleaned (by being listed in the CLEANFILES or DISTCLEANFILES variables) were built in the builddir rather than in the srcdir; this hack was introduced to ensure better backward-compatibility with package such as Texinfo, which do things like: info_TEXINFOS = texinfo.txi info-stnd.texi info.texi DISTCLEANFILES = texinfo texinfo-* info*.info* # Do not create info files for distribution. dist-info: @: in order not to distribute generated '.info' files. Now that we have the 'info-in-builddir' option that explicitly causes generated '.info' files to be placed in the builddir, this hack should be longer necessary, so we deprecate it with runtime warnings. It will be removed altogether in Automake 2.0. * Relative directory in Makefile fragments: - The special Automake-time substitutions '%reldir%' and '%canon_reldir%' (and their short versions, '%D%' and '%C%' respectively) can now be used in an included Makefile fragment. The former is substituted with the relative directory of the included fragment (compared to the top-level including Makefile), and the latter with the canonicalized version of the same relative directory. # in 'Makefile.am': bin_PROGRAMS = # will be updated by included Makefile fragments include src/Makefile.inc # in 'src/Makefile.inc': bin_PROGRAMS += %reldir%/foo %canon_reldir%_foo_SOURCES = %reldir%/bar.c This should be especially useful for packages using a non-recursive build system. * Deprecated distribution formats: - The 'shar' and 'compress' distribution formats are deprecated, and scheduled for removal in Automake 2.0. Accordingly, the use of the 'dist-shar' and 'dist-tarZ' will cause warnings at automake runtime (in the 'obsolete' category), and the recipes of the Automake-generated targets 'dist-shar' and 'dist-tarZ' will unconditionally display (non-fatal) warnings at make runtime. * New configure runtime warnings about "rm -f" support: - To simplify transition to Automake 2.0, the shell code expanded by AM_INIT_AUTOMAKE now checks (at configure runtime) that the default 'rm' program in PATH doesn't complain when called without any non-option argument if the '-f' option is given (so that commands like "rm -f" and "rm -rf" act as a no-op, instead of raising usage errors). If this is not the case, the configure script is aborted, to call the attention of the user on the issue, and invite him to fix his PATH. The checked 'rm' behavior is very widespread in the wild, and will be required by future POSIX versions: The user can still force the configure process to complete even in the presence of a broken 'rm' by defining the ACCEPT_INFERIOR_RM_PROGRAM environment variable to "yes". And the generated Makefiles should still work correctly even when such broken 'rm' is used. But note that this will no longer be the case with Automake 2.0 though, so, if you encounter the warning, please report it to us ASAP (and try to fix your environment as well). ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ New in 1.13.4: * Bugs fixed: - Fix a minor regression introduced in Automake 1.13.3: when two or more user-defined suffix rules were present in a single Makefile.am, automake would needlessly include definition of some make variables related to C compilation in the generated Makefile.in (bug#14560). ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ New in 1.13.3: * Documentation fixes: - The documentation no longer mistakenly reports that the obsolete 'AM_MKDIR_PROG_P' macro and '$(mkdir_p)' make variable are going to be removed in Automake 2.0. * Bugs fixed: - Byte-compilation of Emacs lisp files could fail spuriously on Solaris, when /bin/ksh or /usr/xpg4/bin/sh were used as shell. - If the same user-defined suffixes were transformed into different Automake-known suffixes in different Makefile.am files in the same project, automake could get confused and generate inconsistent Makefiles (automake bug#14441). For example, if 'Makefile.am' contained a ".ext.cc:" suffix rule, and 'sub/Makefile.am' contained a ".ext.c:" suffix rule, automake would have mistakenly placed into 'Makefile.in' rules to compile "*.c" files into object files, and into 'sub/Makefile.in' rules to compile "*.cc" files into object files --- rather than the other way around. This is now fixed. * Testsuite work: - The test cases no longer have the executable bit set. This should make it clear that they are not meant to be run directly; as explained in t/README, they can only be run through the custom 'runtest' script, or by a "make check" invocation. - The testsuite has seen the introduction of a new helper function 'run_make', and several related changes. These serve a two-fold purpose: 1. Remove brittleness due to the use of "make -e" in test cases. 2. Seamlessly allow the use of parallel make ("make -j...") in the test cases, even where redirection of make output is involved (see automake bug#11413 for a description of the subtle issues in this area). - Several spurious failures have been fixed (they hit especially MinGW/MSYS builds). See automake bugs #14493, #14494, #14495, #14498, #14499, #14500, #14501, #14517 and #14528. - Some other minor miscellaneous changes and fixlets. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ New in 1.13.2: * Documentation fixes: - The long-deprecated but still supported two-arguments invocation form of AM_INIT_AUTOMAKE is documented once again. This seems the sanest thing to do, given that support for such usage might need to remain in place for an unspecified amount of time in order to cater to people who want to define the version number for their package dynamically at configure runtime (unfortunately, Autoconf does not yet support this scenario, so we cannot delegate the work to it). - The serial testsuite harness is no longer reported as "deprecated", but as "discouraged". We have no plan to remove it, nor to make its use cause runtime warnings. - The parallel testsuite is no longer reported as "experimental"; it is well tested, and should be stable now. - The 'shar' and 'tarZ' distribution formats and the 'dist-shar' and 'dist-tarZ' options are obsolescent, and their use is deprecated in the documentation. - Other minor miscellaneous fixes and improvements; in particular, some improvements in cross-references. * Obsolescent features: - Use of suffix-less info files (that can be specified through the '@setfilename' macro in Texinfo input files) is discouraged, and its use will raise warnings in the 'obsolete' category. Simply use the '.info' extension for all your info files, transforming usages like: @setfilename myprogram into: @setfilename myprogram.info - Use of Texinfo input files with '.txi' or '.texinfo' extensions is discouraged, and its use will raise warnings in the 'obsolete' category. You are advised to simply use the '.texi' extension instead. * Bugs fixed: - When the 'ustar' option is used, the generated configure script no longer risks hanging during the tests for the availability of the 'pax' utility, even if the user running configure has a UID or GID that requires more than 21 bits to be represented. See automake bug#8343 and bug#13588. - The obsolete macros AM_CONFIG_HEADER or AM_PROG_CC_STDC work once again, as they did in Automake 1.12.x (albeit printing runtime warnings in the 'obsolete' category). Removing them has turned out to be a very bad idea, because it complicated distro packing enormously. Making them issue fatal warnings, as we did in Automake 1.13, has turned out to be a similarly very bad idea, for exactly the same reason. - aclocal will no longer error out if the first local m4 directory (as specified by the '-I' option or the 'AC_CONFIG_MACRO_DIRS' or 'AC_CONFIG_MACRO_DIR' macros) doesn't exist; it will merely report a warning in the 'unsupported' category. This is done to support some pre-existing real-world usages. See automake bug#13514. - aclocal will no longer consider directories for extra m4 files more than once, even if they are specified multiple times. This ensures packages that specify both AC_CONFIG_MACRO_DIR([m4]) in configure.ac ACLOCAL_AMFLAGS = -I m4 in Makefile.am will work correctly, even when the 'm4' directory contains no package-specific files, but is used only to install third-party m4 files (as can happen with e.g., "libtoolize --install"). See automake bug#13514. - Analysis of make flags in Automake-generated rules has been made more robust, and more future-proof. For example, in presence of make that (like '-I') take an argument, the characters in said argument will no longer be spuriously considered as a set of additional make options. In particular, automake-generated rules will no longer spuriously believe to be running in dry mode ("make -n") if run with an invocation like "make -I noob"; nor will they believe to be running in keep-going mode ("make -k") if run with an invocation like "make -I kool" (automake bug#12554). ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ New in 1.13.1: * Bugs fixed: - Use of the obsolete macros AM_CONFIG_HEADER or AM_PROG_CC_STDC now causes a clear and helpful error message, instead of obscure ones (issue introduced in Automake 1.13). ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ New in 1.13: * Bugs fixed: - ylwrap renames properly header guards in generated header files (*.h), instead of leaving Y_TAB_H. - ylwrap now also converts header guards in implementation files (*.c). Because ylwrap failed to rename properly #include in the implementation files, current versions of Bison (e.g., 2.7) duplicate the generated header file in the implementation file. The header guard then protects the implementation file from duplicate definitions from the header file. * Version requirements: - Autoconf 2.65 or greater is now required. - The rules to build PDF and DVI output from Texinfo input now require Texinfo 4.9 or later. * Obsolete features: - Support for the "Cygnus-style" trees (once enabled by the 'cygnus' option) has been removed. See discussion about automake bug#11034 for more background: . - The deprecated aclocal option '--acdir' has been removed. You should use the options '--automake-acdir' and '--system-acdir' instead (which have been introduced in Automake 1.11.2). - The following long-obsolete m4 macros have been removed: AM_PROG_CC_STDC: superseded by AC_PROG_CC since October 2002 fp_PROG_CC_STDC: broken alias for AM_PROG_CC_STDC fp_WITH_DMALLOC: old alias for AM_WITH_DMALLOC AM_CONFIG_HEADER: superseded by AC_CONFIG_HEADERS since July 2002 ud_PATH_LISPDIR: old alias for AM_PATH_LISPDIR jm_MAINTAINER_MODE: old alias for AM_MAINTAINER_MODE ud_GNU_GETTEXT: old alias for AM_GNU_GETTEXT gm_PROG_LIBTOOL: old alias for AC_PROG_LIBTOOL fp_C_PROTOTYPES: old alias for AM_C_PROTOTYPES (which was part of the now-removed automatic de-ANSI-fication support of Automake) - All the "old alias" macros in 'm4/obsolete.m4' have been removed. - Use of the long-deprecated two- and three-arguments invocation forms of the AM_INIT_AUTOMAKE is no longer documented. It's still supported though (albeit with a warning in the 'obsolete' category), to cater for people who want to define the version number for their package dynamically (e.g., from the current VCS revision). We'll have to continue this support until Autoconf itself is fixed to allow better support for such dynamic version numbers. * Elisp byte-compilation: - The byte compilation of '.el' files into '.elc' files is now done with a suffix rule. This has simplified the compilation process, and more importantly made it less brittle. The downside is that emacs is now invoked once for each '.el' files, which cause some noticeable slowdowns. These should however be mitigated on multicore machines (which are becoming the norm today) if concurrent make ("make -j") is used. - Elisp files placed in a subdirectory are now byte-compiled to '.elc' files in the same subdirectory; for example, byte-compiling of file 'sub/foo.el' file will result in 'sub/foo.elc' rather than in 'foo.elc'. This behaviour is backward-incompatible with older Automake versions, but it is more natural and more sane. See also automake bug#7441. - The Emacs invocation performing byte-compilation of '.el' files honors the $(AM_ELCFLAGS) and $(ELCFLAGS) variables; as typical, the former one is developer-reserved and the latter one user-reserved. - The 'elisp-comp' script, once provided by Automake, has been rendered obsoleted by the just-described changes, and thus removed. * Changes to Automake-generated testsuite harnesses: - The parallel testsuite harness (previously only enabled by the 'parallel-tests' option) is the default one; the older serial testsuite harness will still be available through the use of the 'serial-tests' option (introduced in Automake 1.12). - The 'color-tests' option is now unconditionally activated by default. In particular, this means that testsuite output is now colorized by default if the attached terminal seems to support ANSI escapes, and that the user can force output colorization by setting the variable AM_COLOR_TESTS to "always". The 'color-tests' is still recognized for backward-compatibility, although it's a handled as a no-op now. * Silent rules support: - Support for silent rules is now always active in Automake-generated Makefiles. So, although the verbose output is still the default, the user can now always use "./configure --enable-silent-rules" or "make V=0" to enable quieter output in the package he's building. - The 'silent-rules' option has now become a no-op, preserved for backward-compatibility only. In particular, its use no longer disables the warnings in the 'portability-recursive' category. * Texinfo Support: - The rules to build PDF and DVI files from Texinfo input now require Texinfo 4.9 or later. - The rules to build PDF and DVI files from Texinfo input now use the '--build-dir' option, to keep the auxiliary files used by texi2dvi and texi2pdf around without cluttering the build directory, and to make it possible to run the "dvi" and "pdf" recipes in parallel. * Automatic remake rules and 'missing' script: - The 'missing' script no longer tries to update the timestamp of out-of-date files that require a maintainer-specific tool to be remade, in case the user lacks such a tool (or has a too-old version of it). It just gives a useful warning, and in some cases also a tip about how to obtain such a tool. - The missing script has thus become useless as a (poor) way to work around the sketched-timestamps issues that can happen for projects that keep generated files committed in their VCS repository. Such projects are now encouraged to write a custom "fix-timestamps.sh" script to avoid such issues; a simple example is provided in the "CVS and generated files" chapter of the automake manual. * Recursive targets: - The user can now define his own recursive targets that recurse in the directories specified in $(SUBDIRS). This can be done by specifying the name of such targets in invocations of the new 'AM_EXTRA_RECURSIVE_TARGETS' m4 macro. * Tags: - Any failure in the recipe of the "tags", "ctags", "cscope" or "cscopelist" targets in a subdirectory is now propagated to the top-level make invocation. - Tags are correctly computed also for files in _SOURCES variables that only list files with non-standard suffixes (see automake bug#12372). * Improvements to aclocal and related rebuilds rules: - Autoconf-provided macros AC_CONFIG_MACRO_DIR and AC_CONFIG_MACRO_DIRS are now traced by aclocal, and can be used to declare the local m4 include directories. Formerly, one had to specify it with an explicit '-I' option to the 'aclocal' invocation. - The special make variable ACLOCAL_AMFLAGS is deprecated; future Automake versions will warn about its use, and later version will remove support for it altogether. * The depcomp script: - Dropped support for libtool 1.4. - Various internal refactorings. They should cause no visible change, but the chance for regression is there anyway, so please report any unexpected or suspicious behaviour. - Support for pre-8.0 versions of the Intel C Compiler has been dropped. This should cause no problem, since icc 8.0 has been released in December 2003 -- almost nine years ago. - Support for tcc (the Tiny C Compiler) has been improved, and is now handled through a dedicated 'tcc' mode. * The ylwrap script: - ylwrap generates header guards with a single '_' for series of non alphabetic characters, instead of several. This is what Bison >= 2.5.1 does. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Bugs fixed in 1.12.6: * Python-related bugs: - The default installation location for python modules has been improved for Python 3 on Debian and Ubuntu systems, changing from: ${prefix}/lib/python3/dist-packages to ${prefix}/lib/python3.x/site-packages This change should ensure modules installed using the default ${prefix} "/usr/local" are found by default by system python 3.x installations. See automake bug#10227. - Python byte-compilation supports the new layout mandated by PEP-3147, with its __pycache__ directory (automake bug#8847). * Build system issues: - The maintainer rebuild rules for Makefiles and aclocal.m4 in Automake's own build system works correctly again (bug introduced in Automake 1.12.5). * Testsuite issues: - The Vala-related tests has been changed to adjust to the removal of the 'posix' profile in the valac compiler. See automake bug#12934 a.k.a. bug#12522. - Some spurious testsuite failures related to older tools and systems have been fixed. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ New in 1.12.5: * Vala support: - The AM_PROG_VALAC macro has been enhanced to takes two further optional arguments; it's signature now being AM_PROG_VALAC([MINIMUM-VERSION], [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND]) - By default, AM_PROG_VALAC no longer aborts the configure invocation if the Vala compiler found is too old, but simply prints a warning messages (as it did when the Vala compiler was not found). This should avoid unnecessary difficulties for end users that just want to compile the unmodified, distributed Vala-generated C sources, but happens to have an old Vala compiler in their PATH. This fixes automake bug#12688. - If no proper Vala compiler is found at configure runtime, AM_PROG_VALAC will set the AC_SUBST'd variable 'VALAC' to 'valac' rather than to ':'. This is a better default, because with it a triggered makefile rule invoking a Vala compilation will clearly fail with an informative error message like "valac: command not found", rather than silently, with the error possibly going unnoticed or triggering harder-to-diagnose fallout failures in later steps. * Miscellaneous changes: - automake and aclocal no longer honours the 'perllibdir' environment variable. That had always been intended only as an hack required in the testsuite, not meant for any use beyond that. Bugs fixed in 1.12.5: * Long-standing bugs: - Automake no longer generates spurious remake rules invoking autoheader to regenerate the template corresponding to header files specified after the first one in AC_CONFIG_HEADERS (automake bug#12495). - When wrapping Microsoft tools, the 'compile' script falls back to finding classic 'libname.a' style libraries when 'name.lib' and 'name.dll.lib' aren't available. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ New in 1.12.4: * Warnings and deprecations: - Warnings in the 'obsolete' category are enabled by default both in automake and aclocal. * Miscellaneous changes: - Some testsuite weaknesses and spurious failures have been fixed. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ New in 1.12.3: * Miscellaneous changes: - The '.m4' files provided by Automake no longer define serial numbers. This should cause no difference in the behaviour of aclocal though. - Some testsuite weaknesses and spurious failures have been fixed. - There is initial support for automatic dependency tracking with the Portland Group C/C++ compilers, thanks to the new new depmode 'pgcc'. Bugs fixed in 1.12.3: * Long-standing bugs: - Instead of renaming only self-references of files (typically for #lines), ylwrap now also renames references to the other generated files. This fixes support for GLR and C++ parsers from Bison (PR automake/491 and automake bug#7648): 'parser.c' now properly #includes 'parser.h' instead of 'y.tab.h'. - Generated files unknown to ylwrap are now preserved. This fixes C++ support for Bison (automake bug#7648): location.hh and the like are no longer discarded. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ New in 1.12.2: * Warnings and deprecations: - Automake now issues a warning (in the 'portability' category) if 'configure.in' is used instead of 'configure.ac' as the Autoconf input file. Such a warning will also be present in the next Autoconf version (2.70). * Cleaning rules: - Recursive cleaning rules descends into the $(SUBDIRS) in the natural order (as done by the other recursive rules), rather than in the inverse order. They used to do that in order to work a round a limitation in an older implementation of the automatic dependency tracking support, but that limitation had been lifted years ago already, when the automatic dependency tracking based on side-effects of compilation had been introduced. - Cleaning rules for compiled objects (both "plain" and libtool) work better when subdir objects are involved, not triggering a distinct 'rm' invocation for each such object. They do so by removing *any* compiled object file that is in the same directory of a subdir object. See automake bug#10697. * Silent rules support: - A new predefined $(AM_V_P) make variable is provided; it expands to a shell conditional that can be used in recipes to know whether make is being run in silent or verbose mode. Bugs fixed in 1.12.2: * SECURITY VULNERABILITIES! - The 'distcheck' recipe no longer grants temporary world-write permissions on the extracted distdir. Even if such rights were only granted for a vanishingly small time window, the implied race condition proved to be enough to allow a local attacker to run arbitrary code with the privileges of the user running "make distcheck". This is CVE-2012-3386. * Long-standing bugs: - The "recheck" targets behaves better in the face of build failures related to previously failed tests. For example, if a test is a compiled program that must be rerun by "make recheck", and its compilation fails, it will still be rerun by further "make recheck" invocations. See automake bug#11791. * Bugs introduced by 1.12.1: - Automake provides once again the '$(mkdir_p)' make variable and the '@mkdir_p@' substitution (both as simple aliases for '$(MKDIR_P)'), for better backward-compatibility. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ New in 1.12.1: * New supported languages: - Support for Objective C++ has been added; it should work similarly to the support for Objective C. * Deprecated obsolescent features: - Use of the long-deprecated two- and three-arguments invocation forms of the AM_INIT_AUTOMAKE macro now elicits a warning in the 'obsolete' category. Starting from some future major Automake release (likely post-1.13), such usages will no longer be allowed. - Support for the "Cygnus-style" trees (enabled by the 'cygnus' option) is now deprecated (its use triggers a warning in the 'obsolete' category). It will be removed in the next major Automake release (1.13). - The long-obsolete (since 1.10) automake-provided $(mkdir_p) make variable, @mkdir_p@ configure-time substitution and AM_PROG_MKDIR m4 macro are deprecated, eliciting a warning in the 'obsolete' category. * Miscellaneous changes: - The Automake test cases now require a proper POSIX-conforming shell. Older non-POSIX Bourne shells (like Solaris 10 /bin/sh) will no longer be accepted. In most cases, the user shouldn't have to specify such POSIX shell explicitly, since it will be looked up at configure time. Still, when this lookup fails, or when the user wants to override its conclusion, the variable 'AM_TEST_RUNNER_SHELL' can be used (pointing to the shell that will be used to run the Automake test cases). Bugs fixed in 1.12.1: * Bugs introduced by 1.12: - Several weaknesses in Automake's own build system and test suite have been fixed. * Bugs introduced by 1.11.3: - When given non-option arguments, aclocal rejects them, instead of silently ignoring them. * Long-standing bugs: - When the 'color-tests' option is in use, forcing of colored testsuite output through "AM_COLOR_TESTS=always" works even if the terminal is a non-ANSI one, i.e., if the TERM environment variable has a value of "dumb". - Several inefficiencies and poor performances in the implementation of the parallel-tests 'check' and 'recheck' targets have been fixed. - The post-processing of output "#line" directives done the ylwrap script is more faithful w.r.t. files in a subdirectory; for example, if the processed file is "src/grammar.y", ylwrap will correctly produce directives like: #line 7 "src/grammar.y" rather than like #line 7 "grammar.y" as it did before. * Bugs with new Perl versions: - Aclocal works correctly with perl 5.16.0 (automake bug#11543). ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ New in 1.12: * Obsolete features removed: - The never documented nor truly used script 'acinstall' has been removed. - Support for automatic de-ANSI-fication has been removed. - The support for the "obscure" multilib feature has been removed from Automake core (but remains available in the 'contrib/' directory of the Automake distribution). - Support for ".log -> .html" conversion and the check-html and recheck-html targets has been removed from Automake core (but remains available in the 'contrib/' directory of the Automake distribution). - The deprecated 'lzma' compression format for distribution archives has been removed, in favor of 'xz' and 'lzip'. - The obsolete AM_WITH_REGEX macro has been removed. - The long-deprecated options '--output-dir', '--Werror' and '--Wno-error' have been removed. - The chapter on the history of Automake has been moved out of the reference manual, into a new dedicated Texinfo file. * New targets: - New 'cscope' target to build a cscope database for the source tree. * Changes to Automake-generated testsuite harnesses: - The new automake option 'serial-tests' has been introduced. It can be used to explicitly instruct automake to use the older serial testsuite harness. This is still the default at the moment, but it might change in future versions. - The 'recheck' target (provided by the parallel testsuite harness) now depends on the 'all' target. This allows for a better user-experience in test-driven development. See automake bug#11252. - Test scripts that exit with status 99 to signal an "hard error" (e.g., and unexpected or internal error, or a failure to set up the test case scenario) have their outcome reported as an 'ERROR' now. Previous versions of automake reported such an outcome as a 'FAIL' (the only difference with normal failures being that hard errors were counted as failures even when the test originating them was listed in XFAIL_TESTS). - The testsuite summary displayed by the parallel-test harness has a completely new format, that always list the numbers of passed, failed, xfailed, xpassed, skipped and errored tests, even when these numbers are zero (but using smart coloring when the color-tests option is in effect). - The default testsuite driver offered by the 'parallel-tests' option is now implemented (partly at least) with the help of automake-provided auxiliary scripts (e.g., 'test-driver'), instead of relying entirely on code in the generated Makefile.in. This has two noteworthy implications. The first one is that projects using the 'parallel-tests' option should now either run automake with the '--add-missing' option, or manually copy the 'test-driver' script into their tree. The second, and more important, implication is that now, when the 'parallel-tests' option is in use, TESTS_ENVIRONMENT can no longer be used to define a test runner, and the command specified in LOG_COMPILER (and _LOG_COMPILER) must be a *real* executable program or script. For example, this is still a valid usage (albeit a little contorted): TESTS_ENVIRONMENT = \ if test -n '$(STRICT_TESTS)'; then \ maybe_errexit='-e'; \ else \ maybe_errexit=''; \ fi; LOG_COMPILER = $(SHELL) $$maybe_errexit OTOH, this is no longer a valid usage: TESTS_ENVIRONMENT = \ $(SHELL) `test -n '$(STRICT_TESTS_CHECKING)' && echo ' -e'` neither is this: TESTS_ENVIRONMENT = \ run_with_perl_or_shell () \ { \ if grep -q '^#!.*perl' $$1; then $(PERL) $$1; \ else \ $(SHELL) $$1; \ fi; \ } LOG_COMPILER = run_with_perl_or_shell - The package authors can now use customary testsuite drivers within the framework provided by the 'parallel-tests' testsuite harness. Consistently with the existing syntax, this can be done by defining special makefile variables 'LOG_DRIVER' and '_LOG_DRIVER'. - A new developer-reserved variable 'AM_TESTS_FD_REDIRECT' can be used to redirect/define file descriptors used by the test scripts. - The parallel-tests harness generates now, in addition the '.log' files holding the output produced by the test scripts, a new set of '.trs' files, holding "metadata" derived by the execution of the test scripts; among such metadata are the outcomes of the test cases run by a script. - Initial and still experimental support for the TAP test protocol is now provided. * Changes to Yacc and Lex support: - C source and header files derived from non-distributed Yacc and/or Lex sources are now removed by a simple "make clean" (while they were previously removed only by "make maintainer-clean"). - Slightly backward-incompatible change, relevant only for use of Yacc with C++: the extensions of the header files produced by the Yacc rules are now modelled after the extension of the corresponding sources. For example, yacc files named "foo.y++" and "bar.yy" will produce header files named "foo.h++" and "bar.hh" respectively, where they would have previously produced header files named simply "foo.h" and "bar.h". This change offers better compatibility with 'bison -o'. * Miscellaneous changes: - The AM_PROG_VALAC macro now causes configure to exit with status 77, rather than 1, if the vala compiler found is too old. - The build system of Automake itself now avoids the use of make recursion as much as possible. - Automake now prefers to quote 'like this' or "like this", rather than `like this', in diagnostic message and generated Makefiles, to accommodate the new GNU Coding Standards recommendations. - Automake has a new option '--print-libdir' that prints the path of the directory containing the Automake-provided scripts and data files. - The 'dist' and 'dist-all' targets now can run compressors in parallel. - The rules to create pdf, dvi and ps output from Texinfo files now works better with modern 'texi2dvi' script, by explicitly passing it the '--clean' option to ensure stray auxiliary files are not left to clutter the build directory. - Automake can now generate silenced rules for texinfo outputs. - Some auxiliary files that are automatically distributed by Automake (e.g., 'install-sh', or the 'depcomp' script for packages compiling C sources) might now be listed in the DIST_COMMON variable in many Makefile.in files, rather than in the top-level one. - Messages of types warning or error from 'automake' and 'aclocal' are now prefixed with the respective type, and presence of -Werror is noted. - Automake's early configure-time sanity check now tries to avoid sleeping for a second, which slowed down cached configure runs noticeably. In that case, it will check back at the end of the configure script to ensure that at least one second has passed, to avoid time stamp issues with makefile rules rerunning autotools programs. - The warnings in the category 'extra-portability' are now enabled by '-Wall'. In previous versions, one has to use '-Wextra-portability' to enable them. Bugs fixed in 1.12: - Various minor bugfixes for recent or long-standing bugs. * Bugs introduced by 1.11: - The AM_COND_IF macro also works if the shell expression for the conditional is no longer valid for the condition. - The automake-provided parallel testsuite harness no longer fails with BSD make used in parallel mode when there are test scripts in a subdirectory, like in: TESTS = sub/foo.test sub/bar.test * Long-standing bugs: - Automake's own build system finally have a real "installcheck" target. - Vala-related cleanup rules are now more complete, and work better in a VPATH setup. - Files listed with the AC_REQUIRE_AUX_FILE macro in configure.ac are now automatically distributed also if the directory of the auxiliary files coincides with the top-level directory. - Automake now detects the presence of the '-d' flag in the various '*YFLAGS' variables even when their definitions involve indirections through other variables, such as in: foo_opts = -d AM_YFLAGS = $(foo_opts) - Automake now complains if a '*YFLAGS' variable has any conditional content, not only a conditional definition. - Explicit enabling and/or disabling of Automake warning categories through the '-W...' options now always takes precedence over the implicit warning level implied by Automake strictness (foreign, gnu or gnits), regardless of the order in which such strictness and warning flags appear. For example, a setting like: AUTOMAKE_OPTIONS = -Wall --foreign will cause the warnings in category 'portability' to be enabled, even if those warnings are by default disabled in 'foreign' strictness. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Bugs fixed in 1.11.5: * Bugs introduced by 1.11.3: - Vala files with '.vapi' extension are now recognized and handled correctly again. See automake bug#11222. - Vala support work again for projects that contain some program built from '.vala' (and possibly '.c') sources and some other program built from '.c' sources *only*. See automake bug#11229. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ New in 1.11.4: * Miscellaneous changes: - The 'ar-lib' script now ignores the "s" (symbol index) and "S" (no symbol index) modifiers as well as the "s" action, as the symbol index is created unconditionally by Microsoft lib. Also, the "q" (quick) action is now a synonym for "r" (replace). Also, the script has been ignoring the "v" (verbose) modifier already since Automake 1.11.3. - When the 'compile' script is used to wrap MSVC, it now accepts an optional space between the -I, -L and -l options and their respective arguments, for better POSIX compliance. - There is an initial, experimental support for automatic dependency tracking with tcc (the Tiny C Compiler). Its associated depmode is currently recognized as "icc" (but this and other details are likely to change in future versions). - Automatic dependency tracking now works also with the IBM XL C/C++ compilers, thanks to the new new depmode 'xlc'. Bugs fixed in 1.11.4: * Bugs introduced by 1.11.2: - A definition of 'noinst_PYTHON' before 'python_PYTHON' (or similar) no longer cause spurious failures upon "make install". - The user can now instruct the 'uninstall-info' rule not to update the '${infodir}/dir' file by exporting the environment variable 'AM_UPDATE_INFO_DIR' to the value "no". This is done for consistency with how the 'install-info' rule operates since automake 1.11.2. * Long-standing bugs: - It is now possible for a foo_SOURCES variable to hold Vala sources together with C header files, as well as with sources and headers for other supported languages (e.g., C++). Previously, only mixing C and Vala sources was supported. - If "aclocal --install" is used, and the first directory specified with '-I' is non-existent, aclocal will now create it before trying to copy files in it. - An empty declaration of a "foo_PRIMARY" no longer cause the generated install rules to create an empty $(foodir) directory; for example, if Makefile.am contains something like: pkglibexec_SCRIPTS = if FALSE pkglibexec_SCRIPTS += bar.sh endif the $(pkglibexec) directory will not be created upon "make install". ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ New in 1.11.3: * Miscellaneous changes: - Automake's own build system is more silent by default, making use of the 'silent-rules' option. - The master copy of the 'gnupload' script is now maintained in gnulib, not in automake. - The 'missing' script no longer tries to wrap calls to 'tar'. - "make dist" no longer wraps 'tar' invocations with the 'missing' script. Similarly, the obsolescent variable '$(AMTAR)' (which you shouldn't be using BTW ;-) no longer invokes the 'missing' script to wrap tar, but simply invokes the 'tar' program itself. - "make dist" can now create lzip-compressed tarballs. - In the Automake info documentation, the Top node and the nodes about the invocation of the automake and aclocal programs have been renamed; now, calling "info automake" will open the Top node, while calling "info automake-invocation" and "info aclocal-invocation" will access the nodes about the invocation of respectively automake and aclocal. - Automake is now distributed as a gzip-compressed and an xz-compressed tarball. Previously, bzip2 was used instead of xz. - The last relics of Python 1.5 support have been removed from the AM_PATH_PYTHON macro. - For programs and libraries, automake now detects EXTRA_foo_DEPENDENCIES and adds them to the normal list of dependencies, but without overwriting the foo_DEPENDENCIES variable, which is normally computed by automake. Bugs fixed in 1.11.3: * Bugs introduced by 1.11.2: - Automake now correctly recognizes the prefix/primary combination 'pkglibexec_SCRIPTS' as valid. - The parallel-tests harness no longer trips on sed implementations with stricter limits on the length of input lines (problem seen at least on Solaris 8). * Long-standing bugs: - The "deleted header file problem" for *.am files is avoided by stub rules. This allows 'make' to trigger a rerun of 'automake' also if some previously needed '.am' file has been removed. - The 'silent-rules' option now generates working makefiles even for the uncommon 'make' implementations that do not support the nested-variables extension to POSIX 2008. For such 'make' implementations, whether a build is silent is determined at configure time, and cannot be overridden at make time with "make V=0" or "make V=1". - Vala support now works better in VPATH setups. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ New in 1.11.2: * Changes to aclocal: - The `--acdir' option is deprecated. Now you should use the new options `--automake-acdir' and `--system-acdir' instead. - The `ACLOCAL_PATH' environment variable is now interpreted as a colon-separated list of additional directories to search after the automake internal acdir (by default ${prefix}/share/aclocal-APIVERSION) and before the system acdir (by default ${prefix}/share/aclocal). * Miscellaneous changes: - The Automake support for automatic de-ANSI-fication has been deprecated. It will probably be removed in the next major Automake release (1.12). - The `lzma' compression scheme and associated automake option `dist-lzma' is obsoleted by `xz' and `dist-xz' due to upstream changes. - You may adjust the compression options used in dist-xz and dist-bzip2. The default is now merely -e for xz, but still -9 for bzip; you may specify a different level via the XZ_OPT and BZIP2 envvars respectively. E.g., "make dist-xz XZ_OPT=-7" or "make dist-bzip2 BZIP2=-5" - The `compile' script now converts some options for MSVC for a better user experience. Similarly, the new `ar-lib' script wraps Microsoft lib. - The py-compile script now accepts empty arguments passed to the options `--destdir' and `--basedir', and complains about unrecognized options. Moreover, a non-option argument or a special `--' argument terminates the list of options. - A developer that needs to pass specific flags to configure at "make distcheck" time can now, and indeed is advised to, do so by defining the developer-reserved makefile variable AM_DISTCHECK_CONFIGURE_FLAGS, instead of the old DISTCHECK_CONFIGURE_FLAGS. The DISTCHECK_CONFIGURE_FLAGS variable should now be reserved for the user; still, the old Makefile.am files that used to define it will still continue to work as before. - New macro AM_PROG_AR that looks for an archiver and wraps it in the new 'ar-lib' auxiliary script if the selected archiver is Microsoft lib. This new macro is required for LIBRARIES and LTLIBRARIES when automake is run with -Wextra-portability and -Werror. - When using DejaGnu-based testsuites, the user can extend the `site.exp' file generated by automake-provided rules by defining the special make variable `$(EXTRA_DEJAGNU_SITE_CONFIG)'. - The `install-info' rule can now be instructed not to create/update the `${infodir}/dir' file, by exporting the new environment variable `AM_UPDATE_INFO_DIR' to the value "no". Bugs fixed in 1.11.2: * Bugs introduced by 1.11: - The parallel-tests driver no longer produces erroneous results with Tru64/OSF 5.1 sh upon unreadable log files. - The `parallel-tests' test driver does not report spurious successes when used with concurrent FreeBSD make (e.g., "make check -j3"). - When the parallel-tests driver is in use, automake now explicitly rejects invalid entries and conditional contents in TEST_EXTENSIONS, instead of issuing confusing and apparently unrelated error messages (e.g., "non-POSIX variable name", "bad characters in variable name", or "redefinition of TEST_EXTENSIONS), or even, in some situations, silently producing broken `Makefile.in' files. - The `silent-rules' option now truly silences all compile rules, even when dependency tracking is disabled. Also, when `silent-rules' is not used, `make' output no longer contains spurious backslash-only lines, thus once again matching what Automake did before 1.11. - The AM_COND_IF macro also works if the shell expression for the conditional is no longer valid for the condition. * Long-standing bugs: - The order of Yacc and Lex flags is fixed to be consistent with other languages: $(AM_YFLAGS) comes before $(YFLAGS), and $(AM_LFLAGS) before $(LFLAGS), so that the user variables override the developer variables. - "make distcheck" now correctly complains also when "make uninstall" leaves one and only one file installed in $(prefix). - A "make uninstall" issued before a "make install", or after a mere "make install-data" or a mere "make install-exec" does not spuriously fail anymore. - Automake now warns about more primary/directory invalid combinations, such as "doc_LIBRARIES" or "pkglib_PROGRAMS". - Rules generated by Automake now try harder to not change any files when `make -n' is invoked. Fixes include compilation of Emacs Lisp, Vala, or Yacc source files and the rule to update config.h. - Several scripts and the parallel-tests testsuite driver now exit with the right exit status upon receiving a signal. - A per-Makefile.am setting of -Werror does not erroneously carry over to the handling of other Makefile.am files. - The code for automatic dependency tracking works around a Solaris make bug triggered by sources containing repeated slashes when the `subdir-objects' option was used. - The makedepend and hp depmodes now work better with VPATH builds. - Java sources specified with check_JAVA are no longer compiled for "make all", but only for "make check". - An usage like "java_JAVA = foo.java" will now cause Automake to warn and error out if `javadir' is undefined, instead of silently producing a broken Makefile.in. - aclocal and automake now honour the configure-time definitions of AUTOCONF and AUTOM4TE when they spawn autoconf or autom4te processes. - The `install-info' recipe no longer tries to guess whether the `install-info' program is from Debian or from GNU, and adaptively change its behaviour; this has proven to be frail and easy to regress. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Bugs fixed in 1.11.1: - Lots of minor bugfixes. * Bugs introduced by 1.11: - The `parallel-tests' test driver works around a GNU make 3.80 bug with trailing white space in the test list (`TESTS = foo $(EMPTY)'). * Long standing bugs: - On Darwin 9, `pythondir' and `pyexecdir' pointed below `/Library/Python' even if the `--prefix' argument pointed outside of a system directory. AM_PATH_PYTHON has been fixed to ignore the value returned from python's `get_python_lib' function if it points outside the configured prefix, unless the `--prefix' argument was either `/usr' or below `/System'. - The testsuite does not try to change the mode of `ltmain.sh' files from a Libtool installation (symlinked to test directories) any more. - AM_PROG_GCJ uses AC_CHECK_TOOLS to look for `gcj' now, so that prefixed tools are preferred in a cross-compile setup. - The distribution is tarred up with mode 755 now by the `dist*' targets. This fixes a race condition where untrusted users could modify files in the $(PACKAGE)-$(VERSION) distdir before packing if the toplevel build directory was world-searchable. This is CVE-2009-4029. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ New in 1.11: * Version requirements: - Autoconf 2.62 or greater is required. * Changes to aclocal: - The autoconf version check implemented by aclocal in aclocal.m4 (and new in Automake 1.10) is degraded to a warning. This helps in the common case where the Autoconf versions used are compatible. * Changes to automake: - The automake program can run multiple threads for creating most Makefile.in files concurrently, if at least Perl 5.7.2 is available with interpreter-based threads enabled. Set the environment variable AUTOMAKE_JOBS to the maximum number of threads to use, in order to enable this experimental feature. * Changes to Libtool support: - Libtool generic flags are now passed to the install and uninstall modes as well. - distcheck works with Libtool 2.x even when LT_OUTPUT is used, as config.lt is removed correctly now. * Languages changes: - subdir-object mode works now with Fortran (F77, FC, preprocessed Fortran, and Ratfor). - For files with extension .f90, .f95, .f03, or .f08, the flag $(FCFLAGS_f[09]x) computed by AC_FC_SRCEXT is now used in compile rules. - Files with extension .sx are also treated as preprocessed assembler. - The default source file extension (.c) can be overridden with AM_DEFAULT_SOURCE_EXT now. - Python 3.0 is supported now, Python releases prior to 2.0 are no longer supported. - AM_PATH_PYTHON honors python's idea about the site directory. - There is initial support for the Vala programming language, when using Vala 0.7.0 or later. * Miscellaneous changes: - Automake development is done in a git repository on Savannah now, see https://git.sv.gnu.org/gitweb/?p=automake.git A read-only CVS mirror is provided at cvs -d :pserver:anonymous@pserver.git.sv.gnu.org:/automake.git \ checkout -d automake HEAD - "make dist" can now create xz-compressed tarballs, as well as (deprecated?) lzma-compressed tarballs. - `automake --add-missing' will by default install the GPLv3 file as COPYING if it is missing. It will also warn that the license file should be added to source control. Note that Automake will never overwrite an existing COPYING file, even when the `--force-missing' option is used. - The manual is now distributed under the terms of the GNU FDL 1.3. - Automake ships and installs man pages for automake and aclocal now. - New shorthand `$(pkglibexecdir)' for `$(libexecdir)/@PACKAGE@'. - install-sh supports -C, which does not update the installed file (and its time stamps) if the contents did not change. - The `gnupload' script has been revamped. - The `depcomp' and `compile' scripts now work with MSVC under MSYS. - The targets `install' and `uninstall' are more efficient now, in that for example multiple files from one Automake variable such as `bin_SCRIPTS' are copied in one `install' (or `libtool --mode=install') invocation if they do not have to be renamed. Both install and uninstall may sometimes enter (`cd' into) the target installation directory now, when no build-local scripts are used. Both install and uninstall do not fail anymore but do nothing if an installation directory variable like `bindir' is set to the empty string. For built-in rules, `make install' now fails reliably if installation of a file failed. Conversely, `make uninstall' even succeeds when issued multiple times. These changes may need some adjustments from users: For example, some `install' programs refuse to install multiple copies of the same file in one invocation, so you may need to remove duplicate entries from file lists. Also, within one set of files, say, nobase_data_DATA, the order of installation may be changed, or even unstable among different hosts, due to the use of associative arrays in awk. The increased use of awk matches a similar move in Autoconf to provide for better scaling. Further, most undocumented per-rule install command variables such as binSCRIPT_INSTALL have been removed because they are not needed any more. Packages which use them should be using the appropriate one of INSTALL_{DATA,PROGRAM,SCRIPT} or their install_sh_{DATA,PROGRAM,SCRIPT} counterpart, depending on the type of files and the need for automatic target directory creation. - The "deleted header file problem" for *.m4 files is avoided by stub rules. This allows `make' to trigger a rerun of `aclocal' also if some previously needed macro file has been removed. - Rebuild rules now also work for a removed `subdir/Makefile.in' in an otherwise up to date tree. - The `color-tests' option causes colored test result output on terminals. - The `parallel-tests' option enables a new test driver that allows for parallel test execution, inter-test dependencies, lazy test execution for unit-testing, re-testing only failed tests, and formatted result output as RST (reStructuredText) and HTML. Enabling this option may require some changes to your test suite setup; see the manual for details. - The `silent-rules' option enables Linux kernel-style silent build output. This option requires the widely supported but non-POSIX `make' feature of recursive variable expansion, so do not use it if your package needs to build with `make' implementations that do not support it. To enable less verbose build output, the developer has to use the Automake option `silent-rules' in `AM_INIT_AUTOMAKE', or call the `AM_SILENT_RULES' macro. The user may then set the default verbosity by passing the `--enable-silent-rules' option to `configure'. At `make' run time, this default may be overridden using `make V=0' for less verbose, and `make V=1' for backward-compatible verbose output. - New prefix `notrans_' for manpages which should not be transformed by --program-transform. - New macro AM_COND_IF for conditional evaluation and conditional config files. - For AC_CONFIG_LINKS, if source and destination are equal, do not remove the file in a non-VPATH build. Such setups work with Autoconf 2.62 or newer. - AM_MAINTAINER_MODE now allows for an optional argument specifying the default setting. - AM_SUBST_NOTMAKE may prevent substitution of AC_SUBSTed variables, useful especially for multi-line values. - Automake's early configure-time sanity check now diagnoses an unsafe absolute source directory name and makes configure fail. - The Automake macros and rules cope better with whitespace in the current directory name, as long as the relative path to `configure' does not contain whitespace. To this end, the values of `$(MISSING)' and `$(install_sh)' may contain suitable quoting, and their expansion might need `eval'uation if used outside of a makefile. These undocumented variables may be used in several documented macros such as $(AUTOCONF) or $(MAKEINFO). Bugs fixed in 1.11: * Long-standing bugs: - Fix aix dependency tracking for libtool objects. - Work around AIX sh quoting issue in AC_PROG_CC_C_O, leading to unnecessary use of the `compile' script. - For nobase_*_LTLIBRARIES with nonempty directory components, the correct `-rpath' argument is used now. - `config.status --file=Makefile depfiles' now also works with the extra quoting used internally by Autoconf 2.62 and newer (it used to work only without the `--file=' bit). - The `missing' script works better with versioned tool names. - Semantics for `missing help2man' have been revamped: Previously, if `help2man' was not present, `missing help2man' would have the following semantics: if some man page was out of date but present, then a warning would be printed, but the exit status was 0. If the man page was not present at all, then `missing' would create a replacement man page containing an error message, and exit with a status of 2. This does not play well with `make': the next run will see this particular man page as being up to date, and will only error out on the next generated man page, if any; repeat until all pages are done. This was not desirable. These are the new semantics: if some man page is not present, and help2man is not either, then `missing' will warn and generate the replacement page containing the error message, but exit successfully. However, `make dist' will ensure that no such bogus man pages are packaged into a tarball. - Targets provided by automake behave better with `make -n', in that they take care not to create files. - `config.status Makefile... depfiles' works fine again in the presence of disabled dependency tracking. - The default no-op recursive rules for these targets also work with BSD make now: html, install-html, install-dvi, install-pdf, install-pdf, install-info. - `make distcheck' works also when both a directory and some file below it have been added to a distribution variable, such as EXTRA_DIST or *_SOURCES. - Texinfo dvi, ps, pdf, and html output files are not removed upon `make mostlyclean' any more; only the LaTeX by-products are. - Renamed objects also work with the `subdir-objects' option and source file languages which Automake does not know itself. - `automake' now correctly complains about variable assignments which are preceded by a comment, extend over multiple lines with backslash-escaped newlines, and end in a comment sign. Previous versions would silently and wrongly ignore such assignments completely. * Bugs introduced by 1.10: - Fix output of dummy dependency files in presence of post-processed Makefile.in's again, but also cope with long lines. - $(EXEEXT) is automatically appended to filenames of XFAIL_TESTS that have been declared as programs in the same Makefile. This is for consistency with the analogous change to TESTS in 1.10. - Fix order of standard includes to again be `-I. -I$(srcdir)', followed by directories containing config headers. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ New in 1.10: * Version requirements: - Autoconf 2.60 or greater is required. - Perl 5.6 or greater is required. * Changes to aclocal: - aclocal now also supports -Wmumble and -Wno-mumble options. - `dirlist' entries (for the aclocal search path) may use shell wildcards such as `*', `?', or `[...]'. - aclocal supports an --install option that will cause system-wide third-party macros to be installed in the local directory specified with the first -I flag. This option also uses #serial lines in M4 files to upgrade local macros. The new aclocal options --dry-run and --diff help to review changes before they are installed. - aclocal now outputs an autoconf version check in aclocal.m4 in projects using automake. For a few years, automake and aclocal have been calling autoconf (or its underlying engine autom4te) to accurately retrieve the data they need from configure.ac and its siblings. Doing so can only work if all autotools use the same version of autoconf. For instance a Makefile.in generated by automake for one version of autoconf may stop working if configure is regenerated with another version of autoconf, and vice versa. This new version check ensures that the whole build system has been generated using the same autoconf version. * Support for new Autoconf macros: - The new AC_REQUIRE_AUX_FILE Autoconf macro is supported. - If `subdir-objects' is set, and AC_CONFIG_LIBOBJ_DIR is specified, $(LIBOBJS), $(LTLIBOBJS), $(ALLOCA), and $(LTALLOCA) can be used in different directories. However, only one instance of such a library objects directory is supported. * Change to Libtool support: - Libtool generic flags (those that go before the --mode=MODE option) can be specified using AM_LIBTOOLFLAGS and target_LIBTOOLFLAGS. * Yacc and Lex changes: - The rebuild rules for distributed Yacc and Lex output will avoid overwriting existing files if AM_MAINTAINER_MODE and maintainer-mode is not enabled. - ylwrap is now always used for lex and yacc source files, regardless of whether there is more than one source per directory. * Languages changes: - Preprocessed assembler (*.S) compilation now honors CPPFLAGS, AM_CPPFLAGS and per-target _CPPFLAGS, and supports dependency tracking, unlike non-preprocessed assembler (*.s). - subdir-object mode works now with Assembler. Automake assumes that the compiler understands `-c -o'. - Preprocessed assembler (*.S) compilation now also honors $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES). - Improved support for Objective C: - Autoconf's new AC_PROG_OBJC will enable automatic dependency tracking. - A new section of the manual documents the support. - New support for Unified Parallel C: - AM_PROG_UPC looks for a UPC compiler. - A new section of the manual documents the support. - Per-target flags are now correctly handled in link rules. For instance maude_CFLAGS correctly overrides AM_CFLAGS; likewise for maude_LDFLAGS and AM_LDFLAGS. Previous versions bogusly preferred AM_CFLAGS over maude_CFLAGS while linking, and they used both AM_LDFLAGS and maude_LDFLAGS on the same link command. The fix for compiler flags (i.e., using maude_CFLAGS instead of AM_CFLAGS) should not hurt any package since that is how _CFLAGS is expected to work (and actually works during compilation). However using maude_LDFLAGS "instead of" AM_LDFLAGS rather than "in addition to" breaks backward compatibility with older versions. If your package used both variables, as in AM_LDFLAGS = common flags bin_PROGRAMS = a b c a_LDFLAGS = more flags ... and assumed *_LDFLAGS would sum up, you should rewrite it as AM_LDFLAGS = common flags bin_PROGRAMS = a b c a_LDFLAGS = $(AM_LDFLAGS) more flags ... This new behavior of *_LDFLAGS is more coherent with other per-target variables, and the way *_LDFLAGS variables were considered internally. * New installation targets: - New targets mandated by GNU Coding Standards: install-dvi install-html install-ps install-pdf By default they will only install Texinfo manuals. You can customize them with *-local variants: install-dvi-local install-html-local install-ps-local install-pdf-local - The undocumented recursive target `uninstall-info' no longer exists. (`uninstall' is in charge of removing all possible documentation flavors, including optional formats such as dvi, ps, or info even when `no-installinfo' is used.) * Miscellaneous changes: - Automake no longer complains if input files for AC_CONFIG_FILES are specified using shell variables. - clean, distribution, or rebuild rules are normally disabled for inputs and outputs of AC_CONFIG_FILES, AC_CONFIG_HEADERS, and AC_CONFIG_LINK specified using shell variables. However, if these variables are used as ${VAR}, and AC_SUBSTed, then Automake will be able to output rules anyway. (See the Automake documentation for AC_CONFIG_FILES.) - $(EXEEXT) is automatically appended to filenames of TESTS that have been declared as programs in the same Makefile. This is mostly useful when some check_PROGRAMS are listed in TESTS. - `-Wportability' has finally been turned on by default for `gnu' and `gnits' strictness. This means, automake will complain about %-rules or $(GNU Make functions) unless you switch to `foreign' strictness or use `-Wno-portability'. - Automake now uses AC_PROG_MKDIR_P (new in Autoconf 2.60), and uses $(MKDIR_P) instead of $(mkdir_p) to create directories. The $(mkdir_p) variable is still defined (to the same value as $(MKDIR_P)) but should be considered obsolete. If you are using $(mkdir_p) in some of your rules, please plan to update them to $(MKDIR_P) at some point. - AM_C_PROTOTYPES and ansi2knr are now documented as being obsolete. They still work in this release, but may be withdrawn in a future one. - Inline compilation rules for gcc3-style dependency tracking are more readable. - Automake installs a "Hello World!" example package in $(docdir). This example is used throughout the new "Autotools Introduction" chapter of the manual. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ New in 1.9: * Makefile.in bloat reduction: - Inference rules are used to compile sources in subdirectories when the `subdir-objects' option is used and no per-target flags are used. This should reduce the size of some projects a lot, because Automake used to output an explicit rule for each such object in the past. - Automake no longer outputs three rules (.o, .obj, .lo) for each object that must be built with explicit rules. It just outputs the rules required to build the kind of object considered: either the two .o and .obj rules for usual objects, or the .lo rule for libtool objects. * Change to Libtool support: - Libtool tags are used with libtool versions that support them. (I.e., with Libtool 1.5 or greater.) - Automake is now able to handle setups where a libtool library is conditionally installed in different directories, as in if COND lib_LTLIBRARIES = liba.la else pkglib_LTLIBRARIES = liba.la endif liba_la_SOURCES = ... * Changes to aclocal: - aclocal now ensures that AC_DEFUNs and AU_DEFUNs it discovers are really evaluated, before it decides to include them in aclocal.m4. This solves nasty problems with conditional redefinitions of Autoconf macros in /usr/share/aclocal/*.m4 files causing extraneous *.m4 files to be included in any project using these macros. (Calls to AC_PROG_EGREP causing libtool.m4 to be included is the most famous instance of this bug.) - Do not complain about missing conditionally AC_REQUIREd macros that are not actually used. In 1.8.x aclocal would correctly determine which of these macros were really needed (and include only these in the package); unfortunately it would also require all of them to be present in order to run. This created situations were aclocal would not work on a tarball distributing all the macros it uses. For instance running aclocal on a project containing only the subset of the Gettext macros in use by the project did not work, because gettext conditionally requires other macros. * Portability improvements: - Tar format can be chosen with the new options tar-v7, tar-ustar, and tar-pax. The new option filename-length-max=99 helps diagnosing filenames that are too long for tar-v7. (PR/414) - Variables augmented with `+=' are now automatically flattened (i.e., trailing backslashes removed) and then wrapped around 80 columns (adding trailing backslashes). In previous versions, a long series of VAR += value1 VAR += value2 VAR += value3 ... would result in a single-line definition of VAR that could possibly exceed the maximum line length of some make implementations. Non-augmented variables are still output as they are defined in the Makefile.am. * Miscellaneous: - Support Fortran 90/95 with the new "fc" and "ppfc" languages. Works the same as the old Fortran 77 implementation; just replace F77 with FC everywhere (exception: FFLAGS becomes FCFLAGS). Requires a version of autoconf which provides AC_PROG_FC (>=2.59). - Support for conditional _LISP. - Support for conditional -hook and -local rules (PR/428). - Diagnose AC_CONFIG_AUX_DIR calls following AM_INIT_AUTOMAKE. (PR/49) - Automake will not write any Makefile.ins after the first error it encounters. The previous Makefile.ins (if any) will be left in place. (Warnings will not prevent output, but remember they can be turned into errors with -Werror.) - The restriction that SUBDIRS must contain direct children is gone. Do not abuse. - The manual tells more about SUBDIRS vs. DIST_SUBDIRS. It also gives an example of nested packages using AC_CONFIG_SUBDIRS. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Bugs fixed in 1.8.5: * Long-standing bugs: - Define DIST_SUBDIRS even when the `no-dist' or `cygnus' options are used so that `make distclean' and `make maintainer-clean' can work. - Define AR and ARFLAGS even when only EXTRA_LIBRARIES are defined. - Fix many rules to please FreeBSD make, which runs commands with `sh -e'. - Polish diagnostic when no input file is found. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Bugs fixed in 1.8.4: * Long-standing bugs: - Fix AM_PATH_PYTHON to correctly display $PYTHON when it has been overridden by the user. - Honor PATH_SEPARATOR in various places of the Automake package, for the sake of OS/2. - Adjust dependency tracking mode detection to ICC 8.0's new output. (PR/416) - Fix install-sh so it can install the `mv' binary... using `mv'. - Fix tru64 dependency tracking for libtool objects. - Work around Exuberant Ctags when creating a TAGS files in a directory without files to scan but with subdirectories to include. * Bugs introduced by 1.8: - Fix an "internal error" when @LIBOBJS@ is used in a variable that is not defined in the same conditions as the _LDADD that uses it. - Do not warn when JAVAROOT is overridden, this is legitimate. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Bugs fixed in 1.8.3: * Long-standing bugs: - Quote filenames in installation rules, in case $DESTDIR, $prefix, or any of the other *dir variables contain a space. Please note that Automake does not and cannot support spaces in filenames that are involved during the build. This change affects only installation paths, so that `make install' does not bomb out in packages configured with ./configure --prefix '/c/Program Files' - Fix the depfiles output so it works with GNU sed (<4.1) even when POSIXLY_CORRECT is set. - Do not AC_SUBST(LIBOBJS) in AM_WITH_REGEX. This macro was unusable since Autoconf 2.54, which defines LIBOBJS itself. - Fix a potential (but unlikely) race condition in parallel elisp builds. (Introduced in 1.7.3.) - Do not assume that users override _DEPENDENCIES in all conditions where Automake will try to define them. - Do not use `mkdir -p' in mkinstalldirs, unless this is GNU mkdir. Solaris 8's `mkdir -p' is not thread-safe and can break parallel builds. This fix also affects the $(mkdir_p) variable defined since Automake 1.8. It will be set to `mkdir -p' only if mkdir is GNU mkdir, and to `mkinstalldirs' or `install-sh -d' otherwise. - Secure temporary directory creation in `make distcheck'. (PR/413) - Do not generate two build rules for `parser.h' when the parser appears in two different conditionals. - Work around a Solaris 8 /bin/sh bug in the test for dependency checking. Usually ./configure will not pick this shell; so this fix only helps cases where the shell is forced to /bin/sh. * Bugs introduced by 1.8: - In some situations (hand-written `m4_include's), aclocal would call the `File::Spec->rel2abs' method, which was only introduced in Perl 5.6. This new version reestablish support Perl 5.005. It is likely that the next major Automake releases will require at least Perl 5.6. Consider upgrading your development environment if you are still using the five-year-old Perl 5.005. - Automake would sometimes fail to define rules for targets listed in variables defined in multiple conditions. For instance on if C1 bin_PROGRAMS = a else bin_PROGRAMS = b endif it would define only the `a.$(OBJEXT): a.c' rule and omit the `b.$(OBJEXT): b.c' rule. * New sections in manual: - Third-Party Makefiles: how to interface third party Makefiles. - Upgrading: upgrading packages to newer Automake versions. - Multiple Outputs: handling tools that produce many outputs. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Bug fixed in 1.8.2: * A (well known) portability bug slipped in the changes made to install-sh in Automake 1.8.1. The broken install-sh would refuse to install anything on Tru64. * Fix install rules for conditionally built python files. (This never really worked.) ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Bug fixed in 1.8.1: * Bugs introduced by 1.8: - Fix Config.pm import error with old Perl versions (at least 5.005_03). One symptom is that aclocal could not find its macro directory. - Automake 1.8 used `mkdir -m 0755 -p --' to ensure that directories created by `make install' are always world readable, even if the installer happens to have an overly restrictive umask (e.g. 077). This was a mistake and has been reverted. There are at least two reasons why we must not use `-m 0755': - it causes special bits like SGID to be ignored, - it may be too restrictive (some setups expect 775 directories). - Fix aclocal to honor definitions located in files which have been m4_included manually. aclocal 1.8 had been updated to check m4_included files for new requirements, but forgot that these m4_included files can also provide new definitions. Note that if you have such a setup, we recommend you get rid of it. In the past, there was a reason to m4_include files manually: aclocal used to duplicate entire M4 files into aclocal.m4, even files that were distributed. Some packages were therefore m4_including the distributed file directly, and playing some tricks to ensure aclocal would not copy that file to aclocal.m4, in order to limit the amount of duplication. Since aclocal 1.8.x will precisely output m4_includes for local M4 files, we recommend that you clean up your setup, removing all manual m4_includes and letting aclocal output them. - Output detailed menus in the Info version if the Automake manual, so that Emacs can locate the indexes. - configure.ac and configure were listed twice in DIST_COMMON (an internal variable where Automake lists configury files to distribute). This was harmless, but unaesthetic. - Use `chmod a-w' instead of `chmod -w' as the latter honors umask. This was an issue only in the Automake package itself, not in its output. - Automake assumed that all AC_CONFIG_LINKS arguments had the form DEST:SRC. This was wrong, as some packages do AC_CONFIG_LINKS($computedlinks). This version no longer abort in that situation. - Contrary to mkinstalldirs, $(mkdir_p) was expecting exactly one argument. This caused two kinds of failures: - Rules installing data in a conditionally defined directory failed when that directory was undefined. In this case no argument was supplied. - `make installdirs' failed, because several directories were passed to $(mkdir_p). This was an issue only on platform were $(mkdir_p) is implemented with `install-sh -d'. $(mkdir_p) as been changed to accept 0 or more arguments, as mkinstalldirs did. * Long-standing bugs: - Fix an unexpected diagnostic occurring when users attempt to override some internal variables that Automake appends to. - aclocal now scans configure.ac for macro definitions (PR/319). - Fix a portability issue with OSF1/Tru64 Make. If a directory distributes files which are outside itself (this usually occurs when using AC_CONFIG_AUX_DIR([../dir]) to use auxiliary files from a parent package), then `make distcheck' fails due to an optimization performed by OSF1/Tru64 Make in its VPATH handling. (tests/subpkg2.test failure) - Fix another portability issue with Sun and OSF1/Tru64 Make. In a VPATH-build configuration, `make install' would install nobase_ files to wrong locations. - Fix a Perl `uninitialized value' diagnostic occurring when automake complains that a Texinfo file does not have a @setfilename statement. - Erase config.status.lineno during `make distclean'. This file can be created by config.status. Automake already knew about configure.lineno, but forgot config.status.lineno. - Distribute all files, even those which are built and installed conditionally. This change affects files listed in conditionally defined *_HEADERS and *_PYTHON variable (unless they are nodist_*) as well as those listed in conditionally defined dist_*_DATA, dist_*_JAVA, dist_*_LISP, and dist_*_SCRIPTS variables. - Fix AM_PATH_LISPDIR to avoid \? in sed regular expressions; it doesn't conform to POSIX. - Normalize help strings for configure variables and options added by Automake macros. * Anticipation: - Check for python2.4 in AM_PATH_PYTHON. * Spurious failures in test suite: - tests/libtool5.test, tests/ltcond.test, tests/ltcond2.test, tests/ltconv.test: fix failures with CVS Libtool. - tests/aclocal6.test: fix failure if autom4te.cache is disabled. - tests/txinfo24.test, tests/txinfo25.test, tests/txinfo28.test: fix failures with old Texinfo versions. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ New in 1.8: * Meta-News - The NEWS file is more verbose. * Requirements - Autoconf 2.58 or greater is required. * New features - Default source file names in the absence of a _SOURCES declaration are made by removing any target extension before appending `.c', so to make the libtool module `foo.la' from `foo.c', you only need to do this: lib_LTLIBRARIES = foo.la foo_la_LDFLAGS = -module For backward compatibility, foo_la.c will be used instead of foo.c if this file exists or is the explicit target of a rule. However -Wobsolete will warn about this deprecated naming. - AR's `cru' flags are now set in a global ARFLAGS variable instead of being hard-coded in each $(AR) invocation, so they can be substituted from configure.ac. This has been requested by people dealing with non-POSIX ar implementations. - New warning option: -Woverride. This will warn about any user target or variable definitions which override Automake definitions. - Texinfo rules back up and restore info files when makeinfo fails. - Texinfo rules now support the `html' target. Running this requires Texinfo 4.0 or greater. `html' is a new recursive target, so if your package mixes hand-crafted `Makefile.in's with Automake-generated `Makefile.in's, you should adjust the former to support (or ignore) this target so that `make html' recurses successfully. If you had a custom `html' rule in your `Makefile.am', it's better to rename it as `html-local', otherwise your rule will override Automake's new rule (you can check that by running `automake -Woverride') and that will stop the recursion to subdirectories. Last but not least, this `html' rule is declared PHONY, even when overridden. Fortunately, it appears that few packages use a non-PHONY `html' rule. - Any file which is m4_included from configure.ac will appear as a configure and Makefile.in dependency, and will be automatically distributed. - The rules for rebuilding Makefiles and Makefile.ins will now rebuild all Makefiles and all Makefile.ins at once when one of configure's dependencies has changed. This is considerably faster than previous implementations, where config.status and automake were run separately in each directory (this still happens when you change a Makefile.am locally, without touching configure.ac or friends). Doing this also solves a longstanding issue: these rebuild rules failed to work when adding new directories to the tree, forcing you to run automake manually. - For similar reasons, the rules to rebuild configure, config.status, and aclocal.m4 are now defined in all directories. Note that if you were using the CONFIG_STATUS_DEPENDENCIES and CONFIGURE_DEPENDENCIES (formerly undocumented) variables, you should better define them in all directories. This is easily done using an AC_SUBST (make sure you prefix these dependencies with $(top_srcdir) since this variable will appear at different levels of the build tree). - aclocal will now use `m4_include' instead of copying local m4 files into aclocal.m4. (Local m4 files are those you ship with your project, other files will be copied as usual.) Because m4_included files are automatically distributed, it means for most projects there is no point in EXTRA_DISTing the list of m4 files which are used. (You can probably get rid of m4/Makefile.am if you had one.) - aclocal will avoid touching aclocal.m4 when possible, so that Autom4te's cache isn't needlessly invalidated. This behavior can be switched off with the new `--force' option. - aclocal now uses Autoconf's --trace to detect macros which are actually used and will no longer include unused macros simply because they where mentioned. This was often the case for macros called conditionally. - New options no-dist and no-dist-gzip. - compile, depcomp, elisp-comp, install-sh, mdate-sh, mkinstalldirs, py-compile, and ylwrap, now all understand --version and --help. - Automake will now recognize AC_CONFIG_LINKS so far as removing created links as part of the distclean target and including source files in distributions. - AM_PATH_PYTHON now supports ACTION-IF-FOUND and ACTION-IF-NOT-FOUND argument. The latter can be used to override the default behavior (which is to abort). - Automake will exit with $? = 63 on version mismatch. (So does Autoconf 2.58) missing knows this, and in this case it will emulate the tools as if they were absent. Because older versions of Automake and Autoconf did not use this exit code, this change will only be useful in projects generated with future versions of these tools. - When using AC_CONFIG_FILES with multiple input files, Automake generates the first ".in" input file for which a ".am" exists. (Former versions would try to use only the first input file.) - lisp_DATA is now allowed. If you are using the empty ELCFILES idiom to disable byte-compilation of lisp_LISP files, it is recommended that you switch to using lisp_DATA. Note that this is not strictly equivalent: lisp_DATA will install elisp files even if emacs is not installed, while *_LISP do not install anything unless emacs is found. - Makefiles will prefer `mkdir -p' over mkinstalldirs if it is available. This selection is achieved through the Makefile variable $(mkdir_p) that is set by AM_INIT_AUTOMAKE to either `mkdir -m 0755 -p --', `$(mkinstalldirs) -m 0755', or `$(install_sh) -m 0755 -d'. * Obsolete features - Because `mkdir -p' is available on most platforms, and we can use `install-sh -d' when it is not, the use of the mkinstalldirs script is being phased out. `automake --add-missing' no longer installs it, and if you remove mkinstalldirs from your package, automake will define $(mkinstalldirs) as an alias for $(mkdir_p). Gettext 0.12.1 still requires mkinstalldirs. Fortunately gettextize and autopoint will install it when needed. Automake will continue to define the $(mkinstalldirs) and to distribute mkinstalldirs when this script is in the source tree. - AM_PROG_CC_STDC is now empty. The content of this macro was merged in AC_PROG_CC. If your code uses $am_cv_prog_cc_stdc, you should adjust it to use $ac_cv_prog_cc_stdc instead. (This renaming should be safe, even if you have to support several, versions of Automake, because AC_PROG_CC defines this variable since Autoconf 2.54.) - Some users where using the undocumented ACLOCAL_M4_SOURCES variable to override the aclocal.m4 dependencies computed (inaccurately) by older versions of Automake. Because Automake now tracks configure's m4 dependencies accurately (see m4_include above), the use of ACLOCAL_M4_SOURCES should be considered obsolete and will be flagged as such when running `automake -Wobsolete'. * Bug fixes - Defining programs conditionally using Automake conditionals no longer leads to a combinatorial explosion. The following construct used to be troublesome when used with dozens of conditions. bin_PROGRAMS = a if COND1 bin_PROGRAMS += a1 endif if COND2 bin_PROGRAMS += a2 endif if COND3 bin_PROGRAMS += a3 endif ... Likewise for _SOURCES, _LDADD, and _LIBADD variables. - Due to implementation constraints, previous versions of Automake proscribed multiple conditional definitions of some variables like bin_PROGRAMS: if COND1 bin_PROGRAMS = a1 endif if COND2 bin_PROGRAMS = a2 endif All _PROGRAMS, _LDADD, and _LIBADD variables were affected. This restriction has been lifted, and these variables now support multiple conditional definitions as do other variables. - Cleanup the definitions of $(distdir) and $(top_distdir). $(top_distdir) now points to the root of the distribution directory created during `make dist', as it did in Automake 1.4, not to the root of the build tree as it did in intervening versions. Furthermore these two variables are now only defined in the top level Makefile, and passed to sub-directories when running `make dist'. - The --no-force option now correctly checks the Makefile.in's dependencies before deciding not to update it. - Do not assume that make files are called Makefile in cleaning rules. - Update .info files in the source tree, not in the build tree. This is what the GNU Coding Standard recommend. Only Automake 1.7.x used to update these files in the build tree (previous versions did it in the source tree too), and it caused several problems, varying from mere annoyance to portability issues. - COPYING, COPYING.LIB, and COPYING.LESSER are no longer overwritten when --add-missing and --force-missing are used. For backward compatibility --add-missing will continue to install COPYING (in `gnu' strictness) when none of these three files exist, but this use is deprecated: you should better choose a license yourself and install it once for all in your source tree (and in your code management system). - Fix ylwrap so that it does not overwrite header files that haven't changed, as the inline rule already does. - User-defined rules override automake-defined rules for the same targets, even when rules do not have commands. This is not new (and was documented), however some of the automake-generated rules have escaped this principle in former Automake versions. Rules for the following targets are affected by this fix: clean, clean-am, dist-all, distclean, distclean-am, dvi, dvi-am, info, info-am, install-data-am, install-exec-am, install-info, install-info-am, install-man, installcheck-am, maintainer-clean, maintainer-clean-am, mostlyclean, mostlyclean-am, pdf, pdf-am, ps, ps-am, uninstall-am, uninstall-info, uninstall-man Practically it means that an attempt to supplement the dependencies of some target, as in clean: my-clean-rule will now *silently override* the automake definition of the rule for this target. Running `automake -Woverride' will diagnose all such overriding definitions. It should be noted that almost all of these targets support a *-local variant that is meant to supplement the automake-defined rule (See node `Extending' in the manual). The above rule should be rewritten as clean-local: my-clean-rule These *-local targets have been documented since at least Automake 1.2, so you should not fear the change if you have to support multiple automake versions. * Miscellaneous - The Automake manual is now distributed under the terms of the GNU FDL. - Targets dist-gzip, dist-bzip2, dist-tarZ, dist-zip are always defined. - core dumps are no longer removed by the cleaning rules. There are at least three reasons for this: 1. These files should not be created by any build step, so their removal do not fit any of the cleaning rules. Actually, they may be precious to the developer. 2. If such file is created during a build, then it's clearly a bug Automake should not hide. Not removing the file will cause `make distcheck' to complain about its presence. 3. Operating systems have different naming conventions for core dump files. A core file on one system might be a completely legitimate data file on another system. - RUNTESTFLAGS, CTAGSFLAGS, ETAGSFLAGS, JAVACFLAGS are no longer defined by Automake. This means that any definition in the environment will be used, unless overridden in the Makefile.am or on the command line. The old behavior, where these variables were defined empty in each Makefile, can be obtained by AC_SUBSTing or AC_ARG_VARing each variable from configure.ac. - CONFIGURE_DEPENDENCIES and CONFIG_STATUS_DEPENDENCIES are now documented. (The is not a new feature, these variables have been there since at least Automake 1.4.) ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Bugs fixed in 1.7.9: * Fix install-strip to work with nobase_ binaries. * Fix renaming of #line directives in ylwrap. * Rebuild with Autoconf 2.59. (1.7.8 was not installable with pdksh.) Bugs fixed in 1.7.8: * Remove spurious blank lines in cleaning rules introduced in 1.7.7. * Fix detection of Debian's install-info, broken since version 1.5. (Debian bug #213524). * Honor -module if it appears in AM_LDFLAGS (i.e., relax name checking) This was only done for libfoo_LDFLAGS and LDFLAGS in previous versions. Bugs fixed in 1.7.7: * The implementation of automake's --no-force option is unreliable, so this option is ignored in this version. A real fix will appear in Automake 1.8. (Debian Bug #206299) * AM_PATH_PYTHON: really check the whole list of interpreters if no argument is given. (PR/399) * Do not warn about leading `_' in variable names, even with -Wportability. * Support user redefinitions of TEXINFO_TEX. * depcomp: support AIX Compiler version 6. * Fix missing rebuilds during `make dist' with BSD make. (Could produce tarballs containing out-of-date files.) * Resurrect multilib support. * Noteworthy manual updates: - Extending aclocal: how to write m4 macros that won't trigger warnings with Automake 1.8. - A Shared Library: Rewrite and split into subsections. Bugs fixed in 1.7.6: * Fix depcomp's icc mode for ICC 7.1. * Diagnose calls to AC_CONFIG_FILES and friends with not enough arguments. * Fix maintainer-clean's removal of autom4te.cache in VPATH builds. * Fix AM_PATH_LISPDIR to work with POSIXLY_CORRECT=1. * Fix the location reported in some diagnostics related to AUTOMAKE_OPTIONS. * Remove Latin-1 characters from elisp-comp. * Update the manual's @dircategory to match the Free Software Directory. Bugs fixed in 1.7.5: * Update install-sh's license to remove an advertising clause. (Debian bug #191717) * Fix a bug introduced in 1.7.4, related to BUILT_SOURCE handling, that caused invalid Makefile.ins to be generated. * Make sure AM_MAKE_INCLUDE doesn't fail when a `doit' file exists. * New FAQ entry: renamed objects. Bugs fixed in 1.7.4: * Tweak the TAGS rule to support Exuberant Ctags (in addition to the Emacs implementation) * Fix output of aclocal.m4 dependencies in subdirectories. * Use `mv -f' instead of `mv' in fastdep rules. * Upgrade mdate-sh to work on OS/2. * Don't byte-compile elisp files when ELCFILES is set empty. (this documented feature was broken by 1.7.3) * Diagnose trailing backslashes on last line of Makefile.am. * Diagnose whitespace following trailing backslashes. * Multiple tests are now correctly supported in DEJATOOL. (PR/388) * Fix rebuilt rules for AC_CONFIG_FILES([Makefile:Makefile.in:Makefile.bot]) Makefiles. (PR/389) * `make install' will build `BUILT_SOURCES' first. * Minor documentation fixes. Bugs fixed in 1.7.3: * Fix stamp files numbering (when using multiple AC_CONFIG_HEADERS). * Query distutils for `pythondir' and `pythonexecdir', instead of using an hardcoded path. This should allow builds on 64-bit distributions that usually use lib64/ instead of lib/. * AM_PATH_PYTHON will also search for python2.3. * elisp files are now built all at once instead of one by one. Besides incurring a speed-up, this is required to support interdependent elisp files. * Support for DJGPP: - `make distcheck' will now work in `_inst/' and `_build' instead of `=inst/' and `=build/' - use `_dirstamp' when the file-system doesn't support `.dirstamp' - install/uninstall `*.i[0-9][0-9]'-style info files - more changes that affect only the Automake package (not its output) * Fix some incompatibilities with upcoming perl-5.10. * Properly quote AC_PACKAGE_TARNAME and AC_PACKAGE_VERSION when defining PACKAGE and VERSION. * depcomp fixes: - dashmstdout and dashXmstdout modes: don't use `-o /dev/null', this is troublesome with gcc and Solaris compilers. (PR/385) - makedepend mode: work with Libtool. (PR/385 too) - support for ICC. * better support for unusual gettext setups, such as multiple po/ directories (PR/381): - Flag missing po/ and intl/ directories as warnings, not errors. - Disable these warnings if po/ does not exist. * Noteworthy manual updates: - New FAQ chapter. - Document how AC_CONFIG_AUX_DIR interacts with missing files. (Debian Bug #39542) - Document `AM_YFLAGS = -d'. (PR/382) Bugs fixed in 1.7.2: * Fix installation and uninstallation of Info files built in subdirectories. * Do not run `./configure --with-included-gettext' during `make distcheck' if AM_GNU_GETTEXT([external]) is used. * Correctly uninstall renamed man pages. * Do not strip escaped newline in variables defined in one condition and augmented in another condition. * Fix ansi2knr rules for LIBOBJS sources. * Clean all known Texinfo index files, not only those which appear to be used, because we cannot know which indexes are used in included files. (PR/375, Debian Bug #168671) * Honor only the first @setfilename seen in a Texinfo file. * Treat "required file X not found" diagnostics as errors (exit status 1). * Don't complain that a required file is not found when it is a Makefile target. (PR/357) * Don't use single suffix inference rules when building `.info'-less Info files, for the sake of Solaris make. * The `check' target now depends on `$(BUILT_SOURCES)'. (PR/359) * Recognize multiple inference rules such as `.a.b .c.d:'. (PR/371) * Warn about multiple inference rules when -Wportability is used. (PR/372) * Fix building of deansified files from subdirectories. (PR/370) * Add missing `fi' in the .c->.obj rules. * Improve install-sh to work even when names contain spaces or certain (but not all) shell metachars. * Fix the following spurious failures in the test suite: depcomp2.test, gnits2.test, gnits3.test, python3.test, texinfo13.test * Noteworthy manual updates: - Augment the section about BUILT_SOURCES. - Mention that AM_PROG_CC_STDC is a relic that is better avoided today. Bugs fixed in 1.7.1: * Honor `ansi2knr' for files built in subdirectories, or using per-targets flags. * Aclocal should now recognize macro names containing parentheses, e.g. AC_DEFUN([AC_LANG_PREPROC(Fortran 90)], [...]). * Erase *.sum and *.log files created by DejaGnu, during `make distclean'. (Debian Bug#153697) * Install Python files even if they were built. (PR/369) * Have stamp-vti dependent upon configure instead of configure.ac, as the version might not be defined in the latter. (PR/358) * Reorder arguments passed to a couple of commands, so things works when POSIXLY_CORRECT=1. * Fix a regex that can cause Perl to segfault on large input. (Debian Bug#162583) * Fix distribution of packages that have some sources defined conditionally, as in the `Conditional compilation using Automake conditionals' example of the manual. * Fix spurious test suite failures on IRIX. * Don't report a required variable as undefined if it has been defined conditionally for the "right" conditions. * Fix cleaning of the /tmp subdirectory used by `make distcheck', in case `make distcheck' fails. * Fix distribution of included Makefile fragment, so we don't create spurious directories in the distribution. (PR/366) * Don't complain that a target lacks `.$(EXEEXT)' when it has it. New in 1.7: * Autoconf 2.54 is required. * `aclocal' and `automake' will no longer warn about obsolete configure macros. This is done by `autoconf -Wobsolete'. * AM_CONFIG_HEADER, AM_SYS_POSIX_TERMIOS and AM_HEADER_TIOCGWINSZ_NEEDS_SYS_IOCTL are obsolete (although still supported). You should use AC_CONFIG_HEADERS, AC_SYS_POSIX_TERMIOS, and AC_HEADER_TIOCGWINSZ instead. `autoupdate' can upgrade `configure.ac' for you. * Support for per-program and per-library `_CPPFLAGS'. * New `ctags' target (builds CTAGS files). * Support for -Wmumble and -Wno-mumble, where mumble is a warning category (see `automake --help' or the manual for a list of them). * Honor the WARNINGS environment variable. * Omit the call to depcomp when using gcc3: call the compiler directly. * A new option, std-options, tests that programs support --help and --version when `make installcheck' is run. This is enabled by --gnits. * Texinfo rules now support the `ps' and `pdf' targets. * Info files are now created in the build directory, not the source directory. * info_TEXINFOS supports files in subdirectories (this requires Texinfo 4.1 or greater). * `make distcheck' will enforce DESTDIR support by attempting a DESTDIR install. * `+=' can be used in conditionals, even if the augmented variable was defined for another condition. * Makefile fragments (inserted with `include') are always distributed. * Use Autoconf's --trace interface to inspect configure.ac and get a more accurate view of it. * Add support for extending aclocal's default macro search path using a `dirlist' file within the aclocal directory. * automake --output-dir is deprecated. * The part of the distcheck target that checks whether uninstall actually removes all installed files has been moved in a separate target, distuninstallcheck, so it can be overridden easily. * Many bug fixes. New in 1.6.3: * Support for AM_INIT_GETTEXT([external]) * Bug fixes, including: - Fix Automake's own `make install' so it works even if `ln' doesn't. - nobase_ programs and scripts honor --program-transform correctly. - Erase configure.lineno during `make distclean'. - Erase YACC and LEX outputs during `make maintainer-clean'. New in 1.6.2: * Many bug fixes, including: - Requiring the current version works. - Fix "$@" portability issues (for Zsh). - Fix output of dummy dependency files in presence of post-processed Makefile.in's. - Don't compute dependencies in background to avoid races with libtool. - Fix handling of _OBJECTS variables for targets sharing source variables. - Check dependency mode for Java when AM_PROG_GCJ is used. New in 1.6.1: * automake --output-dir is deprecated * Many bug fixes, including: - Don't choke on AM_LDFLAGS definitions. - Clean libtool objects from subdirectories. - Allow configure variables with reserved suffix and unknown prefix (e.g. AC_SUBST(mumble_LDFLAGS) when 'mumble' is not a target). - Fix the definition of AUTOMAKE and ACLOCAL in configure. New in 1.6: * Autoconf 2.52 is required. * automake no longer run libtoolize. This is the job of autoreconf (from GNU Autoconf). * `dist' generates all the archive flavors, as did `dist-all'. * `dist-gzip' generates the Gzip tar file only. * Combining Automake Makefile conditionals no longer lead to a combinatorial explosion. Makefile.in's keep a reasonable size. * AM_FUNC_ERROR_AT_LINE, AM_FUNC_STRTOD, AM_FUNC_OBSTACK, AM_PTRDIFF_T are no longer shipped, since Autoconf 2.52 provides them (both as AM_ and AC_). * `#line' of Lex and Yacc files are properly set. * EXTRA_DIST can contain generated directories. * Support for dot-less extensions in suffix rules. * The part of the distcheck target that checks whether distclean actually cleans all built files has been moved in a separate target, distcleancheck, so it can be overridden easily. * `make distcheck' will pass additional options defined in $(DISTCHECK_CONFIGURE_FLAGS) to configure. * Fixed CDPATH portability problems, in particular for MacOS X. * Fixed handling of nobase_ targets. * Fixed support of implicit rules leading to .lo objects. * Fixed late inclusion of --add-missing files (e.g. depcomp) in DIST_COMMON * Added uninstall-hook target * `AC_INIT AM_INIT_AUTOMAKE(tarname,version)' is an obsolete construct. You can now use `AC_INIT(pkgname,version) AM_INIT_AUTOMAKE' instead. (Note that "pkgname" is not "tarname", see the manual for details.) It is also possible to pass a list of global Automake options as first argument to this new form of AM_INIT_AUTOMAKE. * Compiler-based assembler is now called `CCAS'; people expected `AS' to be a real assembler. * AM_INIT_AUTOMAKE will set STRIP itself when it needs it. Adding AC_CHECK_TOOL([STRIP], [strip]) manually is no longer required. * aclocal and automake are also installed with the version number appended, and some of the install directory names have changed. This lets you have multiple versions installed simultaneously. * Support for parsers and lexers in subdirectories. New in 1.5: * Support for `configure.ac'. * Support for `else COND', `endif COND' and negated conditions `!COND'. * `make dist-all' is much faster. * Allows '@' AC_SUBSTs in macro names. * Faster AM_INIT_AUTOMAKE (requires update of `missing' script) * User-side dependency tracking. Developers no longer need GNU make * Python support * Uses DIST_SUBDIRS in some situations when SUBDIRS is conditional * Most files are correctly handled if they appear in subdirs For instance, a _DATA file can appear in a subdir * GNU tar is no longer required for `make dist' * Added support for `dist_' and `nodist_' prefixes * Added support for `nobase_' prefix * Compiled Java support * Support for per-executable and per-library compilation flags * Many bug fixes New in 1.4: * Added support for the Fortran 77 programming language. * Re-indexed the Automake Texinfo manual. * Added `AM_FOOFLAGS' variable for each compiler invocation; e.g. AM_CFLAGS can be used in Makefile.am to set C compiler flags * Support for latest autoconf, including support for objext * Can now put `.' in SUBDIRS to control build order * `include' command and `+=' support for macro assignment * Dependency tracking no long susceptible to deleted header file problem * Maintainer mode now a conditional. @MAINT@ is now an anachronism. * Bug fixes New in 1.3: * Bug fixes * Better Cygwin32 support * Support for suffix rules with _SOURCES variables * New options `readme-alpha' and `check-news'; Gnits mode sets these * @LEXLIB@ no longer required when lex source seen Lex support in `missing', and new lex macro. Update your missing script. * Built-in support for assembly * aclocal gives error if `AM_' macro not found * Passed YFLAGS, not YACCFLAGS, to yacc * AM_PROG_CC_STDC does not have to come before AC_PROG_CPP * Dependencies computed as a side effect of compilation * Preliminary support for Java * DESTDIR support at "make install" time * Improved ansi2knr support; you must use the latest ansi2knr.c (included) New in 1.2: * Bug fixes * Better DejaGnu support * Added no-installinfo option * Added Emacs Lisp support * Added --no-force option * Included `aclocal' program * Automake will now generate rules to regenerate aclocal.m4, if appropriate * Now uses `AM_' macro names everywhere * ansi2knr option can have directory prefix (eg `../lib/ansi2knr') ansi2knr now works correctly on K&R sources * Better C++, yacc, lex support * Will compute _DEPENDENCIES variables automatically if not supplied * Will interpolate $(...) and ${...} when examining contents of a variable * .deps files now in build directory, not source directory; dependency handling generally rewritten * DATA, MANS and BUILT_SOURCES no longer included in distribution * can now put config.h into a subdir * Added dist-all target * Support for install-info program (see texinfo 3.9) * Support for "yacc -d" * configure substitutions are automatically discovered and included in generated Makefile.in * Special --cygnus mode * OMIT_DEPENDENCIES can now hold list of dependencies to be omitted when making distribution. Some dependencies are auto-ignored. * Changed how libraries are specified in _LIBRARIES variable * Full libtool support, from Gord Matzigkeit * No longer have to explicitly touch stamp-h when using AC_CONFIG_HEADER; AM_CONFIG_HEADER handles it automatically * Texinfo output files no longer need .info extension * Added `missing' support * Cygwin32 support * Conditionals in Makefile.am, from Ian Taylor New in 1.0: * Bug fixes * distcheck target runs install and installcheck targets * Added preliminary support for DejaGnu. New in 0.33: * More bug fixes * More checking * More libtool fixes from Gord Matzigkeit; libtool support is still preliminary however * Added support for jm_MAINTAINER_MODE * dist-zip support * New "distcheck" target New in 0.32: * Many bug fixes * mkinstalldirs and mdate-sh now appear in directory specified by AC_CONFIG_AUX_DIR. * Removed DIST_SUBDIRS, DIST_OTHER * AC_ARG_PROGRAM only required when an actual program exists * dist-hook target now run before distribution packaged up; idea from Dieter Baron. Other hooks exist, too. * Preliminary (unfinished) support for libtool * Added short option names. * Better "dist" support when gluing together multiple packages New in 0.31: * Bug fixes * Documentation updates (many from François Pinard) * strictness `normal' now renamed to `foreign' * Renamed --install-missing to --add-missing * Now handles AC_CONFIG_AUX_DIR * Now handles TESTS macro * DIST_OTHER renamed to EXTRA_DIST * DIST_SUBDIRS is deprecated * @ALLOCA@ and @LIBOBJS@ now work in _LDADD variables * Better error messages in many cases * Program names are canonicalized * Added "check" prefix; from Gord Matzigkeit New in 0.30: * Bug fixes * configure.in scanner knows about AC_PATH_XTRA, AC_OUTPUT ":" syntax * Beginnings of a test suite * Automatically adds -I options for $(srcdir), ".", and path to config.h * Doesn't print anything when running * Beginnings of MAINT_CHARSET support * Can specify version in AUTOMAKE_OPTIONS * Most errors recognizable by Emacs' M-x next-error * Added --verbose option * All "primary" variables now obsolete; use EXTRA_PRIMARY to supply configure-generated names * Required macros now distributed in aclocal.m4 * New documentation * --strictness=gnu is default New in 0.29: * Many bug fixes * More sophisticated configure.in scanning; now understands ALLOCA and LIBOBJS directly, handles AC_CONFIG_HEADER more precisely, etc. * TEXINFOS and MANS now obsolete; use info_TEXINFOS and man_MANS instead. * CONFIG_HEADER variable now obsolete * Can handle multiple Texinfo sources * Allow hierarchies deeper than 2. From Gord Matzigkeit. * HEADERS variable no longer needed; now can put .h files directly into foo_SOURCES variable. * Automake automatically rebuilds files listed in AC_OUTPUT. The corresponding ".in" files are included in the distribution. New in 0.28: * Added --gnu and --gnits options * More standards checking * Bug fixes * Cleaned up 'dist' targets * Added AUTOMAKE_OPTIONS variable and several options * Now scans configure.in to get some information (preliminary) New in 0.27: * Works with Perl 4 again New in 0.26: * Added --install-missing option. * Pretty-prints generated macros and rules * Comments in Makefile.am are placed more intelligently in Makefile.in * Generates .PHONY target * Rule or macro in Makefile.am now overrides contents of Automake file * Substantial cleanups from François Pinard New in 0.25: * Bug fixes. * Works with Perl 4 again. New in 0.24: * New uniform naming scheme. * --strictness option * Works with Perl 5 * '.c' files corresponding to '.y' or '.l' files are automatically distributed. * Many bug fixes and cleanups New in 0.23: * Allow objects to be conditionally included in libraries via lib_LIBADD. New in 0.22: * Bug fixes in 'clean' code. * Now generates 'installdirs' target. * man page installation reworked. * 'make dist' no longer re-creates all Makefile.in's. New in 0.21: * Reimplemented in Perl * Added --amdir option (for debugging) * Texinfo support cleaned up. * Automatic de-ANSI-fication cleaned up. * Cleaned up 'clean' targets. New in 0.20: * Automatic dependency tracking * More documentation * New variables DATA and PACKAGEDATA * SCRIPTS installed using $(INSTALL_SCRIPT) * No longer uses double-colon rules * Bug fixes * Changes in advance of internationalization ----- Copyright (C) 1995-2018 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 . COPYING000064400000043103152532470230005603 0ustar00 GNU GENERAL PUBLIC LICENSE Version 2, June 1991 Copyright (C) 1989, 1991 Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed. Preamble The licenses for most software are designed to take away your freedom to share and change it. By contrast, the GNU General Public License is intended to guarantee your freedom to share and change free software--to make sure the software is free for all its users. This General Public License applies to most of the Free Software Foundation's software and to any other program whose authors commit to using it. (Some other Free Software Foundation software is covered by the GNU Lesser General Public License instead.) You can apply it to your programs, too. When we speak of free software, we are referring to freedom, not price. Our General Public Licenses are designed to make sure that you have the freedom to distribute copies of free software (and charge for this service if you wish), that you receive source code or can get it if you want it, that you can change the software or use pieces of it in new free programs; and that you know you can do these things. To protect your rights, we need to make restrictions that forbid anyone to deny you these rights or to ask you to surrender the rights. These restrictions translate to certain responsibilities for you if you distribute copies of the software, or if you modify it. For example, if you distribute copies of such a program, whether gratis or for a fee, you must give the recipients all the rights that you have. You must make sure that they, too, receive or can get the source code. And you must show them these terms so they know their rights. We protect your rights with two steps: (1) copyright the software, and (2) offer you this license which gives you legal permission to copy, distribute and/or modify the software. Also, for each author's protection and ours, we want to make certain that everyone understands that there is no warranty for this free software. If the software is modified by someone else and passed on, we want its recipients to know that what they have is not the original, so that any problems introduced by others will not reflect on the original authors' reputations. Finally, any free program is threatened constantly by software patents. We wish to avoid the danger that redistributors of a free program will individually obtain patent licenses, in effect making the program proprietary. To prevent this, we have made it clear that any patent must be licensed for everyone's free use or not licensed at all. The precise terms and conditions for copying, distribution and modification follow. GNU GENERAL PUBLIC LICENSE TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION 0. This License applies to any program or other work which contains a notice placed by the copyright holder saying it may be distributed under the terms of this General Public License. The "Program", below, refers to any such program or work, and a "work based on the Program" means either the Program or any derivative work under copyright law: that is to say, a work containing the Program or a portion of it, either verbatim or with modifications and/or translated into another language. (Hereinafter, translation is included without limitation in the term "modification".) Each licensee is addressed as "you". Activities other than copying, distribution and modification are not covered by this License; they are outside its scope. The act of running the Program is not restricted, and the output from the Program is covered only if its contents constitute a work based on the Program (independent of having been made by running the Program). Whether that is true depends on what the Program does. 1. You may copy and distribute verbatim copies of the Program's source code as you receive it, in any medium, provided that you conspicuously and appropriately publish on each copy an appropriate copyright notice and disclaimer of warranty; keep intact all the notices that refer to this License and to the absence of any warranty; and give any other recipients of the Program a copy of this License along with the Program. You may charge a fee for the physical act of transferring a copy, and you may at your option offer warranty protection in exchange for a fee. 2. You may modify your copy or copies of the Program or any portion of it, thus forming a work based on the Program, and copy and distribute such modifications or work under the terms of Section 1 above, provided that you also meet all of these conditions: a) You must cause the modified files to carry prominent notices stating that you changed the files and the date of any change. b) You must cause any work that you distribute or publish, that in whole or in part contains or is derived from the Program or any part thereof, to be licensed as a whole at no charge to all third parties under the terms of this License. c) If the modified program normally reads commands interactively when run, you must cause it, when started running for such interactive use in the most ordinary way, to print or display an announcement including an appropriate copyright notice and a notice that there is no warranty (or else, saying that you provide a warranty) and that users may redistribute the program under these conditions, and telling the user how to view a copy of this License. (Exception: if the Program itself is interactive but does not normally print such an announcement, your work based on the Program is not required to print an announcement.) These requirements apply to the modified work as a whole. If identifiable sections of that work are not derived from the Program, and can be reasonably considered independent and separate works in themselves, then this License, and its terms, do not apply to those sections when you distribute them as separate works. But when you distribute the same sections as part of a whole which is a work based on the Program, the distribution of the whole must be on the terms of this License, whose permissions for other licensees extend to the entire whole, and thus to each and every part regardless of who wrote it. Thus, it is not the intent of this section to claim rights or contest your rights to work written entirely by you; rather, the intent is to exercise the right to control the distribution of derivative or collective works based on the Program. In addition, mere aggregation of another work not based on the Program with the Program (or with a work based on the Program) on a volume of a storage or distribution medium does not bring the other work under the scope of this License. 3. You may copy and distribute the Program (or a work based on it, under Section 2) in object code or executable form under the terms of Sections 1 and 2 above provided that you also do one of the following: a) Accompany it with the complete corresponding machine-readable source code, which must be distributed under the terms of Sections 1 and 2 above on a medium customarily used for software interchange; or, b) Accompany it with a written offer, valid for at least three years, to give any third party, for a charge no more than your cost of physically performing source distribution, a complete machine-readable copy of the corresponding source code, to be distributed under the terms of Sections 1 and 2 above on a medium customarily used for software interchange; or, c) Accompany it with the information you received as to the offer to distribute corresponding source code. (This alternative is allowed only for noncommercial distribution and only if you received the program in object code or executable form with such an offer, in accord with Subsection b above.) The source code for a work means the preferred form of the work for making modifications to it. For an executable work, complete source code means all the source code for all modules it contains, plus any associated interface definition files, plus the scripts used to control compilation and installation of the executable. However, as a special exception, the source code distributed need not include anything that is normally distributed (in either source or binary form) with the major components (compiler, kernel, and so on) of the operating system on which the executable runs, unless that component itself accompanies the executable. If distribution of executable or object code is made by offering access to copy from a designated place, then offering equivalent access to copy the source code from the same place counts as distribution of the source code, even though third parties are not compelled to copy the source along with the object code. 4. You may not copy, modify, sublicense, or distribute the Program except as expressly provided under this License. Any attempt otherwise to copy, modify, sublicense or distribute the Program is void, and will automatically terminate your rights under this License. However, parties who have received copies, or rights, from you under this License will not have their licenses terminated so long as such parties remain in full compliance. 5. You are not required to accept this License, since you have not signed it. However, nothing else grants you permission to modify or distribute the Program or its derivative works. These actions are prohibited by law if you do not accept this License. Therefore, by modifying or distributing the Program (or any work based on the Program), you indicate your acceptance of this License to do so, and all its terms and conditions for copying, distributing or modifying the Program or works based on it. 6. Each time you redistribute the Program (or any work based on the Program), the recipient automatically receives a license from the original licensor to copy, distribute or modify the Program subject to these terms and conditions. You may not impose any further restrictions on the recipients' exercise of the rights granted herein. You are not responsible for enforcing compliance by third parties to this License. 7. If, as a consequence of a court judgment or allegation of patent infringement or for any other reason (not limited to patent issues), conditions are imposed on you (whether by court order, agreement or otherwise) that contradict the conditions of this License, they do not excuse you from the conditions of this License. If you cannot distribute so as to satisfy simultaneously your obligations under this License and any other pertinent obligations, then as a consequence you may not distribute the Program at all. For example, if a patent license would not permit royalty-free redistribution of the Program by all those who receive copies directly or indirectly through you, then the only way you could satisfy both it and this License would be to refrain entirely from distribution of the Program. If any portion of this section is held invalid or unenforceable under any particular circumstance, the balance of the section is intended to apply and the section as a whole is intended to apply in other circumstances. It is not the purpose of this section to induce you to infringe any patents or other property right claims or to contest validity of any such claims; this section has the sole purpose of protecting the integrity of the free software distribution system, which is implemented by public license practices. Many people have made generous contributions to the wide range of software distributed through that system in reliance on consistent application of that system; it is up to the author/donor to decide if he or she is willing to distribute software through any other system and a licensee cannot impose that choice. This section is intended to make thoroughly clear what is believed to be a consequence of the rest of this License. 8. If the distribution and/or use of the Program is restricted in certain countries either by patents or by copyrighted interfaces, the original copyright holder who places the Program under this License may add an explicit geographical distribution limitation excluding those countries, so that distribution is permitted only in or among countries not thus excluded. In such case, this License incorporates the limitation as if written in the body of this License. 9. The Free Software Foundation may publish revised and/or new versions of the General Public License from time to time. Such new versions will be similar in spirit to the present version, but may differ in detail to address new problems or concerns. Each version is given a distinguishing version number. If the Program specifies a version number of this License which applies to it and "any later version", you have the option of following the terms and conditions either of that version or of any later version published by the Free Software Foundation. If the Program does not specify a version number of this License, you may choose any version ever published by the Free Software Foundation. 10. If you wish to incorporate parts of the Program into other free programs whose distribution conditions are different, write to the author to ask for permission. For software which is copyrighted by the Free Software Foundation, write to the Free Software Foundation; we sometimes make exceptions for this. Our decision will be guided by the two goals of preserving the free status of all derivatives of our free software and of promoting the sharing and reuse of software generally. NO WARRANTY 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. END OF TERMS AND CONDITIONS How to Apply These Terms to Your New Programs If you develop a new program, and you want it to be of the greatest possible use to the public, the best way to achieve this is to make it free software which everyone can redistribute and change under these terms. To do so, attach the following notices to the program. It is safest to attach them to the start of each source file to most effectively convey the exclusion of warranty; and each file should have at least the "copyright" line and a pointer to where the full notice is found. Copyright (C) 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 of the License, 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, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. Also add information on how to contact you by electronic and paper mail. If the program is interactive, make it output a short notice like this when it starts in an interactive mode: Gnomovision version 69, Copyright (C) year name of author Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. This is free software, and you are welcome to redistribute it under certain conditions; type `show c' for details. The hypothetical commands `show w' and `show c' should show the appropriate parts of the General Public License. Of course, the commands you use may be called something other than `show w' and `show c'; they could even be mouse-clicks or menu items--whatever suits your program. You should also get your employer (if you work as a programmer) or your school, if any, to sign a "copyright disclaimer" for the program, if necessary. Here is a sample; alter the names: Yoyodyne, Inc., hereby disclaims all copyright interest in the program `Gnomovision' (which makes passes at compilers) written by James Hacker. , 1 April 1989 Ty Coon, President of Vice This General Public License does not permit incorporating your program into proprietary programs. If your program is a subroutine library, you may consider it more useful to permit linking proprietary applications with the library. If this is what you want to do, use the GNU Lesser General Public License instead of this License.