diff options
Diffstat (limited to 'lib')
-rw-r--r-- | lib/Xconfig/card.pm | 4 | ||||
-rw-r--r-- | lib/Xconfig/proprietary.pm | 17 |
2 files changed, 8 insertions, 13 deletions
diff --git a/lib/Xconfig/card.pm b/lib/Xconfig/card.pm index 1db9307..686b3c0 100644 --- a/lib/Xconfig/card.pm +++ b/lib/Xconfig/card.pm @@ -73,7 +73,7 @@ sub to_raw_X { $raw_X->remove_load_module(modules_dir() . "$_/libglx.so") foreach '/extensions/nvidia', '/extensions/nvidia_legacy', '/extensions'; # remove ModulePath that we added - $raw_X->remove_ModulePath(modules_dir() . "/extensions/$_") foreach 'nvidia97xx', 'nvidia96xx', 'nvidia71xx'; + $raw_X->remove_ModulePath(modules_dir() . "/extensions/$_") foreach 'nvidia97xx', 'nvidia96xx', 'nvidia71xx', 'nvidia-current'; $raw_X->remove_ModulePath(modules_dir()); # then may re-add some if ($card->{DRI_GLX_SPECIAL}) { @@ -297,7 +297,7 @@ sub install_server { if ($card->{Driver2}) { require Xconfig::proprietary; - my @pkgs = Xconfig::proprietary::pkgs_for_Driver2($card, $do_pkgs); + my @pkgs = Xconfig::proprietary::pkgs_for_Driver2($card->{Driver2}, $do_pkgs); if (@pkgs && (!$o_in || $o_in->ask_yesorno('', formatAlaTeX(N("There is a proprietary driver available for your video card which may support additional features. Do you wish to use it?")), 1))) { push @packages, @pkgs; diff --git a/lib/Xconfig/proprietary.pm b/lib/Xconfig/proprietary.pm index 381da9e..7c77456 100644 --- a/lib/Xconfig/proprietary.pm +++ b/lib/Xconfig/proprietary.pm @@ -33,20 +33,15 @@ sub install_matrox_hal { rm_rf("$tmpdir/$dir_in_tar"); } -sub pkg_name_for_Driver2 { - my ($card) = @_; - $card->{Driver2} eq 'fglrx' ? 'ati' : - $card->{Driver2} =~ /^nvidia/ ? $card->{Driver2} : ''; -} - sub pkgs_for_Driver2 { - my ($card, $do_pkgs) = @_; + my ($Driver2, $do_pkgs) = @_; - my $pkg = pkg_name_for_Driver2($card); + my ($pkg, $base_name) = $Driver2 eq 'fglrx' ? ('ati', 'ati') : + $Driver2 =~ /^nvidia/ ? ("x11-driver-video-$Driver2", $Driver2) : () or return; - $pkg && $do_pkgs->is_available($pkg) or log::l("proprietary package $pkg not available"), return; + $do_pkgs->is_available($pkg) or log::l("proprietary package $pkg not available"), return; - my $module_pkgs = $do_pkgs->check_kernel_module_packages($pkg) or + my $module_pkgs = $do_pkgs->check_kernel_module_packages($base_name) or log::l("$pkg available, but no kernel module package (for installed kernels, and no dkms)"), return; ($pkg, @$module_pkgs); @@ -84,7 +79,7 @@ sub may_use_Driver2 { log::explanations("Using specific NVIDIA driver and GLX extensions"); $card2->{DRI_GLX_SPECIAL} = $libglx_path; - $card2->{Options}{IgnoreEDID} = 1 if $card2->{DriverVersion} ne '97xx'; + $card2->{Options}{IgnoreEDID} = 1 if $card2->{DriverVersion} ne '-current'; $card2; } elsif ($card2->{Driver} eq 'fglrx') { $check_drv->('fglrx_drv') or return; |