# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:filetype=tcl:et:sw=4:ts=4:sts=4

PortSystem          1.0
PortGroup           python 1.0
PortGroup           bitbucket 1.0
PortGroup           mpi 1.0

bitbucket.setup     petsc petsc4py 3.8.1
revision            0
name                py-petsc4py
categories-append   math
license             BSD
platforms           darwin
universal_variant   no
description         PETSc for Python - Python bindings for PETSc
long_description    PETSc is a suite of data structures and routines for the scalable \
                    (parallel) solution of scientific applications modeled by partial \
                    differential equations. It employs the MPI standard for all \
                    message-passing communication.

maintainers         nomaintainer

checksums           rmd160  a86fd9d249f498e74822375b2bc4c0ceae8cc96b \
                    sha256  da07ffef7da61164ad75b23af59860fea467ae47532302d91b7b4ec561aa0f9c \
                    size    223053

mpi.setup           require

python.versions     27 35 36

build.env-append    PETSC_DIR=${prefix}/lib/petsc
destroot.env-append PETSC_DIR=${prefix}/lib/petsc

if {${subport} ne ${name}} {
    mpi.enforce_variant \
                    py${python.version}-mpi4py

    depends_build-append \
                    port:py${python.version}-setuptools \
                    port:py${python.version}-cython

    depends_lib-append \
                    port:petsc \
                    port:py${python.version}-mpi4py \
                    port:py${python.version}-numpy

    livecheck.type  none
}