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

name                raptor2
version             2.0.15
revision            12
set major           [lindex [split ${version} .] 0]
conflicts           ${name}-devel
description         Raptor RDF Parser Toolkit
long_description    Raptor is an open source C library that provides a set of \
                    parsers and serializers that generate Resource Description \
                    Framework (RDF) triples by parsing syntaxes or serializing \
                    the triples into a syntax.
maintainers         nomaintainer
license             {Apache-2+ GPL-2+ LGPL-2.1+}
categories          www
homepage            https://librdf.org/raptor
master_sites        https://download.librdf.org/source/

checksums           rmd160  6c3dddc13a14626f3fdece08961ad8756e237c30 \
                    sha256  ada7f0ba54787b33485d090d3d2680533520cd4426d2f7fb4782dd4a6a1480ed \
                    size    1886657

depends_build       port:flex
depends_lib         port:curl \
                    path:lib/pkgconfig/icu-uc.pc:icu \
                    port:libxml2 \
                    port:libxslt \
                    port:yajl

patchfiles-append   patch-libxml_ver.diff
patch.pre_args-replace  -p0 -p1

# raptor_json.c: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'static'
# raptor_json.c: error: 'raptor_json_yajl_integer' undeclared here (not in a function)
# compiler.c_standard 2011

test.run            yes
test.target         check

livecheck.type      regex
livecheck.url       ${master_sites}
livecheck.regex     "${name}-(\\d+(?:\\.\\d+)*)${extract.suffix}"
