aboutsummaryrefslogtreecommitdiffhomepage
path: root/internal/rosa/meson.go
diff options
context:
space:
mode:
authorOphestra <cat@gensokyo.uk>2026-05-17 13:07:12 +0900
committerOphestra <cat@gensokyo.uk>2026-05-17 15:56:53 +0900
commit30eb0d6a613ad268f6805ccbcdcabf158e7f526f (patch)
tree07e55baa52748fd139e183017eeb43f5f64cee59 /internal/rosa/meson.go
parentc2ff9c9fa55ea569a5e70ee90d2eb0b2ee2a0540 (diff)
internal/rosa: key metadata by string
For upcoming azalea integration. The API is quite ugly right now to ease migration. Signed-off-by: Ophestra <cat@gensokyo.uk>
Diffstat (limited to 'internal/rosa/meson.go')
-rw-r--r--internal/rosa/meson.go12
1 files changed, 6 insertions, 6 deletions
diff --git a/internal/rosa/meson.go b/internal/rosa/meson.go
index 0aed385b..2015497c 100644
--- a/internal/rosa/meson.go
+++ b/internal/rosa/meson.go
@@ -7,12 +7,12 @@ import (
"hakurei.app/internal/pkg"
)
-func (t Toolchain) newMeson() (pkg.Artifact, string) {
+func (t Toolchain) newMeson(s *S) (pkg.Artifact, string) {
const (
version = "1.11.1"
checksum = "uvILRxdopwc6Dy17UbIeClcQr0qHqyTaqyk1M9OqWKN9PwB9N6UVAiyN8kSSz3r2"
)
- return t.NewPackage("meson", version, newFromGitHub(
+ return s.NewPackage(t, "meson", version, newFromGitHub(
"mesonbuild/meson",
version,
checksum,
@@ -52,7 +52,7 @@ python3 ./run_project_tests.py \
), version
}
func init() {
- artifactsM[Meson] = Metadata{
+ native.MustRegister(&Artifact{
f: Toolchain.newMeson,
Name: "meson",
@@ -67,7 +67,7 @@ func init() {
},
ID: 6472,
- }
+ })
}
// MesonHelper is the [Meson] build system helper.
@@ -106,7 +106,7 @@ func (*MesonHelper) createDir() bool { return false }
func (*MesonHelper) wantsDir() string { return `"$(mktemp -d)"` }
// script generates the cure script.
-func (attr *MesonHelper) script(name string) string {
+func (attr *MesonHelper) script(s *S, name string) string {
if attr == nil {
attr = new(MesonHelper)
}
@@ -117,7 +117,7 @@ func (attr *MesonHelper) script(name string) string {
}
var scriptTest string
- if !attr.SkipTest && presetOpts&OptSkipCheck == 0 {
+ if !attr.SkipTest && s.opts&OptSkipCheck == 0 {
scriptTest = `
meson test \
--print-errorlogs`