mxcl/homebrew — Issue #10618: automake / aclocal looking into /usr/share/aclocal
Author: gpakosz
Created: 2012-03-01 18:02:45+00:00
State: open

OS: 10.6.8
Xcode: 3.2.6

I decided to stop using Macports so I installed homebrew's `autoconf`, `automake` and `libtool` formula. But it seems that `aclocal` is looking into `/usr/share/local` instead of `/usr/local/share/aclocal` and in my case fails to find the proper `libtool` version.

Steps:
1. `brew update`
2. `brew install autoconf automake libtool`
3. `brew link autoconf automake libtool`
4. build your Autotools based project:

autoreconf: Entering directory `/Users/guardian/foo'
autoreconf: configure.ac: not using Gettext
autoreconf: running: aclocal --force -I m4
configure.ac:45: error: Libtool version 2.2.6 or higher is required
/usr/share/aclocal/libtool.m4:51: LT_PREREQ is expanded from...
configure.ac:45: the top level
autom4te: /usr/bin/m4 failed with exit status: 63
aclocal: /usr/local/Cellar/autoconf/2.68/bin/autom4te failed with exit status: 63
autoreconf: aclocal failed with exit status: 63

offending line: `/usr/share/aclocal/libtool.m4:51: LT_PREREQ is expanded from...`

workaround: move away `/usr/share/aclocal` for instance by renaming it to `/usr/share/aclocal.disabled`