2012-02-27 00:41:17 +00:00
|
|
|
require 'formula'
|
|
|
|
|
|
|
|
# Xcode 4.3 provides the Apple libtool
|
|
|
|
# This is not the same, but as a result we must install these as glibtool etc.
|
|
|
|
|
|
|
|
class Libtool < Formula
|
|
|
|
homepage 'http://www.gnu.org/software/libtool/'
|
2012-03-01 06:45:25 +00:00
|
|
|
url 'http://ftpmirror.gnu.org/libtool/libtool-2.4.2.tar.gz'
|
|
|
|
mirror 'http://ftp.gnu.org/gnu/libtool/libtool-2.4.2.tar.gz'
|
|
|
|
sha1 '22b71a8b5ce3ad86e1094e7285981cae10e6ff88'
|
2012-02-27 00:41:17 +00:00
|
|
|
|
2012-02-27 20:08:58 +00:00
|
|
|
if MacOS.xcode_version.to_f < 4.3 or File.file? "/usr/bin/glibtoolize"
|
|
|
|
keg_only "Xcode (up to and including 4.2) provides (a rather old) Libtool."
|
2012-02-27 00:41:17 +00:00
|
|
|
end
|
|
|
|
|
|
|
|
def install
|
2012-02-28 17:34:31 +00:00
|
|
|
system "./configure", "--disable-dependency-tracking",
|
|
|
|
"--prefix=#{prefix}",
|
|
|
|
"--program-prefix=g",
|
2012-02-27 00:41:17 +00:00
|
|
|
"--enable-ltdl-install"
|
|
|
|
system "make install"
|
|
|
|
end
|
|
|
|
|
|
|
|
def caveats; <<-EOS.undent
|
|
|
|
In order to prevent conflicts with Apple's own libtool we have prepended a "g"
|
|
|
|
so, you have instead: glibtool and glibtoolize.
|
|
|
|
EOS
|
|
|
|
end
|
|
|
|
|
|
|
|
def test
|
2012-02-27 20:08:58 +00:00
|
|
|
system "#{bin}/glibtoolize --version"
|
2012-02-27 00:41:17 +00:00
|
|
|
end
|
|
|
|
end
|