aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLibravatar Simon Ser <contact@emersion.fr>2022-11-25 10:51:20 +0100
committerLibravatar Simon Ser <contact@emersion.fr>2022-11-26 10:29:58 +0100
commit52166bc1f530f477a6786707edf4b503e1a92cf5 (patch)
tree2737d2cce6fa10770cbc403c8e2cb78ef2599fb2
parentbuild: drop "server" from target name for protocol code (diff)
downloadsway-52166bc1f530f477a6786707edf4b503e1a92cf5.tar.gz
sway-52166bc1f530f477a6786707edf4b503e1a92cf5.tar.zst
sway-52166bc1f530f477a6786707edf4b503e1a92cf5.zip
build: drop intermediate libraries for protocols
(cherry picked from commit af8a5a8918ef42336194fb1077b008a736de7af9)
-rw-r--r--protocols/meson.build27
-rw-r--r--sway/meson.build3
-rw-r--r--swaybar/meson.build4
-rw-r--r--swaynag/meson.build2
4 files changed, 6 insertions, 30 deletions
diff --git a/protocols/meson.build b/protocols/meson.build
index 53441f38..904aead4 100644
--- a/protocols/meson.build
+++ b/protocols/meson.build
@@ -19,7 +19,6 @@ protocols = [
19] 19]
20 20
21wl_protos_src = [] 21wl_protos_src = []
22wl_protos_headers = []
23 22
24foreach xml : protocols 23foreach xml : protocols
25 wl_protos_src += custom_target( 24 wl_protos_src += custom_target(
@@ -28,38 +27,16 @@ foreach xml : protocols
28 output: '@BASENAME@-protocol.c', 27 output: '@BASENAME@-protocol.c',
29 command: [wayland_scanner, 'private-code', '@INPUT@', '@OUTPUT@'], 28 command: [wayland_scanner, 'private-code', '@INPUT@', '@OUTPUT@'],
30 ) 29 )
31 wl_protos_headers += custom_target( 30 wl_protos_src += custom_target(
32 xml.underscorify() + '_server_h', 31 xml.underscorify() + '_server_h',
33 input: xml, 32 input: xml,
34 output: '@BASENAME@-protocol.h', 33 output: '@BASENAME@-protocol.h',
35 command: [wayland_scanner, 'server-header', '@INPUT@', '@OUTPUT@'], 34 command: [wayland_scanner, 'server-header', '@INPUT@', '@OUTPUT@'],
36 ) 35 )
37 wl_protos_headers += custom_target( 36 wl_protos_src += custom_target(
38 xml.underscorify() + '_client_h', 37 xml.underscorify() + '_client_h',
39 input: xml, 38 input: xml,
40 output: '@BASENAME@-client-protocol.h', 39 output: '@BASENAME@-client-protocol.h',
41 command: [wayland_scanner, 'client-header', '@INPUT@', '@OUTPUT@'], 40 command: [wayland_scanner, 'client-header', '@INPUT@', '@OUTPUT@'],
42 ) 41 )
43endforeach 42endforeach
44
45lib_client_protos = static_library(
46 'client_protos',
47 wl_protos_src + wl_protos_headers,
48 dependencies: wayland_client.partial_dependency(compile_args: true),
49)
50
51client_protos = declare_dependency(
52 link_with: lib_client_protos,
53 sources: wl_protos_headers,
54)
55
56lib_server_protos = static_library(
57 'server_protos',
58 wl_protos_src + wl_protos_headers,
59 dependencies: wayland_server.partial_dependency(compile_args: true),
60)
61
62server_protos = declare_dependency(
63 link_with: lib_server_protos,
64 sources: wl_protos_headers,
65)
diff --git a/sway/meson.build b/sway/meson.build
index 4d7dccfa..bb6bf88c 100644
--- a/sway/meson.build
+++ b/sway/meson.build
@@ -222,7 +222,6 @@ sway_deps = [
222 pcre2, 222 pcre2,
223 glesv2, 223 glesv2,
224 pixman, 224 pixman,
225 server_protos,
226 threads, 225 threads,
227 wayland_server, 226 wayland_server,
228 wlroots, 227 wlroots,
@@ -237,7 +236,7 @@ endif
237 236
238executable( 237executable(
239 'sway', 238 'sway',
240 sway_sources, 239 sway_sources + wl_protos_src,
241 include_directories: [sway_inc], 240 include_directories: [sway_inc],
242 dependencies: sway_deps, 241 dependencies: sway_deps,
243 link_with: [lib_sway_common], 242 link_with: [lib_sway_common],
diff --git a/swaybar/meson.build b/swaybar/meson.build
index 9feb3cd2..e5f1811e 100644
--- a/swaybar/meson.build
+++ b/swaybar/meson.build
@@ -8,7 +8,6 @@ tray_files = have_tray ? [
8 8
9swaybar_deps = [ 9swaybar_deps = [
10 cairo, 10 cairo,
11 client_protos,
12 gdk_pixbuf, 11 gdk_pixbuf,
13 jsonc, 12 jsonc,
14 math, 13 math,
@@ -32,7 +31,8 @@ executable(
32 'main.c', 31 'main.c',
33 'render.c', 32 'render.c',
34 'status_line.c', 33 'status_line.c',
35 tray_files 34 tray_files,
35 wl_protos_src,
36 ], 36 ],
37 include_directories: [sway_inc], 37 include_directories: [sway_inc],
38 dependencies: swaybar_deps, 38 dependencies: swaybar_deps,
diff --git a/swaynag/meson.build b/swaynag/meson.build
index 71f2fc2d..f238bbb5 100644
--- a/swaynag/meson.build
+++ b/swaynag/meson.build
@@ -5,11 +5,11 @@ executable(
5 'render.c', 5 'render.c',
6 'swaynag.c', 6 'swaynag.c',
7 'types.c', 7 'types.c',
8 wl_protos_src,
8 ], 9 ],
9 include_directories: [sway_inc], 10 include_directories: [sway_inc],
10 dependencies: [ 11 dependencies: [
11 cairo, 12 cairo,
12 client_protos,
13 pango, 13 pango,
14 pangocairo, 14 pangocairo,
15 wayland_client, 15 wayland_client,