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

name                lcdf-typetools
version             2.110
revision            1
categories          print tex
license             GPL-2+
maintainers         nomaintainer

description         Tools for manipulating fonts.
long_description    The LCDF Typetools package contains several \
                    programs for manipulating PostScript Type 1, \
                    Type 1 multiple master, and PostScript-flavored \
                    OpenType fonts.
homepage            http://www.lcdf.org/type/

installs_libs       no

master_sites        ${homepage}
checksums           rmd160  deb15840a105666210c1a6ab8e7cd76e7c9acbde \
                    sha256  517f9ee879208679d3224a14d5e6eb20598fc648d5c3562708083d003088a934 \
                    size    674355

patch.pre_args-replace  -p0 -p1

# otffvar.cc: error: ‘nullptr’ was not declared in this scope
compiler.cxx_standard 2011

configure.cxxflags-append \
                    -std=c++11

configure.args-append \
                    --without-kpathsea

destroot.target     install-strip
post-destroot {
    xinstall -m 755 -d ${destroot}${prefix}/share/doc/${name}/doc
    xinstall -m 644 -W ${worksrcpath} COPYING INSTALL NEWS.md ONEWS README.md \
        ${destroot}${prefix}/share/doc/${name}
}

variant texlive description {Link against TeXLive's libkpathsea} {
    depends_lib-append      port:texlive-bin
    configure.args-replace  --without-kpathsea \
                            --with-kpathsea=${prefix}
}

default_variants    +texlive

livecheck.type  regex
livecheck.regex ${name}-(\[0-9.\]+)\\.tar
