# -*- 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-pygtrie
version             2.5.0
revision            0

platforms           {darwin any}
supported_archs     noarch
license             Apache-2
maintainers         nomaintainer

description         Trie data structure implementation.
long_description    pygtrie is a pure Python implementation of a trie\
                    data structure. Trie data structure, also known as\
                    radix or prefix tree, is a tree associating keys\
                    to values where all the descendants of a node have\
                    a common prefix (associated with that node).  The\
                    trie module contains Trie, CharTrie and StringTrie\
                    classes each implementing a mutable mapping\
                    interface, i.e. dict interface. As such, in most\
                    circumstances, Trie could be used as a drop-in\
                    replacement for a dict, but the prefix nature of\
                    the data structure is trie’s real strength.  The\
                    module also contains PrefixSet class which uses a\
                    trie to store a set of prefixes such that a key is\
                    contained in the set if it or its prefix is stored\
                    in the set.

# swith to GitHub; treat as stealth update
dist_subdir         ${name}/${version}_1

checksums           rmd160  823b1e8a18deff25acb90814a24b6021ac1957d4 \
                    sha256  203514ad826eb403dab1d2e2ddd034e0d1534bbe4dbe0213bb0593f66beba4e2 \
                    size    39266

python.versions     314

if {${name} ne ${subport}} {
    test.run        yes
    test.args       test.py

    post-destroot {
        set docdir ${prefix}/share/doc/${subport}
        xinstall -d ${destroot}${docdir}
        xinstall -m 0644 -W ${worksrcpath} README.rst \
            ${destroot}${docdir}
    }
}
