From ef88db9d386a55cc22576b60cddafed1f1de5974 Mon Sep 17 00:00:00 2001 From: Adam Vandenberg Date: Fri, 4 Sep 2009 09:46:53 -0700 Subject: Nehalem supports SSE4.2 Signed Off By: Max Howell I realised that -msse4.1 and -msse4.2 aren't supported by GCC 4.0, so I made the brash decision that we require GCC 4.2. It comes with Xcode 3.1 so people can upgrade if they have to. Requiring a single compiler is better for us anyway -- less possible errors and failures. Formulae can still request gcc-4.0.1, but at least then those formulae still only use a single compiler and not possibly two. --- Library/Homebrew/brewkit.rb | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) (limited to 'Library') diff --git a/Library/Homebrew/brewkit.rb b/Library/Homebrew/brewkit.rb index ce15625a0..204213dec 100644 --- a/Library/Homebrew/brewkit.rb +++ b/Library/Homebrew/brewkit.rb @@ -64,15 +64,14 @@ else end cflags<<"-mfpmath=sse" - # use gcc 4.2 if available (Xcode 3.1 and above) - if system "which -s gcc-4.2" and $?.success? - ENV['CC']="gcc-4.2" - ENV['CXX']="g++-4.2" - end + ENV['CC']="gcc-4.2" + ENV['CXX']="g++-4.2" end cflags<<"-mmmx" case Hardware.intel_family +when :nehalem + cflags<<"-msse4.2" when :penryn cflags<<"-msse4.1" when :core2, :core @@ -107,8 +106,10 @@ module HomebrewEnvExtension when 10.6..11.0 self['CC']='gcc-4.0' self['CXX']='g++-4.0' - remove_from_cflags '-march=core2' # we *should* add back in stuff but meh for now + remove_from_cflags '-march=core2' end + remove_from_cflags '-msse4.1' + remove_from_cflags '-msse4.2' end def osx_10_4 self['MACOSX_DEPLOYMENT_TARGET']=nil -- cgit v1.2.3