pmb.install: automatically pick unlocker package (MR 2154)
This removes the hard-coded installation of osk-sdl when specifying --fde (or using the on-device installer) and instead determines the unlocker package by taking the most suitable provider of postmarketos-fde-unlocker (factoring provider priority and packages selected for installation). With this change applied, one can manually select an unlocker package to be installed via pmbootstrap install --fde --add other-unlocker Relates to: postmarketOS/pmaports#1309
This commit is contained in:
parent
6f6a3b0408
commit
2ad5427126
|
@ -888,7 +888,12 @@ def create_device_rootfs(args, step, steps):
|
|||
# install it when the ondev installer is running.
|
||||
# Always install it when --fde is specified.
|
||||
if args.full_disk_encryption or args.on_device_installer:
|
||||
install_packages += ["osk-sdl"]
|
||||
# Pick the most suitable unlocker depending on the packages
|
||||
# selected for installation
|
||||
unlocker = pmb.parse.depends.package_provider(
|
||||
args, "postmarketos-fde-unlocker", install_packages, suffix)
|
||||
if unlocker["pkgname"] not in install_packages:
|
||||
install_packages += [unlocker["pkgname"]]
|
||||
else:
|
||||
install_packages += ["postmarketos-base-nofde"]
|
||||
|
||||
|
|
Loading…
Reference in New Issue