# -*- 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           R 1.0

R.setup             cran traversc qs 0.27.2
revision            0
categories-append   devel
maintainers         {@barracuda156 gmail.com:vital.had} openmaintainer
license             GPL-3
description         Quick Serialization of R objects
long_description    {*}${description}
homepage            https://github.com/traversc/qs
checksums           rmd160  ad1341277be7bc682b652292e4ad2309bfa40485 \
                    sha256  ed27ebee27f37289ec1cc141134e785aeba61a2c8b9c83b463597bc17e9fab01 \
                    size    2155029

# This is again broken in upstream: https://github.com/traversc/qs/issues/98
if {[string match macports-gcc* ${configure.compiler}]} {
    patchfiles-append \
                    patch-libatomic-fix.diff
}

depends_build-append \
                    path:bin/pkg-config:pkgconfig

depends_lib-append  port:lz4 \
                    port:R-BH \
                    port:R-RApiSerialize \
                    port:R-Rcpp \
                    port:R-stringfish \
                    port:zstd

depends_test-append port:R-data.table \
                    port:R-dplyr \
                    port:R-knitr \
                    port:R-rmarkdown \
                    port:R-testthat

test.run            yes
