How can I ensure that a host + dynamically loaded shared library plugin use the same global state in a third party shared library?
I have a host binary executable that defines main
and uses dlopen/dlsym
to interact with a plugin dynamically loaded shared library. The host might be a game, and the plugin might be a mod for the game.