diff options
| author | ruki <[email protected]> | 2020-05-22 22:44:15 +0800 |
|---|---|---|
| committer | ruki <[email protected]> | 2020-05-22 10:25:35 +0800 |
| commit | b1df391694245eb0f1555b3855fad3faee0d2a82 (patch) | |
| tree | 44c84020580949a4ade4f6579a6a34b75a5f58a7 /xmake/core/platform | |
| parent | e649d1c2a8dab803bacbdd1551f629469ab5158f (diff) | |
load toolchains for project
Diffstat (limited to 'xmake/core/platform')
| -rw-r--r-- | xmake/core/platform/platform.lua | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/xmake/core/platform/platform.lua b/xmake/core/platform/platform.lua index 56491c927..af6a2f0e0 100644 --- a/xmake/core/platform/platform.lua +++ b/xmake/core/platform/platform.lua @@ -34,11 +34,10 @@ local config = require("project/config") local global = require("base/global") -- new an instance -function _instance.new(name, info, rootdir) +function _instance.new(name, info) local instance = table.inherit(_instance) instance._NAME = name instance._INFO = info - instance._ROOTDIR = rootdir return instance end @@ -465,13 +464,8 @@ function platform.load(plat) return nil, string.format("the platform %s not found!", plat) end - -- new an instance - local instance, errors = _instance.new(plat, result, interp:rootdir()) - if not instance then - return nil, errors - end - -- save instance to the cache + local instance = _instance.new(plat, result) platform._PLATFORMS[cachekey] = instance return instance end |
