Since `getLibraryLoaderMutex()` is only used in this one location why not using a local static variable?

    static boost::recursive_mutex load_mutex;
    boost::recursive_mutex::scoped_lock load_lock(mutex);