From 3f37633d1548ea5a6c4d1c942702198ac47a476f Mon Sep 17 00:00:00 2001 From: Chobits <44673219+chen-qingyu@users.noreply.github.com> Date: Tue, 23 Jan 2024 09:12:59 +0800 Subject: [PATCH] rename project: mds -> pytype (#3147) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * add mds * add test for mds * fixed the issue of multiple compilers for templates * update mds from 1.1.0 to 1.1.1 * rename project: mds -> pytype * update pytype --------- Co-authored-by: Jérôme Leclercq --- packages/m/mds/xmake.lua | 27 --------------------------- packages/p/pytype/xmake.lua | 27 +++++++++++++++++++++++++++ 2 files changed, 27 insertions(+), 27 deletions(-) delete mode 100644 packages/m/mds/xmake.lua create mode 100644 packages/p/pytype/xmake.lua diff --git a/packages/m/mds/xmake.lua b/packages/m/mds/xmake.lua deleted file mode 100644 index 34faf7b61..000000000 --- a/packages/m/mds/xmake.lua +++ /dev/null @@ -1,27 +0,0 @@ -package("mds") - set_kind("library", {headeronly = true}) - set_homepage("https://github.com/chen-qingyu/MyDataStructure") - set_description("A C++ containers library that is as easy to use as Python's containers library.") - set_license("GPL-3.0") - - add_urls("https://github.com/chen-qingyu/MyDataStructure/archive/refs/tags/v$(version).zip", - "https://github.com/chen-qingyu/MyDataStructure.git") - add_versions("1.1.1", "5d724a373d6906ef98c30cc0ea39ed2220d5bae09f48dd24a42e5dbfc3a04573") - add_versions("1.1.0", "537a1260ebdeeb1db9f94a3c44e628c04a70e4d26d5eb72f4206765717d6d680") - - on_install(function (package) - os.cp("sources/*.hpp", package:installdir("include/mds")) - end) - - on_test(function (package) - assert(package:check_cxxsnippets({test = [[ - #include - using namespace mds; - void test() { - Map> map = {{"first", {123, 456}}, {"second", {789}}, {"second", {0}}, {"third", {"12345678987654321", 5}}}; - assert(map.size() == 3); - assert(map.keys() == Set({"first", "second", "third"})); - assert(map["third"][-1].factorial() == 120); - } - ]]}, {configs = {languages = "c++17"}, includes = "mds/mds.hpp"})) - end) diff --git a/packages/p/pytype/xmake.lua b/packages/p/pytype/xmake.lua new file mode 100644 index 000000000..2d3009ee0 --- /dev/null +++ b/packages/p/pytype/xmake.lua @@ -0,0 +1,27 @@ +package("pytype") + set_kind("library", {headeronly = true}) + set_homepage("https://github.com/chen-qingyu/Pytype") + set_description("A C++ type library that is as easy to use as Python built-in types.") + + add_urls("https://github.com/chen-qingyu/Pytype/archive/refs/tags/$(version).tar.gz", + "https://github.com/chen-qingyu/Pytype.git") + + add_versions("v1.0.0", "406f808edf4da1901c0a7a3c188c17b206c17211e03eda30fe9af38b644fbb52") + add_versions("v1.1.0", "7c287114d98542bcca022b84fa8497c67311a99219134fce3b645881851b4c03") + + on_install(function (package) + os.cp("sources/*.hpp", package:installdir("include/pytype")) + end) + + on_test(function (package) + assert(package:check_cxxsnippets({test = [[ + #include + using namespace pytype; + void test() { + Map> map = {{"first", {123, 456}}, {"second", {789}}, {"second", {0}}, {"third", {"12345678987654321", 5}}}; + assert(map.size() == 3); + assert(map.keys() == Set({"first", "second", "third"})); + assert(map["third"][-1].factorial() == 120); + } + ]]}, {configs = {languages = "c++17"}, includes = "pytype/pytype.hpp"})) + end)