summaryrefslogtreecommitdiff
path: root/xmake/scripts/base/project.lua
diff options
context:
space:
mode:
authorruki <[email protected]>2015-05-15 13:07:27 +0800
committerruki <[email protected]>2015-05-15 13:07:27 +0800
commit85c024e699198fa0f20e87a611c7e8b579f76b23 (patch)
tree654373b4a99f2a1878c34c98fd7341e5aa47c671 /xmake/scripts/base/project.lua
parent62456790b7c23a4f471d45d69f65bf4dbdc5aab2 (diff)
reimpl configure
Diffstat (limited to 'xmake/scripts/base/project.lua')
-rw-r--r--xmake/scripts/base/project.lua8
1 files changed, 4 insertions, 4 deletions
diff --git a/xmake/scripts/base/project.lua b/xmake/scripts/base/project.lua
index a36b71af1..a14b1a8ed 100644
--- a/xmake/scripts/base/project.lua
+++ b/xmake/scripts/base/project.lua
@@ -21,7 +21,8 @@
--
-- load modules
-local utils = require("base/utils")
+local utils = require("base/utils")
+local config = require("base/config")
-- enter project
local _PROJECT = _PROJECT or {}
@@ -51,9 +52,8 @@ function _preprocess(value)
-- replace $(variable)
value = value:gsub("%$%((.*)%)", function (v)
if v == "buildir" then
- -- TODO
- return v
- --return xmake._CONFIGS.all.output
+ local target = config.getarget()
+ return utils.ifelse(target, target.output, nil);
elseif v == "projectdir" then
return xmake._OPTIONS.project
end