Fix pmbootstrap install --android-recovery-zip (MR 2527)

pmbootstrap install --android-recovery-zip always failed with:
ERROR: The recovery zip has not been generated yet, please run
'pmbootstrap install' with the '--android-recovery-zip' parameter first!

I debugged it with a simple print statement of the full path and saw
a repetition of the first part of the path. I discovered that the
mountpoint is "/mnt/" + chroot, so adding chroot again leads to a
repetition of the first part of the path and to a non-existent location.

Closes: issue 2441
This commit is contained in:
Eisenbahnfan 2025-01-10 09:04:30 +01:00 committed by Oliver Smith
parent 6a776fc67c
commit a84b3eb4d2
No known key found for this signature in database
GPG key ID: 5AE7F5513E0885CB

View file

@ -94,8 +94,7 @@ def sideload(deviceinfo: Deviceinfo, method: str) -> None:
# Missing recovery zip error
if not (
chroot
/ mountpoint
mountpoint
/ "var/lib/postmarketos-android-recovery-installer"
/ f"pmos-{deviceinfo.codename}.zip"
).exists():