Skip to content

Commit 27b519c

Browse files
committed
[GStreamer][WebRTC] Fix build with GStreamer 1.18
In downstream WPE, we build with GstWebRTC support by using GStreamer 1.18 + backports for GstWebRTC from WebPlatformForEmbedded/buildroot#550
1 parent 1b12373 commit 27b519c

File tree

2 files changed

+3
-9
lines changed

2 files changed

+3
-9
lines changed

Source/WebCore/Modules/mediastream/gstreamer/GStreamerDataChannelHandler.cpp

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -262,13 +262,6 @@ bool GStreamerDataChannelHandler::checkState()
262262

263263
RTCDataChannelState state;
264264
switch (channelState) {
265-
#if !GST_CHECK_VERSION(1, 22, 0)
266-
// Removed in https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/2099. In
267-
// GStreamer < 1.22 GST_WEBRTC_DATA_CHANNEL_STATE_NEW had the 0 value. We keep this case only to
268-
// avoid adding a default case.
269-
case GST_WEBRTC_DATA_CHANNEL_STATE_NEW:
270-
break;
271-
#endif
272265
case GST_WEBRTC_DATA_CHANNEL_STATE_CONNECTING:
273266
state = RTCDataChannelState::Connecting;
274267
break;

Source/cmake/GStreamerChecks.cmake

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -51,8 +51,9 @@ if (ENABLE_VIDEO OR ENABLE_WEB_AUDIO)
5151
message(FATAL_ERROR "GStreamerTranscoder >= 1.20 is needed for USE_GSTREAMER_TRANSCODER.")
5252
endif ()
5353

54-
if (USE_GSTREAMER_WEBRTC AND (PC_GSTREAMER_VERSION VERSION_LESS "1.20" OR NOT PC_GSTREAMER_WEBRTC_FOUND))
55-
message(FATAL_ERROR "GStreamerWebRTC >= 1.20 is needed for USE_GSTREAMER_WEBRTC.")
54+
# We use GStreamer 1.18 with backports for GstWebRTC support. In upstream WebKit, >= 1.20 is required.
55+
if (USE_GSTREAMER_WEBRTC AND (PC_GSTREAMER_VERSION VERSION_LESS "1.18" OR NOT PC_GSTREAMER_WEBRTC_FOUND))
56+
message(FATAL_ERROR "GStreamerWebRTC >= 1.18 is needed for USE_GSTREAMER_WEBRTC.")
5657
endif ()
5758
endif ()
5859
endif ()

0 commit comments

Comments
 (0)