[110100] trunk/dports/python/py-usadel1/Portfile
jeremyhu at macports.org
jeremyhu at macports.org
Mon Aug 26 00:41:52 PDT 2013
Revision: 110100
https://trac.macports.org/changeset/110100
Author: jeremyhu at macports.org
Date: 2013-08-26 00:41:52 -0700 (Mon, 26 Aug 2013)
Log Message:
-----------
py-usadel1: Use fortran recipe, fixes build on Mavericks
Modified Paths:
--------------
trunk/dports/python/py-usadel1/Portfile
Modified: trunk/dports/python/py-usadel1/Portfile
===================================================================
--- trunk/dports/python/py-usadel1/Portfile 2013-08-26 07:40:29 UTC (rev 110099)
+++ trunk/dports/python/py-usadel1/Portfile 2013-08-26 07:41:52 UTC (rev 110100)
@@ -33,26 +33,48 @@
port:py${python.version}-tables
python.add_archflags no
+ universal_variant no
- variant gcc45 conflicts gcc46 gcc47 gcc48 description {Use the gcc45 compiler (enables fortran code)} {
- configure.compiler macports-gcc-4.5
+ set gcc_versions {4.3 4.4 4.5 4.6 4.7 4.8 4.9}
+ set default_fortran_variant +gcc48
+
+ foreach ver ${gcc_versions} {
+ set ver_no_dot [join [split ${ver} "."] ""]
+
+ variant gcc${ver_no_dot} description {build with gfortran from gcc${ver_no_dot}} {}
+
+ foreach over ${gcc_versions} {
+ if {${ver} == ${over}} {
+ continue
+ }
+
+ set over_no_dot [join [split ${over} "."] ""]
+ variant gcc${ver_no_dot} conflicts gcc${over_no_dot} {}
+ }
+
+ if {[variant_isset gcc${ver_no_dot}]} {
+ if {${default_fortran_variant} != "+gcc${ver_no_dot}"} {
+ set default_fortran_variant ""
+ }
+ }
}
-
- variant gcc46 conflicts gcc45 gcc47 gcc48 description {Use the gcc46 compiler (enables fortran code)} {
- configure.compiler macports-gcc-4.6
+
+ if {${default_fortran_variant} != ""} {
+ default_variants-append "${default_fortran_variant}"
}
-
- variant gcc47 conflicts gcc45 gcc46 gcc48 description {Use the gcc47 compiler (enables fortran code)} {
- configure.compiler macports-gcc-4.7
+
+ foreach ver ${gcc_versions} {
+ set ver_no_dot [join [split ${ver} "."] ""]
+
+ if {[variant_isset gcc${ver_no_dot}]} {
+ depends_lib-append port:libgcc
+ depends_build-append port:gcc${ver_no_dot}
+
+ configure.fc ${prefix}/bin/gfortran-mp-${ver}
+ configure.f77 ${prefix}/bin/gfortran-mp-${ver}
+ configure.f90 ${prefix}/bin/gfortran-mp-${ver}
+ }
}
-
- variant gcc48 conflicts gcc45 gcc46 gcc47 description {Use the gcc48 compiler (enables fortran code)} {
- configure.compiler macports-gcc-4.8
- }
-
- if {![variant_isset gcc45] && ![variant_isset gcc46] && ![variant_isset gcc48]} {
- default_variants +gcc47
- }
build.args config_fc \
--fcompiler=gfortran \
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macports-changes/attachments/20130826/338e614f/attachment.html>
More information about the macports-changes
mailing list