diff --git a/packages/s/sdsl-lite/xmake.lua b/packages/s/sdsl-lite/xmake.lua new file mode 100644 index 00000000000..d69ad8d1d09 --- /dev/null +++ b/packages/s/sdsl-lite/xmake.lua @@ -0,0 +1,31 @@ +package("sdsl-lite") + set_kind("library", {headeronly = true}) + set_homepage("https://github.com/xxsds/sdsl-lite") + set_description("Succinct Data Structure Library 3.0") + + add_urls("https://github.com/xxsds/sdsl-lite/archive/refs/tags/$(version).tar.gz", + "https://github.com/xxsds/sdsl-lite.git") + + add_versions("v3.0.3", "7b3281139f7a6c38049e967dcf1ca1d0cc9b65e62153c2ea163d2c8077dd864b") + + add_configs("cereal", {description = "support for serialisation via cereal", default = false, type = "boolean"}) + + on_load(function (package) + if package:config("cereal") then + package:add("deps", "cereal >=1.3.2") + package:add("defines", "SDSL_CEREAL=1") + end + end) + + on_install("linux", "macosx", "bsd", "android", "iphoneos", "cross", function (package) + os.cp("include", package:installdir()) + end) + + on_test(function (package) + assert(package:check_cxxsnippets({test = [[ + #include + void test() { + sdsl::memory_monitor::start(); + } + ]]}, {configs = {languages = "c++20"}})) + end) diff --git a/packages/s/seqan3/xmake.lua b/packages/s/seqan3/xmake.lua new file mode 100644 index 00000000000..28c82f879dc --- /dev/null +++ b/packages/s/seqan3/xmake.lua @@ -0,0 +1,49 @@ +package("seqan3") + set_kind("library", {headeronly = true}) + set_homepage("https://www.seqan.de") + set_description("The modern C++ library for sequence analysis. Contains version 3 of the library and API docs.") + set_license("BSD-3-Clause") + + add_urls("https://github.com/seqan/seqan3/archive/refs/tags/$(version).tar.gz", + "https://github.com/seqan/seqan3.git") + + add_versions("3.2.0", "80d41dd035407cfec83eb3a4466d0421adc27129af684290c0c4da31421e7276") + + add_configs("cereal", {description = "required for serialisation and CTD support", default = false, type = "boolean"}) + add_configs("zlib", {description = "required for *.gz and .bam file support", default = false, type = "boolean"}) + add_configs("bzip2", {description = "required for *.bz2 file support", default = false, type = "boolean"}) + + if is_plat("windows") then + add_cxxflags("/Zc:__cplusplus") + elseif is_plat("linux") then + add_syslinks("pthread") + end + + add_deps("sdsl-lite") + + on_load(function (package) + if package:config("cereal") then + package:add("deps", "cereal >=1.3.1") + end + if package:config("zlib") then + package:add("deps", "zlib >=1.2") + package:add("defines", "SEQAN3_HAS_ZLIB=1") + end + if package:config("bzip2") then + package:add("deps", "bzip2 >=1.0") + package:add("defines", "SEQAN3_HAS_BZIP2=1") + end + end) + + on_install("linux", "macosx", "bsd", "android", "iphoneos", "cross", function (package) + os.cp("include", package:installdir()) + end) + + on_test(function (package) + assert(package:check_cxxsnippets({test = [[ + #include + void test() { + seqan3::debug_stream << "Hello World!\n"; + } + ]]}, {configs = {languages = "c++20"}})) + end)