-VLC_EXPORT( void, __msg_Generic, ( vlc_object_t *, int, const char *, const char *, ... ) );
-VLC_EXPORT( void, __msg_Info, ( void *, const char *, ... ) );
-VLC_EXPORT( void, __msg_Err, ( void *, const char *, ... ) );
-VLC_EXPORT( void, __msg_Warn, ( void *, const char *, ... ) );
-VLC_EXPORT( void, __msg_Dbg, ( void *, const char *, ... ) );
-
-#ifdef HAVE_VARIADIC_MACROS
-
-# define msg_Info( p_this, psz_format, args... ) \
- __msg_Generic( CAST_TO_VLC_OBJECT(p_this), VLC_MSG_INFO, MODULE_STRING, \
- psz_format, ## args )
-
-# define msg_Err( p_this, psz_format, args... ) \
- __msg_Generic( CAST_TO_VLC_OBJECT(p_this), VLC_MSG_ERR, MODULE_STRING, \
- psz_format, ## args )
-
-# define msg_Warn( p_this, psz_format, args... ) \
- __msg_Generic( CAST_TO_VLC_OBJECT(p_this), VLC_MSG_WARN, MODULE_STRING, \
- psz_format, ## args )
-
-# define msg_Dbg( p_this, psz_format, args... ) \
- __msg_Generic( CAST_TO_VLC_OBJECT(p_this), VLC_MSG_DBG, MODULE_STRING, \
- psz_format, ## args )
-
-#else /* HAVE_VARIADIC_MACROS */
+VLC_EXPORT( void, msg_Generic, ( vlc_object_t *, int, const char *, const char *, ... ) LIBVLC_FORMAT( 4, 5 ) );
+VLC_EXPORT( void, msg_GenericVa, ( vlc_object_t *, int, const char *, const char *, va_list args ) );
+#define msg_GenericVa(a, b, c, d, e) msg_GenericVa(VLC_OBJECT(a), b, c, d, e)
+
+#define msg_Info( p_this, ... ) \
+ msg_Generic( VLC_OBJECT(p_this), VLC_MSG_INFO, \
+ MODULE_STRING, __VA_ARGS__ )
+#define msg_Err( p_this, ... ) \
+ msg_Generic( VLC_OBJECT(p_this), VLC_MSG_ERR, \
+ MODULE_STRING, __VA_ARGS__ )
+#define msg_Warn( p_this, ... ) \
+ msg_Generic( VLC_OBJECT(p_this), VLC_MSG_WARN, \
+ MODULE_STRING, __VA_ARGS__ )
+#define msg_Dbg( p_this, ... ) \
+ msg_Generic( VLC_OBJECT(p_this), VLC_MSG_DBG, \
+ MODULE_STRING, __VA_ARGS__ )
+
+typedef struct msg_cb_data_t msg_cb_data_t;
+
+/**
+ * Message logging callback signature.
+ * Accepts one private data pointer, the message, and an overrun counter.
+ */
+typedef void (*msg_callback_t) (msg_cb_data_t *, msg_item_t *, unsigned);
+
+VLC_EXPORT( msg_subscription_t*, msg_Subscribe, ( libvlc_int_t *, msg_callback_t, msg_cb_data_t * ) LIBVLC_USED );
+VLC_EXPORT( void, msg_Unsubscribe, ( msg_subscription_t * ) );
+VLC_EXPORT( void, msg_SubscriptionSetVerbosity, ( msg_subscription_t *, const int) );
+
+/* Enable or disable a certain object debug messages */
+VLC_EXPORT( void, msg_EnableObjectPrinting, ( vlc_object_t *, const char * psz_object ) );
+#define msg_EnableObjectPrinting(a,b) msg_EnableObjectPrinting(VLC_OBJECT(a),b)
+VLC_EXPORT( void, msg_DisableObjectPrinting, ( vlc_object_t *, const char * psz_object ) );
+#define msg_DisableObjectPrinting(a,b) msg_DisableObjectPrinting(VLC_OBJECT(a),b)
+
+
+/**
+ * @}
+ */
+
+/**
+ * \defgroup statistics Statistics
+ *
+ * @{
+ */