| Index: base/native_library.h
|
| diff --git a/base/native_library.h b/base/native_library.h
|
| index b4f3a3cd1ba267000848b09c0ee9d8af7983387f..02eae1d508138e35f31bec5962a196529120d41f 100644
|
| --- a/base/native_library.h
|
| +++ b/base/native_library.h
|
| @@ -65,12 +65,32 @@ struct BASE_EXPORT NativeLibraryLoadError {
|
| #endif // OS_WIN
|
| };
|
|
|
| +struct BASE_EXPORT NativeLibraryOptions {
|
| + NativeLibraryOptions() = default;
|
| + NativeLibraryOptions(const NativeLibraryOptions& options) = default;
|
| +
|
| + // If |true|, a loaded library is required to prefer local symbol resolution
|
| + // before considering global symbols. Note that this is already the default
|
| + // behavior on most systems. Setting this to |false| does not guarantee the
|
| + // inverse, i.e., it does not force a preference for global symbols over local
|
| + // ones.
|
| + bool prefer_own_symbols = false;
|
| +};
|
| +
|
| // Loads a native library from disk. Release it with UnloadNativeLibrary when
|
| // you're done. Returns NULL on failure.
|
| // If |error| is not NULL, it may be filled in on load error.
|
| BASE_EXPORT NativeLibrary LoadNativeLibrary(const FilePath& library_path,
|
| NativeLibraryLoadError* error);
|
|
|
| +// Loads a native library from disk. Release it with UnloadNativeLibrary when
|
| +// you're done. Returns NULL on failure.
|
| +// If |error| is not NULL, it may be filled in on load error.
|
| +BASE_EXPORT NativeLibrary LoadNativeLibraryWithOptions(
|
| + const FilePath& library_path,
|
| + const NativeLibraryOptions& options,
|
| + NativeLibraryLoadError* error);
|
| +
|
| #if defined(OS_WIN)
|
| // Loads a native library from disk. Release it with UnloadNativeLibrary when
|
| // you're done.
|
|
|