# Contributor: Nick Black # Maintainer: Bart Ribbers pkgname=nlohmann-json pkgver=3.7.2 pkgrel=0 pkgdesc="JSON for Modern C++" url="https://github.com/nlohmann/json" arch="noarch" license="MIT" makedepends="cmake doxygen graphviz" subpackages="$pkgname-doc" source="nlohmann-json-$pkgver.tar.gz::https://github.com/nlohmann/json/archive/v$pkgver.tar.gz" builddir="$srcdir/json-$pkgver" build() { cmake \ -DCMAKE_BUILD_TYPE=RelWithDebInfo \ -DCMAKE_INSTALL_PREFIX=/usr \ -DCMAKE_INSTALL_LIBDIR=lib make make -C doc } check() { local skipped_tests= if [ "$CARCH" = "aarch64" ]; then # test-unicode_all takes too long and times out skipped_tests="$skipped_tests|test-unicode_all" fi CTEST_OUTPUT_ON_FAILURE=TRUE ctest -E "($skipped_tests)" } package() { DESTDIR="$pkgdir" make install mkdir -p "$pkgdir"/usr/share/doc/$pkgname mv doc/html "$pkgdir"/usr/share/doc/$pkgname/ } sha512sums="c9e5350211d30fe56ff36a5be47c7ea3027759c99cb85c2ec5a03dcf5b4d340b585620922d8e5eff9d7322cc02a3db72eba8e7662d19deecd008a439cec75f52 nlohmann-json-3.7.2.tar.gz"