diff options
Diffstat (limited to 'perl-install')
-rw-r--r-- | perl-install/Xconfigurator.pm | 2 | ||||
-rw-r--r-- | perl-install/Xconfigurator_consts.pm | 2 | ||||
-rw-r--r-- | perl-install/detect_devices.pm | 15 | ||||
-rw-r--r-- | perl-install/install2.pm | 1 | ||||
-rw-r--r-- | perl-install/install_steps.pm | 7 | ||||
-rw-r--r-- | perl-install/install_steps_gtk.pm | 5 | ||||
-rw-r--r-- | perl-install/install_steps_interactive.pm | 3 | ||||
-rw-r--r-- | perl-install/lang.pm | 2 | ||||
-rw-r--r-- | perl-install/modules.pm | 15 |
9 files changed, 24 insertions, 28 deletions
diff --git a/perl-install/Xconfigurator.pm b/perl-install/Xconfigurator.pm index 9c9e53916..a64e924c5 100644 --- a/perl-install/Xconfigurator.pm +++ b/perl-install/Xconfigurator.pm @@ -1129,6 +1129,8 @@ sub main { if (`pidof $_` > 0) { if ($in->ask_okcancel('', _("Please relog into %s to activate the changes", ucfirst $_), 1)) { system("kwmcom logout") if /kwm/; + system("dcop kdesktop default logout") if /kwin/; + system("save-session --kill") if /gnome-session/; open STDIN, "</dev/zero"; open STDOUT, ">/dev/null"; diff --git a/perl-install/Xconfigurator_consts.pm b/perl-install/Xconfigurator_consts.pm index 6a4e6dc79..961e09f19 100644 --- a/perl-install/Xconfigurator_consts.pm +++ b/perl-install/Xconfigurator_consts.pm @@ -13,7 +13,7 @@ use common qw(:common); @resolutions = qw(640x480 800x600 1024x768 1152x864 1280x1024 1600x1200); -@window_managers = qw(icewm wmaker kwm afterstep fvwm fvwm2 fvwm95 mwm twm enlightenment xfce blackbox); +@window_managers = ('kdeinit: kwin', qw(gnome-session icewm wmaker kwm afterstep fvwm fvwm2 fvwm95 mwm twm enlightenment xfce blackbox sawfish)); %serversdriver = arch() =~ /^sparc/ ? ( 'Mach64' => "accel", diff --git a/perl-install/detect_devices.pm b/perl-install/detect_devices.pm index 6bcf38ac6..b8bad956c 100644 --- a/perl-install/detect_devices.pm +++ b/perl-install/detect_devices.pm @@ -158,21 +158,6 @@ sub getDAC960() { values %idi; } -sub net2module() { - my @modules = map { quotemeta first(split) } cat_("/proc/modules"); - my $modules = join '|', @modules; - my $net = join '|', @netdevices; - my ($module, %l); - foreach (syslog()) { - if (/^($modules)\.c:/) { - $module = $1; - } elsif (/^($net):/) { - $l{$1} = $module if $module; - } - } - %l; -} - sub getNet() { grep { hasNetDevice($_) } @netdevices; } diff --git a/perl-install/install2.pm b/perl-install/install2.pm index 16528b672..8dcfb8aa0 100644 --- a/perl-install/install2.pm +++ b/perl-install/install2.pm @@ -351,7 +351,6 @@ sub miscellaneous { addToBeDone { setVarsInSh("$o->{prefix}/etc/sysconfig/system", { - HDPARM => $o->{miscellaneous}{HDPARM}, CLEAN_TMP => $o->{miscellaneous}{CLEAN_TMP}, CLASS => $::expert && "expert" || $::beginner && "beginner" || "medium", TYPE => $o->{installClass}, diff --git a/perl-install/install_steps.pm b/perl-install/install_steps.pm index bb39b695d..62a140473 100644 --- a/perl-install/install_steps.pm +++ b/perl-install/install_steps.pm @@ -431,7 +431,7 @@ Consoles 1,3,4,7 may also contain interesting information"; log::l("updating kde icons according to available devices"); install_any::kdeicons_postinstall($o->{prefix}); - my $welcome = _("Welcome to %s", "[HOSTNAME]"); + my $welcome = _("Welcome to %s", "HOSTNAME"); substInFile { s/^(GreetString)=.*/$1=$welcome/ } "$o->{prefix}/usr/share/config/kdmrc"; substInFile { s/^(UserView)=false/$1=true/ } "$o->{prefix}/usr/share/config/kdmrc" if $o->{security} < 3; run_program::rooted($o->{prefix}, "kdeDesktopCleanup"); @@ -817,8 +817,11 @@ sub miscellaneous { $_ .= " " . join(" ", (map { "$_=ide-scsi" } @l), map { "$_->{device}=ide-floppy" } detect_devices::ide_zips()); } + if ($o->{miscellaneous}{HDPARM}) { + $_ .= join('', map { " $_=autotune" } grep { /ide.*/ } all("/proc/ide")) if !/ide.=autotune/; + } if (my $m = detect_devices::hasUltra66()) { - $_ .= " $m" if !/ide.=/; + $_ .= " $m" if !/ide.=0x/; } #- keep some given parameters diff --git a/perl-install/install_steps_gtk.pm b/perl-install/install_steps_gtk.pm index b7c53e730..a77956aaf 100644 --- a/perl-install/install_steps_gtk.pm +++ b/perl-install/install_steps_gtk.pm @@ -376,7 +376,7 @@ sub choosePackagesTree { my $isSelection = !pkgs::packageFlagSelected($_[0]); foreach (@_) { pkgs::togglePackageSelection($packages, $_, my $l = {}); - @l{keys %$l} = (); + @l{grep {$l->{$_}} keys %$l} = (); } if (my @l = keys %l) { #- check for size before trying to select. @@ -609,8 +609,9 @@ sub create_big_help { gtkpack_(new Gtk::VBox(0,0), 1, createScrolledWindow(gtktext_insert(new Gtk::Text, formatAlaTeX(_ deref($help::steps{$::o->{step}})))), - 0, gtksignal_connect(new Gtk::Button(_("Ok")), "clicked" => sub { Gtk->main_quit }), + 0, gtksignal_connect(my $ok = new Gtk::Button(_("Ok")), "clicked" => sub { Gtk->main_quit }), )); + $ok->grab_focus; $w->main; gtkset_mousecursor_normal(); } diff --git a/perl-install/install_steps_interactive.pm b/perl-install/install_steps_interactive.pm index d88fc3d97..653e9ee20 100644 --- a/perl-install/install_steps_interactive.pm +++ b/perl-install/install_steps_interactive.pm @@ -86,9 +86,10 @@ sub selectKeyboard($) { if ($::expert && ref($o) !~ /newt/) { #- newt is buggy with big windows :-( my %langs; $langs{$_} = 1 foreach @{$o->{langs}}; + my @l = sort { $a->[0] cmp $b->[0] } map { [ lang::lang2text($_) || $_, \$langs{$_} ] } lang::list(); $o->ask_many_from_list_ref('', _("You can choose other languages that will be available after install"), - [ (map { lang::lang2text($_) } lang::list()), 'All' ], [ map { \$langs{$_} } lang::list(), 'all' ] ) or goto &selectKeyboard; + [ map { $_->[0] } @l ], [ map { $_->[1] } @l ], [ 'All' ], [ \$langs{all} ]) or goto &selectKeyboard; $o->{langs} = $langs{all} ? [ 'all' ] : [ grep { $langs{$_} } keys %langs ]; } install_steps::selectKeyboard($o); diff --git a/perl-install/lang.pm b/perl-install/lang.pm index c8e1d78ab..1bd16e689 100644 --- a/perl-install/lang.pm +++ b/perl-install/lang.pm @@ -241,7 +241,7 @@ my %charsets = ( #- Functions #-###################################################################################### -sub list { sort { $a cmp $b } keys %languages } +sub list { keys %languages } sub lang2text { $languages{$_[0]} && $languages{$_[0]}[0] } sub lang2charset { $languages{$_[0]} && $languages{$_[0]}[1] } diff --git a/perl-install/modules.pm b/perl-install/modules.pm index 3ed7e24fc..d2b1c7684 100644 --- a/perl-install/modules.pm +++ b/perl-install/modules.pm @@ -3,7 +3,7 @@ package modules; use strict; use vars qw(%drivers); -use common qw(:common :file :system); +use common qw(:common :file :system :functional); use detect_devices; use run_program; use log; @@ -394,13 +394,17 @@ sub remove_alias($) { sub when_load { my ($name, $type, @options) = @_; - add_alias('scsi_hostadapter', $name), eval { load('sd_mod') } if $type =~ /scsi/ || $type eq $type_aliases{scsi}; + if ($type =~ /scsi/ || $type eq $type_aliases{scsi}) { + add_alias('scsi_hostadapter', $name), eval { load('sd_mod') }; + } $conf{$name}{options} = join " ", @options if @options; } sub load { my ($name, $type, @options) = @_; + my @netdev = detect_devices::getNet() if $type eq 'net'; + if ($::testing) { log::l("i try to install $name module (@options)"); } elsif ($::live) { @@ -413,6 +417,10 @@ sub load { } sleep 2 if $name =~ /usb-storage|mousedev/; + if ($type eq 'net') { + add_alias($_, $name) foreach difference2([ detect_devices::getNet() ], \@netdev); + } + when_load($name, $type, @options); } sub load_multi { @@ -524,9 +532,6 @@ sub write_conf { my $written = read_conf($file); - my %net = detect_devices::net2module(); - while (my ($k, $v) = each %net) { add_alias($k, $v) } - local *F; open F, ">> $file" or die("cannot write module config file $file: $!\n"); while (my ($mod, $h) = each %conf) { |