diff options
| author | Arthur LAURENT <[email protected]> | 2025-10-31 19:51:35 +0100 |
|---|---|---|
| committer | ruki <[email protected]> | 2025-12-18 09:31:43 +0800 |
| commit | 7a1be435eef977b88a2855df9bafc4ebeca1843e (patch) | |
| tree | 687371e4df59a735060f25082322e7062984be71 /tests/projects/c/llvm_compiler_rt/test.lua | |
| parent | 2a81ad148a079dd0cb42c045b8d532b61d154e50 (diff) | |
nfc(llvm) add a test for llvm builtins
Diffstat (limited to 'tests/projects/c/llvm_compiler_rt/test.lua')
| -rw-r--r-- | tests/projects/c/llvm_compiler_rt/test.lua | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/tests/projects/c/llvm_compiler_rt/test.lua b/tests/projects/c/llvm_compiler_rt/test.lua new file mode 100644 index 000000000..3d9fd2cad --- /dev/null +++ b/tests/projects/c/llvm_compiler_rt/test.lua @@ -0,0 +1,18 @@ +import("lib.detect.find_tool") +import("utils.ci.is_running", {alias = "ci_is_running"}) + +function main(t) + local flags = "" + if ci_is_running() then + flags = "-vD" + end + + local cc = find_tool("clang", {version = true}) + if not cc then + wprint("clang not found, skipping tests") + return + end + os.exec("xmake clean -a") + os.exec("xmake f --toolchain=llvm -c --yes " .. flags) + os.run("xmake -r " .. flags) +end |
