Changeset 83234 in vbox for trunk/src/VBox/Additions/x11
- Timestamp:
- Mar 9, 2020 8:10:44 AM (5 years ago)
- Location:
- trunk/src/VBox/Additions/x11/VBoxClient
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Additions/x11/VBoxClient/Makefile.kmk
r83228 r83234 33 33 VBoxClient_DEFS += VBOX_WITH_DBUS 34 34 endif 35 ifdef VBOX_WITH_DISTRO_XRAND_XINERAMA36 VBoxClient_DEFS += WITH_DISTRO_XRAND_XINERAMA37 VBoxClient_LIBS += Xrandr38 endif39 40 35 41 36 VBoxClient_DEFS.linux += _GNU_SOURCE … … 66 61 VBoxClient_LIBS = \ 67 62 X11 Xt Xext Xmu 63 ifdef VBOX_WITH_DISTRO_XRAND_XINERAMA 64 VBoxClient_DEFS += WITH_DISTRO_XRAND_XINERAMA 65 VBoxClient_LIBS += Xrandr 66 endif 67 68 68 # XXX: -L comes from the template, but not rpath 69 69 VBoxClient_LDFLAGS.netbsd = \ -
trunk/src/VBox/Additions/x11/VBoxClient/display-svga-x11.cpp
r83229 r83234 144 144 static int determineOutputCount(); 145 145 146 #define checkFunctionPtr(pFunction) \ 147 do{ \ 148 if (!pFunction) \ 149 { \ 150 VBClLogFatalError("Could not find symbol address\n"); \ 151 dlclose(x11Context.pRandLibraryHandle); \ 152 x11Context.pRandLibraryHandle = NULL; \ 153 return VERR_NOT_FOUND; \ 154 } \ 155 }while(0) 146 156 147 157 bool VMwareCtrlSetTopology(Display *dpy, int hExtensionMajorOpcode, … … 409 419 return VERR_NOT_FOUND; 410 420 } 421 411 422 *(void **)(&x11Context.pXRRSelectInput) = dlsym(x11Context.pRandLibraryHandle, "XRRSelectInput"); 412 if (!x11Context.pXRRSelectInput) 413 { 414 VBClLogFatalError("Could not find address for the symbol XRRSelectInput\n"); 415 dlclose(x11Context.pRandLibraryHandle); 416 x11Context.pRandLibraryHandle = NULL; 417 return VERR_NOT_FOUND; 418 } 423 checkFunctionPtr(x11Context.pXRRSelectInput); 424 419 425 *(void **)(&x11Context.pXRRQueryExtension) = dlsym(x11Context.pRandLibraryHandle, "XRRQueryExtension"); 420 if (!x11Context.pXRRQueryExtension) 421 { 422 VBClLogFatalError("Could not find address for the symbol XRRQueryExtension\n"); 423 dlclose(x11Context.pRandLibraryHandle); 424 x11Context.pRandLibraryHandle = NULL; 425 return VERR_NOT_FOUND; 426 } 426 checkFunctionPtr(x11Context.pXRRQueryExtension); 427 427 428 *(void **)(&x11Context.pXRRQueryVersion) = dlsym(x11Context.pRandLibraryHandle, "XRRQueryVersion"); 428 if (!x11Context.pXRRQueryVersion) 429 { 430 VBClLogFatalError("Could not find address for the symbol XRRQueryVersion\n"); 431 dlclose(x11Context.pRandLibraryHandle); 432 x11Context.pRandLibraryHandle = NULL; 433 return VERR_NOT_FOUND; 434 } 429 checkFunctionPtr(x11Context.pXRRQueryVersion); 430 435 431 *(void **)(&x11Context.pXRRGetMonitors) = dlsym(x11Context.pRandLibraryHandle, "XRRGetMonitors"); 436 if (!x11Context.pXRRGetMonitors) 437 { 438 VBClLogFatalError("Could not find address for the symbol XRRGetMonitors\n"); 439 dlclose(x11Context.pRandLibraryHandle); 440 x11Context.pRandLibraryHandle = NULL; 441 return VERR_NOT_FOUND; 442 } 432 checkFunctionPtr(x11Context.pXRRGetMonitors); 433 443 434 *(void **)(&x11Context.pXRRFreeMonitors) = dlsym(x11Context.pRandLibraryHandle, "XRRFreeMonitors"); 444 if (!x11Context.pXRRFreeMonitors) 445 { 446 VBClLogFatalError("Could not find address for the symbol XRRFreeMonitors\n"); 447 dlclose(x11Context.pRandLibraryHandle); 448 x11Context.pRandLibraryHandle = NULL; 449 return VERR_NOT_FOUND; 450 } 435 checkFunctionPtr(x11Context.pXRRFreeMonitors); 451 436 452 437 return VINF_SUCCESS;
Note:
See TracChangeset
for help on using the changeset viewer.