2009-11-02 03:00:35 +00:00
|
|
|
require 'formula'
|
|
|
|
|
2011-03-10 05:11:03 +00:00
|
|
|
class Libxml2 < Formula
|
2011-01-28 22:55:53 +00:00
|
|
|
url 'ftp://xmlsoft.org/libxml2/libxml2-2.7.8.tar.gz'
|
2009-11-02 03:00:35 +00:00
|
|
|
homepage 'http://xmlsoft.org'
|
2011-01-28 22:55:53 +00:00
|
|
|
md5 '8127a65e8c3b08856093099b52599c86'
|
2009-11-02 03:00:35 +00:00
|
|
|
|
2010-04-07 05:58:35 +00:00
|
|
|
keg_only :provided_by_osx
|
2009-11-02 03:00:35 +00:00
|
|
|
|
2011-03-21 21:24:22 +00:00
|
|
|
fails_with_llvm "Undefined symbols when linking", :build => "2326"
|
|
|
|
|
2010-11-02 06:01:25 +00:00
|
|
|
def options
|
2012-02-04 06:17:37 +00:00
|
|
|
[
|
|
|
|
['--with-python', 'Compile the libxml2 Python 2.x modules'],
|
|
|
|
['--universal', 'Build a universal binary.']
|
|
|
|
]
|
2010-11-02 06:01:25 +00:00
|
|
|
end
|
|
|
|
|
2009-11-02 03:00:35 +00:00
|
|
|
def install
|
2012-02-04 06:17:37 +00:00
|
|
|
ENV.universal_binary if ARGV.build_universal?
|
2010-11-02 06:01:25 +00:00
|
|
|
|
2012-02-04 06:17:37 +00:00
|
|
|
args = ["--disable-dependency-tracking", "--prefix=#{prefix}"]
|
2010-11-02 06:01:25 +00:00
|
|
|
if ARGV.include? '--with-python'
|
|
|
|
python_prefix=`python-config --prefix`
|
|
|
|
ohai "Installing Python module to #{python_prefix}"
|
|
|
|
args << "--with-python=#{python_prefix}"
|
|
|
|
end
|
|
|
|
|
|
|
|
system "./configure", *args
|
2009-11-02 03:00:35 +00:00
|
|
|
system "make"
|
|
|
|
ENV.j1
|
|
|
|
system "make install"
|
|
|
|
end
|
|
|
|
end
|