diff options
author | Pascal Rigaux <pixel@mandriva.com> | 2000-01-04 22:13:57 +0000 |
---|---|---|
committer | Pascal Rigaux <pixel@mandriva.com> | 2000-01-04 22:13:57 +0000 |
commit | 85e21d9abb2daf68be31c33dcdbc8874c3cc8fdc (patch) | |
tree | 3a45e1e56f50f9f59ea5d3db0be6b279ee0eb526 /perl-install | |
parent | f7537f35d8002323124bbb8aa40b627152660bf3 (diff) | |
download | drakx-backup-do-not-use-85e21d9abb2daf68be31c33dcdbc8874c3cc8fdc.tar drakx-backup-do-not-use-85e21d9abb2daf68be31c33dcdbc8874c3cc8fdc.tar.gz drakx-backup-do-not-use-85e21d9abb2daf68be31c33dcdbc8874c3cc8fdc.tar.bz2 drakx-backup-do-not-use-85e21d9abb2daf68be31c33dcdbc8874c3cc8fdc.tar.xz drakx-backup-do-not-use-85e21d9abb2daf68be31c33dcdbc8874c3cc8fdc.zip |
no_comment
Diffstat (limited to 'perl-install')
-rw-r--r-- | perl-install/Makefile | 2 | ||||
-rw-r--r-- | perl-install/Makefile.config | 3 | ||||
-rw-r--r-- | perl-install/Makefile.drakxtools | 2 | ||||
-rw-r--r-- | perl-install/Xconfig.pm | 3 | ||||
-rw-r--r-- | perl-install/install2.pm | 1 | ||||
-rw-r--r-- | perl-install/install_any.pm | 11 | ||||
-rw-r--r-- | perl-install/install_steps.pm | 12 | ||||
-rw-r--r-- | perl-install/install_steps_interactive.pm | 25 | ||||
-rw-r--r-- | perl-install/keyboard.pm | 21 | ||||
-rw-r--r-- | perl-install/lang.pm | 10 | ||||
-rw-r--r-- | perl-install/partition_table_raw.pm | 1 | ||||
-rw-r--r-- | perl-install/pkgs.pm | 2 | ||||
-rw-r--r-- | perl-install/raid.pm | 2 | ||||
-rw-r--r-- | perl-install/share/compssList | 5 | ||||
-rw-r--r-- | perl-install/timezone.pm | 1 |
15 files changed, 69 insertions, 32 deletions
diff --git a/perl-install/Makefile b/perl-install/Makefile index 98d43ab02..b0c8e27f9 100644 --- a/perl-install/Makefile +++ b/perl-install/Makefile @@ -73,7 +73,7 @@ get_needed_files: $(DIRS) install -d $(DEST)/usr/X11R6/lib/X11 install -d $(ROOTDEST)/Mandrake/base install -s $(LOCALFILES) $(DEST)/usr/bin - cp -f $(LOCALFILES2) $(DEST)/usr/bin +# cp -f $(LOCALFILES2) $(DEST)/usr/bin for i in `cat /tmp/list`; do \ if (echo $$i | grep -q "lib/[^/]*\.so"); then \ diff --git a/perl-install/Makefile.config b/perl-install/Makefile.config index 3890b77a6..225d82895 100644 --- a/perl-install/Makefile.config +++ b/perl-install/Makefile.config @@ -11,8 +11,7 @@ STAGE2 = $(ROOTDEST)/Mandrake/base/mdkinst_stage2 BASE = $(ROOTDEST)/Mandrake/base DESTREP4PMS = $(DEST)$(REP4PMS) PERL = perl -LOCALFILES = $(patsubst %, ../tools/%,e2fsck.shared ddcprobe/ddcxinfos pnp_serial/pnp_serial xhost+) -LOCALFILES2 = extract_archive +LOCALFILES = $(patsubst %, ../tools/%,e2fsck.shared ddcprobe/ddcxinfos pnp_serial/pnp_serial xhost+ extract_archive) DIRS = c Newt po pci_probing resize_fat EXCLUDE = $(LOCALFILES) boot.img keymaps consolefonts install CFLAGS = -Wall diff --git a/perl-install/Makefile.drakxtools b/perl-install/Makefile.drakxtools index b630647e1..ae3dcae5d 100644 --- a/perl-install/Makefile.drakxtools +++ b/perl-install/Makefile.drakxtools @@ -22,7 +22,7 @@ install: install $(STANDALONEPMS) $(SBINDEST) mv -f $(SBINDEST)/lspcidrake $(BINDEST) install -s ddcprobe/ddcxinfos pnp_serial/pnp_serial $(SBINDEST) - ln -s ../$(patsubst $(PREFIX)/usr%,%,$(SBINDEST))/XFdrake $(BINX11DEST)/Xdrakres + ln -s ../../$(patsubst $(PREFIX)/usr%,%,$(SBINDEST))/XFdrake $(BINX11DEST)/Xdrakres for i in *.pm ; do perl -pe '$$_ = "\n" if /\s*use\s+(diagnostics|vars|strict)/' $$i > $(LIBDEST)/$$i ; done install -m 644 MonitorsDB $(LIBX11DEST) diff --git a/perl-install/Xconfig.pm b/perl-install/Xconfig.pm index 759696207..71a75cc67 100644 --- a/perl-install/Xconfig.pm +++ b/perl-install/Xconfig.pm @@ -107,8 +107,7 @@ sub getinfoFromSysconfig { add2hash($o->{mouse} ||= {}, { getVarsFromSh("$prefix/etc/sysconfig/mouse") }); if (my %keyboard = getVarsFromSh "$prefix/etc/sysconfig/keyboard") { - $keyboard{KEYTABLE} or last; - $o->{keyboard}{xkb_keymap} ||= keymap_translate($keyboard{KEYTABLE}); + $o->{keyboard}{xkb_keymap} ||= keymap_translate($keyboard{KEYTABLE}) if $keyboard{KEYTABLE}; } $o; } diff --git a/perl-install/install2.pm b/perl-install/install2.pm index 2b6da107d..8c5a0c085 100644 --- a/perl-install/install2.pm +++ b/perl-install/install2.pm @@ -348,6 +348,7 @@ sub choosePackages { $o->setPackages if $_[1] == 1; $o->selectPackagesToUpgrade($o) if $o->{isUpgrade} && $_[1] == 1; if ($_[1] > 1 || !$o->{isUpgrade} || $::expert) { + do { $o->{compssUsersChoice}{$_} = 1 foreach @{$o->{compssUsersSorted}}, 'Miscellaneous' } if $_[1] == 1; $o->choosePackages($o->{packages}, $o->{compss}, $o->{compssUsers}, $o->{compssUsersSorted}, $_[1] == 1); pkgs::unselect($o->{packages}, $o->{packages}{kdesu}) if $o->{packages}{kdesu} && $o->{security} > 3; diff --git a/perl-install/install_any.pm b/perl-install/install_any.pm index e9905906a..7ccb2e73e 100644 --- a/perl-install/install_any.pm +++ b/perl-install/install_any.pm @@ -578,14 +578,9 @@ sub kderc_largedisplay($) { kdeiconstyle => "KDEIconStyle=Large\n", }); foreach ("/etc/skel", "/root", list_home()) { - my $found; substInFile { - $found ||= /KFM Misc Defaults/; - $_ .= -"[KFM Misc Defaults] -GridWidth=78 -GridHeight=75 -" if eof && !$found; + s/^(GridWidth)=85/$1=100/; + s/^(GridWidth)=70/$1=75/; } "$prefix$_/.kde/share/config/kfmrc" } } @@ -643,7 +638,7 @@ sub kdeicons_postinstall($) { foreach my $dir (map { "$prefix$_/Desktop" } qw(/etc/skel /root)) { -d $dir or next; foreach (grep { /\.kdelnk$/ } all($dir)) { - cat_("$dir/$_") =~ /^Name\[$lang\]=(.*)/m + cat_("$dir/$_") =~ /^Name\[$lang\]=(.{2,14})$/m and rename "$dir/$_", "$dir/$1.kdelnk"; } } diff --git a/perl-install/install_steps.pm b/perl-install/install_steps.pm index 64aeba2b5..7e782dc18 100644 --- a/perl-install/install_steps.pm +++ b/perl-install/install_steps.pm @@ -269,6 +269,18 @@ sub afterInstallPackages($) { substInFile { s/^(UserView)=false/$1=true/ } "$o->{prefix}/usr/share/config/kdmrc" if $o->{security} < 3; run_program::rooted($o->{prefix}, "kdeDesktopCleanup"); + foreach ("/etc/skel", "/root", install_any::list_home()) { + my $found; + substInFile { + $found ||= /KFM Misc Defaults/; + $_ .= +"[KFM Misc Defaults] +GridWidth=85 +GridHeight=70 +" if eof && !$found; + } "$o->{prefix}$_/.kde/share/config/kfmrc" + } + #- move some file after an upgrade that may be seriously annoying. if ($o->{isUpgrade}) { log::l("moving previous desktop files that have been updated to \$HOME/tmp of each user"); diff --git a/perl-install/install_steps_interactive.pm b/perl-install/install_steps_interactive.pm index 1cedbccf7..7b69d5c98 100644 --- a/perl-install/install_steps_interactive.pm +++ b/perl-install/install_steps_interactive.pm @@ -201,9 +201,16 @@ sub choosePartitionsToFormat($$) { $_->{toFormat} ||= $_->{toFormatUnsure} foreach @l; log::l("preparing to format $_->{mntpoint}") foreach grep { $_->{toFormat} } @l; + my %label; + $label{$_} = (isSwap($_) ? type2name($_->{type}) : $_->{mntpoint}) . " ($_->{device})" foreach @l; + $o->ask_many_from_list_ref('', _("Choose the partitions you want to format"), - [ map { isSwap($_) ? type2name($_->{type}) . " ($_->{device})" : $_->{mntpoint} } @l ], + [ map { $label{$_} } @l ], [ map { \$_->{toFormat} } @l ]) or die "cancel"; + @l = grep { $_->{toFormat} } @l; + $o->ask_many_from_list_ref('', _("Check bad blocks?"), + [ map { $label{$_} } @l ], + [ map { \$_->{toFormatCheck} } @l ]) or die "cancel" if $::expert; } sub formatPartitions { @@ -237,12 +244,14 @@ sub choosePackages { unless ($o->{isUpgrade}) { my $available = pkgs::invCorrectSize(install_any::getAvailableSpace($o) / sqr(1024)) * sqr(1024); - delete $_->{skip} foreach values %$packages; + foreach (values %$packages) { + delete $_->{skip}; + delete $_->{unskip}; + } pkgs::unselect_all($packages); - pkgs::setSelectedFromCompssList($o->{compssListLevels}, $packages, $::expert ? 95 : 80, $available, $o->{installClass}); + pkgs::setSelectedFromCompssList($o->{compssListLevels}, $packages, $::expert ? 90 : 80, $available, $o->{installClass}); my $min_size = pkgs::size_selected($packages); - do { $o->{compssUsersChoice}{$_} = 1 foreach @$compssUsersSorted, 'Miscellaneous' } if $first_time; $o->chooseGroups($packages, $compssUsers, $compssUsersSorted) unless $::beginner; my %save_selected; $save_selected{$_->{name}} = $_->{selected} foreach values %$packages; @@ -250,7 +259,7 @@ sub choosePackages { my $max_size = pkgs::size_selected($packages); $_->{selected} = $save_selected{$_->{name}} foreach values %$packages; - my $size2install = $::beginner ? $available * 0.7 : $o->chooseSizeToInstall($packages, $min_size, $max_size); + my $size2install = $::beginner ? $available * 0.7 : $o->chooseSizeToInstall($packages, $min_size, $max_size) or goto &choosePackages; ($o->{packages_}{ind}) = pkgs::setSelectedFromCompssList($o->{compssListLevels}, $packages, 1, $size2install, $o->{installClass}); @@ -278,7 +287,6 @@ sub chooseGroups { unless ($o->{compssUsersChoice}{Miscellaneous}) { my %l; $l{@{$compssUsers->{$_}}} = () foreach @$compssUsersSorted; -# exists $l{$_} or print ">>$_\n" foreach keys %$packages; exists $l{$_} or $packages->{$_}{skip} = 1 foreach keys %$packages; } foreach (@$compssUsersSorted) { @@ -286,7 +294,10 @@ sub chooseGroups { } foreach (@$compssUsersSorted) { $o->{compssUsersChoice}{$_} or next; - delete $_->{skip} foreach @{$compssUsers->{$_}}; + foreach (@{$compssUsers->{$_}}) { + $_->{unskip} = 1; + delete $_->{skip}; + } } my $f = "$o->{prefix}/etc/sysconfig/desktop"; output($f, "KDE\n") if $o->{compssUsersChoice}{KDE}; diff --git a/perl-install/keyboard.pm b/perl-install/keyboard.pm index 0190668af..5d02fdb67 100644 --- a/perl-install/keyboard.pm +++ b/perl-install/keyboard.pm @@ -179,20 +179,29 @@ sub load($) { } $count++; } - log::l("loaded $count keymap tables"); + #- log::l("loaded $count keymap tables"); } sub setup($) { my ($keyboard) = @_; my $o = $keyboards{$keyboard} or return; - if (my $file = commands::install_cpio("/usr/share/keymaps", "$o->[1].kmap")) { - log::l("loading keymap $o->[1]"); - load(cat_($file)) if -e $file; + log::l("loading keymap $o->[1]"); + if (-e (my $f = "/usr/share/keymaps/$o->[1].kmap")) { + load(cat_($f)); + } else { + local *F; + open F, "extract_archive /usr/share/keymaps '' $o->[1].kmap |"; + local $/ = undef; + eval { load(<F>) }; } - if (my $file = commands::install_cpio("/usr/share/xmodmap", "xmodmap.$keyboard")) { - eval { run_program::run('xmodmap', $file) } unless $::testing; + + my $f = "/usr/share/xmodmap/xmodmap.$keyboard"; + if (! -e $f) { + run_program::run("extract_archive", "/usr/share/xmodmap", '/tmp', "xmodmap.$keyboard"); + $f = "/tmp/xmodmap.$keyboard"; } + eval { run_program::run('xmodmap', $f) } unless $::testing; } sub write($$;$) { diff --git a/perl-install/lang.pm b/perl-install/lang.pm index df8eb6835..15c5436a7 100644 --- a/perl-install/lang.pm +++ b/perl-install/lang.pm @@ -268,11 +268,19 @@ sub load_po($) { local *F; unless (-e $f) { -e ($f = "$_/po/$lang.po.bz2") and last foreach @INC; - open F, "bzip2 -dc $f 2>/dev/null |"; + if (-e $f) { + open F, "bzip2 -dc $f 2>/dev/null |"; + } else { + -e ($f = "$_/po.cz2") and last foreach @INC; + $f =~ s/\.cz2//; + log::l("loading $lang.po from $f"); + open F, "extract_archive $f '' $lang.po 2>/dev/null |"; + } } else { open F, $f; #- not returning here help avoiding reading the same multiple times. } foreach (<F>) { + log::l("load_po: $_"); /^msgstr/ and $state = 1; /^msgid/ && !$fuzzy and $state = 2; diff --git a/perl-install/partition_table_raw.pm b/perl-install/partition_table_raw.pm index 21ad27582..50d6a0b3e 100644 --- a/perl-install/partition_table_raw.pm +++ b/perl-install/partition_table_raw.pm @@ -16,6 +16,7 @@ my $offset = $common::SECTORSIZE - length($magic) - $nb_primary * common::psizeo my @MBR_signatures = ( [ 'empty', 0, "\0\0\0\0" ], + [ 'lilo', 0x2, "LILO" ], [ 'lilo', 0x6, "LILO" ], [ 'osbs', 0x2, "OSBS" ], #- http://www.prz.tu-berlin.de/~wolf/os-bs.html [ 'pqmagic', 0xef, "PQV" ], diff --git a/perl-install/pkgs.pm b/perl-install/pkgs.pm index 660f55965..8cae2a75f 100644 --- a/perl-install/pkgs.pm +++ b/perl-install/pkgs.pm @@ -314,7 +314,7 @@ sub setSelectedFromCompssList { map_index { $ind = $::i if $_ eq $install_class } @$compssListLevels; defined $ind or log::l("unknown install class $install_class in compssList"), return; - my @values = map { $_->{values}[$ind] } @packages; + my @values = map { $_->{values}[$ind] + ($_->{unskip} ? 10 : 0) } @packages; sort { $values[$b] <=> $values[$a] } 0 .. $#packages; }; foreach (@places) { diff --git a/perl-install/raid.pm b/perl-install/raid.pm index f964cfd4f..2c762c025 100644 --- a/perl-install/raid.pm +++ b/perl-install/raid.pm @@ -133,7 +133,7 @@ sub make { sub format_part($$) { my ($raid, $part) = @_; make($raid->{raid}, $part) if is($part); - fs::format_part($part); + fs::format_part($part, $_->{toFormatCheck} ? "-c" : ()); if (is($part)) { $_->{isFormatted} = 1 foreach @{$part->{disks}}; } diff --git a/perl-install/share/compssList b/perl-install/share/compssList index 54285af1a..3cc694121 100644 --- a/perl-install/share/compssList +++ b/perl-install/share/compssList @@ -38,6 +38,7 @@ bind-utils 65 80 65 binutils 47 0 87 bison 10 0 80 BitchX 43 0 15 +blackbox 43 0 45 blt 10 0 75 bootparamd 20 82 0 byacc 16 0 80 @@ -126,7 +127,7 @@ freetype 10 0 4 freetype-devel 10 0 0 fribidi 10 0 0 ftp 90 90 90 -fvwm 50 0 36 +fvwm 20 0 36 fvwm2 23 0 36 fvwm2-icons 23 0 36 fwhois 25 0 36 @@ -229,7 +230,7 @@ guile-devel 10 0 75 gv 55 0 49 GXedit 60 0 55 helptool 55 0 53 -hexedit 17 0 87 +hexedit 91 91 91 howto 55 0 49 howto-html 55 0 53 howto-sgml 31 0 22 diff --git a/perl-install/timezone.pm b/perl-install/timezone.pm index 5136feb46..eb24e8224 100644 --- a/perl-install/timezone.pm +++ b/perl-install/timezone.pm @@ -47,6 +47,7 @@ my %l2t = ( 'French (France)' => 'Europe/Paris', 'French (Belgium)' => 'Europe/Brussels', 'French (Canada)' => 'Canada/Atlantic', # or Newfoundland ? or Eastern ? +'Gaeilge (Ireland)' => 'Europe/Dublin', 'German (Germany)' => 'Europe/Berlin', 'Hungarian (Hungary)' => 'Europe/Budapest', 'Icelandic (Iceland)' => 'Atlantic/Reykjavik', |