diff options
author | Dylan Baker <dylan@pnwbakers.com> | 2018-06-21 08:35:03 -0700 |
---|---|---|
committer | Dylan Baker <dylan@pnwbakers.com> | 2018-06-25 08:40:18 -0700 |
commit | 6a1ef7ccb85fad3a2fdbf4c947d214d7d6ac0bae (patch) | |
tree | 53438774d8ca766a39fa9d850f083b0e886222fc | |
parent | b5f154a86055a3e804aef81a5c26bd7b2f7eb5d6 (diff) |
meson: Fix auto option for va
The same as the previous two patches, but for the libva state tracker.
Fixes: 724916c8a84b5bba8f880f17da936585d52c97b6
("meson: dedup gallium-xvmc logic")
Signed-off-by: Dylan Baker <dylan.c.baker@intel.com>
Reviewed-by: Eric Engestrom <eric.engestrom@intel.com>
(cherry picked from commit 94cf3970925ec87d913a1549a42cdb03713fc4bb)
-rw-r--r-- | meson.build | 15 |
1 files changed, 9 insertions, 6 deletions
diff --git a/meson.build b/meson.build index 1fd4b02456..fc01056369 100644 --- a/meson.build +++ b/meson.build @@ -581,13 +581,16 @@ elif not (with_gallium_r600 or with_gallium_radeonsi or with_gallium_nouveau) elif _va == 'auto' _va = 'true' endif -with_gallium_va = _va == 'true' +with_gallium_va = false dep_va = null_dep -if with_gallium_va - dep_va = dependency('libva', version : '>= 0.39.0') - dep_va_headers = declare_dependency( - compile_args : run_command(prog_pkgconfig, ['libva', '--cflags']).stdout().split() - ) +if _va != 'false' + dep_va = dependency('libva', version : '>= 0.38.0', required : _va == 'true') + if dep_va.found() + dep_va_headers = declare_dependency( + compile_args : run_command(prog_pkgconfig, ['libva', '--cflags']).stdout().split() + ) + with_gallium_va = true + endif endif va_drivers_path = get_option('va-libs-path') |