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

github.setup        BelledonneCommunications bcunit 5.4.72
github.tarball_from archive
revision            0

categories          devel
license             LGPL-2
maintainers         {judaew @judaew} openmaintainer

description         This is BCUnit, a fork of the defunct project CUnit
long_description    {*}${description} \
    with several fixes and patches applied. CUnit is a Unit testing framework \
    for C. It's lightweight system for writing, administering, and running \
    unit tests in C

checksums           rmd160 f9f43ae18096cc10fc82ac96baa6f5e685d96366 \
                    sha256 b08e96df0bb30defd1311491b024ce45109784f2dbcbaea72b295d21502695fb \
                    size 378790

# cc1: error: unrecognized command line option "-Wno-clobbered"
patchfiles-append   patch-drop-unsupported-flags.diff

post-patch {
        reinplace "s,@prefix@,${prefix},g" ${worksrcpath}/bcunit.pc.in
}

compiler.c_standard 1999

configure.args-append \
                    -DENABLE_DOC=ON \
                    -DENABLE_STATIC=OFF \
                    -DCMAKE_INSTALL_BINDIR=${prefix} \
                    -DCMAKE_INSTALL_LIBDIR=${prefix}/lib \
                    -DCMAKE_INSTALL_INCLUDEDIR=${prefix}/include

github.livecheck.regex  {([0-9.]+)}
