glew: build with cmake

Authored by claudiofantacci

Closes #12722.
This commit is contained in:
FX Coudert 2017-05-02 16:09:38 +02:00
parent ac27618cfc
commit 41d39ddb5a

View file

@ -13,11 +13,24 @@ class Glew < Formula
sha256 "2b72bd7d59343ae64eaa87fd69f806759ac356a77300bb6b6a6ab40247384dc2" => :mavericks
end
def install
inreplace "glew.pc.in", "Requires: @requireslib@", ""
system "make", "GLEW_PREFIX=#{prefix}", "GLEW_DEST=#{prefix}", "all"
system "make", "GLEW_PREFIX=#{prefix}", "GLEW_DEST=#{prefix}", "install.all"
depends_on "cmake" => :build
patch do
url "https://github.com/nigels-com/glew/commit/925722f.patch"
sha256 "6f36179dc42f1bbf5dd5bfe525457e4988749b56ee68180482c3a82b999792ed"
end
patch do
url "https://github.com/nigels-com/glew/pull/143.patch"
sha256 "7761252b504e869e66edfe1615b8eef40311b9eebd6268ae164d4c83af1b31e0"
end
def install
cd "build" do
system "cmake", "./cmake", *std_cmake_args
system "make"
system "make", "install"
end
doc.install Dir["doc/*"]
end