aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Formula/gnu-which.rb
blob: d6e090cd65b4ea6f71df743d1de1c8932af8c135 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
require 'formula'

class GnuWhich < Formula
  url 'http://ftpmirror.gnu.org/which/which-2.20.tar.gz'
  homepage 'http://carlo17.home.xs4all.nl/which/'
  md5 '95be0501a466e515422cde4af46b2744'

  def options
    [['--default-names', "Do NOT prepend 'g' to the binary; will override system utils."]]
  end

  def install
    args = ["--prefix=#{prefix}", "--disable-dependency-tracking"]
    args << "--program-prefix=g" unless ARGV.include? '--default-names'

    system "./configure", *args
    system "make install"
  end
end