[147229] trunk/dports/python/py-graph-tool/Portfile

mmoll at macports.org mmoll at macports.org
Thu Mar 31 12:22:18 PDT 2016


Revision: 147229
          https://trac.macports.org/changeset/147229
Author:   mmoll at macports.org
Date:     2016-03-31 12:22:18 -0700 (Thu, 31 Mar 2016)
Log Message:
-----------
py-graph-tool: add +openmp variant (enabled by default). closes #50958.

Modified Paths:
--------------
    trunk/dports/python/py-graph-tool/Portfile

Modified: trunk/dports/python/py-graph-tool/Portfile
===================================================================
--- trunk/dports/python/py-graph-tool/Portfile	2016-03-31 18:49:02 UTC (rev 147228)
+++ trunk/dports/python/py-graph-tool/Portfile	2016-03-31 19:22:18 UTC (rev 147229)
@@ -9,8 +9,8 @@
 set realname        graph-tool
 name                py-${realname}
 version             2.13
-revision            2
-epoch               20160329
+revision            3
+epoch               20160331
 categories          python science
 platforms           darwin
 license             GPL-3
@@ -83,10 +83,6 @@
     configure.cppflags-append -I${prefix}/include -I${python.include}/..
     configure.ldflags-append -L${prefix}/lib
     configure.args-append --with-boost=${prefix} --exec-prefix=${python.prefix}
-    if {${configure.compiler} eq "macports-clang-3.8" ||
-        ${configure.compiler} eq "macports-clang-3.9"} {
-        configure.args-append --enable-openmp
-    }
     # Clang uses the old libstc++ from gcc 4.2 before OS X 10.9. Boost doesn't
     # include some of the tr1 headers in libstdc++ and defines its own tr1
     # classes. This causes conflicts with sparsehash which insists on using
@@ -107,6 +103,25 @@
                            port:librsvg
     }
 
+    variant openmp description "Enable OpenMP" {
+        configure.args-append --enable-openmp
+    }
+    variant clang37 requires openmp conflicts clang38 clang39 description "Use clang-3.7+openmp and enable OpenMP"  {
+        require_active_variants clang-3.7 openmp
+        configure.compiler  macports-clang-3.7
+    }
+    variant clang38 requires openmp conflicts clang37 clang39 description "Use clang-3.8 and enable OpenMP"  {
+        configure.compiler  macports-clang-3.8
+    }
+
+    variant clang39 requires openmp conflicts clang37 clang38 description "Use clang-3.9 and enable OpenMP" {
+        configure.compiler  macports-clang-3.9
+    }
+    default_variants +openmp
+    if {![variant_isset clang37] && ![variant_isset clang39]} {
+        default_variants-append +clang38
+    }
+
     post-destroot {
         file rename ${destroot}${prefix}/share/doc/graph-tool \
             ${destroot}${prefix}/share/doc/py${python.version}-graph-tool
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.macosforge.org/pipermail/macports-changes/attachments/20160331/ca339dee/attachment.html>


More information about the macports-changes mailing list