[97955] trunk/dports/math/petsc/Portfile

mmoll at macports.org mmoll at macports.org
Thu Sep 20 13:35:59 PDT 2012


Revision: 97955
          http://trac.macports.org//changeset/97955
Author:   mmoll at macports.org
Date:     2012-09-20 13:35:59 -0700 (Thu, 20 Sep 2012)
Log Message:
-----------
math/petsc: update to 3.3-p3, check whether hdf5-18 is installed with +fortran variant, make sure old petsc version is deactivated before upgrade

Modified Paths:
--------------
    trunk/dports/math/petsc/Portfile

Modified: trunk/dports/math/petsc/Portfile
===================================================================
--- trunk/dports/math/petsc/Portfile	2012-09-20 20:06:46 UTC (rev 97954)
+++ trunk/dports/math/petsc/Portfile	2012-09-20 20:35:59 UTC (rev 97955)
@@ -3,7 +3,7 @@
 PortSystem	1.0
 
 name		petsc
-version     3.3-p2
+version     3.3-p3
 categories  math science
 maintainers	mmoll
 description	Portable, Extensible Toolkit for Scientific Computation
@@ -24,8 +24,8 @@
 worksrcdir	${name}-${version}
 universal_variant   no
 
-checksums           rmd160  200d049d691bce307d576aec27a4af6799e19802 \
-                    sha256  75c0b127f1ba5077ae9d87d39331fb7cf1258c98ca7fd1dcf0f29f6d29ad3ff5
+checksums           rmd160  d7c09b2f3fc5bc9780f694774c71e46504181c2a \
+                    sha256  3ebd56d62bbf97c53e13e6987ce4c9f2bf88156010f21457cb41db247bc57969
 
 depends_build-append  port:cmake
 depends_lib-append  port:hdf5-18 \
@@ -44,6 +44,12 @@
                     --with-hdf5-dir=${prefix} \
                     --with-yaml-dir=${prefix}
 
+pre-fetch {
+    if {![file exists ${prefix}/lib/libhdf5_fortran.a]} {
+        return -code error "Please install hdf5-18 with the +fortran variant enabled first."
+    }
+}
+
 pre-configure {
     configure.args-append \
         --COPTFLAGS="${configure.optflags}" \
@@ -51,7 +57,11 @@
         --FOPTFLAGS="${configure.optflags}" \
         --LDFLAGS="${configure.ldflags}" \
         --CFLAGS="${configure.cflags}" \
-        --CXXFLAGS="${configure.cxxflags}" \
+        --CXXFLAGS="${configure.cxxflags}"
+    if {[file exists ${prefix}/lib/petsc/lib/libpetsc.a]} {
+        ui_error "petsc must be deactivated before upgrade."
+        error "Please run `sudo port deactivate petsc` and try again."
+    }
 }
 
 variant openmpi description {Build using the OpenMPI compiler} conflicts mpich2 {
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macports-changes/attachments/20120920/0b65b45d/attachment.html>


More information about the macports-changes mailing list