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

name                gss
version             1.0.4
revision            0
categories          security
license             GPL-3+
maintainers         nomaintainer
description         GNU Generic Security Service Library
long_description \
   GSS is an implementation of the Generic Security Service Application \
   Program Interface (GSS-API). GSS-API is used by network servers to \
   provide security services, e.g., to authenticate SMTP/IMAP clients \
   against SMTP/IMAP servers.

homepage            https://www.gnu.org/software/gss/
master_sites        gnu
checksums           rmd160  6eb222b750116d274991e79c64411ee89770f185 \
                    sha256  ecceabdef4cae3fce7218b2ecb83eb4227dba44b53b61b8c2b2e88ae02419c73 \
                    size    1548407

patchfiles          patch-fix-m4.diff \
                    gettext-vers.patch \
                    _GL_INLINE.patch

# We are patching .m4 files
use_autoreconf      yes
autoreconf.args     -fvi
# https://trac.macports.org/wiki/WimplicitFunctionDeclaration#strchr
configure.checks.implicit_function_declaration.whitelist-append strchr

depends_build-append \
                    port:gettext \
                    port:gtk-doc \
                    path:bin/pkg-config:pkgconfig

depends_lib-append  port:libiconv \
                    port:gettext-runtime

set docdir          ${prefix}/share/doc/${name}

configure.args      --docdir=${docdir} \
                    --disable-kerberos5 \
                    --disable-silent-rules \
                    --with-libiconv-prefix=${prefix} \
                    --with-libintl-prefix=${prefix}

test.run            yes
test.target         check