superenv fix for broken 10.8 apr-1-config

serf requires you to explicitly tell it where to find the supertool because otherwise it has a hardcoded /usr/bin/apr-1-config (:P), ctail however is sensible and searches the PATH so now it's as though we do nothing special in that formula. Nice.
This commit is contained in:
Max Howell 2012-08-31 11:42:01 -04:00
parent c4e0264109
commit a2dbc590d1
2 changed files with 6 additions and 20 deletions

View file

@ -9,16 +9,6 @@ class Ctail < Formula
depends_on :libtool
def install
if MacOS.mountain_lion?
# Fixes a bad path returned by `apr-1-config --cpp` on ML.
# https://github.com/mxcl/homebrew/issues/13586
ENV['CPP'] = "#{ENV.cc} -E"
# Use HB libtool not the one from apr that also has a bad path.
ENV['APR_LIBTOOL'] = 'glibtool'
# Especially for Xcode-only, the apr hearders are needed by glibtool
ENV.append 'CPPFLAGS', "-I#{MacOS.sdk_path}/usr/include/apr-1"
end
system "./configure", "--prefix=#{prefix}", "--disable-debug"
system 'make'
system 'make install'

View file

@ -9,20 +9,16 @@ class Serf < Formula
depends_on :libtool
def apr_bin
superbin or "/usr/bin"
end
def install
ENV.universal_binary if build.universal?
if MacOS.mountain_lion?
# Fixes a bad path returned by `apr-1-config --cpp` on ML.
# https://github.com/mxcl/homebrew/issues/13586
ENV['CPP'] = "#{ENV.cc} -E"
# Use HB libtool not the one from apr that also has a bad path.
ENV['APR_LIBTOOL'] = 'glibtool'
# Especially for Xcode-only, the apr hearders are needed by glibtool
ENV.append 'CPPFLAGS', "-I#{MacOS.sdk_path}/usr/include/apr-1"
end
system "./configure", "--disable-debug",
"--disable-dependency-tracking",
"--prefix=#{prefix}"
"--prefix=#{prefix}",
"--with-apr=#{apr_bin}"
system "make install"
end
end