meson.build: fix pkgconfig deprecation warning
authorPeter Hutterer <peter.hutterer@who-t.net>
Wed, 22 Jul 2020 23:22:51 +0000 (09:22 +1000)
committerRan Benita <ran@unusedvar.com>
Thu, 23 Jul 2020 06:28:23 +0000 (09:28 +0300)
../meson.build:239: DEPRECATION: Library xkbcommon was passed to the "libraries"
keyword argument of a previous call to generate() method instead of first
positional argument. Adding xkbcommon to "Requires" field, but this is a
deprecated behaviour that will change in a future version of Meson. Please
report the issue if this warning cannot be avoided in your case.

This was introduced in meson 0.49.0

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
meson.build

index bd42210..7f566e8 100644 (file)
@@ -7,7 +7,7 @@ project(
         'warning_level=2',
         'b_lundef=true',
     ],
-    meson_version : '>= 0.41.0',
+    meson_version : '>= 0.49.0',
 )
 pkgconfig = import('pkgconfig')
 cc = meson.get_compiler('c')
@@ -237,9 +237,9 @@ install_headers(
     subdir: 'xkbcommon',
 )
 pkgconfig.generate(
+    libxkbcommon,
     name: 'xkbcommon',
     filebase: 'xkbcommon',
-    libraries: libxkbcommon,
     version: meson.project_version(),
     description: 'XKB API common to servers and clients',
 )
@@ -290,9 +290,9 @@ You can disable X11 support with -Denable-x11=false.''')
         subdir: 'xkbcommon',
     )
     pkgconfig.generate(
+        libxkbcommon_x11,
         name: 'xkbcommon-x11',
         filebase: 'xkbcommon-x11',
-        libraries: libxkbcommon_x11,
         version: meson.project_version(),
         description: 'XKB API common to servers and clients - X11 support',
         requires: ['xkbcommon'],
@@ -331,9 +331,9 @@ if get_option('enable-xkbregistry')
         subdir: 'xkbcommon',
     )
     pkgconfig.generate(
+        libxkbregistry,
         name: 'xkbregistry',
         filebase: 'xkbregistry',
-        libraries: libxkbregistry,
         version: meson.project_version(),
         description: 'XKB API to query available rules, models, layouts, variants and options',
     )