summaryrefslogtreecommitdiffstats
path: root/perl-install/fs/partitioning_wizard.pm
diff options
context:
space:
mode:
authorOlivier Blin <oblin@mandriva.com>2009-10-28 14:25:18 +0000
committerOlivier Blin <oblin@mandriva.com>2009-10-28 14:25:18 +0000
commit8c57553925621c1591e422d9ea40449ca828d1b2 (patch)
tree284aef2fb778f62328a931c0e51691697af11d26 /perl-install/fs/partitioning_wizard.pm
parentd2b99a6d0b53c312792d89aa2679750c49f71ee3 (diff)
downloaddrakx-8c57553925621c1591e422d9ea40449ca828d1b2.tar
drakx-8c57553925621c1591e422d9ea40449ca828d1b2.tar.gz
drakx-8c57553925621c1591e422d9ea40449ca828d1b2.tar.bz2
drakx-8c57553925621c1591e422d9ea40449ca828d1b2.tar.xz
drakx-8c57553925621c1591e422d9ea40449ca828d1b2.zip
set total minimum linux size in part min_linux
Diffstat (limited to 'perl-install/fs/partitioning_wizard.pm')
-rw-r--r--perl-install/fs/partitioning_wizard.pm8
1 files changed, 5 insertions, 3 deletions
diff --git a/perl-install/fs/partitioning_wizard.pm b/perl-install/fs/partitioning_wizard.pm
index f5c466f77..3f1050e8b 100644
--- a/perl-install/fs/partitioning_wizard.pm
+++ b/perl-install/fs/partitioning_wizard.pm
@@ -132,16 +132,18 @@ sub partitionWizardSolutions {
log::l("The FAT resizer is unable to get minimal size for $part->{device} partition %s", formatError($@));
undef $part;
} else {
+ my $min_linux_all = $min_linux + $min_swap;
#- make sure that even after normalizing the size to cylinder boundaries, the minimun will be saved,
#- this save at least a cylinder (less than 8Mb).
$min_win += partition_table::raw::cylinder_size($hd);
- if ($part->{size} <= $min_linux + $min_swap + $min_win) {
+ if ($part->{size} <= $min_linux_all + $min_win) {
# die N("Your Microsoft Windows® partition is too fragmented. Please reboot your computer under Microsoft Windows®, run the ``defrag'' utility, then restart the Mandriva Linux installation.");
undef $part;
} else {
$part->{resize_fat} = $resize_fat;
$part->{min_win} = $min_win;
+ $part->{min_linux} = $min_linux_all;
}
}
}
@@ -162,7 +164,7 @@ sub partitionWizardSolutions {
my $resize_fat = $part->{resize_fat};
my $hd = fs::get::part2hd($part, $all_hds);
if (!$in->isa('interactive::gtk')) {
- $part->{size} > $min_linux + $min_swap + $part->{min_win} or die N("Your Microsoft Windows® partition is too fragmented. Please reboot your computer under Microsoft Windows®, run the ``defrag'' utility, then restart the Mandriva Linux installation.");
+ $part->{size} > $part->{min_linux} + $part->{min_win} or die N("Your Microsoft Windows® partition is too fragmented. Please reboot your computer under Microsoft Windows®, run the ``defrag'' utility, then restart the Mandriva Linux installation.");
}
$in->ask_okcancel('', formatAlaTeX(
#-PO: keep the double empty lines between sections, this is formatted a la LaTeX
@@ -181,7 +183,7 @@ When sure, press %s.", N("Next")))) or return;
if (!$in->isa('interactive::gtk')) {
my $mb_size = to_Mb($part->{size});
$in->ask_from(N("Partitionning"), N("Which size do you want to keep for Microsoft Windows® on partition %s?", partition_table::description($part)), [
- { label => N("Size"), val => \$mb_size, min => to_Mb($part->{min_win}), max => to_Mb($part->{size} - $min_linux - $min_swap), type => 'range' },
+ { label => N("Size"), val => \$mb_size, min => to_Mb($part->{min_win}), max => to_Mb($part->{size} - $part->{min_linux}), type => 'range' },
]) or return;
$part->{size} = from_Mb($mb_size, $part->{min_win}, $part->{size});
} else {