mirror of
https://github.com/corda/corda.git
synced 2024-12-29 09:18:58 +00:00
use lib%s.dylib to map library names on Darwin
This commit is contained in:
parent
54cabf9240
commit
a688a6f61a
@ -597,9 +597,15 @@ class MySystem: public System {
|
||||
void* p;
|
||||
unsigned nameLength = (name ? strlen(name) : 0);
|
||||
if (mapName) {
|
||||
#ifdef __APPLE__
|
||||
unsigned size = nameLength + 10;
|
||||
char buffer[size];
|
||||
snprintf(buffer, size, "lib%s.dylib", name);
|
||||
#else
|
||||
unsigned size = nameLength + 7;
|
||||
char buffer[size];
|
||||
snprintf(buffer, size, "lib%s.so", name);
|
||||
#endif
|
||||
p = dlopen(buffer, RTLD_LAZY);
|
||||
} else {
|
||||
p = dlopen(name, RTLD_LAZY);
|
||||
|
Loading…
Reference in New Issue
Block a user