From 77c2bbb4bbaef922f6eb60bde9c65eafd7a15ccc Mon Sep 17 00:00:00 2001 From: FX Coudert Date: Wed, 9 Aug 2017 23:14:11 +0200 Subject: [PATCH] hwloc: migrate from homebrew/science --- Formula/hwloc.rb | 35 +++++++++++++++++++++++++++++++++++ tap_migrations.json | 1 - 2 files changed, 35 insertions(+), 1 deletion(-) create mode 100644 Formula/hwloc.rb diff --git a/Formula/hwloc.rb b/Formula/hwloc.rb new file mode 100644 index 00000000000..ba15e0f1a8b --- /dev/null +++ b/Formula/hwloc.rb @@ -0,0 +1,35 @@ +class Hwloc < Formula + desc "Portable abstraction of the hierarchical topology of modern architectures" + homepage "https://www.open-mpi.org/projects/hwloc/" + url "https://www.open-mpi.org/software/hwloc/v1.11/downloads/hwloc-1.11.7.tar.bz2" + sha256 "ab6910e248eed8c85d08b529917a6aae706b32b346e886ba830895e36a809729" + + head do + url "https://github.com/open-mpi/hwloc.git" + depends_on "autoconf" => :build + depends_on "automake" => :build + depends_on "libtool" => :build + end + + depends_on "pkg-config" => :build + depends_on "cairo" => :optional + + def install + system "./autogen.sh" if build.head? + system "./configure", "--disable-debug", + "--disable-dependency-tracking", + "--enable-shared", + "--enable-static", + "--prefix=#{prefix}", + "--without-x" + system "make", "install" + + pkgshare.install "tests" + end + + test do + system ENV.cc, pkgshare/"tests/hwloc_groups.c", "-I#{include}", + "-L#{lib}", "-lhwloc", "-o", "test" + system "./test" + end +end diff --git a/tap_migrations.json b/tap_migrations.json index 8079558eeb9..0638d8dbbc1 100644 --- a/tap_migrations.json +++ b/tap_migrations.json @@ -29,7 +29,6 @@ "helios": "spotify/public", "hexchat": "caskroom/cask", "horndis": "caskroom/cask", - "hwloc": "homebrew/science", "inkscape": "caskroom/cask", "ipopt": "homebrew/science", "itsol": "homebrew/science",