diff options
author | Diego Elio Pettenò <flameeyes@gentoo.org> | 2006-04-07 16:49:32 +0000 |
---|---|---|
committer | Diego Elio Pettenò <flameeyes@gentoo.org> | 2006-04-07 16:49:32 +0000 |
commit | 696f701cc9f62368326aa8cf005052cf0aa652e0 (patch) | |
tree | e441fbe394ebf88f3b90e1760c0d35d905df223a /eclass/autotools.eclass | |
parent | ppc stable, bug #128317 (diff) | |
download | gentoo-2-696f701cc9f62368326aa8cf005052cf0aa652e0.tar.gz gentoo-2-696f701cc9f62368326aa8cf005052cf0aa652e0.tar.bz2 gentoo-2-696f701cc9f62368326aa8cf005052cf0aa652e0.zip |
Allow eautomake to be called by itself, but call eautoreconf if the Makefile.in comes from a different version.
Diffstat (limited to 'eclass/autotools.eclass')
-rw-r--r-- | eclass/autotools.eclass | 20 |
1 files changed, 18 insertions, 2 deletions
diff --git a/eclass/autotools.eclass b/eclass/autotools.eclass index 6928f4ad5369..a9d90ed0ebed 100644 --- a/eclass/autotools.eclass +++ b/eclass/autotools.eclass @@ -1,6 +1,6 @@ # Copyright 1999-2005 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/eclass/autotools.eclass,v 1.34 2006/03/28 08:11:46 flameeyes Exp $ +# $Header: /var/cvsroot/gentoo-x86/eclass/autotools.eclass,v 1.35 2006/04/07 16:49:32 flameeyes Exp $ # # Author: Diego Pettenò <flameeyes@gentoo.org> # Enhancements: Martin Schlemmer <azarah@gentoo.org> @@ -65,7 +65,7 @@ eautoreconf() { _elibtoolize --copy --force eautoconf eautoheader - eautomake ${AM_OPTS} + FROM_EAUTORECONF="yes" eautomake ${AM_OPTS} # Normally run by econf() [[ ${AT_GNUCONF_UPDATE} == "yes" ]] && gnuconfig_update @@ -147,6 +147,22 @@ eautomake() { [[ -f Makefile.am ]] || return 0 + if [[ -z ${FROM_EAUTORECONF} && -f Makefile.in ]]; then + local used_automake + local installed_automake + + installed_automake=$(automake --version | head -n 1 | \ + sed -e 's:.*(GNU automake) ::') + used_automake=$(head -n 1 < Makefile.in | \ + sed -e 's:.*by automake \(.*\) from .*:\1:') + + if [[ ${installed_automake} != ${used_automake} ]]; then + einfo "Automake used for the package (${used_automake}) differs from" + einfo "the installed version (${installed_automake})." + eautoreconf + fi + fi + [[ -f INSTALL && -f AUTHORS && -f ChangeLog && -f NEWS ]] \ || extra_opts="${extra_opts} --foreign" |