2019-12-10 23:37:43 +00:00
|
|
|
wayland_protocols_dir = wayland_protocols.get_pkgconfig_variable('pkgdatadir')
|
|
|
|
wayland_scanner_bin = wayland_scanner.get_pkgconfig_variable('wayland_scanner')
|
|
|
|
|
|
|
|
protocols_server = [
|
|
|
|
wayland_protocols_dir / 'stable/xdg-shell/xdg-shell.xml',
|
2020-01-03 18:40:11 +00:00
|
|
|
'kiwmi-ipc.xml',
|
2020-01-15 20:30:37 +00:00
|
|
|
'wlr-layer-shell-unstable-v1.xml',
|
2019-12-10 23:37:43 +00:00
|
|
|
]
|
|
|
|
|
|
|
|
protocols_server_src = []
|
|
|
|
protocols_server_inc = []
|
|
|
|
|
|
|
|
foreach protocol : protocols_server
|
|
|
|
protocols_server_src += custom_target(
|
|
|
|
protocol.underscorify() + '_server_c',
|
|
|
|
input: protocol,
|
2020-01-05 00:02:58 +00:00
|
|
|
output: '@BASENAME@-protocol.c',
|
2019-12-10 23:37:43 +00:00
|
|
|
command: [wayland_scanner_bin, 'private-code', '@INPUT@', '@OUTPUT@'],
|
|
|
|
)
|
|
|
|
|
|
|
|
protocols_server_inc += custom_target(
|
|
|
|
protocol.underscorify() + '_server_h',
|
|
|
|
input: protocol,
|
2020-01-05 00:02:58 +00:00
|
|
|
output: '@BASENAME@-protocol.h',
|
2019-12-10 23:37:43 +00:00
|
|
|
command: [wayland_scanner_bin, 'server-header', '@INPUT@', '@OUTPUT@'],
|
|
|
|
)
|
|
|
|
endforeach
|
|
|
|
|
|
|
|
protocols_server_lib = static_library(
|
|
|
|
'protocols_server',
|
|
|
|
[protocols_server_src, protocols_server_inc],
|
|
|
|
)
|
|
|
|
|
|
|
|
protocols_server = declare_dependency(
|
|
|
|
link_with: protocols_server_lib,
|
|
|
|
sources: protocols_server_inc,
|
|
|
|
)
|
2020-01-03 18:40:11 +00:00
|
|
|
|
|
|
|
protocols_client = [
|
|
|
|
'kiwmi-ipc.xml',
|
|
|
|
]
|
|
|
|
|
|
|
|
protocols_client_src = []
|
|
|
|
protocols_client_inc = []
|
|
|
|
|
|
|
|
foreach protocol : protocols_client
|
|
|
|
protocols_client_src += custom_target(
|
|
|
|
protocol.underscorify() + '_client_c',
|
|
|
|
input: protocol,
|
|
|
|
output: '@BASENAME@-client-protocol.c',
|
|
|
|
command: [wayland_scanner_bin, 'private-code', '@INPUT@', '@OUTPUT@'],
|
|
|
|
)
|
|
|
|
|
|
|
|
protocols_client_inc += custom_target(
|
|
|
|
protocol.underscorify() + '_client_h',
|
|
|
|
input: protocol,
|
|
|
|
output: '@BASENAME@-client-protocol.h',
|
|
|
|
command: [wayland_scanner_bin, 'client-header', '@INPUT@', '@OUTPUT@'],
|
|
|
|
)
|
|
|
|
endforeach
|
|
|
|
|
|
|
|
protocols_client_lib = static_library(
|
|
|
|
'protocols_client',
|
|
|
|
[protocols_client_src, protocols_client_inc],
|
|
|
|
)
|
|
|
|
|
|
|
|
protocols_client = declare_dependency(
|
|
|
|
link_with: protocols_client_lib,
|
|
|
|
sources: protocols_client_inc,
|
|
|
|
)
|