Mercurial > hg > vamp-plugin-sdk
diff README.compat @ 263:4454843ff384
* OK, we're going to have to place the host stuff in its own namespace
too. Otherwise our new SV build on OSX fails to load old plugins
because they pull in the host namespace PluginBase and thus report
the wrong Vamp version... *sigh*
author | cannam |
---|---|
date | Thu, 20 Nov 2008 15:01:30 +0000 |
parents | 3d98dd2ba0d6 |
children | 03c7167e1f30 |
line wrap: on
line diff
--- a/README.compat Fri Nov 14 14:20:47 2008 +0000 +++ b/README.compat Thu Nov 20 15:01:30 2008 +0000 @@ -76,22 +76,25 @@ Hosts that incorporate plugin code ---------------------------------- -One of the changes in this version of the SDK is that classes compiled -into plugins are now internally enclosed in a special C++ namespace -(the _VampPlugin namespace) to avoid any confusion between host and -plugin namespaces in unusual linkage situations. This is handled -transparently in most circumstances, and neither plugin nor host -authors will normally need to care about it. +One of the changes in this version of the SDK is that separate +top-level C++ namespaces are used for classes compiled into plugins +(the _VampPlugin namespace) and hosts (the _VampHost namespace), to +avoid any confusion between host and plugin namespaces in unusual +linkage situations. This is handled transparently in most +circumstances, and neither plugin nor host authors will normally need +to care about it. However, hosts that directly incorporate code from plugins, for example to provide functionality that is the same as those plugins without having to explicitly load them, may find that they can no longer resolve plugin functions at link time because of this namespace mismatch. To avoid this, the host build process should define the -preprocessor flag VAMP_NO_PLUGIN_NAMESPACE when compiling the plugin +preprocessor flag _VAMP_NO_PLUGIN_NAMESPACE when compiling the plugin code to ensure that both host and plugin code exist at the same level -of namespace. +of namespace. Note that the corresponding _VAMP_NO_HOST_NAMESPACE is +also available. (If your host does this, why not make it load the plugins dynamically instead using the normal Vamp plugin loader method? There are many advantages to that.) +