# -*- 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 92929 2012-05-11 03:38:20Z ryandesign@macports.org $

PortSystem      1.0

name            libprelude
version         1.0.0
revision        2
categories      security
maintainers     googlemail.com:usx303 \
                openmaintainer

description     Prelude Universal SIM - framework library

long_description \
        Prelude is a Universal "Security Information Management" (SIM) system. \
        Prelude collects, normalizes, sorts, aggregates, correlates and \
        reports all security-related events independently of the product brand \
        or license giving rise to such events. \
        Libprelude is a library that guarantees secure connections between \
        all sensors and the Prelude Manager.

homepage        http://www.prelude-technologies.com/
master_sites    ${homepage}download/releases/libprelude/
platforms       darwin
build.type      gnu

checksums       rmd160  fcdb88ee27944d7b5abeec90524f995304f30c0e \
                sha256  e16d83a6a7bcc43a02d6f2bd40c91a03a258a9a86bab42262cbb5adaba8c4640
 
depends_build   port:pkgconfig
depends_lib     port:gettext port:gnutls port:libgcrypt port:libgpg-error \
                port:libiconv port:libtasn1 port:libtool port:zlib

# error: conflicting types for ‘lt__PROGRAM__LTX_preloaded_symbols’
patchfiles      patch-src-include-prelude-plugin.h.diff

configure.args  --mandir=${prefix}/share/man \
                --with-html-dir=${prefix}/share/doc \
                --localstatedir=${prefix}/var \
                --without-swig \
                --without-lua \
                --without-perl \
                --without-python \
                RUBY=no

# checking size of long... configure: error: cannot determine a size for long
universal_variant   no

destroot.keepdirs \
        ${destroot}${prefix}/var/spool/prelude \
        ${destroot}${prefix}/etc/prelude/profile

post-destroot { file delete -force "${destroot}${prefix}/lib/charset.alias" }

variant python24 conflicts python25 description {python2.4 bindings} {
        configure.args-delete	--without-python
        configure.args-append	--with-python=${prefix}/bin/python2.4
        depends_lib-append port:python24
}

variant python25 conflicts python24 description {python2.5 bindings} {
        configure.args-delete	--without-python
        configure.args-append	--with-python=${prefix}/bin/python2.5
        depends_lib-append port:python25
}

variant perl description {perl bindings} {
        configure.args-delete	--without-perl
        configure.args-append	--with-perl=${prefix}/bin/perl
        depends_lib-append path:bin/perl:perl5
}
