From 9179cd1b9b6d86022b845c62e9bab5e441cf6575 Mon Sep 17 00:00:00 2001 From: Andrew Kane Date: Sat, 21 Sep 2019 02:12:45 -0700 Subject: [PATCH] xgboost 0.90 (new formula) --- Formula/xgboost.rb | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) create mode 100644 Formula/xgboost.rb diff --git a/Formula/xgboost.rb b/Formula/xgboost.rb new file mode 100644 index 000000000000..0c78429719ef --- /dev/null +++ b/Formula/xgboost.rb @@ -0,0 +1,26 @@ +class Xgboost < Formula + desc "Scalable, Portable and Distributed Gradient Boosting Library" + homepage "https://xgboost.ai/" + url "https://github.com/dmlc/xgboost.git", + :tag => "v0.90", + :revision => "515f5f5c4779ff5361dcd796e22d55937e1048ea" + + depends_on "cmake" => :build + + def install + mkdir "build" do + system "cmake", *std_cmake_args, "-DUSE_OPENMP=0", ".." + system "make" + system "make", "install" + end + pkgshare.install "demo" + end + + test do + cp_r (pkgshare/"demo"), testpath + cd "demo/data" do + cp "../binary_classification/mushroom.conf", "." + system "#{bin}/xgboost", "mushroom.conf" + end + end +end