Ticket #35542: Portfile

File Portfile, 3.0 KB (added by jmstephensjr@…, 12 years ago)

file after patch, located in /opt/local/var/macports/sources/rsync.macports.org/release/tarballs/ports/math/petsc

Line 
1# $Id: Portfile 96223 2012-08-05 04:07:18Z mmoll@macports.org $
2
3PortSystem      1.0
4
5name            petsc
6version     3.3-p2
7revision    1
8categories  math science
9maintainers     mmoll
10description     Portable, Extensible Toolkit for Scientific Computation
11long_description        PETSc, pronounced PET-see (the S is silent), is a suite \
12        of data structures and routines for the scalable (parallel) solution \
13        of scientific applications modeled by partial differential equations. \
14        It employs the MPI standard for all message-passing communication.
15
16notes       "Add the following line to your .bash_profile if you plan to use\
17            the PETSC makefile rules in $prefix/lib/petsc/conf: \n\
18            \texport PETSC_DIR=${prefix}/lib/petsc"
19
20platforms       darwin
21homepage        http://www.mcs.anl.gov/petsc/petsc-as/
22master_sites    ftp://ftp.mcs.anl.gov/pub/petsc/release-snapshots/ \
23                http://ftp.mcs.anl.gov/pub/petsc/release-snapshots/
24distname        ${name}-lite-${version}
25worksrcdir      ${name}-${version}
26universal_variant   no
27
28checksums           rmd160  200d049d691bce307d576aec27a4af6799e19802 \
29                    sha256  75c0b127f1ba5077ae9d87d39331fb7cf1258c98ca7fd1dcf0f29f6d29ad3ff5
30
31depends_build-append  port:cmake
32depends_lib-append  port:hdf5-18 \
33                    port:libyaml
34
35configure.args      --prefix=${prefix}/lib/petsc \
36                    --with-mpi=1 \
37                    --with-clanguage=C++ \
38                    --download-ml \
39                    --download-metis \
40                    --download-parmetis \
41                    --download-blacs \
42                    --download-scalapack \
43                    --download-mumps \
44                    --download-ptscotch \
45                    --with-hdf5-dir=${prefix} \
46                    --with-yaml-dir=${prefix}
47
48pre-configure {
49    configure.args-append \
50        --COPTFLAGS="${configure.optflags}" \
51        --CXXOPTFLAGS="${configure.optflags}" \
52        --FOPTFLAGS="${configure.optflags}" \
53        --LDFLAGS="${configure.ldflags}" \
54        --CFLAGS="${configure.cflags}" \
55        --CXXFLAGS="${configure.cxxflags}" \
56        --FFLAGS="-lstdc++"
57}
58
59variant openmpi description {Build using the OpenMPI compiler} conflicts mpich2 {
60    depends_lib-append port:openmpi
61    configure.args-append \
62        --with-cc=${prefix}/bin/openmpicc \
63        --with-cxx=${prefix}/bin/openmpicxx \
64        --with-fc=${prefix}/bin/openmpif90 \
65        --with-mpiexec=${prefix}/bin/openmpiexec
66}
67
68variant mpich2 description {Build using the MPICH2 compiler} conflicts openmpi {
69    depends_lib-append port:mpich2
70    configure.args-append \
71        --with-cc=${prefix}/bin/mpicc \
72        --with-cxx=${prefix}/bin/picxx \
73        --with-fc=${prefix}/bin/mpif90 \
74        --with-mpiexec=${prefix}/bin/mpiexec
75}
76
77default_variants +openmpi
78
79destroot.destdir DESTDIR=${destroot}${prefix}/lib/petsc
80
81livecheck.type  regex
82livecheck.url   http://www.mcs.anl.gov/petsc/petsc-2/download/index.html
83livecheck.regex petsc-lite-(\[0-9.\]+(-p\[0-9\]+))\\.tar\\.gz