local optimizations = { tiny = "-Oz", size = "-Os", debug = "-Og", zero = "-O0", one = "-O1", two = "-O2", three = "-O3", } local debug = { release = "", debug = "-g", } local compilers = {--[["mingw32",]]"mingw64"--[[,"clang32","clang64"]]} local builds = {} --2-part build since we need to compile some binaries for use during the rest of the build builds["luajit-meta"] = { requires = { {"git","luajit"} }, produces = { ["minilua"] = true, ["buildvm"] = true }, entrypoint="init-nix" } for name, optimization, rel, flag, _, image in cartesian(optimizations, debug, compilers) do local name = "luajit-" .. name .. "-" .. rel .. "-" .. image builds[name] = { image = "image-" .. image, requires = { {"git","luajit"}, {"cicd", "image-" .. image}, {"cicd", "luajit-meta:minilua"}, {"cicd", "luajit-meta:buildvm"}, }, produces = { ["lua.exe"] = true, ["lua51.dll"] = true, ["libluajit-5.1.dll.a"] = true, ["libluajit.a"] = true, }, env = { CFLAGS = optimization .. " " .. flag, }, timeout=300, } end return builds