homebrew-core/Formula/autoconf-archive.rb
BrewTestBot 95884bae22 Formula files style updates.
Closes .

Signed-off-by: Mike McQuaid <mike@mikemcquaid.com>
2015-08-03 14:21:42 +01:00

40 lines
1.4 KiB
Ruby

class AutoconfArchive < Formula
desc "Collection of over 500 reusable autoconf macros"
homepage "https://savannah.gnu.org/projects/autoconf-archive/"
url "http://ftpmirror.gnu.org/autoconf-archive/autoconf-archive-2015.02.24.tar.xz"
mirror "https://ftp.gnu.org/gnu/autoconf-archive/autoconf-archive-2015.02.24.tar.xz"
sha256 "69715bdd078f552ca85e498a94543e11cb8bcdf0359e659b84d84d19372b0dc5"
bottle do
sha1 "379b87f4f2a0ab895b98566a9d846e39143febb9" => :yosemite
sha1 "57aa4726af450fa77e509a29aeb03d6c819706cf" => :mavericks
sha1 "5c2d27e4a970cdc0ef102e0404a5eb13cc1f0543" => :mountain_lion
end
# autoconf-archive is useless without autoconf
depends_on "autoconf" => :run
def install
system "./configure", "--prefix=#{prefix}"
system "make", "install"
end
test do
(testpath/"test.m4").write <<-EOS.undent
AC_INIT(myconfig, version-0.1)
AC_MSG_NOTICE([Hello, world.])
m4_include([#{share}/aclocal/ax_have_select.m4])
# from http://www.gnu.org/software/autoconf-archive/ax_have_select.html
AX_HAVE_SELECT(
[AX_CONFIG_FEATURE_ENABLE(select)],
[AX_CONFIG_FEATURE_DISABLE(select)])
AX_CONFIG_FEATURE(
[select], [This platform supports select(7)],
[HAVE_SELECT], [This platform supports select(7).])
EOS
system "#{Formula["autoconf"].bin}/autoconf", "test.m4"
end
end