From f50188b8a0fd06539dbe78938c9975b5f5ecda16 Mon Sep 17 00:00:00 2001 From: Steve Lhomme Date: Sat, 12 Jun 2004 10:51:35 +0000 Subject: [PATCH] Fix a bug to enable/disable DEBUG under MSVC Original commit message from CVS: Fix a bug to enable/disable DEBUG under MSVC --- ChangeLog | 12 ++++++++++++ gst/gst.c | 2 +- gst/gstbin.c | 2 +- gst/gstbin.h | 2 +- gst/gstelement.c | 2 +- gst/gstelement.h | 2 +- gst/gstevent.h | 2 +- gst/gstinfo.h | 4 ++++ gst/gstobject.c | 2 +- gst/gstobject.h | 2 +- gst/gstpad.h | 6 +++--- tools/gst-register.c | 2 +- win32/gstreamer.def | 36 +++++++++++++++++++++++++++--------- win32/vs7/gstreamer.def | 36 +++++++++++++++++++++++++++--------- 14 files changed, 82 insertions(+), 30 deletions(-) diff --git a/ChangeLog b/ChangeLog index 78fb64cc2e..9cf1e467e8 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,15 @@ +2004-06-12 Steve Lhomme + + * gst/gst.c: + * gst/gstbin.*: + * gst/gstelement.*: + * gst/gstevent.h: + * gst/gstobject.*: + * gst/gstpad.h: + * tools/gst-register.c: + * win32/gstreamer.def: + extern symbols are now exported for the Windows DLL + 2004-06-12 Steve Lhomme * gst/gstinfo.h: diff --git a/gst/gst.c b/gst/gst.c index 16e99ae7d9..0e318a4100 100644 --- a/gst/gst.c +++ b/gst/gst.c @@ -40,7 +40,7 @@ #define GST_PLUGIN_SEPARATOR "," #ifndef GST_DISABLE_REGISTRY -gboolean _gst_registry_auto_load = TRUE; +GSTREAMER_EXPORT gboolean _gst_registry_auto_load = TRUE; static GstRegistry *_global_registry; static GstRegistry *_user_registry; static gboolean _gst_registry_fixed = FALSE; diff --git a/gst/gstbin.c b/gst/gstbin.c index 339c55b773..cac5794600 100644 --- a/gst/gstbin.c +++ b/gst/gstbin.c @@ -38,7 +38,7 @@ static GstElementDetails gst_bin_details = GST_ELEMENT_DETAILS ("Generic bin", "Simple container object", "Erik Walthinsen "); -GType _gst_bin_type = 0; +GSTREAMER_EXPORT GType _gst_bin_type = 0; static gboolean _gst_boolean_did_something_accumulator (GSignalInvocationHint * ihint, GValue * return_accu, const GValue * handler_return, gpointer dummy); diff --git a/gst/gstbin.h b/gst/gstbin.h index 373b363ec5..109251e23e 100644 --- a/gst/gstbin.h +++ b/gst/gstbin.h @@ -28,7 +28,7 @@ G_BEGIN_DECLS -extern GType _gst_bin_type; +GSTREAMER_EXPORT GType _gst_bin_type; #define GST_TYPE_BIN (_gst_bin_type) #define GST_IS_BIN(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GST_TYPE_BIN)) diff --git a/gst/gstelement.c b/gst/gstelement.c index b9ee9f5a45..cb2ce47718 100644 --- a/gst/gstelement.c +++ b/gst/gstelement.c @@ -83,7 +83,7 @@ static xmlNodePtr gst_element_save_thyself (GstObject * object, static void gst_element_restore_thyself (GstObject * parent, xmlNodePtr self); #endif -GType _gst_element_type = 0; +GSTREAMER_EXPORT GType _gst_element_type = 0; static GstObjectClass *parent_class = NULL; static guint gst_element_signals[LAST_SIGNAL] = { 0 }; diff --git a/gst/gstelement.h b/gst/gstelement.h index ab5900879a..e2b389eb52 100644 --- a/gst/gstelement.h +++ b/gst/gstelement.h @@ -70,7 +70,7 @@ struct _GstElementDetails { #define GST_STATE_PAUSED_TO_READY ((GST_STATE_PAUSED<<8) | GST_STATE_READY) #define GST_STATE_READY_TO_NULL ((GST_STATE_READY<<8) | GST_STATE_NULL) -extern GType _gst_element_type; +GSTREAMER_EXPORT GType _gst_element_type; #define GST_TYPE_ELEMENT (_gst_element_type) #define GST_IS_ELEMENT(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GST_TYPE_ELEMENT)) diff --git a/gst/gstevent.h b/gst/gstevent.h index 08e575faa6..cecae7b5d9 100644 --- a/gst/gstevent.h +++ b/gst/gstevent.h @@ -32,7 +32,7 @@ G_BEGIN_DECLS -extern GType _gst_event_type; +GSTREAMER_EXPORT GType _gst_event_type; typedef enum { GST_EVENT_UNKNOWN = 0, diff --git a/gst/gstinfo.h b/gst/gstinfo.h index 668543b07c..7f35653cd2 100644 --- a/gst/gstinfo.h +++ b/gst/gstinfo.h @@ -627,7 +627,11 @@ G_CONST_RETURN gchar* #define GST_DEBUG_CATEGORY(var) /* NOP */ #define GST_DEBUG_CATEGORY_EXTERN(var) /* NOP */ +#if !defined(G_HAVE_GNUC_VARARGS) && !defined(G_HAVE_ISO_VARARGS) +#define GST_DEBUG_CATEGORY_STATIC(var) static GstDebugCategory *var = NULL +#else #define GST_DEBUG_CATEGORY_STATIC(var) /* NOP */ +#endif #define GST_DEBUG_CATEGORY_INIT(var,name,color,desc) /* NOP */ #define gst_debug_category_free(category) /* NOP */ #define gst_debug_category_set_threshold(category,level) /* NOP */ diff --git a/gst/gstobject.c b/gst/gstobject.c index f8ab6216b4..2fef7e984e 100644 --- a/gst/gstobject.c +++ b/gst/gstobject.c @@ -55,7 +55,7 @@ enum SO_LAST_SIGNAL }; -GType _gst_object_type = 0; +GSTREAMER_EXPORT GType _gst_object_type = 0; static GHashTable *object_name_counts = NULL; G_LOCK_DEFINE_STATIC (object_name_mutex); diff --git a/gst/gstobject.h b/gst/gstobject.h index 0cb918ff7b..d5e1c73262 100644 --- a/gst/gstobject.h +++ b/gst/gstobject.h @@ -32,7 +32,7 @@ G_BEGIN_DECLS -extern GType _gst_object_type; +GSTREAMER_EXPORT GType _gst_object_type; #define GST_TYPE_OBJECT (_gst_object_type) #define GST_IS_OBJECT(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GST_TYPE_OBJECT)) diff --git a/gst/gstpad.h b/gst/gstpad.h index e62863f914..b2185932b1 100644 --- a/gst/gstpad.h +++ b/gst/gstpad.h @@ -36,9 +36,9 @@ G_BEGIN_DECLS -extern GType _gst_pad_type; -extern GType _gst_real_pad_type; -extern GType _gst_ghost_pad_type; +GSTREAMER_EXPORT GType _gst_pad_type; +GSTREAMER_EXPORT GType _gst_real_pad_type; +GSTREAMER_EXPORT GType _gst_ghost_pad_type; /* * Pad base class diff --git a/tools/gst-register.c b/tools/gst-register.c index baa2be5a72..6ce3b89ae5 100644 --- a/tools/gst-register.c +++ b/tools/gst-register.c @@ -37,7 +37,7 @@ #include #include -extern gboolean _gst_registry_auto_load; +GSTREAMER_EXPORT gboolean _gst_registry_auto_load; static gint num_features = 0; static gint num_plugins = 0; diff --git a/win32/gstreamer.def b/win32/gstreamer.def index 98987a2565..503ceaece8 100644 --- a/win32/gstreamer.def +++ b/win32/gstreamer.def @@ -24,20 +24,14 @@ EXPORTS gst_pad_convert_default gst_pad_get_formats gst_pad_get_formats_default - _gst_ghost_pad_type gst_pad_get_name gst_pad_get_direction - _gst_real_pad_type - _gst_pad_type gst_element_get_pad_list gst_element_is_indexable gst_element_get_clock gst_element_provides_clock gst_element_requires_clock - _gst_bin_type gst_plugin_feature_get_type - _gst_element_type - _gst_object_type gst_element_factory_create gst_structure_foreach gst_structure_get_name @@ -64,6 +58,7 @@ EXPORTS gst_bin_get_clock gst_element_set_state gst_bin_add + gst_bin_add_many gst_element_factory_make gst_xml_write_file gst_element_default_error @@ -90,13 +85,11 @@ EXPORTS gst_registry_add_path gst_registry_get_type gst_registry_pool_list - _gst_registry_auto_load gst_data_unref gst_buffer_new gst_buffer_create_sub gst_buffer_merge gst_buffer_is_span_fast - _gst_event_type gst_pad_pull gst_pad_send_event gst_event_new_seek @@ -122,9 +115,9 @@ EXPORTS gst_util_dump_mem gst_element_wait gst_element_set_time + gst_element_link_pads gst_element_error_full gst_core_error_quark - _gst_element_error_printf gst_pad_set_formats_function gst_pad_set_query_type_function gst_pad_set_query_function @@ -185,6 +178,31 @@ EXPORTS gst_seek_type_get_type gst_event_type_get_type gst_pad_unnegotiate + gst_pipeline_new + gst_bin_new + gst_bin_get_by_interface + gst_bin_get_all_by_interface + gst_alloc_trace_live_all + gst_element_link_many + gst_caps_new_empty + gst_caps_new_simple + gst_caps_is_fixed + gst_caps_to_string + gst_type_fourcc + gst_structure_new + gst_caps_new_full + gst_caps_append + gst_caps_append_structure gst_marshal_VOID__UINT_BOXED gst_marshal_BOOLEAN__POINTER gst_marshal_VOID__POINTER_OBJECT + _gst_element_error_printf + _gst_bin_type DATA + _gst_element_type DATA + _gst_object_type DATA + _gst_registry_auto_load DATA + _gst_pad_type DATA + _gst_real_pad_type DATA + _gst_ghost_pad_type DATA + _gst_event_type DATA + diff --git a/win32/vs7/gstreamer.def b/win32/vs7/gstreamer.def index 98987a2565..503ceaece8 100644 --- a/win32/vs7/gstreamer.def +++ b/win32/vs7/gstreamer.def @@ -24,20 +24,14 @@ EXPORTS gst_pad_convert_default gst_pad_get_formats gst_pad_get_formats_default - _gst_ghost_pad_type gst_pad_get_name gst_pad_get_direction - _gst_real_pad_type - _gst_pad_type gst_element_get_pad_list gst_element_is_indexable gst_element_get_clock gst_element_provides_clock gst_element_requires_clock - _gst_bin_type gst_plugin_feature_get_type - _gst_element_type - _gst_object_type gst_element_factory_create gst_structure_foreach gst_structure_get_name @@ -64,6 +58,7 @@ EXPORTS gst_bin_get_clock gst_element_set_state gst_bin_add + gst_bin_add_many gst_element_factory_make gst_xml_write_file gst_element_default_error @@ -90,13 +85,11 @@ EXPORTS gst_registry_add_path gst_registry_get_type gst_registry_pool_list - _gst_registry_auto_load gst_data_unref gst_buffer_new gst_buffer_create_sub gst_buffer_merge gst_buffer_is_span_fast - _gst_event_type gst_pad_pull gst_pad_send_event gst_event_new_seek @@ -122,9 +115,9 @@ EXPORTS gst_util_dump_mem gst_element_wait gst_element_set_time + gst_element_link_pads gst_element_error_full gst_core_error_quark - _gst_element_error_printf gst_pad_set_formats_function gst_pad_set_query_type_function gst_pad_set_query_function @@ -185,6 +178,31 @@ EXPORTS gst_seek_type_get_type gst_event_type_get_type gst_pad_unnegotiate + gst_pipeline_new + gst_bin_new + gst_bin_get_by_interface + gst_bin_get_all_by_interface + gst_alloc_trace_live_all + gst_element_link_many + gst_caps_new_empty + gst_caps_new_simple + gst_caps_is_fixed + gst_caps_to_string + gst_type_fourcc + gst_structure_new + gst_caps_new_full + gst_caps_append + gst_caps_append_structure gst_marshal_VOID__UINT_BOXED gst_marshal_BOOLEAN__POINTER gst_marshal_VOID__POINTER_OBJECT + _gst_element_error_printf + _gst_bin_type DATA + _gst_element_type DATA + _gst_object_type DATA + _gst_registry_auto_load DATA + _gst_pad_type DATA + _gst_real_pad_type DATA + _gst_ghost_pad_type DATA + _gst_event_type DATA +