Skip to content

Commit 9ed30fe

Browse files
committed
build: delete on_run()
1 parent e7fe7ca commit 9ed30fe

File tree

1 file changed

+0
-22
lines changed

1 file changed

+0
-22
lines changed

xmake.lua

Lines changed: 0 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -16,28 +16,6 @@ target("app")
1616
add_deps("lcui")
1717
set_kind("binary")
1818
add_files("app/**.c")
19-
on_run(function (target)
20-
import("core.base.option")
21-
local argv = {}
22-
local options = {{nil, "memcheck", "k", nil, "enable memory check."}}
23-
local args = option.raw_parse(option.get("arguments") or {}, options)
24-
os.cd("$(scriptdir)/dist")
25-
if args.memcheck then
26-
if is_plat("windows") then
27-
table.insert(argv, target:targetfile())
28-
os.execv("drmemory", argv)
29-
else
30-
table.insert(argv, "valgrind")
31-
table.insert(argv, "--leak-check=full")
32-
table.insert(argv, "--error-exitcode=42")
33-
table.insert(argv, target:targetfile())
34-
os.execv("sudo", argv)
35-
end
36-
else
37-
os.execv(target:targetfile())
38-
end
39-
end)
40-
4119

4220
xpack("app")
4321
set_title("LCUI Quick Start ($(arch))")

0 commit comments

Comments
 (0)