aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJack Nagel2014-06-12 14:28:53 -0500
committerJack Nagel2014-06-12 17:27:53 -0500
commita34daeea236b7eaa13dd74c4c7e211c7906887ce (patch)
treef68fdaf36ee9cc55cb991c3fe5d319d4aaaf01e5
parent40faa4968030994387ab271dbcb70b668c39d0f8 (diff)
downloadhomebrew-a34daeea236b7eaa13dd74c4c7e211c7906887ce.tar.bz2
open-scene-graph: fix several build issues
- add upstream patch to fix C++11 support - add upstream patch to fix freetype detection - remove hardcoded reference to "i386" - branch on build.with?, not installed? Fixes #29839. Closes #30097.
-rw-r--r--Library/Formula/open-scene-graph.rb26
1 files changed, 21 insertions, 5 deletions
diff --git a/Library/Formula/open-scene-graph.rb b/Library/Formula/open-scene-graph.rb
index 60a494bfe..31927fc2a 100644
--- a/Library/Formula/open-scene-graph.rb
+++ b/Library/Formula/open-scene-graph.rb
@@ -2,8 +2,23 @@ require 'formula'
class OpenSceneGraph < Formula
homepage 'http://www.openscenegraph.org/projects/osg'
- url 'http://trac.openscenegraph.org/downloads/developer_releases/OpenSceneGraph-3.2.0.zip'
- sha1 'c20891862b5876983d180fc4a3d3cfb2b4a3375c'
+
+ stable do
+ url "http://trac.openscenegraph.org/downloads/developer_releases/OpenSceneGraph-3.2.0.zip"
+ sha1 "c20891862b5876983d180fc4a3d3cfb2b4a3375c"
+
+ # Build fixes for clang/c++11
+ patch do
+ url "https://github.com/openscenegraph/osg/commit/f71491786ac2d22ef16f9f5ed31de0f6666c6600.diff"
+ sha1 "d96fe3dc1a01c8ad096433ef07f02803c2bf9206"
+ end
+
+ # Fix freetype detection
+ patch do
+ url "https://github.com/openscenegraph/osg/commit/3063b45aba74a0cfc693d46866084cde0d8959e2.diff"
+ sha1 "8a2a0e8384a30e3adb2820786f91adb52ba69cd9"
+ end
+ end
head 'http://www.openscenegraph.org/svn/osg/OpenSceneGraph/trunk/'
@@ -15,6 +30,7 @@ class OpenSceneGraph < Formula
depends_on 'jpeg'
depends_on 'wget'
depends_on 'gtkglext'
+ depends_on 'freetype'
depends_on 'gdal' => :optional
depends_on 'jasper' => :optional
depends_on 'openexr' => :optional
@@ -51,11 +67,11 @@ class OpenSceneGraph < Formula
args << "-DOSG_DEFAULT_IMAGE_PLUGIN_FOR_OSX=imageio"
args << "-DOSG_WINDOWING_SYSTEM=Cocoa"
else
- args << "-DCMAKE_OSX_ARCHITECTURES=i386"
+ args << "-DCMAKE_OSX_ARCHITECTURES=#{Hardware::CPU.arch_32_bit}"
end
- if Formula["collada-dom"].installed?
- args << "-DCOLLADA_INCLUDE_DIR=#{HOMEBREW_PREFIX}/include/collada-dom"
+ if build.with? "collada-dom"
+ args << "-DCOLLADA_INCLUDE_DIR=#{Formula["collada-dom"].opt_include}/collada-dom"
end
if build.with? 'qt5'