From eeeb76b2d14cd942302231bdcdde04dc39cf9928 Mon Sep 17 00:00:00 2001 From: c8ef Date: Sat, 27 Apr 2024 11:40:13 +0800 Subject: [PATCH] Update find_mingw.lua --- xmake/modules/detect/sdks/find_mingw.lua | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/xmake/modules/detect/sdks/find_mingw.lua b/xmake/modules/detect/sdks/find_mingw.lua index b5eca3d5dc7..9a1f2425334 100644 --- a/xmake/modules/detect/sdks/find_mingw.lua +++ b/xmake/modules/detect/sdks/find_mingw.lua @@ -28,17 +28,16 @@ import("detect.sdks.find_cross_toolchain") -- find mingw directory function _find_mingwdir(sdkdir) - cprint("_find_mingwdir #1 %s", sdkdir) -- get mingw directory if not sdkdir then if is_host("macosx", "linux") and os.isdir("/opt/llvm-mingw") then sdkdir = "/opt/llvm-mingw" elseif is_host("macosx") and os.isdir("/usr/local/opt/mingw-w64") then + -- for macOS Intel sdkdir = "/usr/local/opt/mingw-w64" - cprint("_find_mingwdir #2 %s", sdkdir) elseif is_host("macosx") and os.isdir("/opt/homebrew/opt/mingw-w64") then + -- for Apple Silicon sdkdir = "/opt/homebrew/opt/mingw-w64" - cprint("_find_mingwdir #2 %s", sdkdir) elseif is_host("linux") then sdkdir = "/usr" elseif is_subhost("msys") then @@ -82,7 +81,6 @@ function _find_mingw(sdkdir, bindir, cross) -- find mingw root directory sdkdir = _find_mingwdir(sdkdir) - cprint("_find_mingw #1 %s", sdkdir) if not sdkdir then return end