From ad3e9919f7626104ba21a783c286d190730aa87b Mon Sep 17 00:00:00 2001 From: Tom Schoonjans Date: Sat, 19 Dec 2020 19:57:20 +0000 Subject: [PATCH] atkmm@2.28 2.28.1 (new formula) --- Formula/atkmm@2.28.rb | 72 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 72 insertions(+) create mode 100644 Formula/atkmm@2.28.rb diff --git a/Formula/atkmm@2.28.rb b/Formula/atkmm@2.28.rb new file mode 100644 index 00000000000..e2a28c15f87 --- /dev/null +++ b/Formula/atkmm@2.28.rb @@ -0,0 +1,72 @@ +class AtkmmAT228 < Formula + desc "Official C++ interface for the ATK accessibility toolkit library" + homepage "https://www.gtkmm.org/" + url "https://download.gnome.org/sources/atkmm/2.28/atkmm-2.28.1.tar.xz" + sha256 "116876604770641a450e39c1f50302884848ce9cc48d43c5dc8e8efc31f31bad" + license "LGPL-2.1-or-later" + + livecheck do + url :stable + end + + depends_on "meson" => :build + depends_on "ninja" => :build + depends_on "pkg-config" => :build + depends_on "atk" + depends_on "glibmm@2.64" + + def install + ENV.cxx11 + mkdir "build" do + system "meson", *std_meson_args, ".." + system "ninja" + system "ninja", "install" + end + end + + test do + (testpath/"test.cpp").write <<~EOS + #include + + int main(int argc, char *argv[]) + { + Atk::init(); + return 0; + } + EOS + atk = Formula["atk"] + gettext = Formula["gettext"] + glib = Formula["glib"] + glibmm = Formula["glibmm@2.64"] + libsigcxx = Formula["libsigc++@2"] + flags = %W[ + -I#{atk.opt_include}/atk-1.0 + -I#{gettext.opt_include} + -I#{glib.opt_include}/glib-2.0 + -I#{glib.opt_lib}/glib-2.0/include + -I#{glibmm.opt_include}/glibmm-2.4 + -I#{glibmm.opt_lib}/glibmm-2.4/include + -I#{include}/atkmm-1.6 + -I#{lib}/atkmm-1.6/include + -I#{libsigcxx.opt_include}/sigc++-2.0 + -I#{libsigcxx.opt_lib}/sigc++-2.0/include + -L#{atk.opt_lib} + -L#{gettext.opt_lib} + -L#{glib.opt_lib} + -L#{glibmm.opt_lib} + -L#{libsigcxx.opt_lib} + -L#{lib} + -latk-1.0 + -latkmm-1.6 + -lglib-2.0 + -lglibmm-2.4 + -lgobject-2.0 + -lsigc-2.0 + ] + on_macos do + flags << "-lintl" + end + system ENV.cxx, "-std=c++11", "test.cpp", "-o", "test", *flags + system "./test" + end +end