nlohmann_json: new recipe

used by bear
This commit is contained in:
Jerome Duval
2021-10-18 18:11:42 +02:00
parent 305449a880
commit e314db9da9

View File

@@ -0,0 +1,44 @@
SUMMARY="JSON for Modern C++"
DESCRIPTION="Header only library"
HOMEPAGE="https://github.com/nlohmann/json"
COPYRIGHT="2013-2021 Niels Lohmann"
LICENSE="MIT"
REVISION="1"
SOURCE_URI="http://github.com/nlohmann/json/archive/v$portVersion/json-$portVersion.tar.gz"
CHECKSUM_SHA256="1155fd1a83049767360e9a120c43c578145db3204d2b309eba49fbbedd0f4ed3"
SOURCE_DIR="json-$portVersion"
ARCHITECTURES="all !x86_gcc2"
SECONDARY_ARCHITECTURES="x86"
PROVIDES="
nlohmann_json$secondaryArchSuffix = $portVersion
devel:nlohmann_json$secondaryArchSuffix = $portVersion
"
REQUIRES="
haiku$secondaryArchSuffix
"
BUILD_REQUIRES="
haiku${secondaryArchSuffix}_devel
"
BUILD_PREREQUIRES="
cmd:cmake
cmd:gcc$secondaryArchSuffix
cmd:make
"
BUILD()
{
sed -i -e "s|:include>|:${relativeIncludeDir}>|" CMakeLists.txt
cmake -B build -S . $cmakeDirArgs \
-DCMAKE_BUILD_TYPE=Release
make -C build $jobArgs
}
INSTALL()
{
make -C build install
fixPkgconfig
}