aboutsummaryrefslogtreecommitdiff
path: root/.config/pkgit/repos/tinycc.lua
blob: 02f28b22c98cbb3041f788bbf140310d146af858 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
return {
	url = "https://repo.or.cz/tinycc.git",
	targets = {
		default = {
			build = function()
				config_cmd = "./configure --config-musl --exec-prefix="..prefix.." --prefix="..prefix.."/usr"
				e, h, c = os.execute(config_cmd)
				if c ~= 0 then
					print("Configuration Failure: ", c, type(c))
					print("GIVEN UP")
					return c
				end
				e,h,c = os.execute("make")
				if c ~= 0 then
					print("Compilation Error: ", c, type(c))
					print("GIVEN UP")
					return c
				end
				return 0
			end,
			install = function()
				return os.execute("make install")
			end,
			uninstall = function()
				return os.execute("make uninstall")
			end,
		}
	}
}