meson: replace libmesa_util with idep_mesautil
[mesa.git] / src / gallium / targets / vdpau / meson.build
index 67f1469fb0f6347c90baefc1df65aff2bd9f1ed4..3f001aaa5d05531c8d0f2091186b05b5ba2a8c3b 100644 (file)
@@ -1,4 +1,4 @@
-# Copyright © 2017 Intel Corporation
+# Copyright © 2017-2018 Intel Corporation
 
 # Permission is hereby granted, free of charge, to any person obtaining a copy
 # of this software and associated documentation files (the "Software"), to deal
@@ -35,35 +35,43 @@ if with_ld_dynamic_list
   vdpau_link_depends += files('../dri-vdpau.dyn')
 endif
 
+
 libvdpau_gallium = shared_library(
   'vdpau_gallium',
-  'target.c',
+  ['target.c', xmlpool_options_h],
   c_args : c_vis_args,
   cpp_args : cpp_vis_args,
   link_args : [vdpau_link_args, ld_args_gc_sections],
   include_directories : [
     inc_common, inc_util, inc_gallium_winsys, inc_gallium_drivers,
   ],
+  link_whole : [libvdpau_st],
   link_with : [
-    libvdpau_st, libgalliumvlwinsys, libgalliumvl, libgallium, libmesa_util,
-    libpipe_loader_static, libws_null, libwsw,
+    libgalliumvlwinsys, libgalliumvl, libgallium,
+    libpipe_loader_static, libws_null, libwsw, libswdri, libswkmsdri,
   ],
   dependencies : [
-    dep_thread, dep_xcb, dep_x11_xcb, dep_xcb_dri2, dep_libdrm,
+    dep_thread, idep_mesautil,
     driver_r300, driver_r600, driver_radeonsi, driver_nouveau,
   ],
   link_depends : vdpau_link_depends,
+  soversion : '@0@.@1@.0'.format(VDPAU_MAJOR, VDPAU_MINOR),
+  # Will be deleted during installation, see install_megadrivers.py
+  install : true,
+  install_dir : vdpau_drivers_path,
+  name_suffix : 'so',
 )
 foreach d : [[with_gallium_r300, 'r300'],
              [with_gallium_r600, 'r600'],
              [with_gallium_radeonsi, 'radeonsi'],
              [with_gallium_nouveau, 'nouveau']]
   if d[0]
-    vdpau_drivers += 'libvdpau_@0@.so.1.0.0'.format(d[1])
+    vdpau_drivers += 'libvdpau_@0@.so.@1@.@2@.0'.format(d[1], VDPAU_MAJOR, VDPAU_MINOR)
   endif
 endforeach
 
 meson.add_install_script(
+  prog_python.path(),
   join_paths(meson.source_root(), 'bin/install_megadrivers.py'),
   libvdpau_gallium.full_path(),
   vdpau_drivers_path,