diff options
author | Dylan Baker <[email protected]> | 2019-09-26 15:19:54 -0700 |
---|---|---|
committer | Dylan Baker <[email protected]> | 2019-09-30 09:09:52 -0700 |
commit | daeb959c91320052bfccb5e8d6869b6dd740d1d5 (patch) | |
tree | 196c0dd2e7c2b123bdb3f3d1ca9166873141aad2 /src/gallium/state_trackers | |
parent | db1ed17ac46bc721e89990cd015fc3bcde956de2 (diff) |
meson: Try finding libxvmcw via pkg-config before using find_library
This fixes cross compiling issues, because pkg-config is less likely to
get the wrong libs.
v2: - Fix typo in comment
Fixes: 22a817af8a89eb3c762fc3e07b443a3ce37d7416
("meson: build gallium xvmc state tracker")
Closes: https://gitlab.freedesktop.org/mesa/mesa/issues/939
Reviewed-by: Adam Jackson <[email protected]>
(cherry picked from commit 8c5c21d7e337bbaffe8d68d9abbb166a271b35cc)
Diffstat (limited to 'src/gallium/state_trackers')
-rw-r--r-- | src/gallium/state_trackers/xvmc/meson.build | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/src/gallium/state_trackers/xvmc/meson.build b/src/gallium/state_trackers/xvmc/meson.build index d120d533eef..f66b4f2a337 100644 --- a/src/gallium/state_trackers/xvmc/meson.build +++ b/src/gallium/state_trackers/xvmc/meson.build @@ -26,10 +26,15 @@ libxvmc_st = static_library( dependencies : [dep_xvmc, dep_x11_xcb, dep_xcb, dep_xcb_dri2, dep_xcb_dri3], ) -# These tests will not work without a working xvmc configuration. +# These tests will not work without a working xvmc configuration. if with_tools.contains('xvmc') - dep_xvmcw = cc.find_library('XvMCW') + # pkg-config was added in 1.0.12, so allow fallback + dep_xvmcw = dependency('xvmc-wrapper', required : false) + if not dep_xvmcw.found() + dep_xvmcw = cc.find_library('XvMCW') + endif dep_real_xvmc = dependency('xvmc') + foreach x : ['context', 'surface', 'subpicture', 'blocks', 'rendering'] _name = 'xvmc_@0@'.format(x) executable( |