aboutsummaryrefslogtreecommitdiff
path: root/res/keymaps/bam.lua
blob: 7aef6c09593aeef6a2a837145b0cc88903b96974 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
return function(s)
	local keymaps = {}

	local BO = s.host_settings.cc.Output

	for _, file in pairs(Collect('res/keymaps/*.c')) do
		local obj = Compile(s.host_settings, file)
		local tgt = BO(s.host_settings, PathBase(file) .. '_tmp')
		local bin = Link(s.host_settings, tgt, obj)

		local out = BO(s.host_settings, PathBase(file)) .. '.km'
		AddJob(out, "call font " .. bin, "./" .. bin .. " > " .. out)
		AddDependency(out, bin)
		table.insert(keymaps, out)
	end

	return keymaps
end