info: make _gst_debug_init() private for now

This was a FIXME for 0.11. I guess a case could be made to keep it around
separately for apps or libraries that only want to use GStreamer's debugging
system, but it seems more likely they'd just copy the two source files into
their own tree if the case. Also, things like types wouldn't be initialised
without gst_init(). We can still make it public again if anyone needs it,
but then we should make it a proper function and not hide it behind
underscores.
This commit is contained in:
Tim-Philipp Müller 2011-10-08 20:15:46 +01:00
parent 21ec07eab0
commit ac40ab45b3
4 changed files with 7 additions and 15 deletions

View file

@ -577,7 +577,9 @@ init_pre (GOptionContext * context, GOptionGroup * group, gpointer data,
/* we need threading to be enabled right here */ /* we need threading to be enabled right here */
g_assert (g_thread_get_initialized ()); g_assert (g_thread_get_initialized ());
_gst_debug_init (); #ifndef GST_DISABLE_GST_DEBUG
_priv_gst_debug_init ();
#endif
#ifdef ENABLE_NLS #ifdef ENABLE_NLS
setlocale (LC_ALL, ""); setlocale (LC_ALL, "");

View file

@ -79,6 +79,7 @@ struct _GstPluginPrivate {
GstStructure *cache_data; GstStructure *cache_data;
}; };
/* FIXME: could rename all priv_gst_* functions to __gst_* now */
gboolean priv_gst_plugin_loading_have_whitelist (void); gboolean priv_gst_plugin_loading_have_whitelist (void);
guint32 priv_gst_plugin_loading_get_whitelist_hash (void); guint32 priv_gst_plugin_loading_get_whitelist_hash (void);
@ -106,6 +107,7 @@ void _priv_gst_plugin_initialize (void);
void _priv_gst_query_initialize (void); void _priv_gst_query_initialize (void);
void _priv_gst_tag_initialize (void); void _priv_gst_tag_initialize (void);
void _priv_gst_value_initialize (void); void _priv_gst_value_initialize (void);
void _priv_gst_debug_init (void);
/* Private registry functions */ /* Private registry functions */
gboolean _priv_gst_registry_remove_cache_plugins (GstRegistry *registry); gboolean _priv_gst_registry_remove_cache_plugins (GstRegistry *registry);

View file

@ -303,14 +303,9 @@ _priv_gst_in_valgrind (void)
return (in_valgrind == GST_VG_INSIDE); return (in_valgrind == GST_VG_INSIDE);
} }
/** /* Initialize the debugging system */
* _gst_debug_init:
*
* Initializes the debugging system.
* Normally you don't want to call this, because gst_init() does it for you.
*/
void void
_gst_debug_init (void) _priv_gst_debug_init (void)
{ {
const gchar *env; const gchar *env;

View file

@ -256,11 +256,6 @@ typedef void (*GstLogFunction) (GstDebugCategory * category,
GstDebugMessage * message, GstDebugMessage * message,
gpointer data); gpointer data);
/* FIXME 0.11: move this into private headers */
void _gst_debug_init (void);
#ifdef GST_USING_PRINTF_EXTENSION #ifdef GST_USING_PRINTF_EXTENSION
/* not using G_GNUC_PRINTF, since gcc will choke on GST_PTR_FORMAT being %P */ /* not using G_GNUC_PRINTF, since gcc will choke on GST_PTR_FORMAT being %P */
@ -1262,8 +1257,6 @@ GST_TRACE (const char *format, ...)
#define _gst_debug_min GST_LEVEL_NONE #define _gst_debug_min GST_LEVEL_NONE
#define _gst_debug_init() G_STMT_START{ }G_STMT_END
#define gst_debug_set_default_threshold(level) G_STMT_START{ }G_STMT_END #define gst_debug_set_default_threshold(level) G_STMT_START{ }G_STMT_END
#define gst_debug_get_default_threshold() (GST_LEVEL_NONE) #define gst_debug_get_default_threshold() (GST_LEVEL_NONE)