From: Brendan McGrath bmcgrath@codeweavers.com
These defines were only introduced to GStreamer in version 1.20; thus compiling against earlier versions causes a compilation error.
This commit replaces the defines with their respective expansions. --- dlls/winegstreamer/unix_private.h | 2 +- dlls/winegstreamer/unixlib.c | 2 +- dlls/winegstreamer/wg_transform.c | 5 ++++- 3 files changed, 6 insertions(+), 3 deletions(-)
diff --git a/dlls/winegstreamer/unix_private.h b/dlls/winegstreamer/unix_private.h index 149e8e50da5..3199e362fe6 100644 --- a/dlls/winegstreamer/unix_private.h +++ b/dlls/winegstreamer/unix_private.h @@ -110,6 +110,6 @@ extern void wg_allocator_provide_sample(GstAllocator *allocator, struct wg_sampl extern void wg_allocator_release_sample(GstAllocator *allocator, struct wg_sample *sample, bool discard_data);
-GST_ELEMENT_REGISTER_DECLARE(winegstreamerstepper); +extern gboolean gst_element_register_winegstreamerstepper(GstPlugin *plugin);
#endif /* __WINE_WINEGSTREAMER_UNIX_PRIVATE_H */ diff --git a/dlls/winegstreamer/unixlib.c b/dlls/winegstreamer/unixlib.c index 7a07b2e0a2a..354a7ba7047 100644 --- a/dlls/winegstreamer/unixlib.c +++ b/dlls/winegstreamer/unixlib.c @@ -301,7 +301,7 @@ NTSTATUS wg_init_gstreamer(void *arg) GST_INFO("GStreamer library version %s; wine built with %d.%d.%d.", gst_version_string(), GST_VERSION_MAJOR, GST_VERSION_MINOR, GST_VERSION_MICRO);
- if (!GST_ELEMENT_REGISTER(winegstreamerstepper, NULL)) + if (!gst_element_register_winegstreamerstepper(NULL)) GST_ERROR("Failed to register the stepper element");
return STATUS_SUCCESS; diff --git a/dlls/winegstreamer/wg_transform.c b/dlls/winegstreamer/wg_transform.c index 352415ad0b9..1d59f806a31 100644 --- a/dlls/winegstreamer/wg_transform.c +++ b/dlls/winegstreamer/wg_transform.c @@ -65,7 +65,10 @@ typedef struct _WgStepperClass #define GST_IS_WG_STEPPER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_WG_STEPPER))
G_DEFINE_TYPE (WgStepper, wg_stepper, GST_TYPE_ELEMENT); -GST_ELEMENT_REGISTER_DEFINE(winegstreamerstepper, "winegstreamerstepper", GST_RANK_NONE, GST_TYPE_WG_STEPPER); +gboolean gst_element_register_winegstreamerstepper(GstPlugin *plugin) +{ + return gst_element_register(plugin, "winegstreamerstepper", GST_RANK_NONE, GST_TYPE_WG_STEPPER); +}
static bool wg_stepper_step(WgStepper *stepper); static void wg_stepper_flush(WgStepper *stepper);