xmake.lua 941 B

123456789101112131415161718192021
  1. package("stdexec")
  2. set_kind("library", {headeronly = true})
  3. set_homepage("https://github.com/NVIDIA/stdexec")
  4. set_description("`std::execution`, the proposed C++ framework for asynchronous and parallel programming. ")
  5. add_urls("https://github.com/NVIDIA/stdexec.git")
  6. add_versions("2024.03.08", "b3ba13a7b8c206371207196e08844fb7bc745438")
  7. add_deps("cmake")
  8. on_install("linux", "macosx", function (package)
  9. local configs = {"-DSTDEXEC_BUILD_EXAMPLES=OFF", "-DSTDEXEC_BUILD_TESTS=OFF"}
  10. table.insert(configs, "-DCMAKE_BUILD_TYPE=" .. (package:debug() and "Debug" or "Release"))
  11. table.insert(configs, "-DBUILD_SHARED_LIBS=" .. (package:config("shared") and "ON" or "OFF"))
  12. import("package.tools.cmake").install(package, configs)
  13. end)
  14. on_test(function (package)
  15. assert(package:has_cxxincludes("exec/static_thread_pool.hpp", {configs = {languages = "c++20"}}))
  16. end)