# -*- 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             1.17.1
revision            0
categories-append   devel
license             MIT

python.versions     27 37 38 39 310 311 312

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  669ea8ad79af0b25f44130dc0d7bf04b131e9d3e \
                    sha256  1c39c6016c32bc48dd54561950ebd6836e1670f2ae46128f67cf49e789c52824 \
                    size    516621

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} < 38} {
        version     1.15.1
        revision    0
        checksums   md5 f493860a6e98cd0c4178149568a6b4f6 \
                    rmd160 9cc1d96670ad9df27e3be8dc3132e439347542ea \
                    sha256 d400bfb9a37b1351253cb402671cea7e89bdecc294e8016a707f6d1d8ac934f9
    }

    livecheck.type      none
}
