aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Formula
diff options
context:
space:
mode:
authorDavid Coeurjolly2014-11-07 14:49:16 +0100
committerTim D. Smith2014-11-12 07:56:36 -0800
commite8ee2d4bebec8d35a0e5b7b2848aca2a42cc4460 (patch)
treef0a58dd82bdd009f26f8154cb2231cdbdcc9b8ce /Library/Formula
parent95426ab77e674b30fb72e5a68fea3406535455fa (diff)
downloadhomebrew-e8ee2d4bebec8d35a0e5b7b2848aca2a42cc4460.tar.bz2
dgtal 0.8.0
Closes #33994. Signed-off-by: Tim D. Smith <git@tim-smith.us>
Diffstat (limited to 'Library/Formula')
-rw-r--r--Library/Formula/dgtal.rb39
1 files changed, 26 insertions, 13 deletions
diff --git a/Library/Formula/dgtal.rb b/Library/Formula/dgtal.rb
index 975fad239..ad3c340f7 100644
--- a/Library/Formula/dgtal.rb
+++ b/Library/Formula/dgtal.rb
@@ -2,31 +2,44 @@ require 'formula'
class Dgtal < Formula
homepage 'http://libdgtal.org'
- url 'http://liris.cnrs.fr/dgtal/releases/DGtal-0.7.0-Source.tar.gz'
- sha1 '2a5bec10b376cfde5c52760340aa553907664d9c'
-
+ url 'http://liris.cnrs.fr/dgtal/releases/DGtal-0.8.0-Source.tar.gz'
+ sha1 '61c8d4b7db2c31daed9456ab65b0158d0a0e1bab'
head 'https://github.com/DGtal-team/DGtal.git'
- option 'with-qglviewer', "Enable QGLViewer vizualisation"
- option 'with-magick', "Enable GraphicsMagick for 2d image readers"
-
depends_on 'cmake' => :build
- depends_on 'boost'
+ boost_args = []; boost_args << "c++11" if MacOS.version < "10.9";
+ depends_on "boost" => boost_args
depends_on 'gmp' => :optional
depends_on 'cairo' => :optional
- depends_on 'libqglviewer' if build.with? 'qglviewer'
- depends_on 'graphicsmagick' if build.with? 'magick'
+ depends_on 'libqglviewer' => :optional
+ depends_on 'graphicsmagick' => :optional
+ depends_on 'eigen' => :optional
+ depends_on "cgal" => [:optional, "with-eigen3"]
+
+ deprecated_option 'with-magick' => 'with-graphicsmagick'
+ deprecated_option 'with-qglviewer' => 'with-libqglviewer'
+
+ # Bugfix for boost 1.57: https://github.com/DGtal-team/DGtal/issues/938
+ patch do
+ url "https://github.com/dcoeurjo/DGtal/commit/c676dc82d8d959377622a61ceab6354bab7a2baa.diff"
+ sha1 "ef878791a0e31a006f88ea4366344108bf2a4db8"
+ end
+
+ needs :cxx11
def install
+ ENV.cxx11
args = std_cmake_args
args << "-DCMAKE_BUILD_TYPE=Release"
args << "-DBUILD_EXAMPLES=OFF"
args << "-DDGTAL_BUILD_TESTING=OFF"
- args << "-DWITH_C11:bool=false"
- args << "-DWITH_GMP=ON" if build.with? 'gmp'
- args << "-DWITH_CAIRO=ON" if build.with? 'cairo'
- args << "-DWITH_QGLVIEWER=ON" if build.with? 'qglviewer'
+ args << "-DWITH_GMP=true" if build.with? 'gmp'
+ args << "-DWITH_CAIRO=true" if build.with? 'cairo'
+ args << "-DWITH_QGLVIEWER=true" if build.with? 'libqglviewer'
+ args << "-DWITH_EIGEN=true" if build.with? 'eigen'
+ args << "-DWITH_MAGICK=true" if build.with? 'graphicsmagick'
+ args << "-DWITH_EIGEN=true -DWITH_GMP=true -DWITH_CGAL=true" if build.with? 'cgal'
mkdir 'build' do
system "cmake", "..", *args