talkatu/talkatu

Add support for build a vapi module

2020-05-21, Gary Kramlich
50ce8af5399e
Parents 991c2ef6890c
Children d7efd293facd
Add support for build a vapi module
--- a/meson.build Mon May 11 16:24:10 2020 -0500
+++ b/meson.build Thu May 21 22:28:47 2020 -0500
@@ -104,6 +104,7 @@
subdir('po')
subdir('demo')
subdir('packaging')
+subdir('vapi')
###############################################################################
# Install stuff
--- a/meson_options.txt Mon May 11 16:24:10 2020 -0500
+++ b/meson_options.txt Thu May 21 22:28:47 2020 -0500
@@ -30,3 +30,10 @@
type : 'boolean', value : true,
description : 'run unit tests'
)
+
+option(
+ 'vapi',
+ type : 'boolean', value : true,
+ description : 'Whether or not to build vapi files for gplugin'
+)
+
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/vapi/meson.build Thu May 21 22:28:47 2020 -0500
@@ -0,0 +1,14 @@
+if get_option('vapi')
+ if not get_option('gobject-introspection')
+ error('Vala generation requires GObject Introspection.')
+ endif
+
+ add_languages('vala')
+
+ talkatuu_vapi = gnome.generate_vapi('talkatu',
+ sources : talkatu_gir[0],
+ packages : [ 'gtk+-3.0' ],
+ install : true,
+ gir_dirs : meson.current_build_dir() / '..' / 'talkatu',
+ )
+endif # vala