I noticed today that while Mac OS 10.6 (specifically, 10.6.2) comes with automake and autoconf, the versions are a little bit dated. Normally I wouldn’t care, but I ran into an issue when trying to generate a portable distribution using those tools on my mac, and then configure, compile, and install the result on a linux box. What I discovered is that the version of autoconf and automake on OSX can generate a “configure” file which doesn’t work as expected on linux (at least one with gcc 4.3) — specifically, the step “checking for working mktime…” can hang and eventually return “no”, when that is not the correct result. Apparently you need at least autoconf 2.62 in order to avoid this bug.

I figured as long as I was updating autoconf i’d update automake, m4, and libtool as well. Here’s the quick script (as always, I assume you prefer the installation prefix /usr/local as i do). It’s nothing too fancy, but the sequence of the installs is important:

curl -O http://mirrors.kernel.org/gnu/m4/m4-1.4.13.tar.gz
tar -xzvf m4-1.4.13.tar.gz
cd m4-1.4.13
./configure --prefix=/usr/local
make
sudo make install
cd ..
curl -O http://mirrors.kernel.org/gnu/autoconf/autoconf-2.65.tar.gz
tar -xzvf autoconf-2.65.tar.gz
cd autoconf-2.65
./configure --prefix=/usr/local # ironic, isn't it?
make
sudo make install
cd ..
# here you might want to restart your terminal session, to ensure the new autoconf is picked up and used in the rest of the script
curl -O http://mirrors.kernel.org/gnu/automake/automake-1.11.tar.gz
tar xzvf automake-1.11.tar.gz
cd automake-1.11
./configure --prefix=/usr/local
make
sudo make install
cd ..
curl -O http://mirrors.kernel.org/gnu/libtool/libtool-2.2.6b.tar.gz
tar xzvf libtool-2.2.6b.tar.gz
cd libtool-2.2.6b
./configure --prefix=/usr/local
make
sudo make install
and now, (assuming you have /usr/local in your path), when you use autotools your distribution should be correctly portable (at least in regards to this mktime bug).

MAC下安装automake autoconf工具的更多相关文章

  1. Mac下安装Iterm2终端工具

    一般Iterm2是结合oh-my-zsh一起使用,但是如果不喜欢zsh也可以单独使用.Iterm2有个亮点就是可以通过快捷键快速启动. 安装步骤: 1.下载: http://www.iterm2.co ...

  2. Mac 下安装Fiddler抓包工具

    需求 我们都知道在Mac电脑下面有一个非常好的抓包工具:Charles.但是这个只能抓代理的数据包.但是有时候想要调试本地网卡的数据库 Charles 就没办法了.就想到了在windows下面的一个F ...

  3. MAC下安装Fiddler抓包工具

    需求 我们都知道在Mac电脑下面有一个非常好的抓包工具:Charles.但是这个只能抓代理的数据包.但是有时候想要调试本地网卡的数据库 Charles 就没办法了.就想到了在windows下面的一个F ...

  4. Mac 下安装Jenkins

    Mac 下安装Jenkins 开始 Jenkins是一个基于Java开发的一种持续集成工具,用于建工持续重复的工作,功能包括: 持续的软件版本发布/测试项目 监控外部调用执行的工作. 近期打算搭建自动 ...

  5. Mac下安装UPnP Inspector

    由于工作中需要用到UPnP Inspector这个工具,而这个工具在windows下安装非常简单,在Mac下安装却很麻烦,在此记录安装流程. 这个工具依赖于两个其他的库:Coherence(一个DLN ...

  6. Mac下安装HBase及详解

    Mac下安装HBase及详解 1. 千篇一律的HBase简介 HBase是Hadoop的数据库, 而Hive数据库的管理工具, HBase具有分布式, 可扩展及面向列存储的特点(基于谷歌BigTabl ...

  7. 个人建站&mac下安装hexo

    title: 个人建站&mac下安装hexo date: 2018-04-18 16:34:02 tags: [mac,blog,个人建站,markdown] --- 这两天使用了markdo ...

  8. mac下安装安卓开发环境

    对于做ios的人来说,安装安卓开发环境,最好是在mac下安装了,我的mac是10.8.2,64位系统的 安卓开发环境需要下面几个东西: 1 jdk(mac下已经默认有了,可以在命令提示符下输入java ...

  9. MAC下安装Homebrew 和 @权限的问题

    MAC下安装Homebrew和 @权限的问题 1.Homebrew简介: Homebrew是一个包管理器,用于安装Apple没有预装但你需要的UNIX工具.(比如著名的wget). Homebrew会 ...

随机推荐

  1. java实现商品实时录入

    //代表各的主页面 package com.gui; import java.awt.*; import javax.swing.*; import java.awt.event.*; import ...

  2. Ubuntu系统中初次下载Android源码的一点经验

    这阵子突然心血来潮,想看看android的源代码,所以这一两天晚上都在折腾下载这个东西. (其实在GitHub上可以在线看的,不过不太喜欢在线看,URL附上 https://github.com/an ...

  3. poj 2485 (kruskal算法)

    /*kruskal算法*/ #include <iostream> //#include <fstream> #include <algorithm> using ...

  4. icon 图标下载

    1. http://www.easyicon.net/ 2.http://www.iconpng.com/

  5. Oracle 列操作(增加列,修改列,删除列)

    1.增加一列: Alter table 表名 add 列名 varchar2(10); 2.修改一列: Alter table 表名 modify 列名 varchar2(20); 3.删除一列: A ...

  6. 记一次Debian下PHP环境的搭建(nginx+mariadb+PHP)!

    顺序是先安装nginx,然后安装mariadb,最后安装PHP.系统用的是debian7 安装nginx sudo apt-get install nginx 我这里用的是稳定的源,没用测试的源,所以 ...

  7. Sql Server 日期格式化

    select CONVERT(date,myDtae,23),ID from myFirstTable; http://www.cnblogs.com/hantianwei/archive/2009/ ...

  8. Linux学习-文件和目录管理 

    Linux文件和目录管理  文件系统架构  1.Linux文件系统具有层级性     1)文件或者目录起始于根目录"/"成为树状结构    2)最顶层由/开始   2 ...

  9. lua中string常用api

    local a="abcdefgbbb" string.sub(a,1,3) 字符串截取 返回截取的字符串           print(string.sub(a,1,3))   ...

  10. 面试题-Java基础-面向对象

    1.面向对象软件开发的优点有哪些? 代码开发模块化,更易维护和修改.代码复用.增强代码的可靠性和灵活性.增加代码的可理解性.面向对象编程有很多重要的特性,比如:封装,继承,多态和抽象.下面的章节我们会 ...