aboutsummaryrefslogtreecommitdiff
path: root/src/common/CMakeLists.txt
diff options
context:
space:
mode:
authoryuzubot <yuzu@yuzu-emu.org>2023-08-02 12:03:18 +0000
committeryuzubot <yuzu@yuzu-emu.org>2023-08-02 12:03:18 +0000
commit4caa6d86a92cd3c9acbc91144880a4ae2572549c (patch)
treef8f7cd5f91cc232fe486c3a22603b0f1f97b713f /src/common/CMakeLists.txt
parent36aca262e3dc1cac4ee7e1415ddde8e4255ea42b (diff)
"Merge Tagged PR 10839"mainline-0-1515
Diffstat (limited to 'src/common/CMakeLists.txt')
-rw-r--r--src/common/CMakeLists.txt15
1 files changed, 13 insertions, 2 deletions
diff --git a/src/common/CMakeLists.txt b/src/common/CMakeLists.txt
index 3adf13a3f4..bf97d9ba28 100644
--- a/src/common/CMakeLists.txt
+++ b/src/common/CMakeLists.txt
@@ -110,8 +110,12 @@ add_library(common STATIC
scratch_buffer.h
settings.cpp
settings.h
+ settings_common.cpp
+ settings_common.h
+ settings_enums.h
settings_input.cpp
settings_input.h
+ settings_setting.h
socket_types.h
spin_lock.cpp
spin_lock.h
@@ -193,9 +197,16 @@ if (MSVC)
/we4254 # 'operator': conversion from 'type1:field_bits' to 'type2:field_bits', possible loss of data
/we4800 # Implicit conversion from 'type' to bool. Possible information loss
)
-else()
+endif()
+
+if (CMAKE_CXX_COMPILER_ID STREQUAL "Clang")
target_compile_options(common PRIVATE
- $<$<CXX_COMPILER_ID:Clang>:-fsized-deallocation>
+ -fsized-deallocation
+ -Werror=unreachable-code-aggressive
+ )
+ target_compile_definitions(common PRIVATE
+ # Clang 14 and earlier have errors when explicitly instantiating Settings::Setting
+ $<$<VERSION_LESS:$<CXX_COMPILER_VERSION>,15>:CANNOT_EXPLICITLY_INSTANTIATE>
)
endif()