From 9f004d8b0fa37787fe96662cf5ff414e8d6ef5e4 Mon Sep 17 00:00:00 2001 From: "Marty E. Plummer" Date: Sat, 11 May 2019 09:53:01 -0500 Subject: scanner: prepend protocol name to types symbol When doing unity builds via meson (example project: https://github.com/swaywm/sway) multiple source files are glued together via #include directives. Having every wayland-scanner generated source file have an identifier named '*types[]' will lead to errors in these unity builds if two or more of these are joined. Signed-off-by: Marty E. Plummer --- tests/data/small-code-core.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'tests/data/small-code-core.c') diff --git a/tests/data/small-code-core.c b/tests/data/small-code-core.c index 28a00ab..bd6d33d 100644 --- a/tests/data/small-code-core.c +++ b/tests/data/small-code-core.c @@ -32,7 +32,7 @@ extern const struct wl_interface another_intf_interface; extern const struct wl_interface intf_not_here_interface; -static const struct wl_interface *types[] = { +static const struct wl_interface *small_test_types[] = { NULL, &intf_not_here_interface, NULL, @@ -44,13 +44,13 @@ static const struct wl_interface *types[] = { }; static const struct wl_message intf_A_requests[] = { - { "rq1", "sun", types + 0 }, - { "rq2", "nsiufho", types + 1 }, - { "destroy", "", types + 0 }, + { "rq1", "sun", small_test_types + 0 }, + { "rq2", "nsiufho", small_test_types + 1 }, + { "destroy", "", small_test_types + 0 }, }; static const struct wl_message intf_A_events[] = { - { "hey", "", types + 0 }, + { "hey", "", small_test_types + 0 }, }; WL_EXPORT const struct wl_interface intf_A_interface = { -- cgit v1.2.3-70-g09d2