1
0
mirror of synced 2026-04-13 23:23:41 +00:00

Always write down root partition as first physical device

Otherwise pygrub fails. Closes Debian bug report #609673
This commit is contained in:
John Hughes
2012-05-30 19:40:12 +02:00
committed by Axel Beckert
parent 6a6d3876f6
commit d0f85802bd

View File

@@ -53,7 +53,17 @@ memory = '{$memory}'
$OUT .= "disk = [\n";
for ( my $i = $#PARTITIONS; $i >= 0 ; $i-- )
{
$OUT .= " '$PARTITIONS[$i]{'imagetype'}$PARTITIONS[$i]{'image'},$device" . ( $i + 1 ) .",w',\n";
if ( $PARTITIONS[$i]{'mountpoint'} eq '/' )
{
$OUT .= " '$PARTITIONS[$i]{'imagetype'}$PARTITIONS[$i]{'image'},$device" . ( $i + 1 ) .",w',\n";
}
}
for ( my $i = $#PARTITIONS; $i >= 0 ; $i-- )
{
if ( $PARTITIONS[$i]{'mountpoint'} ne '/' )
{
$OUT .= " '$PARTITIONS[$i]{'imagetype'}$PARTITIONS[$i]{'image'},$device" . ( $i + 1 ) .",w',\n";
}
}
$OUT .= " ]\n";
}