diff options
author | Jussi Pakkanen <jpakkane@gmail.com> | 2018-10-28 18:56:54 +0200 |
---|---|---|
committer | Jussi Pakkanen <jpakkane@gmail.com> | 2018-10-28 18:56:54 +0200 |
commit | 78c32e29b340c9ce47f5ac27e0ac108d2e518b7c (patch) | |
tree | ae24231d217521ae28baf988b38df31b1c56bbe4 | |
parent | 807981889f0cbecf165d0dc8bfb1e980adac58d8 (diff) | |
download | meson-fixmergefile.tar.gz |
Fix merge file using an array. Closes #4424.fixmergefile
-rw-r--r-- | mesonbuild/modules/i18n.py | 4 | ||||
-rw-r--r-- | test cases/frameworks/6 gettext/data/meson.build | 2 |
2 files changed, 5 insertions, 1 deletions
diff --git a/mesonbuild/modules/i18n.py b/mesonbuild/modules/i18n.py index cde548fd2..aeab8132d 100644 --- a/mesonbuild/modules/i18n.py +++ b/mesonbuild/modules/i18n.py @@ -85,6 +85,10 @@ class I18nModule(ExtensionModule): if hasattr(inputfile, 'held_object'): ct = build.CustomTarget(kwargs['output'] + '_merge', state.subdir, state.subproject, kwargs) else: + if isinstance(inputfile, list): + # We only use this input file to create a name of the custom target. + # Thus we can ignore the other entries. + inputfile = inputfile[0] if isinstance(inputfile, str): inputfile = mesonlib.File.from_source_file(state.environment.source_dir, state.subdir, inputfile) diff --git a/test cases/frameworks/6 gettext/data/meson.build b/test cases/frameworks/6 gettext/data/meson.build index 0a7811bda..d78c19e6a 100644 --- a/test cases/frameworks/6 gettext/data/meson.build +++ b/test cases/frameworks/6 gettext/data/meson.build @@ -10,7 +10,7 @@ i18n.merge_file( # Use filename substitution for another file i18n.merge_file( - input: 'test2.desktop.in', + input: files('test2.desktop.in'), output: '@BASENAME@', type: 'desktop', po_dir: '../po', |