summaryrefslogtreecommitdiffstats
path: root/lib/Xconfig/card.pm
diff options
context:
space:
mode:
Diffstat (limited to 'lib/Xconfig/card.pm')
-rw-r--r--lib/Xconfig/card.pm10
1 files changed, 5 insertions, 5 deletions
diff --git a/lib/Xconfig/card.pm b/lib/Xconfig/card.pm
index 686b3c0..007c431 100644
--- a/lib/Xconfig/card.pm
+++ b/lib/Xconfig/card.pm
@@ -350,14 +350,14 @@ sub libgl_config_and_more {
$card->{Driver} eq 'nvidia' ? "/etc/nvidia$card->{DriverVersion}/ld.so.conf" :
'/etc/ld.so.conf.d/GL/' . (arch() =~ /64/ ? 'lib64' : 'lib') . 'mesagl1.conf';
my $link = "$::prefix/etc/alternatives/gl_conf";
- if (readlink($link) ne $wanted) {
- -e "$::prefix$wanted" or log::l("ERROR: $wanted does not exist, linking $link to it anyway");
- common::symlinkf_update_alternatives('gl_conf', $wanted);
- if ($::isStandalone) {
+ my $need_run_ldconfig = readlink($link) ne $wanted;
+ -e "$::prefix$wanted" or log::l("ERROR: $wanted does not exist, linking $link to it anyway");
+ common::symlinkf_update_alternatives('gl_conf', $wanted);
+ if ($need_run_ldconfig && $::isStandalone) {
log::explanations("ldconfig will be run because the GL library was " . ($wanted ? 'enabled' : 'disabled'));
system("/sbin/ldconfig");
- }
}
+
if ($card->{Driver} eq 'fglrx') {
log::l("workaround buggy fglrx driver: make dm restart xserver (#29550)");
eval { common::update_gnomekderc_no_create("$::prefix/etc/kde/kdm/kdmrc", 'X-:0-Core' => (