# -*- 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           cmake 1.1
PortGroup           github 1.0

github.setup        artivis manif c8a9fcbfe157b55a7a860577febdc5350043a722
# Change github.tarball_from to 'releases' or 'archive' next update
github.tarball_from tarball
version             2023.11.03
revision            0
categories          devel
license             MIT
maintainers         nomaintainer
description         Small C++11 header-only library for Lie theory
long_description    manif is a Lie theory library for state-estimation targeted at robotics applications. \
                    It is developed as a header-only C++11 library with Python 3 wrappers.
homepage            https://artivis.github.io/manif
checksums           rmd160  62e17b670616963ccc2e6adf3bc81af176d9836d \
                    sha256  305089cd56285fb69b1a10e1afb1346b34e4c92ce1614e73c55f11bb5b6b6ea3 \
                    size    728266
platforms           any
supported_archs     noarch

depends_lib-append  path:share/pkgconfig/eigen3.pc:eigen3
depends_build-append \
                    port:gtest

# https://github.com/artivis/manif/pull/277
patchfiles-append   0001-Add-missing-cassert-in-eigen.h.patch \
                    0002-Fix-gtest_rn-for-32-bit-platforms.patch

# Required for tests, see: https://github.com/artivis/manif/issues/269
compiler.cxx_standard 2014
compiler.blacklist-append {clang < 800}
cmake.set_cxx_standard yes

configure.args-append \
                    -DBUILD_BENCHMARKING=OFF \
                    -DBUILD_EXAMPLES=OFF \
                    -DBUILD_PYTHON_BINDINGS=OFF \
                    -DBUILD_TESTING=ON \
                    -DBUILD_TESTING_PYTHON=OFF \
                    -DENABLE_CPPCHECK=OFF \
                    -DUSE_SYSTEM_WIDE_TL_OPTIONAL=OFF

test.run            yes
