From dbb92fc24abd933eff171909db38d78e1d2f40c6 Mon Sep 17 00:00:00 2001 From: Pascal Rigaux Date: Mon, 28 Feb 2000 17:46:52 +0000 Subject: no_comment --- docs/TODO | 2 ++ perl-install/detect_devices.pm | 5 +++-- perl-install/install2.pm | 2 +- perl-install/install_steps_gtk.pm | 2 +- perl-install/partition_table.pm | 20 +++++--------------- perl-install/partition_table_mac.pm | 12 ++++++------ 6 files changed, 18 insertions(+), 25 deletions(-) diff --git a/docs/TODO b/docs/TODO index d4cb0aaaa..a3109f607 100644 --- a/docs/TODO +++ b/docs/TODO @@ -196,6 +196,8 @@ have a better time estimation of the remaining time in install packages (?) when some occur, partition must be unset isFormatted -hardware------------------------------------------------------------------------------- +ELSA Gloria has bad ddc info + token ring is tr0 not eth0 I have Mandrake 6.1 installed and working on a ThinkPad 770. diff --git a/perl-install/detect_devices.pm b/perl-install/detect_devices.pm index 29269cbbd..1384ed74d 100644 --- a/perl-install/detect_devices.pm +++ b/perl-install/detect_devices.pm @@ -39,8 +39,9 @@ sub zips() { grep { $_->{type} eq 'hd' && isZipDrive($_) } get(); } sub cdroms() { my @l = grep { $_->{type} eq 'cdrom' } get(); my $nb = $modules::scsi; #- this is gross! - foreach (getIDEBurners()) { - my ($e) = grep { $_->{device} eq $_ } @l or next; + foreach my $b (getIDEBurners()) { + log::l("getIDEBurners: $b"); + my ($e) = grep { $_->{device} eq $b } @l or next; $e->{device} = "scd" . $nb++; } @l; diff --git a/perl-install/install2.pm b/perl-install/install2.pm index 40639f0fb..8f8666f02 100644 --- a/perl-install/install2.pm +++ b/perl-install/install2.pm @@ -196,7 +196,7 @@ $o = $::o = { base_i386 => [ "lilo", "mkbootdisk", "isapnptools" ], base_alpha => [ "aboot", "isapnptools" ], base_sparc => [ "silo", "mkbootdisk" ], - base_ppc => [ "kernel-pmac", "pdisk", "hfsutils" ], + base_ppc => [ "kernel-pmac", "pdisk", "hfsutils" ], #- for the list of fields available for user and superuser, see @etc_pass_fields in install_steps.pm #- intf => [ { DEVICE => "eth0", IPADDR => '1.2.3.4', NETMASK => '255.255.255.128' } ], diff --git a/perl-install/install_steps_gtk.pm b/perl-install/install_steps_gtk.pm index cdc06f36e..3e05193ab 100644 --- a/perl-install/install_steps_gtk.pm +++ b/perl-install/install_steps_gtk.pm @@ -194,7 +194,7 @@ sub new($$) { #-@servers = qw(SVGA 3DLabs TGA) } @servers = qw(Mach64) if arch() =~ /^sparc/; - @servers = qw(PPCDummy) if arch() eq "ppc"; + @servers = qw(PPCDummy) if arch() eq "ppc"; foreach (@servers) { log::l("Trying with server $_"); diff --git a/perl-install/partition_table.pm b/perl-install/partition_table.pm index 136d6c500..586d85f26 100644 --- a/perl-install/partition_table.pm +++ b/perl-install/partition_table.pm @@ -28,6 +28,10 @@ use log; my %types = ( 0x0 => 'Empty', +arch() =~ /^ppc/ ? ( + 0x401 => 'Apple Partition', + 0x402 => 'Apple HFS Partition', +) : (), arch() =~ /^sparc/ ? ( 0x1 => 'SunOS boot', 0x2 => 'SunOS root', @@ -153,15 +157,6 @@ arch() =~ /^sparc/ ? ( 0xff => 'Xenix Bad Block Table', ); -if (arch() eq "ppc") { -%types = ( - 0x82 => 'Linux swap', - 0x83 => 'Linux native', - 0x401 => 'Apple Partition', - 0x402 => 'Apple HFS Partition', -); -} - my %type2fs = ( arch() !~ /^sparc/ ? ( 0x01 => 'vfat', @@ -209,7 +204,7 @@ sub isFat($) { isDos($_[0]) || isWin($_[0]) } sub isNfs($) { $_[0]{type} eq 'nfs' } #- small hack sub isSupermount($) { $_[0]{type} eq 'supermount' } sub isHFS($) { $type2fs{$_[0]{type}} eq 'hfs' } -sub isApplePartMap { defined $_[0]->{isMap} } +sub isApplePartMap { defined $_[0]{isMap} } sub isPrimary($$) { my ($part, $hd) = @_; @@ -384,11 +379,6 @@ sub read($;$) { 1; } -sub read_and_clear($) { - my ($hd) = @_; - partition_table::read($hd, 1); -} - sub read_extended { my ($hd, $extended) = @_; diff --git a/perl-install/partition_table_mac.pm b/perl-install/partition_table_mac.pm index 61e741f4b..8cf386cde 100644 --- a/perl-install/partition_table_mac.pm +++ b/perl-install/partition_table_mac.pm @@ -113,7 +113,7 @@ sub read($$) { c::lseek_sector(fileno(F), $sector, 512) or die "reading of partition in sector $sector failed"; my @pt; - for($i=0;$i<$partmapsize;$i++) { + for ($i=0;$i<$partmapsize;$i++) { my $part; sysread F, $part, psizeof($p_format) or die "error while reading partition info in sector $sector"; @@ -165,12 +165,12 @@ sub write($$$;$) { # Now go thru the partitions, sort and fill gaps. my $last; - while($part) { + while ($part) { $last = $part; $part = &partition_table::next($hd, $part); $part or last; - if($last->{start} + $last->{size} < $part->{start}) { + if ($last->{start} + $last->{size} < $part->{start}) { #There is a gap between partitions. Fill it and move on. push @partstowrite, { type => 0x0, @@ -182,7 +182,7 @@ sub write($$$;$) { }; # now, fill a gap at the end if there is one. - if($last->{start} + $last->{size} < $hd->{totalsectors}) { + if ($last->{start} + $last->{size} < $hd->{totalsectors}) { push @partstowrite, { type => 0x0, start => $last->{start} + $last->{size}, @@ -196,7 +196,7 @@ sub write($$$;$) { foreach $i ( 0 .. $info->{bzDrvrCnt} - 1) { my $ddBlock = $_->{ddBlock}; my $dd = $_; - foreach(@partstowrite) { + foreach (@partstowrite) { $ddBlock == $_->{pPBlockStart} and push @ddstowrite, $dd; } } @@ -234,7 +234,7 @@ sub write($$$;$) { $_->{pBootArgs} = "\0"; $_->{pReserved} = "\0"; - if($_->{type} == 0x402) { + if ($_->{type} == 0x402) { $_->{pType} = "Apple_HFS"; $_->{pName} = "MacOS"; $_->{pFlags} = 0x4000037F; -- cgit v1.2.1