From 53edc7535845fb1bc00656e6ff3c729fd686a784 Mon Sep 17 00:00:00 2001 From: Felix Bùˆnemann Date: Wed, 10 Apr 2013 16:30:03 +0200 Subject: john: enable OpenCL and OpenMP support for --jumbo Closes #19105. Signed-off-by: Adam Vandenberg --- Library/Formula/john.rb | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'Library/Formula') diff --git a/Library/Formula/john.rb b/Library/Formula/john.rb index b32654241..27f184810 100644 --- a/Library/Formula/john.rb +++ b/Library/Formula/john.rb @@ -26,9 +26,16 @@ class John < Formula def install ENV.deparallelize arch = Hardware.is_64_bit? ? '64' : 'sse2' + arch += '-opencl' if build.include? 'jumbo' cd 'src' do - system "make", "clean", "macosx-x86-#{arch}", "CC=#{ENV.cc}" + inreplace 'Makefile' do |s| + s.change_make_var! "CC", ENV.cc + if build.include?('jumbo') && MacOS.version != :leopard && ENV.compiler != :clang + s.change_make_var! "OMPFLAGS", "-fopenmp -msse2 -D_FORTIFY_SOURCE=0" + end + end + system "make", "clean", "macosx-x86-#{arch}" end # Remove the README symlink and install the real file -- cgit v1.2.3