diff options
| -rw-r--r-- | xmake/modules/package/manager/pacman/find_package.lua | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/xmake/modules/package/manager/pacman/find_package.lua b/xmake/modules/package/manager/pacman/find_package.lua index 119a8169e..ccbb590cf 100644 --- a/xmake/modules/package/manager/pacman/find_package.lua +++ b/xmake/modules/package/manager/pacman/find_package.lua @@ -113,7 +113,9 @@ function main(name, opt) -- for msys2/mingw? mingw-w64-[i686|x86_64]-xxx if is_subhost("msys") and opt.plat == "mingw" then - name = (opt.arch == "x86_64" and "mingw-w64-x86_64-" or "mingw-w64-i686-") .. name + -- try to get the package prefix from the environment first + -- https://www.msys2.org/docs/package-naming/ + name = (os.getenv("MINGW_PACKAGE_PREFIX") or (opt.arch == "x86_64" and "mingw-w64-x86_64" or "mingw-w64-i686")) .. "-" .. name end -- get package files list |
