homebrew-core/Formula/valgrind.rb

46 lines
1.1 KiB
Ruby

class Valgrind < Formula
desc "Dynamic analysis tools (memory, debug, profiling)"
homepage "https://www.valgrind.org/"
url "https://sourceware.org/pub/valgrind/valgrind-3.19.0.tar.bz2"
sha256 "dd5e34486f1a483ff7be7300cc16b4d6b24690987877c3278d797534d6738f02"
license "GPL-2.0-or-later"
livecheck do
url "https://sourceware.org/pub/valgrind/"
regex(/href=.*?valgrind[._-]v?(\d+(?:\.\d+)+)\.t/i)
end
bottle do
sha256 x86_64_linux: "e8a9a03173c9fb58a583f4ea872a7ed9c3cdb0605d0ff6327fbd8b2ec9fe21de"
end
head do
url "https://sourceware.org/git/valgrind.git"
depends_on "autoconf" => :build
depends_on "automake" => :build
depends_on "libtool" => :build
end
depends_on :linux
def install
args = %W[
--disable-dependency-tracking
--prefix=#{prefix}
--enable-only64bit
--without-mpicc
]
system "./autogen.sh" if build.head?
system "./configure", *args
system "make"
system "make", "install"
end
test do
assert_match "usage", shell_output("#{bin}/valgrind --help")
end
end