-
Notifications
You must be signed in to change notification settings - Fork 12
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
games-emulation/sudachi: fix building against Boost 1.86.0
Besides the concepts issue, the other issue is caused by boostorg/crc@470537f fixed by boostorg/crc#28 but not sure if it will be merged. Signed-off-by: Andrew Udvare <[email protected]>
- Loading branch information
Showing
3 changed files
with
37 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
34 changes: 34 additions & 0 deletions
34
games-emulation/sudachi/files/sudachi-0003-boost-fix.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
diff --git a/CMakeLists.txt b/CMakeLists.txt | ||
index a39d08d..14a7a50 100644 | ||
--- a/CMakeLists.txt | ||
+++ b/CMakeLists.txt | ||
@@ -274,8 +274,6 @@ endif() | ||
# Configure C++ standard | ||
# =========================== | ||
|
||
-# boost asio's concept usage doesn't play nicely with some compilers yet. | ||
-add_definitions(-DBOOST_ASIO_DISABLE_CONCEPTS) | ||
if (MSVC) | ||
add_compile_options($<$<COMPILE_LANGUAGE:CXX>:/std:c++20>) | ||
|
||
diff --git a/src/input_common/helpers/udp_protocol.h b/src/input_common/helpers/udp_protocol.h | ||
index 7bc5992..e64127e 100644 | ||
--- a/src/input_common/helpers/udp_protocol.h | ||
+++ b/src/input_common/helpers/udp_protocol.h | ||
@@ -13,6 +13,7 @@ | ||
#endif | ||
|
||
#include <boost/crc.hpp> | ||
+#include <boost/numeric/conversion/cast.hpp> | ||
|
||
#ifdef _MSC_VER | ||
#pragma warning(pop) | ||
@@ -69,7 +70,7 @@ Message<T> CreateMessage(const u32 magic, const T data, const u32 sender_id) { | ||
}; | ||
Message<T> message{header, data}; | ||
crc.process_bytes(&message, sizeof(Message<T>)); | ||
- message.header.crc = crc.checksum(); | ||
+ message.header.crc = boost::numeric_cast<u32_le>(crc.checksum()); | ||
return message; | ||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters