From 909154a989b84aab24a19483f395b5ea5b06197f Mon Sep 17 00:00:00 2001 From: Seungha Yang Date: Tue, 17 May 2022 03:32:10 +0900 Subject: [PATCH] qsv: Disable non-MSVC build on Windows ... and remove pointless UWP consideration that will never work. Cross-compiled binary has an issue which causes deadlock. Although cerbero will not build this plugin for non-MSVC build, people can still build this plugin and may complain its brokenness. See also https://gitlab.freedesktop.org/gstreamer/cerbero/-/merge_requests/854 Part-of: --- subprojects/gst-plugins-bad/sys/qsv/libmfx/meson.build | 18 ++++-------------- subprojects/gst-plugins-bad/sys/qsv/meson.build | 11 +++++++++++ 2 files changed, 15 insertions(+), 14 deletions(-) diff --git a/subprojects/gst-plugins-bad/sys/qsv/libmfx/meson.build b/subprojects/gst-plugins-bad/sys/qsv/libmfx/meson.build index db78fa87..fcb11f3 100644 --- a/subprojects/gst-plugins-bad/sys/qsv/libmfx/meson.build +++ b/subprojects/gst-plugins-bad/sys/qsv/libmfx/meson.build @@ -1,24 +1,16 @@ -mfx_win_sources = [ +mfx_win32_sources = [ 'dispatcher/windows/main.cpp', + 'dispatcher/windows/mfx_critical_section.cpp', 'dispatcher/windows/mfx_dispatcher_log.cpp', 'dispatcher/windows/mfx_dispatcher.cpp', + 'dispatcher/windows/mfx_driver_store_loader.cpp', 'dispatcher/windows/mfx_dxva2_device.cpp', 'dispatcher/windows/mfx_function_table.cpp', - 'dispatcher/windows/mfx_load_dll.cpp', -] - -mfx_win32_sources = [ - 'dispatcher/windows/mfx_critical_section.cpp', - 'dispatcher/windows/mfx_driver_store_loader.cpp', 'dispatcher/windows/mfx_library_iterator.cpp', + 'dispatcher/windows/mfx_load_dll.cpp', 'dispatcher/windows/mfx_win_reg_key.cpp', ] -mfx_uwp_sources = [ - 'dispatcher/windows/mfx_dispatcher_uwp.cpp', - 'dispatcher/windows/mfx_driver_store_loader.cpp', -] - mfx_linux_sources = [ 'dispatcher/linux/mfxloader.cpp', ] @@ -39,8 +31,6 @@ libmfx_extra_deps = [] libmfx_sources = vpl_sources if host_system == 'windows' - libmfx_sources += mfx_win_sources - # FIXME: check UWP only libmfx_sources += mfx_win32_sources elif host_system == 'linux' libmfx_sources += mfx_linux_sources diff --git a/subprojects/gst-plugins-bad/sys/qsv/meson.build b/subprojects/gst-plugins-bad/sys/qsv/meson.build index 45f4a63..b56b9a5 100644 --- a/subprojects/gst-plugins-bad/sys/qsv/meson.build +++ b/subprojects/gst-plugins-bad/sys/qsv/meson.build @@ -31,6 +31,17 @@ endif qsv_platform_deps = [] if host_system == 'windows' + # TODO: We can cross-compile this plugin using MinGW but there's an issue. + # Re-enable cross-compile once it's investigated and addressed + # https://gitlab.freedesktop.org/gstreamer/cerbero/-/merge_requests/854 + if cc.get_id() != 'msvc' + if qsv_option.enabled() + error('qsv plugin supports only MSVC build') + else + subdir_done() + endif + endif + if not gstd3d11_dep.found() if qsv_option.enabled() error('The qsv was enabled explicitly, but required d3d11 was not found') -- 2.7.4