# -*- 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
# $Id: Portfile 106277 2013-05-21 02:01:39Z cal@macports.org $

PortSystem          1.0

name                zmq
version             3.2.3
categories          devel net
license             LGPL-3+
platforms           darwin
maintainers         inconsistent.nl:merijn

description         ØMQ (ZeroMQ) lightweight messaging kernel

long_description    The ØMQ lightweight messaging kernel is a library which \
                    extends the standard socket interfaces with features \
                    traditionally provided by specialised messaging middleware \
                    products. ØMQ sockets provide an abstraction of asynchronous \
                    message queues, multiple messaging patterns, message \
                    filtering (subscriptions), seamless access to multiple \
                    transport protocols and more.

homepage            http://www.zeromq.org/
master_sites        http://download.zeromq.org/

distname            zeromq-${version}
worksrcdir          zeromq-[strsed ${version} {g/[^0-9.].*$//}]

checksums           rmd160  b31bccf91f639b67dad56ef1265db73467780515 \
                    sha256  e134c1aaf829dd77bca9dc0fa199ba31095a581bd0d3dda5fc59523b9f401238

conflicts           zmq20 zmq22

universal_variant   yes

# macports libtool allows linking against libc++, the libtool in the distribution does not
depends_build       port:libtool
build.args          LIBTOOL=${prefix}/bin/glibtool

# Work-around from upstream, delete debug prints in tests
if {${os.platform} == "darwin" && ${os.major} < 11} {
    patchfiles          patch-tests-test_disconnect_inproc.cpp.diff
}

variant pgm description {build with PGM extension} {
    configure.args-append   --with-pgm
}

livecheck.type      regex
livecheck.url       ${homepage}area:download
livecheck.regex     zeromq-(\[0-9.\]+)${extract.suffix}
