[82670] trunk/dports/math/atlas

vince at macports.org vince at macports.org
Thu Aug 18 08:13:31 PDT 2011


Revision: 82670
          http://trac.macports.org/changeset/82670
Author:   vince at macports.org
Date:     2011-08-17 14:06:35 -0700 (Wed, 17 Aug 2011)
Log Message:
-----------
Avoid ATLAS to use plain 'gcc' despite configuration orders (#30750)

Modified Paths:
--------------
    trunk/dports/math/atlas/Portfile

Added Paths:
-----------
    trunk/dports/math/atlas/files/patch-mmparse_h.diff
    trunk/dports/math/atlas/files/patch-mvparse_h.diff

Modified: trunk/dports/math/atlas/Portfile
===================================================================
--- trunk/dports/math/atlas/Portfile	2011-08-17 20:59:13 UTC (rev 82669)
+++ trunk/dports/math/atlas/Portfile	2011-08-17 21:06:35 UTC (rev 82670)
@@ -34,9 +34,12 @@
 					patch-archinfo_freebsd_c.diff \
 					patch-ATL_goparallel_prank_c.diff \
 					patch-ATL_go_parallel_c.diff \
-					patch-atlas_l2g_base.diff 
+					patch-atlas_l2g_base.diff \
+					patch-mmparse_h.diff \
+					patch-mvparse_h.diff
 
 
+
 checksums			atlas${version}.tar.bz2 \
 					sha1    a3a4797669decea28308bd7d3e0adcac44267471 \
 					rmd160  036dbe08784bbda33ce1fa94b20a1999b22772cd \
@@ -89,6 +92,7 @@
 	} elseif { [variant_isset dragonegg45] } {
 		configure.compiler	clang
 		configure.f77		${prefix}/bin/gfortran-mp-4.5
+		patchfiles-append	patch-clang.diff
 	} else {
 		return -code error "GCC/GFortran 4.6 is not yet available"
 	}
@@ -170,8 +174,8 @@
 		
 }
 
-if { (${os.major} == 11 && [sysctl hw.optional.avx1_0] == 1) || \
-	 (${os.major} > 8 && [sysctl hw.cpufamily] == 1418770316) } {
+if { (${os.major} == 11 && [exec sysctl -n hw.optional.avx1_0] == 1) || \
+	 (${os.major} > 8 && [exec sysctl -n hw.cpufamily] == 1418770316) } {
 	# Corei2 is not supported yet because gcc4.5 does not
 	# support AVX instructions and gcc4.6 does not compile yet.
 	# Set CPU to Corei1 instead
@@ -265,7 +269,7 @@
 				 ${workpath}/${name}-${version}/CONFIG/src/atlcomp.txt
 
 	# Get some system specific variables for maximum optimization
-	set			cpufreq [expr {[sysctl hw.cpufrequency]/1000000}]
+	set			cpufreq [expr {[exec sysctl -n hw.cpufrequency]/1000000}]
 	ui_debug	"Setting CPU Frequency for: ${cpufreq}"
 
 	if { ${os.arch} == "powerpc" } {
@@ -332,7 +336,7 @@
 post-build {
   # We have to manually create the dylib shared libs as the default build does not do this
 
-  set ncpu [sysctl hw.ncpu]
+  set ncpu [exec sysctl -n hw.ncpu]
 
 	if { [variant_isset universal] } {
 		set	archs ${universal_archs_to_use}

Added: trunk/dports/math/atlas/files/patch-mmparse_h.diff
===================================================================
--- trunk/dports/math/atlas/files/patch-mmparse_h.diff	                        (rev 0)
+++ trunk/dports/math/atlas/files/patch-mmparse_h.diff	2011-08-17 21:06:35 UTC (rev 82670)
@@ -0,0 +1,38 @@
+--- include/atlas_mmparse.h.orig	2011-08-17 22:35:24.000000000 +0200
++++ include/atlas_mmparse.h	2011-08-17 22:35:57.000000000 +0200
+@@ -243,17 +243,6 @@
+  *  use an old GOODGCC that lacks something like -pg.
+  */
+ {
+-   ATL_mmnode_t *kp;  /* queue to make sub in */
+-   char *gcc;
+-   gcc = GetGoodGcc();
+-   for (kp=bp; kp; kp = kp->next)
+-   {
+-      if (kp->comp && !strcmp(kp->comp, gcc))
+-      {
+-         free(kp->comp);
+-	 kp->comp = DupString("gcc");
+-      }
+-   }
+ }
+ 
+ /* procedure 11 */
+@@ -266,17 +255,6 @@
+  * to help portability
+  */
+ {
+-   ATL_mmnode_t *kp;  /* queue to make sub in */
+-   char *gcc;
+-   gcc = GetGoodGcc();
+-   for (kp=bp; kp; kp = kp->next)
+-   {
+-      if (kp->comp && !strcmp(kp->comp, gcc))
+-      {
+-         free(kp->comp);
+-	 kp->comp = DupString("gcc");
+-      }
+-   }
+ }
+ 
+ /* procedure 12 */

Added: trunk/dports/math/atlas/files/patch-mvparse_h.diff
===================================================================
--- trunk/dports/math/atlas/files/patch-mvparse_h.diff	                        (rev 0)
+++ trunk/dports/math/atlas/files/patch-mvparse_h.diff	2011-08-17 21:06:35 UTC (rev 82670)
@@ -0,0 +1,38 @@
+--- include/atlas_mvparse.h.orig	2011-08-17 22:36:13.000000000 +0200
++++ include/atlas_mvparse.h	2011-08-17 22:36:42.000000000 +0200
+@@ -243,17 +243,6 @@
+  *  use an old GOODGCC that lacks something like -pg.
+  */
+ {
+-   ATL_mvnode_t *kp;  /* queue to make sub in */
+-   char *gcc;
+-   gcc = GetGoodGcc();
+-   for (kp=bp; kp; kp = kp->next)
+-   {
+-      if (kp->comp && !strcmp(kp->comp, gcc))
+-      {
+-         free(kp->comp);
+-	 kp->comp = DupString("gcc");
+-      }
+-   }
+ }
+ 
+ /* procedure 11 */
+@@ -266,17 +255,6 @@
+  * to help portability
+  */
+ {
+-   ATL_mvnode_t *kp;  /* queue to make sub in */
+-   char *gcc;
+-   gcc = GetGoodGcc();
+-   for (kp=bp; kp; kp = kp->next)
+-   {
+-      if (kp->comp && !strcmp(kp->comp, gcc))
+-      {
+-         free(kp->comp);
+-	 kp->comp = DupString("gcc");
+-      }
+-   }
+ }
+ 
+ /* procedure 12 */
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macports-changes/attachments/20110818/77d5b952/attachment-0001.html>


More information about the macports-changes mailing list