modules/gnome: gnome.compile_resources() must have 'install_dir' if installing

Since they do not implement a default install dir like BuildTargets do.

gnome.compile_resources() would result in an unhandled python exception
when missing install_dir argument together with providing following arguments:

  gresource_bundle: true
  install: true

closes: https://github.com/mesonbuild/meson/issues/13447

Signed-off-by: RaviRahar <ravirahar33@gmail.com>
pull/13454/head
RaviRahar 4 months ago committed by Dylan Baker
parent 7a306e1a46
commit 96f20d5b37
  1. 7
      mesonbuild/modules/gnome.py

@ -479,8 +479,11 @@ class GnomeModule(ExtensionModule):
else:
raise MesonException('Compiling GResources into code is only supported in C and C++ projects')
if kwargs['install'] and not gresource:
raise MesonException('The install kwarg only applies to gresource bundles, see install_header')
if kwargs['install']:
if not gresource:
raise MesonException('The install kwarg only applies to gresource bundles, see install_header')
elif not kwargs['install_dir']:
raise MesonException('gnome.compile_resources: "install_dir" keyword argument must be set when "install" is true.')
install_header = kwargs['install_header']
if install_header and gresource:

Loading…
Cancel
Save