[114195] trunk/dports/math/fftw-3/Portfile

ram at macports.org ram at macports.org
Sun Dec 1 18:40:07 PST 2013


Revision: 114195
          https://trac.macports.org/changeset/114195
Author:   ram at macports.org
Date:     2013-12-01 18:40:07 -0800 (Sun, 01 Dec 2013)
Log Message:
-----------
math/fftw-3: use avx optimisation where supported (#41622)

Modified Paths:
--------------
    trunk/dports/math/fftw-3/Portfile

Modified: trunk/dports/math/fftw-3/Portfile
===================================================================
--- trunk/dports/math/fftw-3/Portfile	2013-12-02 02:01:41 UTC (rev 114194)
+++ trunk/dports/math/fftw-3/Portfile	2013-12-02 02:40:07 UTC (rev 114195)
@@ -5,7 +5,7 @@
 
 name            fftw-3
 version         3.3.3
-revision        3
+revision        4
 categories      math
 license         GPL-2+
 platforms       darwin
@@ -52,13 +52,28 @@
     -fomit-frame-pointer \
     -fstrict-aliasing
 
-array set merger_configure_args {
-    ppc    "--enable-fma"
-    ppc64  "--enable-fma"
-    i386   "--enable-sse2"
-    x86_64 "--enable-sse2"
+if { ![string compare ${configure.compiler} "clang"] } {
+    set is_clang    1
+} else {
+    set is_clang    0
 }
 
+if { $is_clang == 1 } {
+    array set merger_configure_args {
+        ppc    "--enable-fma"
+        ppc64  "--enable-fma"
+        i386   "--enable-sse2 --enable-avx"
+        x86_64 "--enable-sse2 --enable-avx"
+    }
+} else {
+    array set merger_configure_args {
+        ppc    "--enable-fma"
+        ppc64  "--enable-fma"
+        i386   "--enable-sse2"
+        x86_64 "--enable-sse2"
+    }
+}
+
 test.run     yes
 test.target  check
 
@@ -67,6 +82,9 @@
 platform i386 {
   if {![variant_isset universal]} {
     configure.args-append --enable-sse2
+    if { $is_clang == 1 } {
+        configure.args-append --enable-avx
+    }
   }
 }
 
@@ -125,6 +143,7 @@
 }
 
 subport fftw-3-long {
+    revision 3
     configure.args-append --enable-long-double
 
      array set merger_configure_args {
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.macosforge.org/pipermail/macports-changes/attachments/20131201/b5a0df8d/attachment.html>


More information about the macports-changes mailing list