Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 3cc44d52 authored by Jackeagle's avatar Jackeagle
Browse files

kernel: fix .repo/repo nesting on re-used runner volumes



When a runner's /srv/src volume already had .repo/repo/ from a previous
attempt, cp -R src dest with an existing dest directory nests the source
inside (creating .repo/repo/repo/main.py). _FindRepo() then fails to
find main.py at the expected path and walks up to the parent Android
tree, causing repo init to reuse the wrong checkout.

Add rm -rf before cp -R so the copy always overwrites cleanly.

Signed-off-by: default avatarJackeagle <jackeagle102@gmail.com>
parent 2e80593e
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -955,6 +955,7 @@ function build_kernel() {
        # instead of walking up to the parent Android tree. repo init then
        # creates manifests.git fresh from the kernel manifest URL.
        mkdir -p "${KERNEL_BUILD_TOP}/.repo"
        rm -rf "${KERNEL_BUILD_TOP}/.repo/repo"
        cp -R "${ANDROID_BUILD_TOP}/.repo/repo" "${KERNEL_BUILD_TOP}/.repo/repo"

        # Allow custom .repo/project-objects dir