mumble: Fix 32-bit build

32-bit builds fail due to the following error. Apply a patch from master
to fix the issue.

[ 25%] Building CXX object plugins/gtav/CMakeFiles/gtav.dir/gtav.cpp.o
In file included from /build/source/plugins/gtav/Game.h:9,
from /build/source/plugins/gtav/gtav.cpp:6:
/build/source/plugins/gtav/structs.h:218:37: error: static assertion failed
218 | static_assert(sizeof(CCameraAngles) == 0x408, "");
| ~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~
/build/source/plugins/gtav/structs.h:218:37: note: the comparison reduces to '(1028 == 1032)'

Signed-off-by: Felix Singer <felixsinger@posteo.net>

+32
+31
pkgs/applications/networking/mumble/0002-FIX-positional-audio-Force-8-bytes-alignment-for-CCa.patch
··· 1 + From 13c051b36b387356815cff5d685bc628b74ba136 Mon Sep 17 00:00:00 2001 2 + From: Davide Beatrici <git@davidebeatrici.dev> 3 + Date: Thu, 1 Sep 2022 23:32:57 +0200 4 + Subject: [PATCH] FIX(positional-audio): Force 8 bytes alignment for 5 + CCameraAngles in GTAV plugin 6 + 7 + https://en.cppreference.com/w/cpp/language/alignas 8 + 9 + This fixes compilation when the implicit alignment is not 8 bytes. 10 + 11 + It can be the case with 32 bit targets. 12 + --- 13 + plugins/gtav/structs.h | 2 +- 14 + 1 file changed, 1 insertion(+), 1 deletion(-) 15 + 16 + diff --git a/plugins/gtav/structs.h b/plugins/gtav/structs.h 17 + index 2829dc11e..0e4f76eda 100644 18 + --- a/plugins/gtav/structs.h 19 + +++ b/plugins/gtav/structs.h 20 + @@ -118,7 +118,7 @@ struct CCameraManagerAngles { 21 + ptr_t cameraAngles; // CCameraAngles * 22 + }; 23 + 24 + -struct CCameraAngles { 25 + +struct alignas(8) CCameraAngles { 26 + uint8_t pad1[960]; 27 + ptr_t playerAngles; // CPlayerAngles * 28 + uint8_t pad2[60]; 29 + -- 30 + 2.38.5 31 +
+1
pkgs/applications/networking/mumble/default.nix
··· 22 22 23 23 patches = [ 24 24 ./0001-BUILD-crypto-Migrate-to-OpenSSL-3.0-compatible-API.patch 25 + ./0002-FIX-positional-audio-Force-8-bytes-alignment-for-CCa.patch 25 26 ]; 26 27 27 28 nativeBuildInputs = [ cmake pkg-config python3 qt5.wrapQtAppsHook qt5.qttools ]