2010-12-02 02:57:44 +00:00
|
|
|
require 'formula'
|
|
|
|
|
2011-03-10 05:11:03 +00:00
|
|
|
class Box2d < Formula
|
2015-05-19 00:00:59 +00:00
|
|
|
desc "2D physics engine for games"
|
2010-12-02 02:57:44 +00:00
|
|
|
homepage 'http://www.box2d.org/'
|
2013-11-15 19:40:43 +00:00
|
|
|
url 'https://box2d.googlecode.com/files/Box2D_v2.3.0.7z'
|
|
|
|
sha1 '1d3ea1f872b3cab3ef5130a2404d74f9ff66f265'
|
2010-12-02 02:57:44 +00:00
|
|
|
|
2011-11-07 07:20:34 +00:00
|
|
|
depends_on 'cmake' => :build
|
2010-12-02 02:57:44 +00:00
|
|
|
|
|
|
|
def install
|
2014-04-17 04:10:11 +00:00
|
|
|
cd "Box2D_v#{version}/Box2D" do
|
|
|
|
system "cmake", "-DBOX2D_INSTALL=ON",
|
|
|
|
"-DBOX2D_BUILD_SHARED=ON",
|
|
|
|
"-DBOX2D_BUILD_EXAMPLES=OFF",
|
|
|
|
*std_cmake_args
|
|
|
|
system "make install"
|
2011-11-07 07:20:34 +00:00
|
|
|
end
|
2010-12-02 02:57:44 +00:00
|
|
|
end
|
|
|
|
end
|