modules/gnome: add export_packages kwarg to g-ir-scanner

Signed-off-by: Igor Gnatenko <i.gnatenko.brain@gmail.com>
pull/77/head
Igor Gnatenko 10 years ago
parent 2db5f97402
commit d121b7cd55
  1. 8
      modules/gnome.py
  2. 1
      test cases/frameworks/7 gnome/gir/meson.build

@ -81,6 +81,14 @@ class GnomeModule:
if not isinstance(identifier_prefix, str):
raise MesonException('Gir identifier prefix must be str')
scan_command += ['--identifier-prefix=%s' % identifier_prefix]
if kwargs.get('export_packages'):
pkgs = kwargs.pop('export_packages')
if isinstance(pkgs, str):
scan_command += ['--pkg-export=%s' % pkgs]
elif isinstance(pkgs, list):
scan_command += ['--pkg-export=%s' % pkg for pkg in pkgs]
else:
raise MesonException('Gir export packages must be str or list')
if isinstance(girtarget, build.Executable):
scan_command += ['--program', girtarget]
elif isinstance(girtarget, build.SharedLibrary):

@ -9,6 +9,7 @@ sources : libsources,
nsversion : '1.0',
namespace : 'Meson',
symbol_prefix : 'meson_',
identifier_prefix : 'Meson',
includes : ['GObject-2.0', 'Gio-2.0'],
install : true
)

Loading…
Cancel
Save