xmake.lua 596 B

12345678910111213141516
  1. package("json.h")
  2. set_kind("library", {headeronly = true})
  3. set_homepage("https://github.com/sheredom/json.h")
  4. set_description("single header json parser for C and C++")
  5. add_urls("https://github.com/sheredom/json.h.git")
  6. add_versions("2022.11.27", "06aa5782d650e7b46c6444c2d0a048c0a1b3a072")
  7. add_versions("2024.07.19", "3e1c624e24a0366eecc909854dc9fb0103e5c845")
  8. on_install(function (package)
  9. os.cp("*.h", package:installdir("include"))
  10. end)
  11. on_test(function (package)
  12. assert(package:has_cfuncs("json_parse", {includes = "json.h"}))
  13. end)