diff options
Diffstat (limited to 'xmake/scripts/action/_build.lua')
| -rw-r--r-- | xmake/scripts/action/_build.lua | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/xmake/scripts/action/_build.lua b/xmake/scripts/action/_build.lua index d07005eab..288485fc1 100644 --- a/xmake/scripts/action/_build.lua +++ b/xmake/scripts/action/_build.lua @@ -37,7 +37,7 @@ function _build.done() local target_name = config.get("target") -- rebuild it? - if config.get("rebuild") then + if config.get("rebuild") or config.get("__rebuild") then clean.remove(target_name) -- update it? elseif config.get("update") then @@ -53,6 +53,19 @@ function _build.done() return false end + -- clear rebuild mark and save configure to file + if config.get("__rebuild") then + + -- clear it + config.set("__rebuild", nil) + + -- save the configure + if not config.savexconf() then + -- error + utils.error("update configure failed!") + end + end + -- ok print("build ok!") return true |
