summaryrefslogtreecommitdiff
path: root/xmake/actions/install/install.lua
diff options
context:
space:
mode:
authorruki <[email protected]>2018-09-20 23:07:53 +0800
committerruki <[email protected]>2018-09-20 12:47:21 +0800
commit5a757da5cdb45c5027a0090188c5b6401146fff4 (patch)
tree2f933ad4182b5d2c644ec39bfe5f2eaf5acea29e /xmake/actions/install/install.lua
parentab631d5b0be6697d501aaa7e7cc3393dab343549 (diff)
disable target for clean, install actions
Diffstat (limited to 'xmake/actions/install/install.lua')
-rw-r--r--xmake/actions/install/install.lua19
1 files changed, 19 insertions, 0 deletions
diff --git a/xmake/actions/install/install.lua b/xmake/actions/install/install.lua
index af4567bec..226b4076f 100644
--- a/xmake/actions/install/install.lua
+++ b/xmake/actions/install/install.lua
@@ -85,6 +85,11 @@ end
-- on install
function _on_install(target)
+ -- has been disabled?
+ if target:get("enabled") == false then
+ return
+ end
+
-- build target with rules
local done = false
for _, r in ipairs(target:orderules()) do
@@ -122,6 +127,13 @@ function _install_target(target)
{
target:script("install_before")
, function (target)
+
+ -- has been disabled?
+ if target:get("enabled") == false then
+ return
+ end
+
+ -- install rules
for _, r in ipairs(target:orderules()) do
local before_install = r:script("install_before")
if before_install then
@@ -131,6 +143,13 @@ function _install_target(target)
end
, target:script("install", _on_install)
, function (target)
+
+ -- has been disabled?
+ if target:get("enabled") == false then
+ return
+ end
+
+ -- install rules
for _, r in ipairs(target:orderules()) do
local after_install = r:script("install_after")
if after_install then