diff --git a/Formula/open-scene-graph.rb b/Formula/open-scene-graph.rb index b762f060a63..3a98513df33 100644 --- a/Formula/open-scene-graph.rb +++ b/Formula/open-scene-graph.rb @@ -3,7 +3,7 @@ require 'formula' class OpenSceneGraph < Formula homepage 'http://www.openscenegraph.org/projects/osg' url 'http://www.openscenegraph.org/downloads/stable_releases/OpenSceneGraph-3.0.1/source/OpenSceneGraph-3.0.1.zip' - md5 'c43a25d023e635c3566b2083d8e6d956' + sha1 '13c7e39f6d62047ad944d8d28a0f0eb60384ce33' head 'http://www.openscenegraph.org/svn/osg/OpenSceneGraph/trunk/' depends_on 'cmake' => :build @@ -23,33 +23,28 @@ class OpenSceneGraph < Formula end fails_with :clang do - build 318 + build 421 cause <<-EOS.undent cannot initialize a parameter of type 'void *' with an lvalue of type 'const void *const' http://forum.openscenegraph.org/viewtopic.php?t=10042 EOS end - # First patch: The mini-Boost finder in FindCOLLADA doesn't find our boost, so fix it. - # Second patch: - # Lion replacement for CGDisplayBitsPerPixel(); - # taken from: http://www.openscenegraph.org/projects/osg/changeset/12790/OpenSceneGraph/trunk/src/osgViewer/DarwinUtils.mm - # Issue at: https://github.com/mxcl/homebrew/issues/11391 - # the second patch should be obsolete with some newer versions (current version is: 3.0.1, it's fixed upstream in 3.1.1) + # 1: The mini-Boost finder in FindCOLLADA doesn't find our boost, so fix it. + # 2: Lion replacement for CGDisplayBitsPerPixel() taken from: + # http://www.openscenegraph.org/projects/osg/changeset/12790/OpenSceneGraph/trunk/src/osgViewer/DarwinUtils.mm + # https://github.com/mxcl/homebrew/issues/11391 + # Remove at >= 3.1.1 def patches p = [DATA] p << "https://raw.github.com/gist/2890654/a07dec42b8451edf9edbf6468e5ae464c73b3b95/osg.diff" if build.stable? + return p end def install - args = %W{ - .. - -DCMAKE_INSTALL_PREFIX='#{prefix}' - -DCMAKE_BUILD_TYPE=None - -Wno-dev - -DBUILD_OSG_WRAPPERS=ON + args = std_cmake_args + %w[ -DBUILD_DOCUMENTATION=ON - } + ] if snow_leopard_64? args << "-DCMAKE_OSX_ARCHITECTURES=x86_64" @@ -62,6 +57,7 @@ class OpenSceneGraph < Formula if Formula.factory('collada-dom').installed? args << "-DCOLLADA_INCLUDE_DIR=#{HOMEBREW_PREFIX}/include/collada-dom" end + args << '..' mkdir "build" do system "cmake", *args