automake: Upgrading
1
1 26 Upgrading a Package to a Newer Automake Version
1 **************************************************
1
1 Automake maintains three kind of files in a package.
1
1 • ‘aclocal.m4’
1 • ‘Makefile.in’s
1 • auxiliary tools like ‘install-sh’ or ‘py-compile’
1
1 ‘aclocal.m4’ is generated by ‘aclocal’ and contains some
1 Automake-supplied M4 macros. Auxiliary tools are installed by ‘automake
1 --add-missing’ when needed. ‘Makefile.in’s are built from ‘Makefile.am’
1 by ‘automake’, and rely on the definitions of the M4 macros put in
1 ‘aclocal.m4’ as well as the behavior of the auxiliary tools installed.
1
1 Because all of these files are closely related, it is important to
1 regenerate all of them when upgrading to a newer Automake release. The
1 usual way to do that is
1
1 aclocal # with any option needed (such a -I m4)
1 autoconf
1 automake --add-missing --force-missing
1
1 or more conveniently:
1
1 autoreconf -vfi
1
1 The use of ‘--force-missing’ ensures that auxiliary tools will be
1 overridden by new versions (⇒automake Invocation).
1
1 It is important to regenerate all of these files each time Automake
1 is upgraded, even between bug fixes releases. For instance, it is not
1 unusual for a bug fix to involve changes to both the rules generated in
1 ‘Makefile.in’ and the supporting M4 macros copied to ‘aclocal.m4’.
1
1 Presently ‘automake’ is able to diagnose situations where
1 ‘aclocal.m4’ has been generated with another version of ‘aclocal’.
1 However it never checks whether auxiliary scripts are up-to-date. In
1 other words, ‘automake’ will tell you when ‘aclocal’ needs to be rerun,
1 but it will never diagnose a missing ‘--force-missing’.
1
1 Before upgrading to a new major release, it is a good idea to read
1 the file ‘NEWS’. This file lists all changes between releases: new
1 features, obsolete constructs, known incompatibilities, and workarounds.
1