如何获取最新版的automake?

这与https://askubuntu.com/questions/453660/warning-automake-1-11-is-probably-too-old非常相似。
在Ubuntu 12.04 LTS上,我遇到了以下错误信息:
WARNING: 'automake-1.14' is missing on your system.
         You should only need it if you modified 'Makefile.am' or
         'configure.ac' or m4 files included by 'configure.ac'.
         The 'automake' program is part of the GNU Automake package:
         <http://www.gnu.org/software/automake>
         It also requires GNU Autoconf, GNU m4 and Perl in order to run:
         <http://www.gnu.org/software/autoconf>
         <http://www.gnu.org/software/m4/>
         <http://www.perl.org/>
make: *** [../Makefile.in] Error 1

我尝试使用apt-get安装最新的automake,但它声称我已经是最新版本。然而,我当前的automake版本是1.11,显然我并不是最新版本。我希望保留系统上的automake1.11,以免破坏依赖于它的任何东西。
我该如何获取最新版本以解决这个错误?
3个回答

使用

sudo apt-get autoremove automake
sudo apt-get install automake

这应该可以让您升级到版本1.14.1,这是我的系统14.04的结果。

1我没有提到我想保留现有的automake1.11,这样就不会破坏当前依赖于该特定版本的任何内容。我已经编辑了问题。 - s g


如果问题仍然存在,你可以使用这个来自git的脚本,或者在这里找到它。
#!/bin/bash


# run as root only
if [[ $EUID -ne 0 ]] ; then
    echo -e "\e[1;39m[   \e[31mError\e[39m   ] need root access to run this script\e[0;39m"
    exit 1
fi

function install_automake() {
    [ $# -eq 0 ] && { run_error "Usage: install_automake <version>"; exit; }
    local VERSION=${1}
    wget ftp://ftp.gnu.org/gnu/automake/automake-${VERSION}.tar.gz &> /dev/null
    if [ -f "automake-${VERSION}.tar.gz" ]; then
            tar -xzf automake-${VERSION}.tar.gz
            cd automake-${VERSION}/
            ./configure
            make && make install
            echo -e "\e[1;39m[   \e[1;32mOK\e[39m   ] automake-${VERSION} installed\e[0;39m"

        else
            echo -e "\e[1;39m[   \e[31mError\e[39m   ] cannot fetch file from ftp://ftp.gnu.org/gnu/automake/ \e[0;39m"
            exit 1
    fi
}
install_automake 1.15