From cebb83d01c879ad60cef07273f4e167da25507c4 Mon Sep 17 00:00:00 2001 From: sthen Date: Wed, 9 May 2018 20:26:08 +0000 Subject: [PATCH] static_cast fix build on ILP32 arches with clang 6, from Thomas Frohwein (maintainer) --- games/godot/patches/patch-drivers_unix_os_unix_cpp | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/games/godot/patches/patch-drivers_unix_os_unix_cpp b/games/godot/patches/patch-drivers_unix_os_unix_cpp index f00f8a7162e..cf00faa9a25 100644 --- a/games/godot/patches/patch-drivers_unix_os_unix_cpp +++ b/games/godot/patches/patch-drivers_unix_os_unix_cpp @@ -1,10 +1,20 @@ -$OpenBSD: patch-drivers_unix_os_unix_cpp,v 1.1.1.1 2018/04/27 07:32:53 bentley Exp $ +$OpenBSD: patch-drivers_unix_os_unix_cpp,v 1.2 2018/05/09 20:26:08 sthen Exp $ -hardcode executablepath +- fix with clang6 on ILP32 arches +- hardcode executable path Index: drivers/unix/os_unix.cpp --- drivers/unix/os_unix.cpp.orig +++ drivers/unix/os_unix.cpp +@@ -235,7 +235,7 @@ OS::TimeZoneInfo OS_Unix::get_time_zone_info() const { + + void OS_Unix::delay_usec(uint32_t p_usec) const { + +- struct timespec rem = { p_usec / 1000000, (p_usec % 1000000) * 1000 }; ++ struct timespec rem = { p_usec / 1000000, static_cast((p_usec % 1000000) * 1000) }; + while (nanosleep(&rem, &rem) == EINTR) { + } + } @@ -456,7 +456,7 @@ String OS_Unix::get_executable_path() const { #elif defined(__OpenBSD__) char resolved_path[MAXPATHLEN];