aboutsummaryrefslogtreecommitdiff
path: root/src/CMakeLists.txt
diff options
context:
space:
mode:
authorLiam <byteslice@airmail.cc>2023-04-02 19:02:04 -0400
committerLiam <byteslice@airmail.cc>2023-04-02 19:02:04 -0400
commitbbc9f0d3e929cbadb1d4f07a73b97abd014ccb91 (patch)
treeb6513dfee3b8410ab61d5e9ea799e757f049a1de /src/CMakeLists.txt
parent6f649f250f52265f1153bb4e1f98352074ff0e78 (diff)
general: fixes for gcc 13
Diffstat (limited to 'src/CMakeLists.txt')
-rw-r--r--src/CMakeLists.txt11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
index 0eca8e90e7..312a49f42d 100644
--- a/src/CMakeLists.txt
+++ b/src/CMakeLists.txt
@@ -126,6 +126,17 @@ else()
add_compile_options("-stdlib=libc++")
endif()
+ # GCC bugs
+ if (CMAKE_CXX_COMPILER_VERSION VERSION_GREATER_EQUAL "12" AND CMAKE_CXX_COMPILER_ID STREQUAL "GNU")
+ # These diagnostics would be great if they worked, but are just completely broken
+ # and produce bogus errors on external libraries like fmt.
+ add_compile_options(
+ -Wno-array-bounds
+ -Wno-stringop-overread
+ -Wno-stringop-overflow
+ )
+ endif()
+
# Set file offset size to 64 bits.
#
# On modern Unixes, this is typically already the case. The lone exception is