# -*- 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           gitlab 1.0
PortGroup           ocaml 1.1

gitlab.setup        camlspotter camlimages 5.0.5
revision            1
categories          ocaml devel graphics
license             {LGPL-2 Permissive}
maintainers         nomaintainer
description         Objective Caml interface to image manipulation functions.
long_description    Camlimages provides basic functions for image processing \
                    and loading/saving various image file formats, an \
                    interface to display images, and a Freetype interface \
                    to render TrueType fonts.

ocaml.build_type    dune

checksums           rmd160  6cf6452c2b7e19f03c3ea9d8edd43c46d7306263 \
                    sha256  af34b244ef3f5642a079fd58cf6bdab3603fab660f152b614f87134d4357a249 \
                    size    790491

patchfiles-append   patch-rgb_location.diff \
                    patch-caml-module.diff
post-patch {
    reinplace       "s|__MACPORTS_PREFIX__|${prefix}|g" \
                    ${worksrcpath}/config/ciconfig.ml
}

depends_build-append \
                    port:pkgconfig

depends_lib-append  port:freetype \
                    port:ghostscript \
                    port:giflib \
                    path:include/turbojpeg.h:libjpeg-turbo \
                    port:lablgtk2 \
                    port:libpng \
                    port:libexif \
                    port:ocaml-base \
                    port:ocaml-cppo \
                    port:ocaml-dune-configurator \
                    port:ocaml-stdio \
                    port:rgb \
                    port:tiff \
                    port:xpm
