From e656b9c819b073a9af501619cf512f63aa16e8ec Mon Sep 17 00:00:00 2001 From: Iñigo Martínez Date: Thu, 12 Apr 2018 08:08:39 +0200 Subject: gdbus_codegen: Fix custom target name The namebase which is used as the target name, also holds part of the file names. This used in combination generates files with wrong names. --- mesonbuild/modules/gnome.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/mesonbuild/modules/gnome.py b/mesonbuild/modules/gnome.py index b4af8d850..43a9d1ce0 100644 --- a/mesonbuild/modules/gnome.py +++ b/mesonbuild/modules/gnome.py @@ -873,9 +873,10 @@ This will become a hard error in the future.''') def gdbus_codegen(self, state, args, kwargs): if len(args) != 2: raise MesonException('Gdbus_codegen takes two arguments, name and xml file.') - namebase = args[0] + '-gdbus' + namebase = args[0] xml_file = args[1] - cmd = [find_program('gdbus-codegen', namebase)] + target_name = namebase + '-gdbus' + cmd = [find_program('gdbus-codegen', target_name)] if 'interface_prefix' in kwargs: cmd += ['--interface-prefix', kwargs.pop('interface_prefix')] if 'namespace' in kwargs: @@ -954,7 +955,7 @@ This will become a hard error in the future.''') 'command': cmd, 'build_by_default': build_by_default } - ct = build.CustomTarget(namebase, state.subdir, state.subproject, custom_kwargs) + ct = build.CustomTarget(target_name, state.subdir, state.subproject, custom_kwargs) # Ensure that the same number (and order) of arguments are returned # regardless of the gdbus-codegen (glib) version being used targets = [ct, ct] -- cgit v1.2.3