diff options
author | Pascal Rigaux <pixel@mandriva.com> | 1999-09-04 21:49:40 +0000 |
---|---|---|
committer | Pascal Rigaux <pixel@mandriva.com> | 1999-09-04 21:49:40 +0000 |
commit | bcd1bf4e45de7e5f59a6c1e7eaaf7ad401d7fc28 (patch) | |
tree | 01e2e993eee17983f2d616caecc998cc3dba5acf | |
parent | beb56af292cfc8f5ed3e78034da33e96ca9e7953 (diff) | |
download | drakx-backup-do-not-use-bcd1bf4e45de7e5f59a6c1e7eaaf7ad401d7fc28.tar drakx-backup-do-not-use-bcd1bf4e45de7e5f59a6c1e7eaaf7ad401d7fc28.tar.gz drakx-backup-do-not-use-bcd1bf4e45de7e5f59a6c1e7eaaf7ad401d7fc28.tar.bz2 drakx-backup-do-not-use-bcd1bf4e45de7e5f59a6c1e7eaaf7ad401d7fc28.tar.xz drakx-backup-do-not-use-bcd1bf4e45de7e5f59a6c1e7eaaf7ad401d7fc28.zip |
no_comment
-rw-r--r-- | perl-install/Makefile | 6 | ||||
-rw-r--r-- | perl-install/install_steps_interactive.pm | 2 | ||||
-rw-r--r-- | perl-install/keyboard.pm | 1 | ||||
-rw-r--r-- | perl-install/modules.pm | 18 |
4 files changed, 15 insertions, 12 deletions
diff --git a/perl-install/Makefile b/perl-install/Makefile index b93caf6b7..cc1991b19 100644 --- a/perl-install/Makefile +++ b/perl-install/Makefile @@ -10,7 +10,7 @@ DESTREP4PMS = $(DEST)/usr/bin/perl-install PERL = perl LOCALFILES = $(PERL) mouseconfig DIRS = po pci_probing -EXCLUDE = $(LOCALFILES) boot.img xmodmap keymaps consolefonts install +EXCLUDE = $(LOCALFILES) boot.img keymaps consolefonts install RPMS = $(wildcard $(ROOTDEST)/Mandrake/RPMS/*.rpm) CFLAGS = -Wall override CFLAGS += -pipe @@ -106,6 +106,7 @@ get_needed_files: $(SO_FILES) install -d $(DEST)/usr/bin install -d $(DEST)/usr/lib install -d $(DEST)/usr/share + install -d $(DEST)/usr/share/xmodmap install -d $(ROOTDEST)/Mandrake/base install -s $(LOCALFILES) $(DEST)/usr/bin @@ -135,7 +136,8 @@ get_needed_files: $(SO_FILES) cd /usr/X11R6/lib/X11/fonts/75dpi ; cp -a fonts.* helvR* $(DEST)/usr/X11R6/lib/X11/fonts/75dpi cd /usr/X11R6/lib/X11/fonts/misc ; cp -a fonts.* cursor.pcf.gz 6x13.pcf.gz $(DEST)/usr/X11R6/lib/X11/fonts/misc - cp -a xmodmap $(DEST)/usr/share + perl -I. -Ic -Ic/blib/arch -Mkeyboard -e 'foreach (keyboard::xmodmaps()) { `cp /usr/share/xmodmap/xmodmap.$$_ $(DEST)/usr/share/xmodmap` }' + cp -a keymaps $(DEST)/usr/share cp -a consolefonts $(DEST)/usr/share cp MonitorsDB $(DEST)/usr/share diff --git a/perl-install/install_steps_interactive.pm b/perl-install/install_steps_interactive.pm index e778c6fa3..1138f6c4f 100644 --- a/perl-install/install_steps_interactive.pm +++ b/perl-install/install_steps_interactive.pm @@ -427,7 +427,7 @@ sub load_thiskind { modules::load_thiskind($type, sub { $w = $o->wait_message('', [ _("Installing driver for %s card %s", $type, $_->[0]), - $::beginner ? _("(module %s)", $_->[1]) : () + $::beginner ? () : _("(module %s)", $_->[1]) ]); }); } diff --git a/perl-install/keyboard.pm b/perl-install/keyboard.pm index bf49804df..3b53bf194 100644 --- a/perl-install/keyboard.pm +++ b/perl-install/keyboard.pm @@ -61,6 +61,7 @@ my %keyboards = ( ); sub list { map { $_->[0] } values %keyboards } +sub xmodmaps { map { $_->[2] } values %keyboards } sub keyboard2text { $keyboards{$_[0]} && $keyboards{$_[0]}[0] } sub text2keyboard { my ($t) = @_; diff --git a/perl-install/modules.pm b/perl-install/modules.pm index 5ca395645..da89bae31 100644 --- a/perl-install/modules.pm +++ b/perl-install/modules.pm @@ -11,6 +11,7 @@ use log; my %conf; +my $scsi = 0; my %deps = (); @@ -242,7 +243,7 @@ sub text2driver($) { sub load($;$@) { my ($name, $type, @options) = @_; - $conf{'scsi_hostadapter' . ($conf{scsi}++ || '')}{alias} = $name + $conf{'scsi_hostadapter' . ($scsi++ || '')}{alias} = $name if $type eq 'scsi'; if ($::testing) { @@ -301,20 +302,19 @@ sub load_deps($) { } } -sub read_conf { - my ($file) = @_; +sub read_conf($;$) { + my ($file, $scsi) = @_; my %c; - $c{scsi} = 0; foreach (cat_($file)) { do { $c{$2}{$1} = $3; - $c{scsi} = max($c{scsi}, $1 || 0) if /^\s*alias\s+scsi_hostadapter (\d*)/x; + $$scsi = max($$scsi, $1 || 0) if /^\s*alias\s+scsi_hostadapter (\d*)/x && $scsi; } if /^\s*(\S+)\s+(\S+)\s+(.*?)\s*$/; } # cheating here: not handling aliases of aliases while (my ($k, $v) = each %c) { - $c{scsi} ||= $v->{scsi_hostadapter}; + $$scsi ||= $v->{scsi_hostadapter} if $scsi; if (my $a = $v->{alias}) { local $c{$a}{alias}; add2hash($c{$a}, $v); @@ -325,7 +325,7 @@ sub read_conf { sub write_conf { my ($file) = @_; - my %written = read_conf($file); + my (undef, %written) = read_conf($file); local *F; open F, ">> $file" or die("cannot write module config file $file: $!\n"); @@ -338,7 +338,7 @@ sub write_conf { } sub get_stage1_conf { - %conf = read_conf($_[0]); + %conf = read_conf($_[0], \$scsi); $conf{parport_lowlevel}{alias} ||= "parport_pc"; $conf{pcmcia_core}{"pre-install"} ||= "/etc/rc.d/init.d/pcmcia start"; $conf{plip}{"pre-install"} ||= "modprobe parport_pc ; echo 7 > /proc/parport/0/irq"; @@ -356,7 +356,7 @@ sub load_thiskind($;&) { $drivers{$mod} or log::l("module $mod not in install table"), next; log::l("found driver for $mod"); &$f($text, $mod) if $f; - load($mod); + load($mod, $type); } @devs; } |