diff options
Diffstat (limited to 'meson.build')
-rw-r--r-- | meson.build | 38 |
1 files changed, 38 insertions, 0 deletions
diff --git a/meson.build b/meson.build new file mode 100644 index 0000000..7b33b3a --- /dev/null +++ b/meson.build @@ -0,0 +1,38 @@ +project('fakeimp', 'c', + version : '0.1', + default_options : ['warning_level=3', 'c_std=c2x']) + +sources = [ + 'fakeimp.c' +] + +wl_protocols = dependency('wayland-protocols').get_variable('pkgdatadir') +wl_scanner = find_program(dependency('wayland-scanner').get_variable('wayland_scanner')) + +protos = { + 'ext-action-binder': wl_protocols / 'staging/ext-action-binder/ext-action-binder-v1.xml' +} + +foreach name, path : protos + sources += custom_target( + name.underscorify() + '_c', + input: path, + output: '@BASENAME@-protocol.c', + command: [wl_scanner, 'private-code', '@INPUT@', '@OUTPUT@'] + ) + sources += custom_target( + name.underscorify() + '_h', + input: path, + output: '@BASENAME@-protocol.h', + command: [wl_scanner, 'client-header', '@INPUT@', '@OUTPUT@'] + ) +endforeach + +exe = executable('fakeimp', sources, + dependencies: [ + dependency('wayland-client'), + dependency('xcb'), + dependency('xcb-keysyms'), + dependency('xcb-xtest') + ], + install : true) |