From 2b93631f5274e5606358cb5af648c4361e8f3950 Mon Sep 17 00:00:00 2001 From: Ophestra Date: Wed, 25 Feb 2026 01:05:49 +0900 Subject: [PATCH] cmd/mbf: use stage2 musl when possible This avoids pulling in the stage3 toolchain when it is not requested. Signed-off-by: Ophestra --- cmd/mbf/main.go | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/cmd/mbf/main.go b/cmd/mbf/main.go index 017f45c..0b6cff8 100644 --- a/cmd/mbf/main.go +++ b/cmd/mbf/main.go @@ -270,10 +270,12 @@ func main() { root = append(root, rosa.Std.Load(p)) } - musl, compilerRT, runtimes, clang := rosa.Std.NewLLVM() - root = append(root, musl) if flagWithToolchain { - root = append(root, compilerRT, runtimes, clang) + musl, compilerRT, runtimes, clang := rosa.Std.NewLLVM() + root = append(root, musl, compilerRT, runtimes, clang) + } else { + musl, _, _, _ := (rosa.Std - 1).NewLLVM() + root = append(root, musl) } root = append(root, rosa.Std.Load(rosa.Mksh),