# -*- 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           github 1.0
PortGroup           cmake 1.1

github.setup        zrax string_theory 3.8
# Change github.tarball_from to 'releases' or 'archive' next update
github.tarball_from tarball
revision            0

categories          devel
license             MIT

description         C++ string library
long_description    Flexible modern C++ string library with type-safe formatting

maintainers         {@dpogue dpogue.ca:darryl} openmaintainer

checksums           rmd160  2336921819ec5617cc2eccf4121e892f3afc7971 \
                    sha256  db8174e05a75fa0cbc0821d0ac279dcd165947d54b9280bdf4aac0054c78c22b \
                    size    68721

if {[variant_isset debug]} {
    cmake.build_type Debug
} else {
    cmake.build_type RelWithDebInfo
}

compiler.cxx_standard 2011

configure.args-append \
                    -DST_BUILD_TESTS:BOOL=OFF


variant tests description {Enable test support} {
    fetch.type      git
    post-fetch {
        system -W ${worksrcpath} "git submodule update --init"
    }

    configure.args-replace \
                    -DST_BUILD_TESTS:BOOL=OFF \
                    -DST_BUILD_TESTS:BOOL=ON

    test.run        yes
}
