-
rockot authored
Using RTLD_DEEPBIND by default is problematic (see comments in native_library_posix.cc), but in the case of Mojo services where the host binary is lightweight but otherwise may export some conflicting symbols (e.g. tcmalloc), it is desirable. This CL adds a NativeLibraryOptions structure and a new LoadNativeLibraryWithOptions() call. The only supported option (|prefer_own_symbols|) only affects behavior on non-OSX, non-Android, POSIX systems. The default behavior of LoadNativeLibrary is unchanged. Also adds a unit test for general native library loading since there wasn't one before. BUG=594674 Review-Url: https://codereview.chromium.org/2277863002 Cr-Commit-Position: refs/heads/master@{#414605}
596a0dd7