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

PortSystem          1.0
PortGroup           python 1.0

name                py-control
version             0.8.2
revision            0
categories-append   science
license             BSD
platforms           darwin

python.versions     27 35 36 37

maintainers         nomaintainer

description         Python package for feedback control systems
long_description    \
    The Python Control Systems Library, python-control, is a python package that \
    implements basic operations for analysis and design of feedback control \
    systems.

homepage            http://python-control.org/
master_sites        pypi:c/${python.rootname}/

distname            ${python.rootname}-${version}

checksums           rmd160  6bb9844a53a1168d3d1b12a46e6d3ce7315d752a \
                    sha256  726e8c36a253a54c8886df31f860d740d70de4f8b041421d5df078c3bff3aadb \
                    size    182584

if {${name} ne ${subport}} {
    depends_build-append \
                    port:py${python.version}-setuptools

    depends_lib-append \
                    port:py${python.version}-matplotlib \
                    port:py${python.version}-numpy \
                    port:py${python.version}-scipy

    depends_test-append \
                    port:py${python.version}-nose
    test.run        yes
    test.cmd        ${python.bin} setup.py

    post-destroot {
        xinstall -m 0755 -d ${destroot}${prefix}/share/doc/${subport}
        xinstall -m 0644 -W ${worksrcpath} ChangeLog LICENSE Pending \
            README.rst ${destroot}${prefix}/share/doc/${subport}
        xinstall -m 0644 {*}[glob ${worksrcpath}/examples/*] \
            ${destroot}${prefix}/share/doc/${subport}/examples
    }

    livecheck.type  none
}