From 1cbb266180d66d0db3ab2f2ac5e38621b15751c4 Mon Sep 17 00:00:00 2001
From: Craftyawesome <craftyawesome.ak@gmail.com>
Date: Fri, 14 Feb 2025 20:02:12 -0500
Subject: [PATCH] explicit -mno-ms-bitfields for clang

---
 src/CMakeLists.txt | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
index 32ea71d1b..46ef372bd 100644
--- a/src/CMakeLists.txt
+++ b/src/CMakeLists.txt
@@ -408,7 +408,7 @@ endif()
 
 # Compatibility flag with later versions of GCC
 # We should really fix our code to not need this
-if ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "GNU")
+if ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "GNU" OR "${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang")
 	check_cxx_compiler_flag("-mno-ms-bitfields" HAS_NO_MS_BITFIELDS)
 	if(HAS_NO_MS_BITFIELDS)
 		target_compile_options(SRB2SDL2 PRIVATE -mno-ms-bitfields)
-- 
GitLab