summaryrefslogtreecommitdiff
path: root/xmake/modules
diff options
context:
space:
mode:
authorruki <[email protected]>2020-02-27 22:37:00 +0800
committerruki <[email protected]>2020-02-27 09:42:01 +0800
commitf26c0edb8b74cd48a27d833bc75a0cd0ecf6a0a1 (patch)
treea181b445feda5a650e4ed79cb3aa02dd2b1132d3 /xmake/modules
parent8ff71e5b75987914e71fa446c0fad82868be6c50 (diff)
add dry-run command
Diffstat (limited to 'xmake/modules')
-rw-r--r--xmake/modules/private/action/build/object.lua4
1 files changed, 3 insertions, 1 deletions
diff --git a/xmake/modules/private/action/build/object.lua b/xmake/modules/private/action/build/object.lua
index b2aec9c72..aaeef7725 100644
--- a/xmake/modules/private/action/build/object.lua
+++ b/xmake/modules/private/action/build/object.lua
@@ -76,7 +76,9 @@ function _do_build_file(target, sourcefile, opt)
-- compile it
dependinfo.files = {}
- assert(compinst:compile(sourcefile, objectfile, {dependinfo = dependinfo, compflags = compflags}))
+ if not option.get("dry-run") then
+ assert(compinst:compile(sourcefile, objectfile, {dependinfo = dependinfo, compflags = compflags}))
+ end
-- update files and values to the dependent file
dependinfo.values = depvalues