[106075] trunk/dports/python/py26-scientific-devel/Portfile

jmr at macports.org jmr at macports.org
Tue May 14 04:27:01 PDT 2013


Revision: 106075
          https://trac.macports.org/changeset/106075
Author:   jmr at macports.org
Date:     2013-05-14 04:27:01 -0700 (Tue, 14 May 2013)
Log Message:
-----------
py26-scientific-devel: use unified portgroup

Modified Paths:
--------------
    trunk/dports/python/py26-scientific-devel/Portfile

Modified: trunk/dports/python/py26-scientific-devel/Portfile
===================================================================
--- trunk/dports/python/py26-scientific-devel/Portfile	2013-05-14 11:18:26 UTC (rev 106074)
+++ trunk/dports/python/py26-scientific-devel/Portfile	2013-05-14 11:27:01 UTC (rev 106075)
@@ -2,9 +2,9 @@
 # $Id$
 
 PortSystem      1.0
-PortGroup       python26 1.0
+PortGroup       python 1.0
 
-name            py26-scientific-devel
+name            py-scientific-devel
 version         2.9.0
 categories-append   science
 platforms       darwin
@@ -23,44 +23,51 @@
                 sha1 60fb1ec7c31c86b7e7a068ccda780197e1e95ad8 \
                 rmd160 2533879b64fcb17027b11784fc0cff4351284c98
 
-depends_lib     port:netcdf \
-                port:py26-numpy
+python.versions 26
 
-conflicts       py26-scientific
+if {$subport != $name} {
+    depends_lib     port:netcdf \
+                    port:py${python.version}-numpy
 
-build.args		--numpy
+    conflicts       py${python.version}-scientific
 
-build.env    	CPPFLAGS="-I${python.include} \
-	            -I${worksrcpath}/Include" \
-                NETCDF_PREFIX=${prefix}
+    build.args		--numpy
 
-platform macosx {
-    post-extract {
-        copy -force ${filespath}/customize.py-macosx ${worksrcpath}/customize.py
+    build.env    	CPPFLAGS="-I${python.include} \
+                    -I${worksrcpath}/Include" \
+                    NETCDF_PREFIX=${prefix}
+
+    platform macosx {
+        post-extract {
+            copy -force ${filespath}/customize.py-macosx ${worksrcpath}/customize.py
+        }
     }
-}
 
-platform puredarwin {
-    post-extract {
-        copy -force ${filespath}/customize.py-puredarwin ${worksrcpath}/customize.py
+    platform puredarwin {
+        post-extract {
+            copy -force ${filespath}/customize.py-puredarwin ${worksrcpath}/customize.py
+        }
     }
+
+    livecheck.type  none
+} else {
+    livecheck.type  regex
+    livecheck.url   http://sourcesup.cru.fr/projects/scientific-py/
+    livecheck.regex {<strong>Development Releases</strong></td><td>(\d+(?:\.\d+)*)}
 }
 
 variant mpi description {Enable lammpi support} {
-    depends_lib-append  port:lammpi
-    patchfiles-append patch-Src-MPI-compile.py.diff
-    post-build {
-        reinplace "s|@prefix@|${prefix}|g" ${worksrcpath}/Src/MPI/compile.py
-        reinplace "s|@worksrcpath@|${worksrcpath}|g" ${worksrcpath}/Src/MPI/compile.py
-        system "cd ${worksrcpath}/Src/MPI && ${prefix}/bin/python${python.branch} compile.py"
+    if {$subport != $name} {
+        depends_lib-append  port:lammpi
+        patchfiles-append patch-Src-MPI-compile.py.diff
+        post-build {
+            reinplace "s|@prefix@|${prefix}|g" ${worksrcpath}/Src/MPI/compile.py
+            reinplace "s|@worksrcpath@|${worksrcpath}|g" ${worksrcpath}/Src/MPI/compile.py
+            system "cd ${worksrcpath}/Src/MPI && ${prefix}/bin/python${python.branch} compile.py"
+        }
+        post-destroot {
+            xinstall ${worksrcpath}/Src/MPI/mpipython ${destroot}${python.prefix}/bin
+            ln -s ${python.prefix}/bin/mpipython ${destroot}${prefix}/bin/mpipython-${python.branch}
+        }
     }
-    post-destroot {
-        xinstall ${worksrcpath}/Src/MPI/mpipython ${destroot}${python.prefix}/bin
-        ln -s ${python.prefix}/bin/mpipython ${destroot}${prefix}/bin/mpipython-${python.branch}
-    }
 }
-
-
-livecheck.type  regex
-livecheck.url   http://sourcesup.cru.fr/projects/scientific-py/
-livecheck.regex {<strong>Development Releases</strong></td><td>(\d+(?:\.\d+)*)}
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macports-changes/attachments/20130514/ff7fff38/attachment.html>


More information about the macports-changes mailing list