From 37101a80357a53f4df052fb28c0c279f98f56a8d Mon Sep 17 00:00:00 2001 From: Daniele Debernardi Date: Mon, 13 Apr 2020 00:44:53 +0200 Subject: [PATCH] pmb.install._install: fix subpartitions size calculation (MR 1915) --- pmb/install/_install.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/pmb/install/_install.py b/pmb/install/_install.py index cab29230..f679aa4d 100644 --- a/pmb/install/_install.py +++ b/pmb/install/_install.py @@ -38,20 +38,20 @@ def get_subpartitions_size(args): """ # Calculate required sizes first chroot = args.work + "/chroot_rootfs_" + args.device - root = pmb.helpers.other.folder_size(args, chroot) + full = pmb.helpers.other.folder_size(args, chroot) boot = pmb.helpers.other.folder_size(args, chroot + "/boot") home = pmb.helpers.other.folder_size(args, chroot + "/home") # The home folder gets omitted when copying the rootfs to # /dev/installp2 - full = root - home + root = full - boot - home # Add some free space, see also: #336, #1671 - full *= 1.20 - full += 50 * 1024 * 1024 + root *= 1.20 + root += 50 * 1024 * 1024 boot *= 2 boot += 25 * 1024 * 1024 - return (boot, full - boot) + return (boot, root) def get_nonfree_packages(args, device):