summaryrefslogtreecommitdiff
path: root/xmake/core/project/project.lua
diff options
context:
space:
mode:
authorruki <[email protected]>2021-07-20 22:47:58 +0800
committerruki <[email protected]>2021-07-20 22:47:58 +0800
commit801cc4d75f3aee6f845f69e9be7c55d70614071c (patch)
tree2d99f35493aa1f63e5335fa6ca5dae31dbf7b2fb /xmake/core/project/project.lua
parent4451461655f1f725aa1667a9287fb9a0367c291b (diff)
set allowed modes and archs
Diffstat (limited to 'xmake/core/project/project.lua')
-rw-r--r--xmake/core/project/project.lua5
1 files changed, 3 insertions, 2 deletions
diff --git a/xmake/core/project/project.lua b/xmake/core/project/project.lua
index 9bdb4ca4d..5bda50f05 100644
--- a/xmake/core/project/project.lua
+++ b/xmake/core/project/project.lua
@@ -650,8 +650,9 @@ function project.apis()
{
-- set_xxx
"set_project"
- , "set_modes" -- TODO deprecated
, "set_description"
+ , "set_allowedmodes"
+ , "set_allowedarchs"
-- add_xxx
, "add_requires"
, "add_requireconfs"
@@ -1081,7 +1082,7 @@ end
-- get the project modes
function project.modes()
- local modes = project.get("modes") or {}
+ local modes = project.get("allowedmodes") or {}
for _, target in pairs(table.wrap(project.targets())) do
for _, rule in ipairs(target:orderules()) do
local name = rule:name()