PortSystem      1.0

name            dact
version         0.8.42
categories      archivers
platforms       darwin
maintainers     nomaintainer
license         GPL-2+
description     dynamic adaptive compression tool

long_description \
    DACT attempts to create very efficient compressed files by \
    attempting to use many different algorithms on each block until it \
    finds the best for every block in the file.

homepage        http://www.rkeene.org/oss/dact/
master_sites    http://www.rkeene.org/files/oss/dact/release/

checksums           md5     60d6ea03a08d14108ee155d2fbf1eadc \
                    sha1    f0ff1ff8a3eae9e15eeb3c9b567c7cd7f829eaac \
                    rmd160  2f79cb5a1baa64767253b499b6f0121c8f5a3857

depends_lib     port:libmcrypt \
                port:zlib \
                port:bzip2 \
                port:lzo2

# for arm64 and correct mandir
use_autoreconf  yes
autoreconf.args -fvi

configure.args  --disable-chkvers

destroot.destdir    prefix=${destroot}${prefix}

post-destroot {
    system "install_name_tool -id ${prefix}/lib/lib${name}.dylib \
        ${destroot}${prefix}/lib/lib${name}.dylib"

    set docdir ${prefix}/share/doc/${name}-${version}
    xinstall -d ${destroot}${docdir}
    xinstall -m 0644 -W ${worksrcpath} AUTHORS ChangeLog LICENSE README TODO TODO.ideas \
        ${destroot}${docdir}
}

# gcc: -E, -S, -save-temps and -M options are not allowed with multiple -arch flags
universal_variant   no

livecheck.type  regex
livecheck.url   ${homepage}
livecheck.regex Version\:</b> (\\d+(?:\\.\\d+)*)
