From 2c23cf4b3968a2c4f86253dcadba9779bc00e6ff Mon Sep 17 00:00:00 2001 From: Mole Shang <135e2@135e2.dev> Date: Fri, 1 Mar 2024 21:51:47 +0800 Subject: xmake: move deps to third_party dir --- third_party/packages/c/c11threads/xmake.lua | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) create mode 100644 third_party/packages/c/c11threads/xmake.lua (limited to 'third_party/packages/c/c11threads/xmake.lua') diff --git a/third_party/packages/c/c11threads/xmake.lua b/third_party/packages/c/c11threads/xmake.lua new file mode 100644 index 0000000..8310ca9 --- /dev/null +++ b/third_party/packages/c/c11threads/xmake.lua @@ -0,0 +1,28 @@ +package("c11threads") + +set_homepage("https://github.com/jtsiomb/c11threads") +set_description("Portable C11 threads implementation over POSIX threads and win32 threads.") + +add_urls("https://github.com/jtsiomb/c11threads/archive/ec95e1aa82079aefe109d18e5069b79711692064.zip") +add_versions("1.0-ec95e1a", "9eb5eab9db4c32418eea39543d4883022c81167ea5e37f820f5af972bea7a30e") + +on_install("linux", "macosx", function(package) + io.writefile("xmake.lua", [[ + add_rules("mode.debug", "mode.release") + target("c11threads") + set_kind("static") + add_headerfiles("c11threads.h") + ]]) + import("package.tools.xmake").install(package) +end) + +on_install("windows", "mingw", function(package) + io.writefile("xmake.lua", [[ + add_rules("mode.debug", "mode.release") + target("c11threads") + set_kind("static") + add_files("c11threads_win32.c") + add_headerfiles("c11threads.h") + ]]) + import("package.tools.xmake").install(package) +end) \ No newline at end of file -- cgit v1.2.3