diff options
Diffstat (limited to 'dso')
-rw-r--r-- | dso/unix/dso.c | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/dso/unix/dso.c b/dso/unix/dso.c index 944fafe15..a9b22b28e 100644 --- a/dso/unix/dso.c +++ b/dso/unix/dso.c @@ -126,12 +126,18 @@ APR_DECLARE(apr_status_t) apr_dso_load(apr_dso_handle_t **res_handle, NSModule os_handle = NULL; char* err_msg = NULL; if (NSCreateObjectFileImageFromFile(path, &image) == NSObjectFileImageSuccess) { -#ifdef NSLINKMODULE_OPTION_PRIVATE + +/* + * Under Darwin, we want/need to place dynamically loaded extensions' + * public symbols into the global symbol table. As long as modules + * don't have overlapping symbols, we're golden. + */ +#if defined(NSLINKMODULE_OPTION_NONE) os_handle = NSLinkModule(image, path, - NSLINKMODULE_OPTION_PRIVATE | + NSLINKMODULE_OPTION_NONE | NSLINKMODULE_OPTION_RETURN_ON_ERROR); #else - os_handle = NSLinkModule(image, path, TRUE); + os_handle = NSLinkModule(image, path, FALSE); #endif NSDestroyObjectFileImage(image); } |