[144223] trunk/dports/science/ccpnmr/Portfile

sean at macports.org sean at macports.org
Mon Jan 4 16:49:16 PST 2016


Revision: 144223
          https://trac.macports.org/changeset/144223
Author:   sean at macports.org
Date:     2016-01-04 16:49:16 -0800 (Mon, 04 Jan 2016)
Log Message:
-----------
ccpnmr: use compilers portgroup; fixes #49010

Modified Paths:
--------------
    trunk/dports/science/ccpnmr/Portfile

Modified: trunk/dports/science/ccpnmr/Portfile
===================================================================
--- trunk/dports/science/ccpnmr/Portfile	2016-01-05 00:41:40 UTC (rev 144222)
+++ trunk/dports/science/ccpnmr/Portfile	2016-01-05 00:49:16 UTC (rev 144223)
@@ -2,6 +2,7 @@
 # $Id$
 
 PortSystem          1.0
+PortGroup           compilers 1.0
 
 name                ccpnmr
 version             2.4.2
@@ -27,6 +28,9 @@
 patchfiles          ccpnmr.patch
 use_configure       no
 
+compilers.choose    cc cxx
+compilers.setup     -clang -dragonegg -g95 -gfortran -llvm
+
 set python.branch	2.7
 set python.prefix	${frameworks_dir}/Python.framework/Versions/${python.branch}
 set python.bin	${python.prefix}/bin/python${python.branch}
@@ -34,9 +38,11 @@
 set python.libdir ${python.prefix}/lib/python${python.branch}
 set python.include	${python.prefix}/include/python${python.branch}
 
-set lib ""
-
 post-patch {
+    set lib ""
+    if {[gcc_variant_isset]} {
+        set lib "${prefix}/lib/[gcc_variant_name]"
+    }
     reinplace  "s|@PYTHON_BIN@|${python.bin}|g"   ${worksrcpath}/bin/analysis \
                                                   ${worksrcpath}/bin/formatConverter \
                                                   ${worksrcpath}/bin/pipe2azara \
@@ -78,27 +84,6 @@
     system "${python.bin} -O ${python.libdir}/compileall.py -d ${python.pkgd}/${name}/${name}${branch} ${destroot}${python.pkgd}/${name}/${name}${branch}"
 }
 
-variant gcc45 conflicts gcc46 gcc47 gcc48 gcc49  description {Build with GCC 4.5} {
-    configure.compiler  macports-gcc-4.5
-    set lib ${prefix}/lib/gcc45
+if {![gcc_variant_isset]} {
+    default_variants-append +${compilers.gcc_default}
 }
-variant gcc46 conflicts gcc45 gcc47 gcc48 gcc49 description {Build with GCC 4.6} {
-    configure.compiler  macports-gcc-4.6
-    set lib ${prefix}/lib/gcc46
-}
-variant gcc47 conflicts gcc45 gcc46 gcc48 gcc49 description {Build with GCC 4.7} {
-    configure.compiler  macports-gcc-4.7
-    set lib ${prefix}/lib/gcc47
-}
-variant gcc48 conflicts gcc45 gcc46 gcc47 gcc49 description {Build with GCC 4.8} {
-    configure.compiler  macports-gcc-4.8
-    set lib ${prefix}/lib/gcc48
-}
-variant gcc49 conflicts gcc45 gcc46 gcc47 gcc48 description {Build with GCC 4.9} {
-    configure.compiler  macports-gcc-4.9
-    set lib ${prefix}/lib/gcc49
-}
-
-if {![variant_isset gcc45] && ![variant_isset gcc46] && ![variant_isset gcc47] && ![variant_isset gcc48] && ![variant_isset gcc49]} {
-    default_variants    +gcc48
-}
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.macosforge.org/pipermail/macports-changes/attachments/20160104/1406e2f0/attachment.html>


More information about the macports-changes mailing list