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

name                qpid-proton
description         Qpid Proton is a high-performance, lightweight AMQP \
                    1.0 messaging library.
long_description    Qpid Proton is a high-performance, lightweight messaging library. It can \
                    be used in the widest range of messaging applications, including brokers, \
                    client libraries, routers, bridges, proxies, and more. Proton makes it \
                    trivial to integrate with the AMQP 1.0 ecosystem from any platform, \
                    environment, or language.
categories          net
license             Apache-2
maintainers         {unifiedsoftworx.com:roddie.kieley @roddiekieley} openmaintainer
platforms           darwin freebsd linux
homepage            https://qpid.apache.org

PortGroup           github 1.0

github.setup        apache qpid-proton 0.27.1

PortGroup           cmake 1.1

checksums           rmd160  e8829c4cfefdbef60d72b073c71c75e5591e0370 \
                    sha256  51c309f97bf8dcd18e38a61130e5aed086101c38158eea9d2e8be421ea2e2c42 \
                    size    1266378

configure.args-append \
                    -DSASL_IMPL=none \
                    -DSSL_IMPL=none \
                    -DLIB_SUFFIX="" \
                    -DBUILD_PERL=OFF \
                    -DBUILD_PYTHON=OFF \
                    -DBUILD_GO=OFF \
                    -DBUILD_RUBY=OFF \
                    -DENABLE_VALGRIND=OFF

default_variants    +openssl

variant openssl description {With built-in support for OpenSSL} {
    configure.args-replace -DSSL_IMPL=none -DSSL_IMPL=openssl

    depends_lib-append      port:openssl
}

variant swig description {With built-in support for SWIG so the bindings can be built} {
    configure.args-replace -DBUILD_PERL=OFF -DBUILD_PERL=ON
    configure.args-replace -DBUILD_PYTHON=OFF -DBUILD_PYTHON=ON
    configure.args-replace -DBUILD_GO=OFF -DBUILD_GO=ON
    configure.args-replace -DBUILD_RUBY=OFF -DBUILD_RUBY=ON

    depends_lib-append      port:swig \
                            port:swig-perl \
                            port:swig-python \
                            port:swig-go \
                            port:swig-ruby
}