Merge pull request #6116 from Hinsbart/xrandr_so

x11: Use proper sonames for loading libXrandr.
This commit is contained in:
Rémi Verschelde 2016-08-29 19:04:13 +02:00 committed by GitHub
commit ecaa8844ca

View file

@ -127,10 +127,10 @@ void OS_X11::initialize(const VideoMode& p_desired,int p_video_driver,int p_audi
int xrandr_minor = 0; int xrandr_minor = 0;
int event_base, error_base; int event_base, error_base;
xrandr_ext_ok = XRRQueryExtension(x11_display,&event_base, &error_base); xrandr_ext_ok = XRRQueryExtension(x11_display,&event_base, &error_base);
xrandr_handle = dlopen("libXrandr.so", RTLD_LAZY); xrandr_handle = dlopen("libXrandr.so.2", RTLD_LAZY);
err = dlerror();
if (!xrandr_handle) { if (!xrandr_handle) {
fprintf(stderr, "could not load libXrandr.so, Error: %s\n", err); err = dlerror();
fprintf(stderr, "could not load libXrandr.so.2, Error: %s\n", err);
} }
else { else {
XRRQueryVersion(x11_display, &xrandr_major, &xrandr_minor); XRRQueryVersion(x11_display, &xrandr_major, &xrandr_minor);