diff options
author | Pascal Terjan <pterjan@mandriva.org> | 2009-02-11 14:54:16 +0000 |
---|---|---|
committer | Pascal Terjan <pterjan@mandriva.org> | 2009-02-11 14:54:16 +0000 |
commit | 854afa7328b4616840fa743197f6759b8d8963a8 (patch) | |
tree | 1db20d67006916fd557246700d7c7e0c0044d8f6 /lib/mouse.pm | |
parent | 2804fa5046b4d73feedc19d539093b41677e4aa0 (diff) | |
download | drakx-kbd-mouse-x11-854afa7328b4616840fa743197f6759b8d8963a8.tar drakx-kbd-mouse-x11-854afa7328b4616840fa743197f6759b8d8963a8.tar.gz drakx-kbd-mouse-x11-854afa7328b4616840fa743197f6759b8d8963a8.tar.bz2 drakx-kbd-mouse-x11-854afa7328b4616840fa743197f6759b8d8963a8.tar.xz drakx-kbd-mouse-x11-854afa7328b4616840fa743197f6759b8d8963a8.zip |
mousedrake: test if the file is there before trying to install the packages
Diffstat (limited to 'lib/mouse.pm')
-rw-r--r-- | lib/mouse.pm | 19 |
1 files changed, 10 insertions, 9 deletions
diff --git a/lib/mouse.pm b/lib/mouse.pm index 17ac8f4..9335c6f 100644 --- a/lib/mouse.pm +++ b/lib/mouse.pm @@ -435,15 +435,16 @@ sub various_xfree_conf { output_with_perm($f, 0755, "xset m 1/8 1\n"); } } - - my @pkgs = ( - if_($mouse->{synaptics}, 'x11-driver-input-synaptics'), - if_($mouse->{evdev_mice}, 'x11-driver-input-evdev'), - if_($mouse->{Protocol} eq 'vboxmouse', 'x11-driver-input-vboxmouse'), - if_($mouse->{imwheel}, 'imwheel'), - if_(@{$mouse->{wacom}}, 'linuxwacom'), - ); - $do_pkgs->install(@pkgs) if @pkgs; + + my $inputdrvpath = '/usr/lib/xorg/modules/input'; + my @pkgs = [ + if_($mouse->{synaptics}, ['x11-driver-input-synaptics', "$inputdrvpath/synaptics_drv.so"]), + if_($mouse->{evdev_mice}, ['x11-driver-input-evdev', "$inputdrvpath/evdev_drv.so"]), + if_($mouse->{Protocol} eq 'vboxmouse', ['x11-driver-input-vboxmouse', "$inputdrvpath/vboxmouse_drv.so"]), + if_($mouse->{imwheel}, ['imwheel', "/usr/bin/imwheel"]), + if_(@{$mouse->{wacom}}, ['linuxwacom', "$inputdrvpath/wacom_drv.so"]), + ]; + $do_pkgs->ensure_files_are_installed(@pkgs, 1) if @pkgs; if ($mouse->{imwheel}) { my $rc = "/etc/X11/imwheel/imwheelrc.$mouse->{imwheel}"; |