homebrew-core/Formula/ncview.rb
2017-11-10 05:02:04 -08:00

35 lines
1.1 KiB
Ruby

class Ncview < Formula
desc "Visual browser for netCDF format files"
homepage "http://meteora.ucsd.edu/~pierce/ncview_home_page.html"
url "ftp://cirrus.ucsd.edu/pub/ncview/ncview-2.1.7.tar.gz"
sha256 "a14c2dddac0fc78dad9e4e7e35e2119562589738f4ded55ff6e0eca04d682c82"
revision 5
bottle do
sha256 "bd2df1b3290bf6fc03543fecf727698064f858329b62d7665f516bff8e094067" => :high_sierra
sha256 "df920fc488f54f8f128f635c42c618fed9cf82beaed5e99087b44397e3770066" => :sierra
sha256 "65e303f36bc95f74adcac5eac2c6f11a3d474ad1babd573016576c8467320214" => :el_capitan
end
depends_on "netcdf"
depends_on "udunits"
depends_on :x11
def install
# Bypass compiler check (which fails due to netcdf's nc-config being
# confused by our clang shim)
inreplace "configure",
"if test x$CC_TEST_SAME != x$NETCDF_CC_TEST_SAME; then",
"if false; then"
system "./configure", "--disable-dependency-tracking",
"--prefix=#{prefix}"
system "make", "install"
man1.install "data/ncview.1"
end
test do
assert_match "Ncview #{version}",
shell_output("#{bin}/ncview -c 2>&1", 1)
end
end