# -*- 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                xercesc3
conflicts           xercesc
version             3.2.0
categories          textproc xml shibboleth
maintainers         snc scantor
license             Apache-2
description         an XML parser
long_description    Xerces-C++ is a validating XML parser written in \
                    a portable subset of C++.  Xerces-C++ makes it \
                    easy to give your application the ability to read \
                    and write XML data.  A shared library is provided \
                    for parsing, generating, manipulating, and \
                    validating XML documents.
homepage            http://xerces.apache.org/xerces-c/
master_sites        apache:xerces/c/3/sources/
distname            xerces-c-${version}
use_bzip2           yes

configure.args      --disable-silent-rules \
                    --enable-static \
                    --enable-netaccessor-socket \
                    --enable-transcoder-icu \
                    --enable-msgloader-icu \
                    --with-icu=${prefix}
checksums           rmd160  4a2ede7d36e2295999123d6c9c3990d7e82f5521 \
                    sha256  9f3327b63fd7eef3de45025449d5d948ab46f066a475706d2e34f94e91617b34

platforms           darwin

depends_lib         port:icu

post-destroot {
    # Rename the bin programs with a prefix to avoid conflicts
    foreach f [glob -tails -directory ${destroot}${prefix}/bin *] {
        move ${destroot}${prefix}/bin/${f} ${destroot}${prefix}/bin/Xerces${f}
    }
}

livecheck.type      regex
livecheck.url       http://www.apache.org/dist/xerces/c/3/sources/
livecheck.regex     xerces-c-(\\d+\\.\\d+\\.\\d+)
