diff options
author | Angelos Mouzakitis <a.mouzakitis@virtualopensystems.com> | 2023-10-10 14:33:42 +0000 |
---|---|---|
committer | Angelos Mouzakitis <a.mouzakitis@virtualopensystems.com> | 2023-10-10 14:33:42 +0000 |
commit | af1a266670d040d2f4083ff309d732d648afba2a (patch) | |
tree | 2fc46203448ddcc6f81546d379abfaeb323575e9 /meson/test cases/frameworks/7 gnome/gdbus/meson.build | |
parent | e02cda008591317b1625707ff8e115a4841aa889 (diff) |
Change-Id: Iaf8d18082d3991dec7c0ebbea540f092188eb4ec
Diffstat (limited to 'meson/test cases/frameworks/7 gnome/gdbus/meson.build')
-rw-r--r-- | meson/test cases/frameworks/7 gnome/gdbus/meson.build | 39 |
1 files changed, 39 insertions, 0 deletions
diff --git a/meson/test cases/frameworks/7 gnome/gdbus/meson.build b/meson/test cases/frameworks/7 gnome/gdbus/meson.build new file mode 100644 index 000000000..2de172fa5 --- /dev/null +++ b/meson/test cases/frameworks/7 gnome/gdbus/meson.build @@ -0,0 +1,39 @@ +gdbus_src = gnome.gdbus_codegen('generated-gdbus-no-docbook', + 'data/com.example.Sample.xml', + interface_prefix : 'com.example.', + namespace : 'Sample', + annotations : [ + ['com.example.Hello()', 'org.freedesktop.DBus.Deprecated', 'true'] + ], +) +assert(gdbus_src.length() == 2, 'expected 2 targets') +assert(gdbus_src[0].full_path().endswith('.c'), 'expected 1 c source file') +assert(gdbus_src[1].full_path().endswith('.h'), 'expected 1 c header file') + +gdbus_src = gnome.gdbus_codegen('generated-gdbus', + sources : files('data/com.example.Sample.xml'), + interface_prefix : 'com.example.', + namespace : 'Sample', + annotations : [ + ['com.example.Hello()', 'org.freedesktop.DBus.Deprecated', 'true'] + ], + docbook : 'generated-gdbus-doc', + install_header : true, + install_dir : get_option('includedir') +) +assert(gdbus_src.length() == 3, 'expected 3 targets') +assert(gdbus_src[0].full_path().endswith('.c'), 'expected 1 c source file') +assert(gdbus_src[1].full_path().endswith('.h'), 'expected 1 c header file') + +if not pretend_glib_old and glib.version().version_compare('>=2.51.3') + includes = [] +else + includes = include_directories('..') +endif + +gdbus_exe = executable('gdbus-test', 'gdbusprog.c', + gdbus_src, + include_directories : includes, + dependencies : giounix) + +test('gdbus', gdbus_exe) |