Changeset 75267 in vbox for trunk/src/VBox/GuestHost/OpenGL/util
- Timestamp:
- Nov 6, 2018 6:58:03 AM (6 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/GuestHost/OpenGL/util/dll.c
r68859 r75267 16 16 17 17 #if defined(IRIX) || defined(IRIX64) || defined(Linux) || defined(FreeBSD) || defined(AIX) || defined(DARWIN) || defined(SunOS) || defined(OSF1) 18 # include <iprt/assert.h> 19 # include <iprt/err.h> 20 # include <iprt/path.h> 18 21 #include <dlfcn.h> 19 22 #endif … … 274 277 }; 275 278 #elif defined(IRIX) || defined(IRIX64) || defined(Linux) || defined(FreeBSD) || defined(AIX) || defined(SunOS) || defined(OSF1) 276 if (resolveGlobal) 277 dll->hinstLib = dlopen( dllname, RTLD_LAZY | RTLD_GLOBAL ); 278 else 279 dll->hinstLib = dlopen( dllname, RTLD_LAZY ); 280 dll_err = (char*) dlerror(); 279 { 280 int flags = RTLD_LAZY; 281 if (resolveGlobal) 282 flags |= RTLD_GLOBAL; 283 dll->hinstLib = dlopen( dllname, flags ); 284 # ifndef IN_GUEST 285 /* GCC address sanitiser breaks DT_RPATH. */ 286 if (!dll->hinstLib) do { 287 char szPath[RTPATH_MAX]; 288 int rc = RTPathSharedLibs(szPath, sizeof(szPath)); 289 AssertLogRelMsgRCBreak(rc, ("RTPathSharedLibs() failed: %Rrc\n", rc)); 290 rc = RTPathAppend(szPath, sizeof(szPath), dllname); 291 AssertLogRelMsgRCBreak(rc, ("RTPathAppend() failed: %Rrc\n", rc)); 292 dll->hinstLib = dlopen( szPath, flags ); 293 } while(0); 294 # endif 295 dll_err = (char*) dlerror(); 296 } 281 297 #else 282 298 #error DSO
Note:
See TracChangeset
for help on using the changeset viewer.