gstreamer/subprojects/gst-plugins-bad/gst-libs/gst/dxva/meson.build
Mathieu Duponchelle 7983ecff1c docs: generate hotdoc configs for libraries with our helper script
With this patch, configure time is identical no matter whether doc is
enabled or not.

The configuration files also now contain explicitly-listed sources with
no wildcards.

For the four libraries where hotdoc needs to use clang to generate the
documentation (as opposed to the rest of the libraries where hotdoc uses
the gir), the script will call pkg-config to determine the appropriate
C flags.

This means a side effect of this patch is that pkg-config files are now
generated for the gstadaptivedemux and gstopencv libraries.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8312>
2025-01-17 20:36:06 +01:00

85 lines
2.1 KiB
Meson

dxva_sources = files(
'gstdxvaav1decoder.cpp',
'gstdxvah264decoder.cpp',
'gstdxvah265decoder.cpp',
'gstdxvampeg2decoder.cpp',
'gstdxvautils.cpp',
'gstdxvavp8decoder.cpp',
'gstdxvavp9decoder.cpp',
)
dxva_headers = files(
'gstdxvaav1decoder.h',
'gstdxvah264decoder.h',
'gstdxvah265decoder.h',
'gstdxvampeg2decoder.h',
'gstdxvatypes.h',
'gstdxvautils.h',
'gstdxvavp8decoder.h',
'gstdxvavp9decoder.h',
)
extra_args = [
'-DGST_USE_UNSTABLE_API',
'-DBUILDING_GST_DXVA',
'-DG_LOG_DOMAIN="GStreamer-Dxva"',
]
doc_sources = []
foreach s: dxva_sources + dxva_headers
doc_sources += s.full_path()
endforeach
libs_sources += {
'dxva': pathsep.join(doc_sources)
}
if host_system != 'windows' and not build_gir
subdir_done()
endif
pkg_name = 'gstreamer-dxva-' + api_version
gstdxva = library('gstdxva-' + api_version,
dxva_sources,
c_args : gst_plugins_bad_args + extra_args,
cpp_args : gst_plugins_bad_args + extra_args,
include_directories : [configinc, libsinc],
version : libversion,
soversion : soversion,
install : true,
dependencies : [gstvideo_dep, gstcodecs_dep],
override_options: ['cpp_std=c++11'],
)
library_def = {'lib': gstdxva}
gen_sources = []
if build_gir
gir = {
'sources' : dxva_sources + dxva_headers,
'namespace' : 'GstDxva',
'nsversion' : api_version,
'identifier_prefix' : 'Gst',
'symbol_prefix' : 'gst',
'export_packages' : pkg_name,
'includes' : ['Gst-1.0', 'GstVideo-1.0', 'GstCodecs-1.0'],
'install' : true,
'extra_args' : gir_init_section + ['-DGST_USE_UNSTABLE_API'],
'dependencies' : [gstvideo_dep, gstcodecs_dep]
}
library_def += {'gir': [gir]}
if not static_build
dxva_gir = gnome.generate_gir(gstdxva, kwargs: gir)
library_def += {'gir_targets': library_def.get('gir_targets', []) + [dxva_gir]}
gen_sources += dxva_gir
endif
endif
gst_libraries += [[pkg_name, library_def]]
# Still non-public api, should not install headers
gstdxva_dep = declare_dependency(link_with : gstdxva,
include_directories : [libsinc],
sources: gen_sources,
dependencies : [gstvideo_dep, gstcodecs_dep])
meson.override_dependency(pkg_name, gstdxva_dep)