33 #if OGRE_PLATFORM == OGRE_PLATFORM_WIN32
34 # define DYNLIB_HANDLE hInstance
35 # define DYNLIB_LOAD( a ) LoadLibraryEx( a, NULL, LOAD_WITH_ALTERED_SEARCH_PATH )
36 # define DYNLIB_GETSYM( a, b ) GetProcAddress( a, b )
37 # define DYNLIB_UNLOAD( a ) !FreeLibrary( a )
40 typedef struct HINSTANCE__* hInstance;
42 #elif OGRE_PLATFORM == OGRE_PLATFORM_LINUX || OGRE_PLATFORM == OGRE_PLATFORM_ANDROID || OGRE_PLATFORM == OGRE_PLATFORM_NACL
43 # define DYNLIB_HANDLE void*
44 # define DYNLIB_LOAD( a ) dlopen( a, RTLD_LAZY | RTLD_GLOBAL)
45 # define DYNLIB_GETSYM( a, b ) dlsym( a, b )
46 # define DYNLIB_UNLOAD( a ) dlclose( a )
48 #elif OGRE_PLATFORM == OGRE_PLATFORM_APPLE || OGRE_PLATFORM == OGRE_PLATFORM_APPLE_IOS
49 # define DYNLIB_HANDLE void*
50 # define DYNLIB_LOAD( a ) mac_loadDylib( a )
51 # define DYNLIB_GETSYM( a, b ) dlsym( a, b )
52 # define DYNLIB_UNLOAD( a ) dlclose( a )
112 void* getSymbol(
const String& strName )
const throw();
Resource holding data about a dynamic library.
Superclass for all objects that wish to use custom memory allocators when their new / delete operator...
const String & getName(void) const
Get the name of the library.
DYNLIB_HANDLE mInst
Handle to the loaded library.