[Spice-devel] [PATCH spice-streaming-agent 3/3] Add a macro to deal with the boilerplate of writing a streaming agent plugin

Christophe Fergeau cfergeau at redhat.com
Fri Apr 20 15:42:39 UTC 2018


Looks good to me,

Acked-by: Christophe Fergeau <cfergeau at redhat.com>

On Thu, Apr 19, 2018 at 05:48:35PM +0100, Frediano Ziglio wrote:
> From: Christophe de Dinechin <dinechin at redhat.com>
> 
> Signed-off-by: Christophe de Dinechin <dinechin at redhat.com>
> ---
>  include/spice-streaming-agent/plugin.hpp | 9 +++++++++
>  1 file changed, 9 insertions(+)
> 
> diff --git a/include/spice-streaming-agent/plugin.hpp b/include/spice-streaming-agent/plugin.hpp
> index f95fb11..b01cd82 100644
> --- a/include/spice-streaming-agent/plugin.hpp
> +++ b/include/spice-streaming-agent/plugin.hpp
> @@ -151,6 +151,15 @@ extern "C" unsigned spice_streaming_agent_plugin_interface_version;
>   * \return true if plugin should stay loaded, false otherwise
>   */
>  extern "C" spice::streaming_agent::PluginInitFunc spice_streaming_agent_plugin_init;
> +
> +#define SPICE_STREAMING_AGENT_PLUGIN(agent)                             \
> +    __attribute__ ((visibility ("default")))                            \
> +    unsigned spice_streaming_agent_plugin_interface_version =           \
> +        spice::streaming_agent::PluginInterfaceVersion;                 \
> +                                                                        \
> +    __attribute__ ((visibility ("default")))                            \
> +    bool spice_streaming_agent_plugin_init(spice::streaming_agent::Agent* agent)
> +
>  #endif
>  
>  #endif // SPICE_STREAMING_AGENT_PLUGIN_HPP
> -- 
> 2.14.3
> 
> _______________________________________________
> Spice-devel mailing list
> Spice-devel at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/spice-devel
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: not available
URL: <https://lists.freedesktop.org/archives/spice-devel/attachments/20180420/4aaf04fd/attachment.sig>


More information about the Spice-devel mailing list