aboutsummaryrefslogtreecommitdiff
path: root/.config/pkgit/repos/musl.lua
blob: df535afc4e2a5304a82a96c63b51c715cc3a8ce4 (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://git.musl-libc.org/git/musl",
  targets = {
    default = {
      build = function()
        config_cmd = "./configure --bindir="..install_directories.bin.." --libdir="..install_directories.lib.." --includedir="..install_directories.include.." --syslibdir="..install_directories.lib
				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 DESTDIR=" .. prefix .. " install")
			end,
			uninstall = function()
				return os.execute("make DESTDIR=" .. prefix .. " uninstall")
			end,
    },
  },
}