git: f2611f144b25 - main - games/wesnoth: fix build following addition of unreachable(3)
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Wed, 10 Dec 2025 14:56:45 UTC
The branch main has been updated by fuz:
URL: https://cgit.FreeBSD.org/ports/commit/?id=f2611f144b2515efc3e372385a6439fad0271908
commit f2611f144b2515efc3e372385a6439fad0271908
Author: Robert Clausecker <fuz@FreeBSD.org>
AuthorDate: 2025-12-01 17:21:07 +0000
Commit: Robert Clausecker <fuz@FreeBSD.org>
CommitDate: 2025-12-10 14:56:17 +0000
games/wesnoth: fix build following addition of unreachable(3)
This avoids a name collision between the C23 unreachable() macro from
<stddef.h> and a local variable, fixing the build on FreeBSD 16-CURRENT.
Reported by: fluffy
Approved by: portmgr (build fix blanket)
MFH: 2025Q4
---
games/wesnoth/files/patch-src_game__display.cpp | 14 ++++++++++++++
1 file changed, 14 insertions(+)
diff --git a/games/wesnoth/files/patch-src_game__display.cpp b/games/wesnoth/files/patch-src_game__display.cpp
new file mode 100644
index 000000000000..999f3d7e969d
--- /dev/null
+++ b/games/wesnoth/files/patch-src_game__display.cpp
@@ -0,0 +1,14 @@
+--- src/game_display.cpp.orig 2025-12-01 17:11:07 UTC
++++ src/game_display.cpp
+@@ -278,9 +278,9 @@ void game_display::draw_hex(const map_location& loc)
+ // Draw reach_map information.
+ // We remove the reachability mask of the unit that we want to attack.
+ if(!is_shrouded && !reach_map_.empty() && reach_map_.find(loc) == reach_map_.end() && loc != attack_indicator_dst_) {
+- static const image::locator unreachable(game_config::images::unreachable);
++ static const image::locator unreachable_image(game_config::images::unreachable);
+ drawing_buffer_add(LAYER_REACHMAP, loc,
+- [tex = image::get_texture(unreachable, image::HEXED)](const rect& dest) { draw::blit(tex, dest); });
++ [tex = image::get_texture(unreachable_image, image::HEXED)](const rect& dest) { draw::blit(tex, dest); });
+ }
+
+ if(std::shared_ptr<wb::manager> w = wb_.lock()) {