aboutsummaryrefslogtreecommitdiffhomepage
path: root/internal/rosa/llvm.go
diff options
context:
space:
mode:
authorOphestra <cat@gensokyo.uk>2026-05-21 15:35:48 +0900
committerOphestra <cat@gensokyo.uk>2026-05-21 15:36:10 +0900
commitcbf18b302d51c3e667ebe06cfebb14b90ccc93b7 (patch)
treec3ad2222ae0e28cf00f11d305a44b8fb900cbf6f /internal/rosa/llvm.go
parent1acb5b010507dd2246b77b8c856612b86cb2eda4 (diff)
internal/rosa/package: migrate nss
Signed-off-by: Ophestra <cat@gensokyo.uk>
Diffstat (limited to 'internal/rosa/llvm.go')
-rw-r--r--internal/rosa/llvm.go86
1 files changed, 42 insertions, 44 deletions
diff --git a/internal/rosa/llvm.go b/internal/rosa/llvm.go
index 7db15d1e..11f8ad0b 100644
--- a/internal/rosa/llvm.go
+++ b/internal/rosa/llvm.go
@@ -9,21 +9,21 @@ import (
)
var (
- llvmSource = H("llvm-project")
- muslHeaders = H("musl-headers")
- earlyCompilerRT = H("early-compiler-rt")
- earlyRuntimes = H("early-runtimes")
- musl = H("musl")
+ _llvmSource = H("llvm-project")
+ _muslHeaders = H("musl-headers")
+ _earlyCompilerRT = H("early-compiler-rt")
+ _earlyRuntimes = H("early-runtimes")
+ _musl = H("musl")
- bash = H("bash")
- gawk = H("gawk")
- coreutils = H("coreutils")
- diffutils = H("diffutils")
- findutils = H("findutils")
+ _bash = H("bash")
+ _gawk = H("gawk")
+ _coreutils = H("coreutils")
+ _diffutils = H("diffutils")
+ _findutils = H("findutils")
- zlib = H("zlib")
- zstd = H("zstd")
- kernelHeaders = H("kernel-headers")
+ _zlib = H("zlib")
+ _zstd = H("zstd")
+ _kernelHeaders = H("kernel-headers")
)
// litArgs returns LIT arguments for optional verbosity and check skipping.
@@ -53,11 +53,9 @@ func init() {
Name: "early-compiler-rt",
Description: "early LLVM runtime: compiler-rt",
- Dependencies: P{
- musl,
- },
+ Dependencies: P{_musl},
}
- _meta, source := t.MustLoad(llvmSource)
+ _meta, source := t.MustLoad(_llvmSource)
meta.Version = _meta.Version
major, _, _ := strings.Cut(meta.Version, ".")
return &meta, t.NewPackage("early-compiler-rt", meta.Version, source, &PackageAttr{
@@ -106,10 +104,10 @@ ln -s \
"/work/system/lib/${ROSA_TRIPLE}/crtendS.o"
`,
},
- Python,
+ _python,
- muslHeaders,
- kernelHeaders,
+ _muslHeaders,
+ _kernelHeaders,
)
})
@@ -119,10 +117,10 @@ ln -s \
Description: "early LLVM runtimes: libunwind, libcxx, libcxxabi",
Dependencies: P{
- earlyCompilerRT,
+ _earlyCompilerRT,
},
}
- _meta, source := t.MustLoad(llvmSource)
+ _meta, source := t.MustLoad(_llvmSource)
meta.Version = _meta.Version
return &meta, t.NewPackage("early-runtimes", meta.Version, source, &PackageAttr{
@@ -162,12 +160,12 @@ ln -s \
},
SkipTest: true,
},
- Python,
+ _python,
- zlib,
- zstd,
- earlyCompilerRT,
- kernelHeaders,
+ _zlib,
+ _zstd,
+ _earlyCompilerRT,
+ _kernelHeaders,
)
})
@@ -184,7 +182,7 @@ ln -s \
ID: 1830,
}
- return &meta, t.NewPatchedSource("llvm", version, newFromGitHub(
+ return &meta, t.NewPatchedSource("llvm-"+version, newFromGitHub(
"llvm/llvm-project",
"llvmorg-"+version,
checksum,
@@ -198,22 +196,22 @@ ln -s \
Website: "https://llvm.org",
Dependencies: P{
- zlib,
- zstd,
- musl,
+ _zlib,
+ _zstd,
+ _musl,
},
}
- _meta, source := t.MustLoad(llvmSource)
+ _meta, source := t.MustLoad(_llvmSource)
meta.Version = _meta.Version
- early := muslHeaders
+ early := _muslHeaders
if t.stage.isStage0() {
// The LLVM build system uses the system installation when building with
// LLVM_LINK_LLVM_DYLIB, since it builds runtimes after the fact, using
// the just-built toolchain. This is unacceptable in stage0 due to the
// potential version difference. Later stages bootstrap off of runtimes
// of its previous stage via 3-stage determinism.
- early = earlyRuntimes
+ early = _earlyRuntimes
}
cache := []KV{
@@ -351,18 +349,18 @@ chmod +w /bin && ln -s \
ninja ` + jobsFlagE + ` check-all
`,
},
- Python,
- Perl,
- diffutils,
- bash,
- gawk,
- coreutils,
- findutils,
+ _python,
+ _perl,
+ _diffutils,
+ _bash,
+ _gawk,
+ _coreutils,
+ _findutils,
- zlib,
- zstd,
+ _zlib,
+ _zstd,
early,
- kernelHeaders,
+ _kernelHeaders,
)
})