meson: Fix qt detection for qt6d3d11 plugin
This now matches the code for the qml6gl plugin. Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9046>
This commit is contained in:
parent
099b8825a7
commit
331a381c66
@ -27,6 +27,7 @@ moc_headers = [
|
||||
|
||||
have_qt6d3d11 = false
|
||||
|
||||
qt6_method = get_option('qt-method')
|
||||
qt6_option = get_option('qt6d3d11')
|
||||
if qt6_option.disabled()
|
||||
subdir_done()
|
||||
@ -41,21 +42,26 @@ if not gstd3d11_dep.found()
|
||||
endif
|
||||
|
||||
qt6_mod = import('qt6')
|
||||
if not qt6_mod.has_tools()
|
||||
if meson.version().version_compare('>=1.6')
|
||||
have_tools = qt6_mod.has_tools(method: qt6_method, tools: ['moc', 'uic', 'rcc'])
|
||||
else
|
||||
have_tools = qt6_mod.has_tools(method: qt6_method)
|
||||
endif
|
||||
if not have_tools
|
||||
if qt6_option.enabled()
|
||||
error('qt6 plugin was enabled, but qt specific tools were not found')
|
||||
error('qt6 d3d11 plugin was enabled, but qt specific tools were not found')
|
||||
endif
|
||||
subdir_done()
|
||||
endif
|
||||
|
||||
qt6qml_dep = dependency('qt6', modules : ['Core', 'Gui', 'Qml', 'Quick'],
|
||||
required: qt6_option)
|
||||
method: qt6_method, required: qt6_option)
|
||||
if not qt6qml_dep.found()
|
||||
subdir_done()
|
||||
endif
|
||||
|
||||
have_qt6d3d11 = true
|
||||
moc_files = qt6_mod.preprocess(moc_headers : moc_headers)
|
||||
moc_files = qt6_mod.preprocess(moc_headers : moc_headers, method: qt6_method)
|
||||
gstqt6d3d11 = library('gstqt6d3d11', gstqt6d3d11_sources, moc_files,
|
||||
c_args : gst_plugins_bad_args + ['-DGST_USE_UNSTABLE_API'],
|
||||
cpp_args : gst_plugins_bad_args + ['-DGST_USE_UNSTABLE_API'],
|
||||
|
@ -159,7 +159,6 @@ option('opensles', type : 'feature', value : 'auto', description : 'OpenSL ES au
|
||||
option('opus', type : 'feature', value : 'auto', description : 'OPUS audio parser plugin')
|
||||
option('qroverlay', type : 'feature', value : 'auto', description : 'Element to set random data on a qroverlay')
|
||||
option('qsv', type : 'feature', value : 'auto', description : 'Intel Quick Sync Video plugin')
|
||||
option('qt6d3d11', type : 'feature', value : 'auto', description : 'Qt6 Direct3D11 plugin')
|
||||
option('resindvd', type : 'feature', value : 'auto', description : 'Resin DVD playback plugin (GPL - only built if gpl option is also enabled!)')
|
||||
option('rsvg', type : 'feature', value : 'auto', description : 'SVG overlayer and image decoder plugin')
|
||||
option('rtmp', type : 'feature', value : 'auto', description : 'RTMP video network source and sink plugin')
|
||||
@ -266,6 +265,11 @@ option('nvds-lib-path', type: 'string', value : '',
|
||||
option('mfx-modules-dir', type: 'string', value : '',
|
||||
description : 'libmfx runtime module dir, linux only')
|
||||
|
||||
# Qt6 plugin options
|
||||
option('qt6d3d11', type : 'feature', value : 'auto', description : 'Qt6 Direct3D11 plugin')
|
||||
option('qt-method', type: 'combo', value: 'auto', choices: ['auto', 'pkg-config', 'qmake'],
|
||||
description: 'Method to use to find Qt')
|
||||
|
||||
# Vulkan integration library and plugin options
|
||||
option('vulkan', type: 'feature', value: 'auto', description: 'Vulkan integration library and video sink plugin')
|
||||
option('vulkan-video', type: 'feature', value: 'auto', description: 'Whether to use Vulkan Video Extensions for encoding/decoding')
|
||||
|
@ -2,9 +2,8 @@ if not have_qt6d3d11
|
||||
subdir_done()
|
||||
endif
|
||||
|
||||
qt6_example_deps = dependency('qt6',
|
||||
modules : ['Core', 'Gui', 'Widgets', 'Qml', 'Quick'],
|
||||
required: get_option('examples'))
|
||||
qt6_example_deps = dependency('qt6', modules : ['Core', 'Gui', 'Widgets', 'Qml', 'Quick'],
|
||||
method: qt6_method, required: get_option('examples'))
|
||||
|
||||
if not qt6_example_deps.found()
|
||||
subdir_done()
|
||||
|
Loading…
x
Reference in New Issue
Block a user