xmake.lua 945 B

123456789101112131415161718192021222324
  1. package("xorstr")
  2. set_kind("library", {headeronly = true})
  3. set_homepage("https://github.com/JustasMasiulis/xorstr")
  4. set_description("heavily vectorized c++17 compile time string encryption.")
  5. set_license("Apache-2.0")
  6. add_urls("https://github.com/JustasMasiulis/xorstr/archive/8ab293225374e16cbae9a54b6a1bed3ee0bf9681.tar.gz",
  7. "https://github.com/JustasMasiulis/xorstr.git")
  8. add_versions("2021.11.19", "b52220a50c33f8b13e6aaa2fcd14f31a44d96ba721b014ab921c30b5e3cb61eb")
  9. on_install("!cross and !wasm and mingw|!i386", function (package)
  10. os.cp("include", package:installdir())
  11. end)
  12. on_test(function (package)
  13. assert(package:check_cxxsnippets({test = [[
  14. #define JM_XORSTR_DISABLE_AVX_INTRINSICS
  15. #include <xorstr.hpp>
  16. void test() {
  17. xorstr_("hello world");
  18. }
  19. ]]}, {configs = {languages = "c++17"}}))
  20. end)