summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSaikari <[email protected]>2026-02-16 00:30:22 +0300
committerSaikari <[email protected]>2026-02-16 00:30:22 +0300
commit92cbb94be2d3ce0d1a302beaf9e031d9ee47126a (patch)
tree0662f1d421002e17fe9b6c92cceda3e04599fd0e
parent0d4a4234f59f92c13b9b63284324b66eef1313c2 (diff)
try improve wrapper. it wont work if we pass just gcc.exe instead of fullpath as file_signature would not work without full path provided
-rw-r--r--xmake/core/sandbox/modules/import/lib/detect/find_program.lua4
1 files changed, 2 insertions, 2 deletions
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 42c1a80d7..9f1815f38 100644
--- a/xmake/core/sandbox/modules/import/lib/detect/find_program.lua
+++ b/xmake/core/sandbox/modules/import/lib/detect/find_program.lua
@@ -41,9 +41,9 @@ local scheduler = require("sandbox/modules/import/core/base/scheduler")
function sandbox_lib_detect_find_program._do_check(program, opt)
-- avoid gcc.exe signed by GIGA-BYTE
- if winos.file_signature and program:lower():match("gcc%.exe") then
+ if winos.file_signature and program:lower():endswith("gcc.exe") then
local signer = winos.file_signature(program)
- if signer and signer.signer_name and signer.signer_name:find("GIGA-BYTE", 1, true) then
+ if signer and signer.signer_name and signer.signer_name:startswith("GIGA-BYTE") then
return false
end
end