From d9bd665f7e61ca0024ffbc779ec718cb397a3fec Mon Sep 17 00:00:00 2001 From: ambs Date: Tue, 7 Feb 2012 19:45:57 +0000 Subject: boost: add --with-icu option Closes #10031. Signed-off-by: Jack Nagel --- Library/Formula/boost.rb | 17 ++++++++++++++--- 1 file changed, 14 insertions(+), 3 deletions(-) diff --git a/Library/Formula/boost.rb b/Library/Formula/boost.rb index d4c542403..29c4349b8 100644 --- a/Library/Formula/boost.rb +++ b/Library/Formula/boost.rb @@ -12,6 +12,8 @@ class Boost < Formula sha1 'c7871ddd020a24e3b0cfd3c9a352a1210b68b372' end + depends_on "icu4c" if ARGV.include? "--with-icu" + def patches # https://svn.boost.org/trac/boost/ticket/6131 # @@ -28,7 +30,8 @@ class Boost < Formula [ ["--with-mpi", "Enable MPI support"], ["--universal", "Build universal binaries"], - ["--without-python", "Build without Python"] + ["--without-python", "Build without Python"], + ["--with-icu", "Build regexp engine with icu support"], ] end @@ -72,6 +75,14 @@ class Boost < Formula file.write "using mpi ;\n" if ARGV.include? '--with-mpi' end + # we specify libdir too because the script is apparently broken + bargs = ["--prefix=#{prefix}", "--libdir=#{lib}"] + + if ARGV.include? "--with-icu" + icu4c_prefix = Formula.factory('icu4c').prefix + bargs << "--with-icu=#{icu4c_prefix}" + end + args = ["--prefix=#{prefix}", "--libdir=#{lib}", "-j#{ENV.make_jobs}", @@ -83,11 +94,11 @@ class Boost < Formula args << "address-model=32_64" << "architecture=x86" << "pch=off" if ARGV.include? "--universal" args << "--without-python" if ARGV.include? "--without-python" - # we specify libdir too because the script is apparently broken - system "./bootstrap.sh", "--prefix=#{prefix}", "--libdir=#{lib}" + system "./bootstrap.sh", *bargs system "./bjam", *args end end + __END__ Index: /boost/foreach_fwd.hpp =================================================================== -- cgit v1.2.3