aboutsummaryrefslogtreecommitdiffhomepage
path: root/internal/rosa/pkg-config.go
diff options
context:
space:
mode:
authorOphestra <cat@gensokyo.uk>2026-01-31 03:38:16 +0900
committerOphestra <cat@gensokyo.uk>2026-01-31 05:01:22 +0900
commit5f81aac0e23e0197b449373912aa995dd7bb004a (patch)
treeec537ec178b0d3820d22754b18fe222a710d6212 /internal/rosa/pkg-config.go
parent47490823be4d81643ed3895263feec1da64f751e (diff)
internal/rosa: make helper
This change only migrates artifacts that remain unchanged under the helper, so this change should not cause any rebuilds. Signed-off-by: Ophestra <cat@gensokyo.uk>
Diffstat (limited to 'internal/rosa/pkg-config.go')
-rw-r--r--internal/rosa/pkg-config.go24
1 files changed, 9 insertions, 15 deletions
diff --git a/internal/rosa/pkg-config.go b/internal/rosa/pkg-config.go
index 1e3ff217..28a42dc0 100644
--- a/internal/rosa/pkg-config.go
+++ b/internal/rosa/pkg-config.go
@@ -7,25 +7,19 @@ func (t Toolchain) newPkgConfig() pkg.Artifact {
version = "0.29.2"
checksum = "gi7yAvkwo20Inys1tHbeYZ3Wjdm5VPkrnO0Q6_QZPCAwa1zrA8F4a63cdZDd-717"
)
- return t.New("pkg-config-"+version, 0, []pkg.Artifact{
- t.Load(Make),
- t.Load(Gawk),
- t.Load(Coreutils),
- }, nil, nil, `
-cd "$(mktemp -d)"
-/usr/src/pkg-config/configure \
- --prefix=/system \
- --build="${ROSA_TRIPLE}" \
- CFLAGS='-Wno-int-conversion' \
- --with-internal-glib
-make "-j$(nproc)" check
-make DESTDIR=/work install
-`, pkg.Path(AbsUsrSrc.Append("pkg-config"), true, pkg.NewHTTPGetTar(
+ return t.NewViaMake("pkg-config", version, pkg.NewHTTPGetTar(
nil,
"https://pkgconfig.freedesktop.org/releases/"+
"pkg-config-"+version+".tar.gz",
mustDecode(checksum),
pkg.TarGzip,
- )))
+ ), &MakeAttr{
+ Writable: true,
+
+ Configure: [][2]string{
+ {"CFLAGS", "'-Wno-int-conversion'"},
+ {"with-internal-glib"},
+ },
+ })
}
func init() { artifactsF[PkgConfig] = Toolchain.newPkgConfig }