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

name                    libe-book
version                 0.1.3
revision                9
categories              textproc multimedia devel
license                 MPL-2
maintainers             {mcalhoun @MarcusCalhoun-Lopez} openmaintainer

description             library for import of reflowable e-book formats
long_description        libe-book is a library and a set of tools for reading and converting \
                        various reflowable e-book formats.

homepage                https://sourceforge.net/projects/libebook/
master_sites            sourceforge:libebook

checksums               rmd160  77ffc3b6fe7982f4ed2aa08b91ad265737488218 \
                        sha256  b76f0f9170160cb07e77905d3d6ecdf07757b4373ebd77484e5561e0b62b710c \
                        size    660524

boost.depends_type      build
depends_build-append    port:pkgconfig \
                        port:gperf

depends_lib-append      path:lib/pkgconfig/icu-uc.pc:icu \
                        port:liblangtag \
                        port:librevenge \
                        port:libxml2 \
                        port:zlib

# Required for ICU
compiler.cxx_standard   2017
configure.cxxflags-append   -std=c++17
configure.env-append    ICU_LIBS=-licui18n\ -licuuc

patch.pre_args-replace  -p0 -p1
patchfiles              0001-fix-build-with-ICU-68.patch

# avoid dependency on cppunit
configure.args-append   --enable-tests=no

livecheck.regex         {/libe-book-(\d+(?:\.\d+)*)}
