[144233] trunk/dports/python/py-qutip/Portfile

dstrubbe at macports.org dstrubbe at macports.org
Mon Jan 4 19:12:14 PST 2016


Revision: 144233
          https://trac.macports.org/changeset/144233
Author:   dstrubbe at macports.org
Date:     2016-01-04 19:12:14 -0800 (Mon, 04 Jan 2016)
Log Message:
-----------
py-qutip: Use compilers portgroup for Fortran variants. Remove "required" variant +scientific for ipython which no longer exists. Probably CFLAGS etc should be set to configure.cflags not configure.cc_archflags etc.

Modified Paths:
--------------
    trunk/dports/python/py-qutip/Portfile

Modified: trunk/dports/python/py-qutip/Portfile
===================================================================
--- trunk/dports/python/py-qutip/Portfile	2016-01-05 03:06:56 UTC (rev 144232)
+++ trunk/dports/python/py-qutip/Portfile	2016-01-05 03:12:14 UTC (rev 144233)
@@ -4,6 +4,7 @@
 PortSystem              1.0
 PortGroup               python 1.0
 PortGroup               active_variants 1.1
+PortGroup               compilers 1.0
 
 name                    py-qutip
 version                 3.1.0
@@ -27,59 +28,18 @@
 
 # py-scipy is not universal
 if {${name} ne ${subport}} {
+    compilers.choose    fc f77 f90
+    compilers.setup     require_fortran
+
     depends_lib-append  port:py${python.version}-cython \
                         port:py${python.version}-ipython \
                         port:py${python.version}-matplotlib \
                         port:py${python.version}-numpy \
                         port:py${python.version}-scipy
 
-    require_active_variants py${python.version}-ipython "notebook parallel scientific"
+    require_active_variants py${python.version}-ipython "notebook parallel"
     require_active_variants py${python.version}-matplotlib latex
 
-    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} "."] ""]
-
-        set variant_line {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} "."] ""]
-            append variant_line " conflicts gcc${over_no_dot}"
-        }
-        append variant_line { {}}
-
-        eval $variant_line
-
-        if {[variant_isset gcc${ver_no_dot}]} {
-            if {${default_fortran_variant} != "+gcc${ver_no_dot}"} {
-                set default_fortran_variant ""
-            }
-        }
-    }
-
-    if {${default_fortran_variant} != ""} {
-        default_variants-append "${default_fortran_variant}"
-    }
-
-    foreach ver ${gcc_versions} {
-        set ver_no_dot [join [split ${ver} "."] ""]
-
-        if {[variant_isset gcc${ver_no_dot}]} {
-            depends_lib-append path:lib/libgcc/libgcc_s.1.dylib: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}
-        }
-    }
-
     use_parallel_build  no
 
     python.add_archflags    no
@@ -88,6 +48,7 @@
     build.args
     build.post_args-append  --with-f90mc
 
+    # why only archflags?
     build.env-append CFLAGS="${configure.cc_archflags}" \
                      OBJCFLAGS="${configure.objc_archflags}" \
                      CXXFLAGS="${configure.cxx_archflags}" \
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.macosforge.org/pipermail/macports-changes/attachments/20160104/0b34a543/attachment-0001.html>


More information about the macports-changes mailing list