mirror of
https://github.com/obsproject/obs-studio.git
synced 2026-10-17 03:31:24 -04:00
By default duplicate non-static symbols loaded by dynamic libraries are de-duplicated by the dynamic library loader. This can lead to issues with statically linked libraries inside obs plugins if the symbols share their signature: Whichever plugin is loaded first gets to "set" the symbol (which can become problematic especially for C++ template functions). Using RTLD_LOCAL ensures that all symbols are hidden and can only be explicitly loaded using dlsym() which avoids this issue. Unfortunately due to the way scripting works in obs-studio, Python still needs to be loaded with RTLD_GLOBAL, hence the branch in the fix.