2020-09-26 17:32:12 +00:00
|
|
|
class Libxpm < Formula
|
|
|
|
desc "X.Org: X Pixmap (XPM) image file format library"
|
|
|
|
homepage "https://www.x.org/"
|
2020-10-05 14:29:08 +00:00
|
|
|
url "https://www.x.org/archive/individual/lib/libXpm-3.5.13.tar.bz2"
|
|
|
|
sha256 "9cd1da57588b6cb71450eff2273ef6b657537a9ac4d02d0014228845b935ac25"
|
2020-09-26 17:32:12 +00:00
|
|
|
license "MIT"
|
|
|
|
|
2020-10-04 19:12:27 +00:00
|
|
|
bottle do
|
|
|
|
cellar :any
|
|
|
|
sha256 "53865d3b3d752c71525a40db99851580b5d979f7b722b0bf361d923e33a39ea5" => :catalina
|
|
|
|
sha256 "9b34b6b7ca85c9e0082b823d31e82094c5b7106e7d3af1e8cba33fc994b54382" => :mojave
|
|
|
|
sha256 "32c76e168d128d34dea14d51c422888fab28c3db1ecad10fc5bd457afe239b8a" => :high_sierra
|
|
|
|
end
|
|
|
|
|
2020-09-26 17:32:12 +00:00
|
|
|
depends_on "gettext" => :build
|
|
|
|
depends_on "pkg-config" => :build
|
|
|
|
depends_on "gettext"
|
|
|
|
depends_on "libx11"
|
|
|
|
|
|
|
|
def install
|
|
|
|
args = %W[
|
|
|
|
--prefix=#{prefix}
|
|
|
|
--sysconfdir=#{etc}
|
|
|
|
--localstatedir=#{var}
|
|
|
|
--disable-dependency-tracking
|
|
|
|
--disable-silent-rules
|
|
|
|
]
|
|
|
|
|
|
|
|
system "./configure", *args
|
|
|
|
system "make"
|
|
|
|
system "make", "install"
|
|
|
|
end
|
|
|
|
|
|
|
|
test do
|
|
|
|
(testpath/"test.c").write <<~EOS
|
|
|
|
#include "X11/Xlib.h"
|
|
|
|
#include "X11/xpm.h"
|
|
|
|
|
|
|
|
int main(int argc, char* argv[]) {
|
|
|
|
XpmColor color;
|
|
|
|
return 0;
|
|
|
|
}
|
|
|
|
EOS
|
|
|
|
system ENV.cc, "test.c"
|
|
|
|
assert_equal 0, $CHILD_STATUS.exitstatus
|
|
|
|
end
|
|
|
|
end
|