util::dynamic_import

Futex implementation
This commit is contained in:
Nekotekina 2017-01-24 16:52:15 +03:00 committed by Ivan
parent 8ad31d2559
commit 98fc131d47
3 changed files with 183 additions and 175 deletions

View file

@ -57,4 +57,13 @@ namespace utils
{
return loaded();
}
void* get_proc_address(const char* lib, const char* name)
{
#ifdef _WIN32
return GetProcAddress(GetModuleHandleA(lib), name);
#else
return dlsym(dlopen(lib, RTLD_NOLOAD), name);
#endif
}
}