X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=include%2Fvlc_plugin.h;h=f0d2554562ecbb4b15a76776a44664f5c0cf25c2;hb=6a66117a34f627ad9560b07cead07663b48f23b6;hp=b5893003637fc905a2d9b0525860cc0013466d19;hpb=8e17cc40106fd1b44b6f48fec0bdc1298b27c2bf;p=vlc diff --git a/include/vlc_plugin.h b/include/vlc_plugin.h index b589300363..f0d2554562 100644 --- a/include/vlc_plugin.h +++ b/include/vlc_plugin.h @@ -34,8 +34,8 @@ /** * Current plugin ABI version */ -# define MODULE_SYMBOL 0_9_0k -# define MODULE_SUFFIX "__0_9_0k" +# define MODULE_SYMBOL 0_9_0m +# define MODULE_SUFFIX "__0_9_0m" /***************************************************************************** * Add a few defines. You do not want to read this section. Really. @@ -83,13 +83,11 @@ * instance the module name, its shortcuts, its capabilities... we also create * a copy of its config because the module can be unloaded at any time. */ -#if defined (__PLUGIN__) || defined (__BUILTIN__) -EXTERN_SYMBOL DLL_SYMBOL int CDECL_SYMBOL -E_(vlc_entry) ( module_t *p_module ); -#endif - #define vlc_module_begin( ) \ EXTERN_SYMBOL DLL_SYMBOL int CDECL_SYMBOL \ + E_(vlc_entry) ( module_t *p_module ); \ + \ + EXTERN_SYMBOL DLL_SYMBOL int CDECL_SYMBOL \ __VLC_SYMBOL(vlc_entry) ( module_t *p_module ) \ { \ module_config_t *p_config = NULL; \ @@ -107,7 +105,8 @@ E_(vlc_entry) ( module_t *p_module ); \ error: \ return VLC_EGENERIC; \ - } + } \ + VLC_METADATA_EXPORTS #define add_submodule( ) \ p_submodule = vlc_submodule_create( p_module ); @@ -448,4 +447,34 @@ enum vlc_config_properties #define change_safe() \ vlc_config_set (p_config, VLC_CONFIG_SAFE); +/* Meta data plugin exports */ +#define VLC_META_EXPORT( name, value ) \ + EXTERN_SYMBOL DLL_SYMBOL const char * CDECL_SYMBOL \ + E_(vlc_entry_ ## name) (void); \ + EXTERN_SYMBOL DLL_SYMBOL const char * CDECL_SYMBOL \ + __VLC_SYMBOL(vlc_entry_ ## name) (void) \ + { \ + return value; \ + } + +#if defined (__LIBVLC__) +# define VLC_COPYRIGHT_EXPORT VLC_META_EXPORT (copyright, \ + "\x43\x6f\x70\x79\x72\x69\x67\x68\x74\x20\x28\x43\x29\x20\x74\x68" \ + "\x65\x20\x56\x69\x64\x65\x6f\x4c\x41\x4e\x20\x56\x4c\x43\x20\x6d" \ + "\x65\x64\x69\x61\x20\x70\x6c\x61\x79\x65\x72\x20\x64\x65\x76\x65" \ + "\x6c\x6f\x70\x70\x65\x72\x73" ) +#elif !defined (VLC_COPYRIGHT_EXPORT) +# define VLC_COPYRIGHT_EXPORT +#endif +#define VLC_LICENSE_EXPORT VLC_META_EXPORT (license, \ + "\x4c\x69\x63\x65\x6e\x73\x65\x64\x20\x75\x6e\x64\x65\x72\x20\x74" \ + "\x68\x65\x20\x74\x65\x72\x6d\x73\x20\x6f\x66\x20\x74\x68\x65\x20" \ + "\x47\x4e\x55\x20\x47\x65\x6e\x65\x72\x61\x6c\x20\x50\x75\x62\x6c" \ + "\x69\x63\x20\x4c\x69\x63\x65\x6e\x73\x65\x2c\x20\x76\x65\x72\x73" \ + "\x69\x6f\x6e\x20\x32\x20\x6f\x72\x20\x6c\x61\x74\x65\x72\x2e" ) + +#define VLC_METADATA_EXPORTS \ + VLC_COPYRIGHT_EXPORT \ + VLC_LICENSE_EXPORT + #endif