summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorruki <[email protected]>2018-05-04 22:58:10 +0800
committerruki <[email protected]>2018-05-04 11:49:03 +0800
commit95af67cc06c76559599b79cfd057b1253bfdc95c (patch)
tree0f78cf5ca458f2e92af190d3e31dad92ca608b7e
parent73a30725702515eb2810161e98754731699cb837 (diff)
improve tracewpp rule
-rw-r--r--tests/projects/wdk/kmdf/ioctl/localwpp.ini (renamed from tests/projects/wdk/kmdf/ioctl/driver/localwpp.ini)0
-rw-r--r--xmake/rules/wdk/xmake.lua16
2 files changed, 15 insertions, 1 deletions
diff --git a/tests/projects/wdk/kmdf/ioctl/driver/localwpp.ini b/tests/projects/wdk/kmdf/ioctl/localwpp.ini
index c290070a7..c290070a7 100644
--- a/tests/projects/wdk/kmdf/ioctl/driver/localwpp.ini
+++ b/tests/projects/wdk/kmdf/ioctl/localwpp.ini
diff --git a/xmake/rules/wdk/xmake.lua b/xmake/rules/wdk/xmake.lua
index 4158bba83..047bfe573 100644
--- a/xmake/rules/wdk/xmake.lua
+++ b/xmake/rules/wdk/xmake.lua
@@ -131,8 +131,22 @@ rule("wdk.tracewpp")
-- get configdir
local configdir = target:data("wdk.tracewpp.configdir")
+ -- init args
+ local args = {}
+ if target:rule("wdk.kmdf.driver") then
+ table.insert(args, "-km")
+ table.insert(args, "-gen:{km-WdfDefault.tpl}*.tmh")
+
+ -- TODO
+ table.insert(args, "-func:TraceEvents(LEVEL,FLAGS,MSG,...)")
+ table.insert(args, "-func:Hexdump((LEVEL,FLAGS,MSG,...))")
+ end
+ table.insert(args, "-cfgdir:" .. configdir)
+ table.insert(args, "-odir:" .. outputdir)
+ table.insert(args, sourcefile)
+
-- update the timestamp
- os.vrunv(tracewpp, {"-cfgdir:" .. configdir, "-odir:" .. outputdir, sourcefile})
+ os.vrunv(tracewpp, args, {wildcards = false})
-- add includedirs
target:add("includedirs", outputdir)