require 'formula' class Utf8cpp 'master' depends_on 'gettext' depends_on 'boost' depends_on 'mpfr' depends_on 'gmp' depends_on 'pcre' depends_on 'expat' def install unless 'HEAD' == @version system "./configure", "--prefix=#{prefix}", "--disable-debug", "--disable-dependency-tracking" else utfcpp = Pathname.new(Dir.pwd)+'lib/utfcpp' Utf8cpp.new.brew { utfcpp.install Dir['*'] } # gmp installs x86_64 only inreplace 'acprep', "'-arch', 'i386', ", "" if Hardware.is_64_bit? system "./acprep -j#{Hardware.processor_count} opt make -- --prefix=#{prefix}" end system "make install" end end