aboutsummaryrefslogtreecommitdiffhomepage
path: root/internal/rosa/gnu.go
diff options
context:
space:
mode:
authorOphestra <cat@gensokyo.uk>2026-01-29 19:51:18 +0900
committerOphestra <cat@gensokyo.uk>2026-01-29 19:51:18 +0900
commitabf96d228308fdd2f728d7ccacb170d37590d911 (patch)
tree013d014a11fb98eecbb08c0bc53f6612798ec51d /internal/rosa/gnu.go
parent6c90e879da14cf7542668da13ee6be22178e3b9b (diff)
internal/rosa: replace busybox with toybox
The busybox artifact does not run on aarch64, and the workarounds required for it to compile successfully on x86_64 is unacceptably shaky. This change fully replaces it with toybox. Signed-off-by: Ophestra <cat@gensokyo.uk>
Diffstat (limited to 'internal/rosa/gnu.go')
-rw-r--r--internal/rosa/gnu.go16
1 files changed, 12 insertions, 4 deletions
diff --git a/internal/rosa/gnu.go b/internal/rosa/gnu.go
index 8104dba4..bd00d8f5 100644
--- a/internal/rosa/gnu.go
+++ b/internal/rosa/gnu.go
@@ -31,6 +31,7 @@ func (t Toolchain) newM4() pkg.Artifact {
)
return t.New("m4-"+version, false, []pkg.Artifact{
t.Load(Make),
+ t.Load(Coreutils),
}, nil, nil, `
cd /usr/src/m4
chmod +w tests/test-c32ispunct.sh && echo '#!/bin/sh' > tests/test-c32ispunct.sh
@@ -84,6 +85,7 @@ func (t Toolchain) newAutoconf() pkg.Artifact {
t.Load(M4),
t.Load(Perl),
t.Load(Bash),
+ t.Load(Coreutils),
}, nil, nil, `
cd "$(mktemp -d)"
/usr/src/autoconf/configure \
@@ -133,6 +135,9 @@ func (t Toolchain) newGettext() pkg.Artifact {
)
return t.New("gettext-"+version, false, []pkg.Artifact{
t.Load(Make),
+ t.Load(Coreutils),
+ t.Load(Gzip),
+ t.Load(Sed),
}, nil, nil, `
cd /usr/src/gettext
test_disable() { chmod +w "$2" && echo "$1" > "$2"; }
@@ -147,6 +152,8 @@ test_disable '#!/bin/sh' gettext-tools/tests/format-c-5
test_disable '#!/bin/sh' gettext-tools/gnulib-tests/test-c32ispunct.sh
test_disable 'int main(){return 0;}' gettext-tools/gnulib-tests/test-stdcountof-h.c
+touch gettext-tools/misc/archive.dir.tar
+
cd "$(mktemp -d)"
/usr/src/gettext/configure \
--prefix=/system \
@@ -175,6 +182,7 @@ test_disable() { chmod +w "$2" && echo "$1" > "$2"; }
test_disable '#!/bin/sh' gnulib-tests/test-c32ispunct.sh
test_disable 'int main(){return 0;}' gnulib-tests/test-c32ispunct.c
+test_disable '#!/bin/sh' tests/cmp
cd "$(mktemp -d)"
/usr/src/diffutils/configure \
@@ -315,7 +323,7 @@ cd "$(mktemp -d)"
--build="${ROSA_TRIPLE}"
make "-j$(nproc)"
make DESTDIR=/work install
-`, pkg.Path(AbsUsrSrc.Append("gawk"), true, pkg.NewHTTPGetTar(
+`, pkg.Path(AbsUsrSrc.Append("gawk"), false, pkg.NewHTTPGetTar(
nil, "https://ftp.gnu.org/gnu/gawk/gawk-"+version+".tar.gz",
mustDecode(checksum),
pkg.TarGzip,
@@ -333,9 +341,9 @@ func (t Toolchain) newFindutils() pkg.Artifact {
t.Load(XZ),
t.Load(Sed),
}, nil, nil, `
-cd /usr/src
-xzcat findutils.tar.xz | tar -x
-mv 'findutils-`+version+`' findutils
+cd /usr/src/
+tar xf findutils.tar.xz
+mv findutils-`+version+` findutils
cd findutils
echo '#!/bin/sh' > gnulib-tests/test-c32ispunct.sh