[cheese/wip/davidk/meson-tweaks: 2/2] Avoid get_pkgconfig_variable()




commit 3b5eadacbe4bf21f380bf9d53ecae46224f83de0
Author: David King <amigadave amigadave com>
Date:   Tue May 31 14:52:46 2022 +0100

    Avoid get_pkgconfig_variable()
    
    Use the simpler get_variable() and depend meson 0.58 or greater.

 docs/reference/meson.build |  4 ++--
 meson.build                | 12 ++++++------
 2 files changed, 8 insertions(+), 8 deletions(-)
---
diff --git a/docs/reference/meson.build b/docs/reference/meson.build
index 5df94fec..ec863d63 100644
--- a/docs/reference/meson.build
+++ b/docs/reference/meson.build
@@ -8,8 +8,8 @@ if enable_gtk_doc
     'um-crop-area.h',
   ]
 
-  glib_prefix = glib_dep.get_pkgconfig_variable('prefix')
-  gtk_prefix = gtk_dep.get_pkgconfig_variable('prefix')
+  glib_prefix = glib_dep.get_variable('prefix')
+  gtk_prefix = gtk_dep.get_variable('prefix')
 
   fixxref_args = [
     '--html-dir=' + (cheese_prefix / gnome.gtkdoc_html_dir(cheese_name)),
diff --git a/meson.build b/meson.build
index f35fa9f2..6a758219 100644
--- a/meson.build
+++ b/meson.build
@@ -3,7 +3,7 @@ project(
   version: '41.0',
   license: 'GPL2',
   default_options: 'buildtype=debugoptimized',
-  meson_version: '>= 0.50.0',
+  meson_version: '>= 0.58.0',
 )
 
 cheese_name = meson.project_name()
@@ -130,15 +130,15 @@ if cc.has_header('X11/extensions/XTest.h', dependencies: x11_dep)
   have_xtest = xtst_dep.found() and cc.has_function('XTestFakeKeyEvent', dependencies: xtst_dep)
 endif
 
-dbus_session_bus_services_dir = dependency('dbus-1').get_pkgconfig_variable(
+dbus_session_bus_services_dir = dependency('dbus-1').get_variable(
   'session_bus_services_dir',
-  define_variable: ['datadir', cheese_prefix / cheese_datadir],
+  pkgconfig_define: ['datadir', cheese_prefix / cheese_datadir],
 )
 
-gio_schemasdir = gio_dep.get_pkgconfig_variable(
+gio_schemasdir = gio_dep.get_variable(
   'schemasdir',
-  define_variable: ['datadir', cheese_prefix / cheese_datadir],
-  default: cheese_prefix / cheese_datadir / 'glib-2.0/schemas',
+  pkgconfig_define: ['datadir', cheese_prefix / cheese_datadir],
+  default_value: cheese_prefix / cheese_datadir / 'glib-2.0/schemas',
 )
 
 gnome_video_effects_dep = dependency(


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]