# -*- 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
PortGroup           compiler_wrapper 1.0

name                py-cffi
version             2.0.0
revision            0
categories-append   devel
license             MIT

python.versions     27 310 311 312 313 314

maintainers         {stromnov @stromnov} openmaintainer

description         Foreign Function Interface for Python calling C code.

long_description    Foreign Function Interface for Python calling C code. \
                    The aim of this project is to provide a convenient and \
                    reliable way of calling C code from Python.

homepage            https://cffi.readthedocs.org/

checksums           rmd160  a7db9ebbcd8a56b9772983202bc64a278d80ce65 \
                    sha256  44d1b5909021139fe36001ae048dbdde8214afa20200eda0f64c068cac5d5529 \
                    size    523588

if {${name} ne ${subport}} {
    patchfiles-append   patch-setup.py.diff

    # ticket 61804
    compiler.blacklist-append *gcc-3.* *gcc-4.*

    depends_build-append \
                        port:py${python.version}-setuptools
    depends_lib-append  port:libffi \
                        port:py${python.version}-pycparser

    if {${python.version} == 27} {
        version     1.15.1
        revision    0
        checksums   md5 f493860a6e98cd0c4178149568a6b4f6 \
                    rmd160 9cc1d96670ad9df27e3be8dc3132e439347542ea \
                    sha256 d400bfb9a37b1351253cb402671cea7e89bdecc294e8016a707f6d1d8ac934f9
    }

    livecheck.type      none
}
