summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorruki <[email protected]>2021-02-14 10:10:22 +0800
committerruki <[email protected]>2021-02-14 10:10:22 +0800
commit6ba5ae3834b4e2e9efb0abb44576b669859abf26 (patch)
treedc7f75fd98d58670a6f7073ba08567805d911764
parentd22832a1eaf691db8aae20d0d08f08a98a19d23b (diff)
fix require
-rw-r--r--xmake/core/base/option.lua2
-rw-r--r--xmake/core/package/package.lua4
-rw-r--r--xmake/core/project/option.lua4
-rw-r--r--xmake/core/project/package.lua2
-rw-r--r--xmake/core/sandbox/modules/import/lib/detect/find_program.lua1
5 files changed, 7 insertions, 6 deletions
diff --git a/xmake/core/base/option.lua b/xmake/core/base/option.lua
index 977a39a40..539f3f637 100644
--- a/xmake/core/base/option.lua
+++ b/xmake/core/base/option.lua
@@ -19,7 +19,7 @@
--
-- define module: option
-local option = option or {}
+local option = {}
-- load modules
local cli = require("base/cli")
diff --git a/xmake/core/package/package.lua b/xmake/core/package/package.lua
index ccb4fd9e0..3e1862b0d 100644
--- a/xmake/core/package/package.lua
+++ b/xmake/core/package/package.lua
@@ -19,8 +19,8 @@
--
-- define module
-local package = package or {}
-local _instance = _instance or {}
+local package = {}
+local _instance = {}
-- load modules
local os = require("base/os")
diff --git a/xmake/core/project/option.lua b/xmake/core/project/option.lua
index e7d1c159c..072c1cc5f 100644
--- a/xmake/core/project/option.lua
+++ b/xmake/core/project/option.lua
@@ -19,8 +19,8 @@
--
-- define module
-local option = option or {}
-local _instance = _instance or {}
+local option = {}
+local _instance = {}
-- load modules
local io = require("base/io")
diff --git a/xmake/core/project/package.lua b/xmake/core/project/package.lua
index f2790581d..619f086a8 100644
--- a/xmake/core/project/package.lua
+++ b/xmake/core/project/package.lua
@@ -19,7 +19,7 @@
--
-- define module
-local package = package or {}
+local package = {}
-- load modules
local io = require("base/io")
diff --git a/xmake/core/sandbox/modules/import/lib/detect/find_program.lua b/xmake/core/sandbox/modules/import/lib/detect/find_program.lua
index 8e466bbd2..6fe7d845f 100644
--- a/xmake/core/sandbox/modules/import/lib/detect/find_program.lua
+++ b/xmake/core/sandbox/modules/import/lib/detect/find_program.lua
@@ -31,6 +31,7 @@ local option = require("base/option")
local project = require("project/project")
local detectcache = require("cache/detectcache")
local sandbox = require("sandbox/sandbox")
+local package = require("package/package")
local raise = require("sandbox/modules/raise")
local vformat = require("sandbox/modules/vformat")
local scheduler = require("sandbox/modules/import/core/base/scheduler")