diff options
| author | charles seizilles <[email protected]> | 2022-09-12 18:28:27 +0200 |
|---|---|---|
| committer | charles seizilles <[email protected]> | 2022-09-12 18:28:27 +0200 |
| commit | c8768fc11f3ecedfcebec4ac36a20f4e76355098 (patch) | |
| tree | 7754249a25d0988ae306614878d6da9f838542ec /xmake/modules/detect/sdks/find_matlab.lua | |
| parent | 1bf418b749afd4abaeaf36574569e6ac4fc4b8d9 (diff) | |
Rename 'runtime_version' to 'version'
Diffstat (limited to 'xmake/modules/detect/sdks/find_matlab.lua')
| -rw-r--r-- | xmake/modules/detect/sdks/find_matlab.lua | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/xmake/modules/detect/sdks/find_matlab.lua b/xmake/modules/detect/sdks/find_matlab.lua index b8089d170..308926be0 100644 --- a/xmake/modules/detect/sdks/find_matlab.lua +++ b/xmake/modules/detect/sdks/find_matlab.lua @@ -33,7 +33,7 @@ import("detect.sdks.matlab") -- function main(opt) opt = opt or {} - local runtime_version = opt.runtime_version and tostring(opt.runtime_version) or nil + local version = opt.version and tostring(opt.version) or nil local result = {sdkdir = "", includedirs = {}, linkdirs = {}, links = {}} if is_host("windows") then local matlabkey = "HKEY_LOCAL_MACHINE\\SOFTWARE\\MathWorks\\MATLAB" @@ -43,14 +43,14 @@ function main(opt) end local itemkey - if runtime_version == nil then + if version == nil then itemkey = valuekeys[1] .. ";MATLABROOT" else - local versionname = matlab.versions()[runtime_version] + local versionname = matlab.versions()[version] if versionname ~= nil then - itemkey = matlabkey .. "\\" .. runtime_version .. ";MATLABROOT" + itemkey = matlabkey .. "\\" .. version .. ";MATLABROOT" else - local versionvalue = matlab.versions_names()[runtime_version:lower()] + local versionvalue = matlab.versions_names()[version:lower()] if versionvalue ~= nil then itemkey = matlabkey .. "\\" .. versionvalue .. ";MATLABROOT" else @@ -58,7 +58,7 @@ function main(opt) for k, v in pairs(matlab.versions()) do print(" ", k, v) end - raise("MATLAB Runtime version does not exist: " .. runtime_version) + raise("MATLAB Runtime version does not exist: " .. version) end end end |
