aboutsummaryrefslogtreecommitdiffhomepage
path: root/internal/rosa/package/muon/package.az
blob: 3a5be8bd3f864c9e26e18d638f9bdd0bd953e993 (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
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
package meson-tests {
	description = "tests from meson/test cases, updated alongside muon";
	website = "https://github.com/muon-build/meson-tests";
	exclude = true;

	version# = "38483b8cf5eb4f6e9df7a78d786ec111e0d6eb5d";
	output = remoteTar {
		url = "https://github.com/muon-build/meson-tests/archive/"+
			version+".tar.gz";
		checksum = "ikrJiczlObaLUMHRbzzWmGgAyZMymxxC3D9VFozD0sV3e5ckiHXk8qk0Zr8bBWvO";
		compress = gzip;
	};
	patches = [ "remove-broken-tests.patch" ];
}

package muon {
	description = "meson implementation in C";
	website = "https://muon.build";
	anitya = 391173;

	version# = "0.7.0";
	source = remoteTar {
		url = "https://git.sr.ht/~lattis/muon/archive/"+version+".tar.gz";
		checksum = "ackLkMhxutd7xvLAVU25qkM5CAztLaYf1dAC2vIvlRIZ8o6LjaNpH-3OyP1xGQTO";
		compress = gzip;
	};
	patches = [
		// for some reason, muon decides to use clang-cl on Rosa OS
		"remove-cl.patch",

		// equivalent to the meson patches
		"respect-colour.patch",
	];
	extra = [ meson-tests ];

	writable = true;
	early = `
chmod +w subprojects
cp -r ../extra/meson-tests subprojects
chmod -R +w subprojects/meson-tests
`;

	exec = generic {
		build = `
(cd /usr/src/muon && CC=cc ./bootstrap.sh /boot)
/boot/muon-bootstrap setup \
	-Dprefix=/system \
	-Dbuildtype=release \
	-Dlibcurl=disabled \
	-Dlibarchive=disabled \
	-Dlibpkgconf=disabled \
	-Dtracy=disabled \
	-Dmeson-docs=disabled \
	-Dmeson-tests=enabled \
	-Dwebsite=disabled \
	/usr/src/muon
/boot/muon-bootstrap samu `+jobsFlagE+`
`;
		check = "./muon test "+jobsFlagE+" -Rv\n";
		install = "./muon install -d /work\n";
	};

	tools = [ python-early ];
	inputs = [ kernel-headers ];
	runtime = [ pkg-config ];
}