mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-22 00:06:36 +00:00
va: Fix and simplify build recipe.
1. Use api_version variable rather than static string. 2. Remove pkgconfig generation since currently the library is not installed, only used internally. 3. Rely on dependency "required" to abort compilation. Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/1650>
This commit is contained in:
parent
5e4c152de4
commit
4455d908eb
1 changed files with 2 additions and 13 deletions
|
@ -23,18 +23,14 @@ if va_option.disabled() or host_system != 'linux'
|
|||
endif
|
||||
|
||||
libva_req = ['>= 1.6']
|
||||
|
||||
libva_dep = dependency('libva', version: libva_req, required: va_option)
|
||||
libva_drm_dep = dependency('libva-drm', version: libva_req, required: va_option)
|
||||
libdrm_dep = dependency('libdrm', required: false, fallback: ['libdrm', 'ext_libdrm'])
|
||||
|
||||
if not (libva_dep.found() and libva_drm_dep.found())
|
||||
if va_option.enabled()
|
||||
error('The va lib was enabled explicity, but required dependencies were not found.')
|
||||
endif
|
||||
subdir_done()
|
||||
endif
|
||||
|
||||
libdrm_dep = dependency('libdrm', required: false, fallback: ['libdrm', 'ext_libdrm'])
|
||||
cdata.set10('HAVE_LIBDRM', libdrm_dep.found())
|
||||
|
||||
gstva = library('gstva-' + api_version,
|
||||
|
@ -47,15 +43,8 @@ gstva = library('gstva-' + api_version,
|
|||
dependencies : [gst_dep, libva_dep, libva_drm_dep, libdrm_dep],
|
||||
)
|
||||
|
||||
pkg_name = 'gstreamer-va-1.0'
|
||||
pkg_name = 'gstreamer-va-' + api_version
|
||||
libraries += [[pkg_name, {'lib': gstva}]]
|
||||
pkgconfig.generate(gstva,
|
||||
libraries : gst_dep,
|
||||
variables : pkgconfig_variables,
|
||||
subdirs : pkgconfig_subdirs,
|
||||
name : pkg_name,
|
||||
description : 'GStreamer VA support',
|
||||
)
|
||||
|
||||
gstva_dep = declare_dependency(link_with : gstva,
|
||||
include_directories : [libsinc],
|
||||
|
|
Loading…
Reference in a new issue