diff options
-rw-r--r-- | perl-install/fsedit.pm | 5 | ||||
-rw-r--r-- | perl-install/install2.pm | 2 | ||||
-rw-r--r-- | perl-install/install_steps_gtk.pm | 8 | ||||
-rw-r--r-- | perl-install/install_steps_interactive.pm | 4 | ||||
-rw-r--r-- | perl-install/partition_table.pm | 5 | ||||
-rwxr-xr-x | perl-install/standalone/keyboarddrake | 10 | ||||
-rwxr-xr-x | perl-install/standalone/mousedrake | 11 | ||||
-rw-r--r-- | perl-install/timezone.pm | 2 |
8 files changed, 38 insertions, 9 deletions
diff --git a/perl-install/fsedit.pm b/perl-install/fsedit.pm index 599a7af5e..5df4cb109 100644 --- a/perl-install/fsedit.pm +++ b/perl-install/fsedit.pm @@ -64,11 +64,14 @@ sub hds($$) { # for RAID arrays of format c0d0p1 $hd->{prefix} .= "p" if $hd->{prefix} =~ m,(rd|ida)/,; - eval { partition_table::read($hd, $flags->{clearall}) }; + eval { partition_table::read($hd, $flags->{clearall} || member($_->{device}, @{$flags->{clear} || []})) }; if ($@) { cdie($@) unless $flags->{eraseBadPartitions}; partition_table_raw::zero_MBR($hd); } + member($_->{device}, @{$flags->{clear} || []}) and partition_table::remove($hd, $_) + foreach partition_table::get_normal_parts($hd); + #- special case for type overloading (eg: reiserfs is 0x183) foreach (grep { isExt2($_) } partition_table::get_normal_parts($hd)) { my $type = typeOfPart($_->{device}); diff --git a/perl-install/install2.pm b/perl-install/install2.pm index 633b46eb3..926f547d5 100644 --- a/perl-install/install2.pm +++ b/perl-install/install2.pm @@ -234,7 +234,7 @@ $::oo = {}; #------------------------------------------------------------------------------ sub selectLanguage { - $o->selectLanguage; + $o->selectLanguage($_[1] == 1); addToBeDone { lang::write($o->{prefix}); diff --git a/perl-install/install_steps_gtk.pm b/perl-install/install_steps_gtk.pm index 08520db98..36be9877c 100644 --- a/perl-install/install_steps_gtk.pm +++ b/perl-install/install_steps_gtk.pm @@ -143,10 +143,16 @@ sub leavingStep { #- Steps Functions #-###################################################################################### sub selectLanguage { - my ($o) = @_; + my ($o, $first_time) = @_; $o->SUPER::selectLanguage; Gtk->set_locale; install_theme($o); + + $o->ask_warn('', +_("Your system is low on resource. You may have some problem installing +Linux-Mandrake. If that occurs, you can try a text install instead. For this, +press `F1' when booting on CDROM, then enter `text'.")) if $first_time && availableRam < 60 * 1024; # 60MB + } #------------------------------------------------------------------------------ diff --git a/perl-install/install_steps_interactive.pm b/perl-install/install_steps_interactive.pm index 13b3558a0..17961735d 100644 --- a/perl-install/install_steps_interactive.pm +++ b/perl-install/install_steps_interactive.pm @@ -79,8 +79,8 @@ sub selectKeyboard($) { my %langs; $langs{$_} = 1 foreach @{$o->{langs}}; $o->ask_many_from_list_ref('', _("You can choose other languages that will be available after install"), - [ lang::list() ], [ map { \$langs{lang::text2lang($_)} } lang::list() ] ) or goto &selectKeyboard; - $o->{langs} = [ grep { $langs{$_} } keys %langs ]; + [ lang::list(), 'All' ], [ map { \$langs{$_} } (map { lang::text2lang($_) } lang::list()), 'all' ] ) or goto &selectKeyboard; + $o->{langs} = $langs{all} ? [ 'all' ] : [ grep { $langs{$_} } keys %langs ]; } install_steps::selectKeyboard($o); } diff --git a/perl-install/partition_table.pm b/perl-install/partition_table.pm index 9d13745d5..fc43e53ab 100644 --- a/perl-install/partition_table.pm +++ b/perl-install/partition_table.pm @@ -316,15 +316,16 @@ sub adjust_main_extended($) { # the first is a special case, must recompute its real size my $start = round_down($l->{normal}{start} - 1, $hd->{geom}{sectors}); my $end = $l->{normal}{start} + $l->{normal}{size}; - my $only_linux = 1; + my $only_linux = 1; my $has_win_lba = 0; foreach (map $_->{normal}, $l, @l) { $start = min($start, $_->{start}); $end = max($end, $_->{start} + $_->{size}); $only_linux &&= isTrueFS($_) || isSwap($_); + $has_win_lba ||= $_->{type} == 0xc || $_->{type} == 0xe; } $l->{start} = $hd->{primary}{extended}{start} = $start; $l->{size} = $hd->{primary}{extended}{size} = $end - $start; - $hd->{primary}{extended}{type} = $only_linux ? 0x85 : 0x5 if !$::expert; + $hd->{primary}{extended}{type} = $only_linux ? 0x85 : $has_win_lba ? 0xf : 0x5 if !$::expert; } unless (@{$hd->{extended} || []} || !$hd->{primary}{extended}) { %{$hd->{primary}{extended}} = (); #- modify the raw entry diff --git a/perl-install/standalone/keyboarddrake b/perl-install/standalone/keyboarddrake index d2177b459..016202c68 100755 --- a/perl-install/standalone/keyboarddrake +++ b/perl-install/standalone/keyboarddrake @@ -33,6 +33,8 @@ my $xkb = keyboard::keyboard2xkb($keyboard); `setxkbmap $xkb`; my $f = "/etc/X11/XF86Config"; +my $g = "/etc/X11/XF86Config-4"; + substInFile { if (/^Section "Keyboard"/ .. /^EndSection/) { s|^(\s*XkbLayout\s+).*|$1"$xkb"| @@ -41,6 +43,14 @@ substInFile { } } $f if -e $f && !$::testing; +substInFile { + if (/^Identifier "Keyboard1"/ .. /^EndSection/) { + s|^(\s*Option\s+"XkbLayout"\s+).*|$1"$xkb"| + and $_ .= join '', map { /(\S+)(.*)/; qq( Option "$1" $2\n) } @{$xkb_options{$xkb} || []}; + s,^(\s*Option\s+"(XkbVariant|XkbOptions)"\s+).*,,; # remove existing one + } +} $g if -e $g && !$::testing; + keyboard::write('', $keyboard, $isNotDelete); $in->exit(0); diff --git a/perl-install/standalone/mousedrake b/perl-install/standalone/mousedrake index d40bcff62..2b646e334 100755 --- a/perl-install/standalone/mousedrake +++ b/perl-install/standalone/mousedrake @@ -47,17 +47,24 @@ my $g = "/etc/X11/XF86Config-4"; my $zaxis = "\n ZAxisMapping 4 5" if $mouse->{nbuttons} > 3; $zaxis .= "\n ZAxisMapping 6 7" if $mouse->{nbuttons} > 5; + $zaxis = " + Emulate3Buttons + Emulate3Timeout 50" if $mouse->{nbuttons} < 3; + substInFile { if (/^Section "Pointer"/ .. /^EndSection/) { - $_ = '' if /ZAxisMapping/; #- remove existing line + $_ = '' if /(ZAxisMapping|Emulate3)/; #- remove existing line s|^(\s*Protocol\s+).*|$1"$mouse->{XMOUSETYPE}"|; s|^(\s*Device\s+).*|$1"/dev/mouse"$zaxis|; } } $f if -e $f && !$::testing; + +$zaxis =~ s/(ZAxisMapping|Emulate3\w+)/Option "$1"/g; substInFile { if (/^Identifier "Mouse1"/ .. /^EndSection/) { + $_ = '' if /(ZAxisMapping|Emulate3)/; #- remove existing line s|^(\s*Option\s+"Protocol"\s+).*|$1"$mouse->{XMOUSETYPE}"|; - s|^(\s*Option\s+"Device"\s+).*|$1"/dev/mouse"|; + s|^(\s*Option\s+"Device"\s+).*|$1"/dev/mouse"$zaxis|; } } $g if -e $g && !$::testing; diff --git a/perl-install/timezone.pm b/perl-install/timezone.pm index dae92f881..13a29029a 100644 --- a/perl-install/timezone.pm +++ b/perl-install/timezone.pm @@ -39,6 +39,8 @@ sub write($$$) { my %l2t = ( 'Brezhoneg (Brittany)' => 'Europe/Paris', 'Chinese (China)' => 'Asia/Shanghai', +'Croatian (Bosnia)' => 'Europe/Sarajevo', +'Croatian (Croatia)' => 'Europe/Zagreb', 'Danish (Denmark)' => 'Europe/Copenhagen', 'Dutch (Netherlands)' => 'Europe/Amsterdam', 'English (USA)' => 'America/New_York', |