# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:filetype=tcl:et:sw=4:ts=4:sts=4
# $Id: Portfile 91901 2012-04-13 02:59:28Z jeremyhu@macports.org $

PortSystem      1.0
PortGroup       archcheck 1.0

name            libsoup
version         2.38.0
set branch      [join [lrange [split ${version} .] 0 1] .]
categories      gnome net
platforms       darwin
license         LGPL-2+
maintainers     devans openmaintainer
description     Soup is an HTTP library implementation in C.

long_description \
    Soup provides a queued asynchronous callback-based \
    mechanism for sending and servicing SOAP requests \
    and a WSDL (Web Service Definition Language) for C \
    compilers which generates client stubs and server \
    skeletons for easily calling and implementing SOAP \
    methods.

homepage        http://www.gnome.org/
master_sites    gnome:sources/${name}/${branch}/
use_xz          yes

checksums       md5     8a44d7cf1dea364b08cec2188b616657 \
                sha1    a23cf69fc5428fa5ae6d892acb6e5e295baddbc2 \
                rmd160  df21331ad25116ba5505cd5fd72b4ba7454f22c8

depends_build   port:pkgconfig

depends_lib     port:libxml2 \
                port:glib-networking \
                port:sqlite3 \
                port:gconf \
                port:libproxy \
                port:libgnome-keyring

archcheck.files \
    lib/gio/modules/libgiognutls.so \
    lib/gio/modules/libgiolibproxy.so \
    lib/libsqlite3.dylib \
    lib/libxml2.dylib

configure.args \
    --disable-more-warnings

test.run        yes
test.target     check

variant no_gnome description "Disable GNOME support" {
    depends_lib-delete \
        port:gconf \
        port:libgnome-keyring

    configure.args-append \
        --without-gnome
}

platform darwin 8 {
    depends_run-append      port:gmake
    depends_skip_archcheck-append gmake
    build.cmd               ${prefix}/bin/gmake
    destroot.cmd            ${prefix}/bin/gmake
}

livecheck.type  regex
livecheck.url   ftp://ftp.gnome.org/pub/gnome/sources/$name/$branch/
livecheck.regex {LATEST-IS-(\d+(?:\.\d+)*)}
