diff options
| author | Xin Sun | 2013-11-15 02:42:52 +0800 |
|---|---|---|
| committer | Jack Nagel | 2013-11-21 16:44:52 -0600 |
| commit | 652b68fd910928c01160cf73a7bddef74b28b5aa (patch) | |
| tree | 34cefb087ac4477c5804ed671da1722a4d2f33b1 | |
| parent | 88ac11b6c7e0c380ee63c8d1a13cb783c97e961d (diff) | |
| download | homebrew-652b68fd910928c01160cf73a7bddef74b28b5aa.tar.bz2 | |
Add c++11 option to tbb, gmp, and libtiff
Closes #24024.
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
| -rw-r--r-- | Library/Formula/gmp.rb | 2 | ||||
| -rw-r--r-- | Library/Formula/libtiff.rb | 2 | ||||
| -rw-r--r-- | Library/Formula/tbb.rb | 4 |
3 files changed, 8 insertions, 0 deletions
diff --git a/Library/Formula/gmp.rb b/Library/Formula/gmp.rb index 898e206ae..c2cb68067 100644 --- a/Library/Formula/gmp.rb +++ b/Library/Formula/gmp.rb @@ -15,6 +15,7 @@ class Gmp < Formula end option '32-bit' + option :cxx11 # Patches gmp.h to remove the __need_size_t define, which # was preventing libc++ builds from getting the ptrdiff_t type @@ -24,6 +25,7 @@ class Gmp < Formula end def install + ENV.cxx11 if build.cxx11? args = ["--prefix=#{prefix}", "--enable-cxx"] if build.build_32_bit? diff --git a/Library/Formula/libtiff.rb b/Library/Formula/libtiff.rb index bb3eb567d..a0b1b0591 100644 --- a/Library/Formula/libtiff.rb +++ b/Library/Formula/libtiff.rb @@ -7,11 +7,13 @@ class Libtiff < Formula sha256 'ea1aebe282319537fb2d4d7805f478dd4e0e05c33d0928baba76a7c963684872' option :universal + option :cxx11 depends_on 'jpeg' def install ENV.universal_binary if build.universal? + ENV.cxx11 if build.cxx11? jpeg = Formula.factory('jpeg').opt_prefix system "./configure", "--disable-dependency-tracking", "--prefix=#{prefix}", diff --git a/Library/Formula/tbb.rb b/Library/Formula/tbb.rb index 040407f46..26a2df3aa 100644 --- a/Library/Formula/tbb.rb +++ b/Library/Formula/tbb.rb @@ -6,6 +6,8 @@ class Tbb < Formula sha1 'f354bd9b67295f65c43531b751e34f483ed8a024' version '4.2' + option :cxx11 + fails_with :llvm do cause 'llvm is not supported on macos. Add build/macos.llvm.inc file with compiler-specific settings.' end @@ -18,11 +20,13 @@ class Tbb < Formula def install # Intel sets varying O levels on each compile command. ENV.no_optimization + ENV.cxx11 if build.cxx11? # Override build prefix so we can copy the dylibs out of the same place # no matter what system we're on, and use our compilers. args = ['tbb_build_prefix=BUILDPREFIX', "compiler=#{ENV.compiler}"] args << (MacOS.prefer_64_bit? ? "arch=intel64" : "arch=ia32") + args << "cpp0x=1" << "stdlib=libc++" if build.cxx11? system "make", *args lib.install Dir['build/BUILDPREFIX_release/*.dylib'] include.install 'include/tbb' |
