diff options
Diffstat (limited to 'protocol/meson.build')
-rw-r--r-- | protocol/meson.build | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/protocol/meson.build b/protocol/meson.build new file mode 100644 index 0000000..0a27675 --- /dev/null +++ b/protocol/meson.build @@ -0,0 +1,29 @@ +protocols_dir = wayland_protocols.get_variable(pkgconfig: 'pkgdatadir') + +wayland_scanner = dependency('wayland-scanner', native: true) +wayland_scanner_exe = find_program( + wayland_scanner.get_variable(pkgconfig: 'wayland_scanner'), + native: true, +) + +protocols = { + 'input-method-unstable-v2': 'input-method-unstable-v2.xml', +} + +foreach name, path : protocols + code = custom_target( + name.underscorify() + '_c', + input: path, + output: '@BASENAME@-protocol.c', + command: [wayland_scanner_exe, 'private-code', '@INPUT@', '@OUTPUT@'], + ) + wlhangul_files += code + + client_header = custom_target( + name.underscorify() + '_client_h', + input: path, + output: '@BASENAME@-client-protocol.h', + command: [wayland_scanner_exe, 'client-header', '@INPUT@', '@OUTPUT@'], + ) + wlhangul_files += client_header +endforeach |