Build/Boilerplate/options.lua
Reece 630939c6ac [+] JSON -> noLink
[*] Most actions can now be json objects. Evaluating lua should be the last thing we want to do from a json file
[+] Added isArray
[*] Update language to C++20 across all modules
[*] Various improvements
[*] Various bug fixes
2021-06-03 14:00:02 +01:00

82 lines
1.4 KiB
Lua

newoption
{
trigger = "target-win32",
description = "Specifies Win32 as the host and compile machine"
}
newoption
{
trigger = "target-linux",
description = "Specifies linux as the host and compile machine"
}
newoption
{
trigger = "target-switch",
description = "Specifies NX as the host and build chain"
}
newoption
{
trigger = "target-switch-pc",
description = "Specifies NX-win32 as the host and build chain"
}
newoption
{
trigger = "target-ps5",
description = "Specifies PS5 as the host and build chain"
}
newoption
{
trigger = "target-x86_64",
description = "Use Intel vector optimizations and JIT"
}
newoption
{
trigger = "target-arm",
description = "Use ARM JIT"
}
newoption
{
trigger = "target-wayland",
description = "Compile time support for wayland"
}
newoption
{
trigger = "mm-restricted-platform",
description = "uses vendor supplied libcxx for allocations and assumes no jit unless forced"
}
local tbl =
{
"target-win32",
"target-linux",
"target-switch",
"target-ps5",
"target-x86_64",
"target-arm",
"target-wayland"
}
for i, k in pairs(tbl) do
local key = string.sub(k, 8)
_G[key] = false
if (_OPTIONS[k]) then
_G[key] = true
end
end
local userOptions = userRequire("options")
if (not userOptions) then
return
end
for i, k in pairs(userOptions) do
_G[k] = _OPTIONS[k]
end