From c59cf08156d62e9c82e62fe98b7bc816fe4b0468 Mon Sep 17 00:00:00 2001 From: Hideo Hattori Date: Tue, 20 Jun 2017 18:48:52 +0900 Subject: [PATCH] apache-arrow 0.4.1 (new formula) Closes #14764. Signed-off-by: JCount --- Formula/apache-arrow.rb | 38 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) create mode 100644 Formula/apache-arrow.rb diff --git a/Formula/apache-arrow.rb b/Formula/apache-arrow.rb new file mode 100644 index 0000000000..09135e382b --- /dev/null +++ b/Formula/apache-arrow.rb @@ -0,0 +1,38 @@ +class ApacheArrow < Formula + desc "Columnar in-memory analytics layer designed to accelerate big data" + homepage "https://arrow.apache.org/" + url "https://www.apache.org/dyn/closer.cgi?path=arrow/arrow-0.4.1/apache-arrow-0.4.1.tar.gz" + sha256 "499401661f9c768ba7e8a27f02a2079efc207628d7fd856cf03aa301f5dc9986" + + head "https://github.com/apache/arrow.git" + + # NOTE: remove ccache with Apache Arrow 0.5 and higher version + depends_on "cmake" => :build + depends_on "boost" + depends_on "ccache" => :recommended + + needs :cxx11 + + def install + ENV.cxx11 + + cd "cpp" do + system "cmake", ".", *std_cmake_args + system "make", "unittest" + system "make", "install" + end + end + + test do + (testpath/"test.cpp").write <<-EOS.undent + #include "arrow/api.h" + int main(void) + { + arrow::Int64Builder builder(arrow::default_memory_pool(), arrow::int64()); + return 0; + } + EOS + system ENV.cxx, "test.cpp", "-std=c++11", "-I#{include}", "-L#{lib}", "-larrow", "-o", "test" + system "./test" + end +end