diff --git a/xmake/core/package/package.lua b/xmake/core/package/package.lua index 5d80c5e380c..271aaad9786 100644 --- a/xmake/core/package/package.lua +++ b/xmake/core/package/package.lua @@ -1729,9 +1729,8 @@ end function _instance:_fetch_library(opt) opt = opt or {} local fetchinfo - local is_cross = self:is_cross() local on_fetch = self:script("fetch") - if on_fetch and not is_cross() then + if on_fetch and not self:is_cross() then fetchinfo = on_fetch(self, {force = opt.force, system = opt.system, external = opt.external,