pmb: build: envkernel: Fix bind mount detection (MR 2217)
At the moment the "envkernel.sh hasn't run, assuming the kernel was cross compiled on host and using current dir as source" code path triggers even when using envkernel.sh, which works somewhat but requires sourcing envkernel.sh again after each invocation of "pmbootstrap build --envkernel ...". The reason is that os.path.ismount() does not work for bind mounts (see https://bugs.python.org/issue29707). There is a workaround for that already in pmbootstrap but it is not used here for some reason.
This commit is contained in:
parent
dfada2a522
commit
3b5492d91e
|
@ -144,7 +144,7 @@ def run_abuild(args, pkgname, arch, apkbuild_path, kbuild_out):
|
|||
flag_file = "envkernel-bind-mounted"
|
||||
host_build = False
|
||||
|
||||
if not os.path.ismount(chroot + "/mnt/linux"):
|
||||
if not pmb.helpers.mount.ismount(chroot + "/mnt/linux"):
|
||||
logging.info("envkernel.sh hasn't run, assuming the kernel was cross compiled"
|
||||
"on host and using current dir as source")
|
||||
host_build = True
|
||||
|
|
Loading…
Reference in New Issue