PortSystem          1.0
PortGroup           github 1.0
PortGroup           muniversal 1.0

github.setup        jplevyak dparser 1.31 v
# Change github.tarball_from to 'releases' or 'archive' next update
github.tarball_from tarball

categories          devel lang
license             BSD
maintainers         nomaintainer
description         general-purpose parser generator
long_description \
    DParser is a simple but powerful tool for parsing.  You can specify \
    the form of the text to be parsed using a combination of regular \
    expressions and grammar productions. Because of the parsing technique \
    (technically a scannerless GLR parser based on the Tomita algorithm) \
    there are no restrictions. The grammar can be ambiguous, right or \
    left recursive, have any number of null productions, and because there \
    is no seperate tokenizer, can include whitespace in terminals and have \
    terminals which are prefixes of other terminals. DParser handles not \
    just well formed computer languages and data files, but just about any \
    wacky situation that occurs in the real world.

checksums           rmd160  4276ba0f56dba897aebd061d016d6b58bcffe7fd \
                    sha256  bc7272b245a89c7ae2ef8605c0273dd681bd7e1b774cde9561ec750ff9557755 \
                    size    190681

patchfiles          patch-Makefile-put-man-in-share.diff

use_configure       no

if {!${universal_possible} || ![variant_isset universal]} {
    build.args-append   CC="${configure.cc} ${configure.cflags} [get_canonical_archflags cc]" PREFIX=${prefix}
} else {
    foreach arch ${configure.universal_archs} {
        lappend merger_build_args(${arch}) \
            CC="${configure.cc} ${configure.cflags} -arch ${arch}" PREFIX=${prefix}
    }
}

test.run            yes

destroot.destdir    PREFIX=${destroot}${prefix}
