summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorStew Benedict <stewb@mandriva.org>2005-03-08 14:14:43 +0000
committerStew Benedict <stewb@mandriva.org>2005-03-08 14:14:43 +0000
commit68e173d018ffdc674d2e3073a1f6cd9f73f6ff68 (patch)
tree00140d4abe78a898198a3f11139e4039fb41f6e1
parentcb9eddf62ade56b3bc546b87d72ffc4c57b7618d (diff)
downloaddrakx-68e173d018ffdc674d2e3073a1f6cd9f73f6ff68.tar
drakx-68e173d018ffdc674d2e3073a1f6cd9f73f6ff68.tar.gz
drakx-68e173d018ffdc674d2e3073a1f6cd9f73f6ff68.tar.bz2
drakx-68e173d018ffdc674d2e3073a1f6cd9f73f6ff68.tar.xz
drakx-68e173d018ffdc674d2e3073a1f6cd9f73f6ff68.zip
mousedrake, detectloader support for XBox
-rw-r--r--perl-install/bootloader.pm19
-rw-r--r--perl-install/mouse.pm4
2 files changed, 23 insertions, 0 deletions
diff --git a/perl-install/bootloader.pm b/perl-install/bootloader.pm
index 9aa46b72a..092ffe44b 100644
--- a/perl-install/bootloader.pm
+++ b/perl-install/bootloader.pm
@@ -167,6 +167,9 @@ sub read {
} elsif ($main_method eq 'yaboot') {
#- not checking on ppc, there's only yaboot anyway :)
$main_method;
+ } elsif ($main_method eq 'cromwell') {
+ #- XBox
+ $main_method;
} elsif (my $type = partition_table::raw::typeOfMBR($_)) {
warn "typeOfMBR $type on $_ for method $main_method\n" if $ENV{DEBUG};
$type;
@@ -258,6 +261,11 @@ sub yaboot2file {
"$::prefix/boot/" . basename($of_path);
}
+sub read_cromwell() {
+ my %b;
+ $b{method} = 'cromwell';
+ \%b;
+}
sub read_yaboot() { &read_lilo }
sub read_lilo() {
my $file = sprintf("$::prefix/etc/%s.conf", arch() =~ /ppc/ ? 'yaboot' : 'lilo');
@@ -824,6 +832,7 @@ sub method2text {
}
sub method_choices_raw() {
+ is_xbox() ? 'cromwell' :
arch() =~ /ppc/ ? 'yaboot' :
arch() =~ /ia64/ ? 'lilo' :
(
@@ -973,6 +982,16 @@ sub when_config_changed_yaboot {
run_program::rooted($::prefix, "/usr/sbin/ybin", "2>", \$error) or die "ybin failed: $error";
}
+sub install_cromwell {
+ log::l("XBox/Cromwell - nothing to install...");
+}
+sub write_cromwell {
+ log::l("XBox/Cromwell - nothing to write...");
+}
+sub when_config_changed_cromwell {
+ my ($_bootloader) = @_;
+ log::l("XBox/Cromwell - nothing to do...");
+}
sub make_label_lilo_compatible {
my ($label) = @_;
diff --git a/perl-install/mouse.pm b/perl-install/mouse.pm
index d79eaa020..459c8ce61 100644
--- a/perl-install/mouse.pm
+++ b/perl-install/mouse.pm
@@ -86,6 +86,7 @@ my %mice =
N_("Universal") =>
[ [ 'input/mice' ],
[ [ 7, 'ps/2', 'ExplorerPS/2', N_("Any PS/2 & USB mice") ],
+ if_(is_xbox(), [ 5, 'ps/2', 'IMPS/2', N_("Microsoft Xbox Controller S") ]),
[ 5, 'ps/2', 'auto-dev', N_("Synaptics Touchpad") ],
] ],
),
@@ -292,6 +293,9 @@ sub detect {
my @input_devices = cat_('/proc/bus/input/devices');
my $synaptics_mouse;
if (my $mouse_nb = grep { /^H: Handlers=mouse/ } @input_devices) {
+ if (is_xbox()) {
+ return fullname2mouse('Universal|Microsoft Xbox Controller S');
+ }
my $univ_mouse = fullname2mouse('Universal|Any PS/2 & USB mice', wacom => \@wacom);
if (any { m!^N: Name="(?:SynPS/2 Synaptics TouchPad|AlpsPS/2 ALPS TouchPad)"$! } @input_devices) {
$synaptics_mouse = fullname2mouse('Universal|Synaptics Touchpad');