homebrew-core/Formula/the_silver_searcher.rb
Austin Ziegler c19c2baa1c the_silver_searcher: don't assume /usr/local
This formula assumes that the aclocal include directory is
/usr/local/share/aclocal; this is not true if you have installed
homebrew into a different location (as I have done).

Using HOMEBREW_PREFIX instead of assuming /usr/local is the correct fix.

Closes Homebrew/homebrew#14987.

Signed-off-by: Misty De Meo <mistydemeo@gmail.com>
2012-09-17 13:01:50 -05:00

33 lines
877 B
Ruby

require 'formula'
class TheSilverSearcher < Formula
homepage 'https://github.com/ggreer/the_silver_searcher'
url 'https://github.com/ggreer/the_silver_searcher/tarball/0.7.2'
sha1 '48c33fa25ded5c446c0fca8d32b10872aee38e70'
head 'https://github.com/ggreer/the_silver_searcher.git'
depends_on :automake
depends_on :autoconf
depends_on 'pkg-config' => :build
depends_on 'pcre'
def install
# Stable tarball does not include pre-generated configure script
system "aclocal -I #{HOMEBREW_PREFIX}/share/aclocal"
system "autoconf"
system "autoheader"
system "automake --add-missing"
system "./configure", "--disable-debug",
"--disable-dependency-tracking",
"--prefix=#{prefix}"
system "make"
system "make install"
end
def test
system "#{bin}/ag", "--version"
end
end