pdb, po-tips: fix meson warnings.

Meson is apparently able to show different warning depending on the
meson version tests we do in specific code paths.

Since our global required meson is 0.53.0 but on some code paths, we
test for 0.57.0, we must use meson.source_root() on older meson and
meson.project_source_root() on newer one.

Fixes:

> pdb/meson.build:141: WARNING: Project targets '>=0.57.0' but uses feature deprecated since '0.56.0': meson.source_root. use meson.project_source_root() or meson.global_source_root() instead.
> pdb/meson.build:141: WARNING: Project targets '>=0.57.0' but uses feature deprecated since '0.56.0': meson.build_root. use meson.project_build_root() or meson.global_build_root() instead.
> po-tips/meson.build:5: WARNING: Project targets '>=0.53.0' but uses feature introduced in '0.56.0': meson.project_source_root.
This commit is contained in:
Jehan 2022-07-31 17:40:39 +02:00
parent 47ba11056f
commit c857fc58a6
2 changed files with 2 additions and 2 deletions

View File

@ -138,7 +138,7 @@ if meson.version().version_compare('>=0.57.0')
output: [ 'stamp-pdbgen.h', ], output: [ 'stamp-pdbgen.h', ],
env: perl_env, env: perl_env,
command: [ command: [
pdbgen_run, perl, meson.source_root(), meson.build_root() pdbgen_run, perl, meson.project_source_root(), meson.project_build_root()
], ],
) )

View File

@ -2,5 +2,5 @@ potips_dir = meson.current_source_dir()
i18n.gettext(gettext_package + '-tips', i18n.gettext(gettext_package + '-tips',
preset: 'glib', preset: 'glib',
install: false, install: false,
data_dirs: meson.project_source_root() / 'data' / 'tips', data_dirs: meson.source_root() / 'data' / 'tips',
) )