[Mesa-dev] [PATCH v3 9/9] meson: fix xvmc target linkage

Dylan Baker dylan at pnwbakers.com
Fri Feb 2 19:30:45 UTC 2018


This needs to link the state tracker with --whole-archive to expose the
right symbols.

Fixes: 22a817af8a89eb3c7 ("meson: build gallium xvmc state tracker")
Signed-off-by: Dylan Baker <dylan.c.baker at intel.com>
---
 src/gallium/targets/xvmc/meson.build | 13 +++++++++++--
 1 file changed, 11 insertions(+), 2 deletions(-)

diff --git a/src/gallium/targets/xvmc/meson.build b/src/gallium/targets/xvmc/meson.build
index 07d6c72..4889942 100644
--- a/src/gallium/targets/xvmc/meson.build
+++ b/src/gallium/targets/xvmc/meson.build
@@ -24,6 +24,7 @@
 
 xvmc_link_args = []
 xvmc_link_depends = []
+xvmc_link_with = []
 xvmc_drivers = []
 
 if with_ld_version_script
@@ -31,6 +32,13 @@ if with_ld_version_script
   xvmc_link_depends += files('xvmc.sym')
 endif
 
+if with_dri
+  xvmc_link_with += libswdri
+endif
+if with_gallium_drisw_kms
+  xvmc_link_with += libswkmsdri
+endif
+
 libxvmc_gallium = shared_library(
   'XvMCgallium',
   'target.c',
@@ -40,9 +48,10 @@ libxvmc_gallium = shared_library(
   include_directories : [
     inc_common, inc_util, inc_gallium_winsys, inc_gallium_drivers,
   ],
+  link_whole : [libxvmc_st],
   link_with : [
-    libxvmc_st, libgalliumvlwinsys, libgalliumvl, libgallium, libmesa_util,
-    libpipe_loader_static, libws_null, libwsw,
+    libgalliumvlwinsys, libgalliumvl, libgallium, libmesa_util,
+    libpipe_loader_static, libws_null, libwsw, xvmc_link_with,
   ],
   dependencies : [dep_thread, driver_r600, driver_nouveau],
   link_depends : xvmc_link_depends,
-- 
git-series 0.9.1


More information about the mesa-dev mailing list