yyjson: new package (#47563)

* yyjson: new package

* [@spackbot] updating style on behalf of pranav-sivaraman

---------

Co-authored-by: pranav-sivaraman <pranav-sivaraman@users.noreply.github.com>
This commit is contained in:
Pranav Sivaraman 2024-11-14 14:01:21 -05:00 committed by GitHub
parent 9888683a21
commit 9b2cd1b208
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -0,0 +1,23 @@
# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other
# Spack Project Developers. See the top-level COPYRIGHT file for details.
#
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
from spack.package import *
class Yyjson(CMakePackage):
"""The fastest JSON library in C"""
homepage = "https://ibireme.github.io/yyjson/doc/doxygen/html/"
url = "https://github.com/ibireme/yyjson/archive/refs/tags/0.10.0.tar.gz"
license("MIT", checked_by="pranav-sivaraman")
version("0.10.0", sha256="0d901cb2c45c5586e3f3a4245e58c2252d6b24bf4b402723f6179523d389b165")
depends_on("c", type="build")
depends_on("cxx", type="build") # TODO: test only dependency, but does not work
def cmake_args(self):
return [self.define("YYJSON_BUILD_TESTS", self.run_tests)]