From 16b5a3af1260ee3e5b1b03c440aa598d5b05a874 Mon Sep 17 00:00:00 2001 From: Pascal Rigaux Date: Thu, 5 Aug 2004 05:32:39 +0000 Subject: isLaptop() special code for ppc --- perl-install/detect_devices.pm | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) (limited to 'perl-install/detect_devices.pm') diff --git a/perl-install/detect_devices.pm b/perl-install/detect_devices.pm index 541c0762f..30ba97147 100644 --- a/perl-install/detect_devices.pm +++ b/perl-install/detect_devices.pm @@ -733,11 +733,14 @@ sub hasPCMCIA() { $::o->{pcmcia} } #- because /proc/pcmcia seems not to be prese #- try to detect a laptop, we assume pcmcia service is an indication of a laptop or #- the following regexp to match graphics card apparently only used for such systems. sub isLaptop() { - hasPCMCIA() || (matching_desc('C&T.*655[45]\d') || matching_desc('C&T.*68554') || - matching_desc('Neomagic.*Magic(Media|Graph)') || - matching_desc('ViRGE.MX') || matching_desc('S3.*Savage.*[IM]X') || - matching_desc('ATI.*(Mobility|LT)')) - || cat_('/proc/cpuinfo') =~ /\bmobile\b/i; + arch() =~ /ppc/ ? + get_mac_model() =~ /Book/ : + hasPCMCIA() + || (matching_desc('C&T.*655[45]\d') || matching_desc('C&T.*68554') || + matching_desc('Neomagic.*Magic(Media|Graph)') || + matching_desc('ViRGE.MX') || matching_desc('S3.*Savage.*[IM]X') || + matching_desc('ATI.*(Mobility|LT)')) + || cat_('/proc/cpuinfo') =~ /\bmobile\b/i; } sub usbMice() { grep { $_->{media_type} =~ /\|Mouse/ && $_->{driver} !~ /Tablet:wacom/ || -- cgit v1.2.1