diff options
| -rw-r--r-- | xmake/core/package/package.lua | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/xmake/core/package/package.lua b/xmake/core/package/package.lua index d0c6ecd88..074e35b29 100644 --- a/xmake/core/package/package.lua +++ b/xmake/core/package/package.lua @@ -270,7 +270,14 @@ end -- get urls function _instance:urls() - return self._URLS or table.wrap(self:get("urls")) + local urls = self._URLS + if urls == nil then + urls = table.wrap(self:get("urls")) + if #urls == 1 and urls[1] == "" then + urls = {} + end + end + return urls end -- get urls @@ -615,7 +622,7 @@ end -- is local embed source code package? -- we install directly from the local source code instead of downloading it remotely function _instance:is_source_embed() - return self:get("sourcedir") and self:script("install") + return self:get("sourcedir") and #self:urls() == 0 and self:script("install") end -- is local embed binary package? it's come from `xmake package` |
