Skip to content

Commit

Permalink
improve check flags #5000
Browse files Browse the repository at this point in the history
  • Loading branch information
waruqi committed Apr 25, 2024
1 parent eae5d0f commit 979023e
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions xmake/modules/private/check/checkers/api/api_checker.lua
Original file line number Diff line number Diff line change
Expand Up @@ -145,10 +145,12 @@ function check_flag(target, toolinst, flagkind, flag)
local extraconf = target:extraconf(flagkind)
flag = target_utils.flag_belong_to_tool(target, flag, toolinst, extraconf)
if flag then
return toolinst:has_flags(flag)
else
return true
extraconf = extraconf and extraconf[flag]
if not extraconf or not extraconf.force then
return toolinst:has_flags(flag)
end
end
return true
end

-- check api configuration in targets
Expand Down

0 comments on commit 979023e

Please sign in to comment.