libxml2: Added --HEAD and fixed Python bindings
- Python 2.7+ is needed for current version. A fix to build with Python 2.6 has been recently added to the master: https://git.gnome.org/browse/libxml2/commit/?id=722923bc9b788f028e4221c77138fc66735a3113 - So for system python on 10.6, you'll have to use the --HEAD for now. - Fix audit not detecting the `if python` after the def caveats.master
parent
8afdfb1d52
commit
cddb186fdb
|
@ -6,11 +6,21 @@ class Libxml2 < Formula
|
|||
mirror 'http://xmlsoft.org/sources/libxml2-2.9.1.tar.gz'
|
||||
sha256 'fd3c64cb66f2c4ea27e934d275904d92cec494a8e8405613780cbc8a71680fdb'
|
||||
|
||||
head 'https://git.gnome.org/browse/libxml2', :using => :git
|
||||
|
||||
keg_only :provided_by_osx
|
||||
|
||||
option :universal
|
||||
|
||||
depends_on :python => :recommended
|
||||
if build.head?
|
||||
depends_on :python => :recommended # satisfied by Python 2.6+
|
||||
depends_on :autoconf
|
||||
depends_on :automake
|
||||
depends_on :libtool
|
||||
else
|
||||
# 2.9.1 cannot build with Python 2.6: https://github.com/mxcl/homebrew/issues/20249
|
||||
depends_on PythonInstalled.new("2.7") => :recommended
|
||||
end
|
||||
|
||||
fails_with :llvm do
|
||||
build 2326
|
||||
|
@ -19,6 +29,10 @@ class Libxml2 < Formula
|
|||
|
||||
def install
|
||||
ENV.universal_binary if build.universal?
|
||||
if build.head?
|
||||
inreplace 'autogen.sh', 'libtoolize', 'glibtoolize'
|
||||
system './autogen.sh'
|
||||
end
|
||||
|
||||
system "./configure", "--disable-dependency-tracking",
|
||||
"--prefix=#{prefix}",
|
||||
|
@ -47,13 +61,15 @@ class Libxml2 < Formula
|
|||
end
|
||||
|
||||
def caveats
|
||||
<<-EOS.undent
|
||||
Even if this formula is keg_only, the python bindings have been linked
|
||||
into the global site-packages for your convenience.
|
||||
#{python.global_site_packages}
|
||||
if build.with? 'python'
|
||||
<<-EOS.undent
|
||||
Even if this formula is keg_only, the python bindings have been linked
|
||||
into the global site-packages for your convenience.
|
||||
#{python.global_site_packages}
|
||||
|
||||
EOS
|
||||
end if build.with? 'python'
|
||||
end
|
||||
end
|
||||
|
||||
def test
|
||||
if build.with? 'python'
|
||||
|
|
Loading…
Reference in New Issue