internal/rosa: kernel patching
All checks were successful
Test / Create distribution (push) Successful in 50s
Test / Sandbox (push) Successful in 2m44s
Test / Hakurei (push) Successful in 3m56s
Test / ShareFS (push) Successful in 4m8s
Test / Hpkg (push) Successful in 4m43s
Test / Sandbox (race detector) (push) Successful in 5m12s
Test / Hakurei (race detector) (push) Successful in 6m5s
Test / Flake checks (push) Successful in 1m57s
All checks were successful
Test / Create distribution (push) Successful in 50s
Test / Sandbox (push) Successful in 2m44s
Test / Hakurei (push) Successful in 3m56s
Test / ShareFS (push) Successful in 4m8s
Test / Hpkg (push) Successful in 4m43s
Test / Sandbox (race detector) (push) Successful in 5m12s
Test / Hakurei (race detector) (push) Successful in 6m5s
Test / Flake checks (push) Successful in 1m57s
The side effect of this is to work around zfs performance issue with chmod on overlay mount. Signed-off-by: Ophestra <cat@gensokyo.uk>
This commit is contained in:
@@ -8,6 +8,7 @@ import (
|
|||||||
|
|
||||||
// newKernel is a helper for interacting with Kbuild.
|
// newKernel is a helper for interacting with Kbuild.
|
||||||
func (t Toolchain) newKernel(
|
func (t Toolchain) newKernel(
|
||||||
|
patches [][2]string,
|
||||||
script string,
|
script string,
|
||||||
extra ...pkg.Artifact,
|
extra ...pkg.Artifact,
|
||||||
) pkg.Artifact {
|
) pkg.Artifact {
|
||||||
@@ -20,18 +21,20 @@ func (t Toolchain) newKernel(
|
|||||||
}, extra), nil, nil, `
|
}, extra), nil, nil, `
|
||||||
export LLVM=1
|
export LLVM=1
|
||||||
export HOSTLDFLAGS="${LDFLAGS}"
|
export HOSTLDFLAGS="${LDFLAGS}"
|
||||||
chmod -R +w /usr/src/linux && cd /usr/src/linux
|
cd /usr/src/linux
|
||||||
`+script, pkg.Path(AbsUsrSrc.Append("linux"), true, pkg.NewHTTPGetTar(
|
`+script, pkg.Path(AbsUsrSrc.Append("linux"), true, t.NewPatchedSource(
|
||||||
nil,
|
"kernel", pkg.NewHTTPGetTar(
|
||||||
"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/"+
|
nil,
|
||||||
"snapshot/linux-"+version+".tar.gz",
|
"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/"+
|
||||||
mustDecode(checksum),
|
"snapshot/linux-"+version+".tar.gz",
|
||||||
pkg.TarGzip,
|
mustDecode(checksum),
|
||||||
|
pkg.TarGzip,
|
||||||
|
), false, patches...,
|
||||||
)))
|
)))
|
||||||
}
|
}
|
||||||
|
|
||||||
func (t Toolchain) newKernelHeaders() pkg.Artifact {
|
func (t Toolchain) newKernelHeaders() pkg.Artifact {
|
||||||
return t.newKernel(`
|
return t.newKernel(nil, `
|
||||||
make "-j$(nproc)" \
|
make "-j$(nproc)" \
|
||||||
INSTALL_HDR_PATH=/work/system \
|
INSTALL_HDR_PATH=/work/system \
|
||||||
headers_install
|
headers_install
|
||||||
|
|||||||
Reference in New Issue
Block a user