diff options
| author | voidanix <voidanix@keyedlimepie.org> | 2025-03-28 00:33:57 +0100 |
|---|---|---|
| committer | Briar <205427297+icybriarr@users.noreply.github.com> | 2025-04-01 18:31:44 +0200 |
| commit | d60cf76e2db0a7f6201c3160b946dadc15329004 (patch) | |
| tree | c772d009b5d519e61e7feb0c1a263246620ff82f | |
| parent | 127fdbc93e20d24cf367010f455e8c70f4b4ff7e (diff) | |
Fix GCC builds with Debug build type
| -rw-r--r-- | src/common/CMakeLists.txt | 9 | ||||
| -rw-r--r-- | src/video_core/CMakeLists.txt | 5 |
2 files changed, 14 insertions, 0 deletions
diff --git a/src/common/CMakeLists.txt b/src/common/CMakeLists.txt index 779be211e6..eb9be6d6a6 100644 --- a/src/common/CMakeLists.txt +++ b/src/common/CMakeLists.txt @@ -241,6 +241,15 @@ if (MSVC) ) else() set_source_files_properties(stb.cpp PROPERTIES COMPILE_OPTIONS "-Wno-implicit-fallthrough;-Wno-missing-declarations;-Wno-missing-field-initializers") + + # Get around GCC failing with intrinsics in Debug + if (CMAKE_CXX_COMPILER_ID STREQUAL "GNU" AND CMAKE_BUILD_TYPE MATCHES "Debug") + set_property( + SOURCE stb.cpp + APPEND + PROPERTY COMPILE_OPTIONS ";-O2" + ) + endif() endif() if (CMAKE_CXX_COMPILER_ID STREQUAL "Clang") diff --git a/src/video_core/CMakeLists.txt b/src/video_core/CMakeLists.txt index 2de2beb6ed..5b3e9c301f 100644 --- a/src/video_core/CMakeLists.txt +++ b/src/video_core/CMakeLists.txt @@ -366,6 +366,11 @@ else() # VMA set_source_files_properties(vulkan_common/vma.cpp PROPERTIES COMPILE_OPTIONS "-Wno-conversion;-Wno-unused-variable;-Wno-unused-parameter;-Wno-missing-field-initializers") + + # Get around GCC failing with intrinsics in Debug + if (CMAKE_CXX_COMPILER_ID STREQUAL "GNU" AND CMAKE_BUILD_TYPE MATCHES "Debug") + set_source_files_properties(host1x/vic.cpp PROPERTIES COMPILE_OPTIONS "-O2") + endif() endif() if (ARCHITECTURE_x86_64) |
