From 2b8f9401ee105c21a86e3a0f15dd0d1659ea259d Mon Sep 17 00:00:00 2001 From: Simon Ser Date: Sun, 7 Jul 2024 18:21:30 +0200 Subject: [PATCH 1/7] scanner: extract validator function emission to helper function This function will grow in the next commit. Signed-off-by: Simon Ser (cherry picked from commit caaa308c0d4025928917115c98c75edf7c796cd4) --- src/scanner.c | 59 ++++++++++++++++++++++++++++----------------------- 1 file changed, 33 insertions(+), 26 deletions(-) diff --git a/src/scanner.c b/src/scanner.c index 95524513..a4f3cc96 100644 --- a/src/scanner.c +++ b/src/scanner.c @@ -1378,6 +1378,37 @@ emit_event_wrappers(struct wl_list *message_list, struct interface *interface) } } +static void +emit_validator(struct interface *interface, struct enumeration *e) +{ + struct entry *entry; + + printf("/**\n" + " * @ingroup iface_%s\n" + " * Validate a %s %s value.\n" + " *\n" + " * @return true on success, false on error.\n" + " * @ref %s_%s\n" + " */\n" + "static inline bool\n" + "%s_%s_is_valid(uint32_t value, uint32_t version) {\n" + " switch (value) {\n", + interface->name, interface->name, e->name, + interface->name, e->name, + interface->name, e->name); + wl_list_for_each(entry, &e->entry_list, link) { + printf(" case %s%s_%s_%s:\n" + " return version >= %d;\n", + entry->value[0] == '-' ? "(uint32_t)" : "", + interface->uppercase_name, e->uppercase_name, + entry->uppercase_name, entry->since); + } + printf(" default:\n" + " return false;\n" + " }\n" + "}\n"); +} + static void emit_enumerations(struct interface *interface, bool with_validators) { @@ -1439,32 +1470,8 @@ emit_enumerations(struct interface *interface, bool with_validators) } - if (with_validators) { - printf("/**\n" - " * @ingroup iface_%s\n" - " * Validate a %s %s value.\n" - " *\n" - " * @return true on success, false on error.\n" - " * @ref %s_%s\n" - " */\n" - "static inline bool\n" - "%s_%s_is_valid(uint32_t value, uint32_t version) {\n" - " switch (value) {\n", - interface->name, interface->name, e->name, - interface->name, e->name, - interface->name, e->name); - wl_list_for_each(entry, &e->entry_list, link) { - printf(" case %s%s_%s_%s:\n" - " return version >= %d;\n", - entry->value[0] == '-' ? "(uint32_t)" : "", - interface->uppercase_name, e->uppercase_name, - entry->uppercase_name, entry->since); - } - printf(" default:\n" - " return false;\n" - " }\n" - "}\n"); - } + if (with_validators) + emit_validator(interface, e); printf("#endif /* %s_%s_ENUM */\n\n", interface->uppercase_name, e->uppercase_name); From f72f2aec55705faceaa6e1a40ad13d0f0b037cd2 Mon Sep 17 00:00:00 2001 From: Simon Ser Date: Sun, 7 Jul 2024 18:39:51 +0200 Subject: [PATCH 2/7] scanner: fix validator for bitfields Bitfields are valid if the value only contains bits inside of the supported entries for the given version. Signed-off-by: Simon Ser (cherry picked from commit c669d992599d74af2762fbf71a4336af2e311c45) --- src/scanner.c | 37 +++++++++---- tests/data/example-server.h | 106 ++++++++++++++++-------------------- 2 files changed, 73 insertions(+), 70 deletions(-) diff --git a/src/scanner.c b/src/scanner.c index a4f3cc96..3cd05d13 100644 --- a/src/scanner.c +++ b/src/scanner.c @@ -1391,22 +1391,35 @@ emit_validator(struct interface *interface, struct enumeration *e) " * @ref %s_%s\n" " */\n" "static inline bool\n" - "%s_%s_is_valid(uint32_t value, uint32_t version) {\n" - " switch (value) {\n", + "%s_%s_is_valid(uint32_t value, uint32_t version) {\n", interface->name, interface->name, e->name, interface->name, e->name, interface->name, e->name); - wl_list_for_each(entry, &e->entry_list, link) { - printf(" case %s%s_%s_%s:\n" - " return version >= %d;\n", - entry->value[0] == '-' ? "(uint32_t)" : "", - interface->uppercase_name, e->uppercase_name, - entry->uppercase_name, entry->since); + + if (e->bitfield) { + printf(" uint32_t valid = 0;\n"); + wl_list_for_each(entry, &e->entry_list, link) { + printf(" if (version >= %d)\n" + " valid |= %s_%s_%s;\n", + entry->since, + interface->uppercase_name, e->uppercase_name, + entry->uppercase_name); + } + printf(" return (value & ~valid) == 0;\n"); + } else { + printf(" switch (value) {\n"); + wl_list_for_each(entry, &e->entry_list, link) { + printf(" case %s%s_%s_%s:\n" + " return version >= %d;\n", + entry->value[0] == '-' ? "(uint32_t)" : "", + interface->uppercase_name, e->uppercase_name, + entry->uppercase_name, entry->since); + } + printf(" default:\n" + " return false;\n" + " }\n"); } - printf(" default:\n" - " return false;\n" - " }\n" - "}\n"); + printf("}\n"); } static void diff --git a/tests/data/example-server.h b/tests/data/example-server.h index b0d9226d..2fad7097 100644 --- a/tests/data/example-server.h +++ b/tests/data/example-server.h @@ -2396,18 +2396,16 @@ enum wl_data_device_manager_dnd_action { */ static inline bool wl_data_device_manager_dnd_action_is_valid(uint32_t value, uint32_t version) { - switch (value) { - case WL_DATA_DEVICE_MANAGER_DND_ACTION_NONE: - return version >= 1; - case WL_DATA_DEVICE_MANAGER_DND_ACTION_COPY: - return version >= 1; - case WL_DATA_DEVICE_MANAGER_DND_ACTION_MOVE: - return version >= 1; - case WL_DATA_DEVICE_MANAGER_DND_ACTION_ASK: - return version >= 1; - default: - return false; - } + uint32_t valid = 0; + if (version >= 1) + valid |= WL_DATA_DEVICE_MANAGER_DND_ACTION_NONE; + if (version >= 1) + valid |= WL_DATA_DEVICE_MANAGER_DND_ACTION_COPY; + if (version >= 1) + valid |= WL_DATA_DEVICE_MANAGER_DND_ACTION_MOVE; + if (version >= 1) + valid |= WL_DATA_DEVICE_MANAGER_DND_ACTION_ASK; + return (value & ~valid) == 0; } #endif /* WL_DATA_DEVICE_MANAGER_DND_ACTION_ENUM */ @@ -2560,28 +2558,26 @@ enum wl_shell_surface_resize { */ static inline bool wl_shell_surface_resize_is_valid(uint32_t value, uint32_t version) { - switch (value) { - case WL_SHELL_SURFACE_RESIZE_NONE: - return version >= 1; - case WL_SHELL_SURFACE_RESIZE_TOP: - return version >= 1; - case WL_SHELL_SURFACE_RESIZE_BOTTOM: - return version >= 1; - case WL_SHELL_SURFACE_RESIZE_LEFT: - return version >= 1; - case WL_SHELL_SURFACE_RESIZE_TOP_LEFT: - return version >= 1; - case WL_SHELL_SURFACE_RESIZE_BOTTOM_LEFT: - return version >= 1; - case WL_SHELL_SURFACE_RESIZE_RIGHT: - return version >= 1; - case WL_SHELL_SURFACE_RESIZE_TOP_RIGHT: - return version >= 1; - case WL_SHELL_SURFACE_RESIZE_BOTTOM_RIGHT: - return version >= 1; - default: - return false; - } + uint32_t valid = 0; + if (version >= 1) + valid |= WL_SHELL_SURFACE_RESIZE_NONE; + if (version >= 1) + valid |= WL_SHELL_SURFACE_RESIZE_TOP; + if (version >= 1) + valid |= WL_SHELL_SURFACE_RESIZE_BOTTOM; + if (version >= 1) + valid |= WL_SHELL_SURFACE_RESIZE_LEFT; + if (version >= 1) + valid |= WL_SHELL_SURFACE_RESIZE_TOP_LEFT; + if (version >= 1) + valid |= WL_SHELL_SURFACE_RESIZE_BOTTOM_LEFT; + if (version >= 1) + valid |= WL_SHELL_SURFACE_RESIZE_RIGHT; + if (version >= 1) + valid |= WL_SHELL_SURFACE_RESIZE_TOP_RIGHT; + if (version >= 1) + valid |= WL_SHELL_SURFACE_RESIZE_BOTTOM_RIGHT; + return (value & ~valid) == 0; } #endif /* WL_SHELL_SURFACE_RESIZE_ENUM */ @@ -2609,12 +2605,10 @@ enum wl_shell_surface_transient { */ static inline bool wl_shell_surface_transient_is_valid(uint32_t value, uint32_t version) { - switch (value) { - case WL_SHELL_SURFACE_TRANSIENT_INACTIVE: - return version >= 1; - default: - return false; - } + uint32_t valid = 0; + if (version >= 1) + valid |= WL_SHELL_SURFACE_TRANSIENT_INACTIVE; + return (value & ~valid) == 0; } #endif /* WL_SHELL_SURFACE_TRANSIENT_ENUM */ @@ -3486,16 +3480,14 @@ enum wl_seat_capability { */ static inline bool wl_seat_capability_is_valid(uint32_t value, uint32_t version) { - switch (value) { - case WL_SEAT_CAPABILITY_POINTER: - return version >= 1; - case WL_SEAT_CAPABILITY_KEYBOARD: - return version >= 1; - case WL_SEAT_CAPABILITY_TOUCH: - return version >= 1; - default: - return false; - } + uint32_t valid = 0; + if (version >= 1) + valid |= WL_SEAT_CAPABILITY_POINTER; + if (version >= 1) + valid |= WL_SEAT_CAPABILITY_KEYBOARD; + if (version >= 1) + valid |= WL_SEAT_CAPABILITY_TOUCH; + return (value & ~valid) == 0; } #endif /* WL_SEAT_CAPABILITY_ENUM */ @@ -4567,14 +4559,12 @@ enum wl_output_mode { */ static inline bool wl_output_mode_is_valid(uint32_t value, uint32_t version) { - switch (value) { - case WL_OUTPUT_MODE_CURRENT: - return version >= 1; - case WL_OUTPUT_MODE_PREFERRED: - return version >= 1; - default: - return false; - } + uint32_t valid = 0; + if (version >= 1) + valid |= WL_OUTPUT_MODE_CURRENT; + if (version >= 1) + valid |= WL_OUTPUT_MODE_PREFERRED; + return (value & ~valid) == 0; } #endif /* WL_OUTPUT_MODE_ENUM */ From 619d99cbba9dbe0a9e9c7bee2d870085416c866a Mon Sep 17 00:00:00 2001 From: Simon Ser Date: Sun, 7 Jul 2024 18:48:44 +0200 Subject: [PATCH 3/7] tests: add enum bitfield test Signed-off-by: Simon Ser (cherry picked from commit fa1811ce3e1475a95aa39e00cfa083797661d651) --- tests/data/small-client-core.h | 23 +++++++++++++++++++ tests/data/small-client.h | 23 +++++++++++++++++++ tests/data/small-server-core.h | 41 ++++++++++++++++++++++++++++++++++ tests/data/small-server.h | 41 ++++++++++++++++++++++++++++++++++ tests/data/small.xml | 7 ++++++ tests/enum-validator-test.c | 15 +++++++++++++ 6 files changed, 150 insertions(+) diff --git a/tests/data/small-client-core.h b/tests/data/small-client-core.h index 0e722441..03f889c8 100644 --- a/tests/data/small-client-core.h +++ b/tests/data/small-client-core.h @@ -106,6 +106,29 @@ enum intf_A_foo { #define INTF_A_FOO_DEPRECATED_SINCE_VERSION 2 #endif /* INTF_A_FOO_ENUM */ +#ifndef INTF_A_BAR_ENUM +#define INTF_A_BAR_ENUM +enum intf_A_bar { + /** + * this is the first + */ + INTF_A_BAR_FIRST = 0x01, + /** + * this is the second + */ + INTF_A_BAR_SECOND = 0x02, + /** + * this is the third + * @since 2 + */ + INTF_A_BAR_THIRD = 0x04, +}; +/** + * @ingroup iface_intf_A + */ +#define INTF_A_BAR_THIRD_SINCE_VERSION 2 +#endif /* INTF_A_BAR_ENUM */ + /** * @ingroup iface_intf_A * @struct intf_A_listener diff --git a/tests/data/small-client.h b/tests/data/small-client.h index ad435923..0d5b6055 100644 --- a/tests/data/small-client.h +++ b/tests/data/small-client.h @@ -106,6 +106,29 @@ enum intf_A_foo { #define INTF_A_FOO_DEPRECATED_SINCE_VERSION 2 #endif /* INTF_A_FOO_ENUM */ +#ifndef INTF_A_BAR_ENUM +#define INTF_A_BAR_ENUM +enum intf_A_bar { + /** + * this is the first + */ + INTF_A_BAR_FIRST = 0x01, + /** + * this is the second + */ + INTF_A_BAR_SECOND = 0x02, + /** + * this is the third + * @since 2 + */ + INTF_A_BAR_THIRD = 0x04, +}; +/** + * @ingroup iface_intf_A + */ +#define INTF_A_BAR_THIRD_SINCE_VERSION 2 +#endif /* INTF_A_BAR_ENUM */ + /** * @ingroup iface_intf_A * @struct intf_A_listener diff --git a/tests/data/small-server-core.h b/tests/data/small-server-core.h index e696cde7..d4476959 100644 --- a/tests/data/small-server-core.h +++ b/tests/data/small-server-core.h @@ -133,6 +133,47 @@ intf_A_foo_is_valid(uint32_t value, uint32_t version) { } #endif /* INTF_A_FOO_ENUM */ +#ifndef INTF_A_BAR_ENUM +#define INTF_A_BAR_ENUM +enum intf_A_bar { + /** + * this is the first + */ + INTF_A_BAR_FIRST = 0x01, + /** + * this is the second + */ + INTF_A_BAR_SECOND = 0x02, + /** + * this is the third + * @since 2 + */ + INTF_A_BAR_THIRD = 0x04, +}; +/** + * @ingroup iface_intf_A + */ +#define INTF_A_BAR_THIRD_SINCE_VERSION 2 +/** + * @ingroup iface_intf_A + * Validate a intf_A bar value. + * + * @return true on success, false on error. + * @ref intf_A_bar + */ +static inline bool +intf_A_bar_is_valid(uint32_t value, uint32_t version) { + uint32_t valid = 0; + if (version >= 1) + valid |= INTF_A_BAR_FIRST; + if (version >= 1) + valid |= INTF_A_BAR_SECOND; + if (version >= 2) + valid |= INTF_A_BAR_THIRD; + return (value & ~valid) == 0; +} +#endif /* INTF_A_BAR_ENUM */ + /** * @ingroup iface_intf_A * @struct intf_A_interface diff --git a/tests/data/small-server.h b/tests/data/small-server.h index 009d9cdd..9cafcd93 100644 --- a/tests/data/small-server.h +++ b/tests/data/small-server.h @@ -133,6 +133,47 @@ intf_A_foo_is_valid(uint32_t value, uint32_t version) { } #endif /* INTF_A_FOO_ENUM */ +#ifndef INTF_A_BAR_ENUM +#define INTF_A_BAR_ENUM +enum intf_A_bar { + /** + * this is the first + */ + INTF_A_BAR_FIRST = 0x01, + /** + * this is the second + */ + INTF_A_BAR_SECOND = 0x02, + /** + * this is the third + * @since 2 + */ + INTF_A_BAR_THIRD = 0x04, +}; +/** + * @ingroup iface_intf_A + */ +#define INTF_A_BAR_THIRD_SINCE_VERSION 2 +/** + * @ingroup iface_intf_A + * Validate a intf_A bar value. + * + * @return true on success, false on error. + * @ref intf_A_bar + */ +static inline bool +intf_A_bar_is_valid(uint32_t value, uint32_t version) { + uint32_t valid = 0; + if (version >= 1) + valid |= INTF_A_BAR_FIRST; + if (version >= 1) + valid |= INTF_A_BAR_SECOND; + if (version >= 2) + valid |= INTF_A_BAR_THIRD; + return (value & ~valid) == 0; +} +#endif /* INTF_A_BAR_ENUM */ + /** * @ingroup iface_intf_A * @struct intf_A_interface diff --git a/tests/data/small.xml b/tests/data/small.xml index ac527795..ab297490 100644 --- a/tests/data/small.xml +++ b/tests/data/small.xml @@ -58,5 +58,12 @@ + + + + + + + diff --git a/tests/enum-validator-test.c b/tests/enum-validator-test.c index 92037cff..8fb05b43 100644 --- a/tests/enum-validator-test.c +++ b/tests/enum-validator-test.c @@ -10,4 +10,19 @@ main(int argc, char *argv[]) { assert(intf_A_foo_is_valid(INTF_A_FOO_THIRD, 2)); assert(intf_A_foo_is_valid(INTF_A_FOO_NEGATIVE, 2)); + + assert(intf_A_bar_is_valid(INTF_A_BAR_FIRST, 1)); + assert(intf_A_bar_is_valid(INTF_A_BAR_FIRST, 2)); + assert(intf_A_bar_is_valid(INTF_A_BAR_SECOND, 1)); + assert(intf_A_bar_is_valid(INTF_A_BAR_SECOND, 2)); + assert(intf_A_bar_is_valid(INTF_A_BAR_FIRST | INTF_A_BAR_SECOND, 1)); + assert(intf_A_bar_is_valid(INTF_A_BAR_FIRST | INTF_A_BAR_SECOND, 2)); + + assert(!intf_A_bar_is_valid(INTF_A_BAR_THIRD, 1)); + assert(!intf_A_bar_is_valid(INTF_A_BAR_FIRST | INTF_A_BAR_THIRD, 1)); + assert(intf_A_bar_is_valid(INTF_A_BAR_THIRD, 2)); + assert(intf_A_bar_is_valid(INTF_A_BAR_FIRST | INTF_A_BAR_THIRD, 2)); + + assert(!intf_A_bar_is_valid(0xFF, 1)); + assert(!intf_A_bar_is_valid(0xFF, 2)); } From c5c418de035913dc34f4842f7ba822b9ed165109 Mon Sep 17 00:00:00 2001 From: Sebastian Wick Date: Fri, 26 Jul 2024 16:35:15 +0200 Subject: [PATCH 4/7] client: Handle proxies with no queue wl_proxy_get_queue can return NULL if the queue of the proxy was already destroyed with wl_event_queue_destroy. In this case, the queue also has no name anymore. Fixes: b42218f ("client: Allow setting names for queues") Signed-off-by: Sebastian Wick (cherry picked from commit f6f0a3cdec1c23c0adfe1deb9c53e8fdbb998ea4) --- src/wayland-client.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/wayland-client.c b/src/wayland-client.c index 9cf27939..ef305c32 100644 --- a/src/wayland-client.c +++ b/src/wayland-client.c @@ -921,10 +921,14 @@ wl_proxy_marshal_array_flags(struct wl_proxy *proxy, uint32_t opcode, if (debug_client) { struct wl_event_queue *queue; + const char *queue_name = NULL; queue = wl_proxy_get_queue(proxy); + if (queue) + queue_name = wl_event_queue_get_name(queue); + wl_closure_print(closure, &proxy->object, true, false, NULL, - wl_event_queue_get_name(queue)); + queue_name); } if (wl_closure_send(closure, proxy->display->connection)) { From 7e2ec4606e6e67a19ef79125422ede72ebfa1bbf Mon Sep 17 00:00:00 2001 From: Kirill Primak Date: Sat, 29 Jun 2024 15:05:00 +0300 Subject: [PATCH 5/7] Put WL_DEPRECATED in front of the function declarations This fixes the following clang error when using C23: ../src/wayland-server-core.h:680:41: error: 'deprecated' attribute cannot be applied to types 680 | int32_t stride, uint32_t format) WL_DEPRECATED; | ^ ../src/wayland-util.h:52:25: note: expanded from macro 'WL_DEPRECATED' 52 | #define WL_DEPRECATED [[deprecated]] | ^ Signed-off-by: Kirill Primak (cherry picked from commit a6a4e081da12140ffe1881d83be0981966ba6daf) --- src/wayland-server-core.h | 3 ++- src/wayland-server.c | 15 ++++++++++----- src/wayland-server.h | 15 ++++++++++----- 3 files changed, 22 insertions(+), 11 deletions(-) diff --git a/src/wayland-server-core.h b/src/wayland-server-core.h index 63d0f02d..fb900a91 100644 --- a/src/wayland-server-core.h +++ b/src/wayland-server-core.h @@ -674,10 +674,11 @@ wl_display_init_shm(struct wl_display *display); uint32_t * wl_display_add_shm_format(struct wl_display *display, uint32_t format); +WL_DEPRECATED struct wl_shm_buffer * wl_shm_buffer_create(struct wl_client *client, uint32_t id, int32_t width, int32_t height, - int32_t stride, uint32_t format) WL_DEPRECATED; + int32_t stride, uint32_t format); void wl_log_set_handler_server(wl_log_func_t handler); diff --git a/src/wayland-server.c b/src/wayland-server.c index 2e185634..0ba1bcc0 100644 --- a/src/wayland-server.c +++ b/src/wayland-server.c @@ -2483,9 +2483,10 @@ wl_priv_signal_final_emit(struct wl_priv_signal *signal, void *data) /** \cond */ /* Deprecated functions below. */ +WL_DEPRECATED uint32_t wl_client_add_resource(struct wl_client *client, - struct wl_resource *resource) WL_DEPRECATED; + struct wl_resource *resource); WL_EXPORT uint32_t wl_client_add_resource(struct wl_client *client, @@ -2514,11 +2515,12 @@ wl_client_add_resource(struct wl_client *client, return resource->object.id; } +WL_DEPRECATED struct wl_resource * wl_client_add_object(struct wl_client *client, const struct wl_interface *interface, const void *implementation, - uint32_t id, void *data) WL_DEPRECATED; + uint32_t id, void *data); WL_EXPORT struct wl_resource * wl_client_add_object(struct wl_client *client, @@ -2537,10 +2539,11 @@ wl_client_add_object(struct wl_client *client, return resource; } +WL_DEPRECATED struct wl_resource * wl_client_new_object(struct wl_client *client, const struct wl_interface *interface, - const void *implementation, void *data) WL_DEPRECATED; + const void *implementation, void *data); WL_EXPORT struct wl_resource * wl_client_new_object(struct wl_client *client, @@ -2599,10 +2602,11 @@ wl_client_get_user_data(struct wl_client *client) return client->data; } +WL_DEPRECATED struct wl_global * wl_display_add_global(struct wl_display *display, const struct wl_interface *interface, - void *data, wl_global_bind_func_t bind) WL_DEPRECATED; + void *data, wl_global_bind_func_t bind); WL_EXPORT struct wl_global * wl_display_add_global(struct wl_display *display, @@ -2612,9 +2616,10 @@ wl_display_add_global(struct wl_display *display, return wl_global_create(display, interface, interface->version, data, bind); } +WL_DEPRECATED void wl_display_remove_global(struct wl_display *display, - struct wl_global *global) WL_DEPRECATED; + struct wl_global *global); WL_EXPORT void wl_display_remove_global(struct wl_display *display, struct wl_global *global) diff --git a/src/wayland-server.h b/src/wayland-server.h index 1be565f2..48fab1dd 100644 --- a/src/wayland-server.h +++ b/src/wayland-server.h @@ -70,30 +70,35 @@ struct wl_resource { void *data; }; +WL_DEPRECATED uint32_t wl_client_add_resource(struct wl_client *client, - struct wl_resource *resource) WL_DEPRECATED; + struct wl_resource *resource); +WL_DEPRECATED struct wl_resource * wl_client_add_object(struct wl_client *client, const struct wl_interface *interface, const void *implementation, - uint32_t id, void *data) WL_DEPRECATED; + uint32_t id, void *data); +WL_DEPRECATED struct wl_resource * wl_client_new_object(struct wl_client *client, const struct wl_interface *interface, - const void *implementation, void *data) WL_DEPRECATED; + const void *implementation, void *data); +WL_DEPRECATED struct wl_global * wl_display_add_global(struct wl_display *display, const struct wl_interface *interface, void *data, - wl_global_bind_func_t bind) WL_DEPRECATED; + wl_global_bind_func_t bind); +WL_DEPRECATED void wl_display_remove_global(struct wl_display *display, - struct wl_global *global) WL_DEPRECATED; + struct wl_global *global); #endif From cc34a7a4f1d720498ef2b3b62a113d818d4141a7 Mon Sep 17 00:00:00 2001 From: Joaquim Monteiro Date: Fri, 31 May 2024 02:57:29 +0100 Subject: [PATCH 6/7] meson: Fix use of install_data() without specifying install_dir This was broken (when in a subproject) before Meson 1.3.0, and so Meson warns against this unless the project targets 1.3.0 or newer. Signed-off-by: Joaquim Monteiro (cherry picked from commit 0239b082b9d312275ce1112b61d795072596ce2d) --- meson.build | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/meson.build b/meson.build index 8e28f2a2..f7ef7483 100644 --- a/meson.build +++ b/meson.build @@ -131,7 +131,9 @@ if get_option('scanner') 'wayland-scanner.mk', 'protocol/wayland.xml', 'protocol/wayland.dtd', - ]) + ], + install_dir: join_paths(get_option('prefix'), get_option('datadir'), 'wayland'), + ) install_data( [ 'wayland-scanner.m4' ], From a9fec8dd65977c57f4039ced34327204d9b9d779 Mon Sep 17 00:00:00 2001 From: Simon Ser Date: Sat, 24 Aug 2024 17:43:55 +0200 Subject: [PATCH 7/7] build: bump version to 1.23.1 for the bugfix release Signed-off-by: Simon Ser --- meson.build | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/meson.build b/meson.build index f7ef7483..a5ef524b 100644 --- a/meson.build +++ b/meson.build @@ -1,6 +1,6 @@ project( 'wayland', 'c', - version: '1.23.0', + version: '1.23.1', license: 'MIT', meson_version: '>= 0.57.0', default_options: [