blob: 750f3fbd1ce33c39cd6c5f204965b80c12a66a28 (
plain) (
tree)
|
|
# Maintainer: A. Wilcox <awilfox@adelielinux.org>
pkgname=json
pkgver=3.11.3
pkgrel=0
pkgdesc="JSON for Modern C++"
url="https://json.nlohmann.me/"
arch="noarch"
license="MIT"
depends=""
makedepends="cmake"
subpackages=""
source="json-$pkgver.tar.gz::https://github.com/nlohmann/json/archive/refs/tags/v$pkgver.tar.gz"
build() {
if [ "$CBUILD" != "$CHOST" ]; then
CMAKE_CROSSOPTS="-DCMAKE_SYSTEM_NAME=Linux -DCMAKE_HOST_SYSTEM_NAME=Linux"
fi
cmake \
-DCMAKE_INSTALL_PREFIX=/usr \
-DCMAKE_INSTALL_LIBDIR=lib \
-DCMAKE_CXX_FLAGS="$CXXFLAGS" \
${CMAKE_CROSSOPTS} \
-Bbuild
make DESTDIR="$pkgdir" -C build
}
check() {
cd build
CTEST_OUTPUT_ON_FAILURE=true ctest -E '(cmake_fetch*|test-unicode*)' -j${JOBS}
}
package() {
make DESTDIR="$pkgdir" -C build install
}
sha512sums="7df19b621de34f08d5d5c0a25e8225975980841ef2e48536abcf22526ed7fb99f88ad954a2cb823115db59ccc88d1dbe74fe6c281b5644b976b33fb78db9d717 json-3.11.3.tar.gz"
|