summaryrefslogtreecommitdiff
path: root/tests/actions/addon/custom-toolchain/src/modules/detect/tools/find_mycl6x.lua
blob: c0ed3791464150c01a8ff2f9eea42c19e9bdbe0c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
import("lib.detect.find_program")

-- find the compiler of the my-c6000 toolchain
--
-- @note it's just the host compiler, we only need a real program to build with,
-- the point of this test is that this finder itself comes from the addon
--
function main(opt)
    for _, name in ipairs({"gcc", "clang", "cc"}) do
        local program = find_program(name, opt)
        if program then
            return program
        end
    end
end