1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22
|
Description: Fix FTBFS (unit-tests) with GCC-11
Instead of fully disabling compiler optimizations, this patch only
disables the problematic optimization, so that if new compiler versions
introduce new incompatible optimizations it will be easy to spot them and
report them upstream.
Bug: https://github.com/g-truc/glm/pull/1087
Bug-Ubuntu: https://bugs.launchpad.net/ubuntu/+source/glm/+bug/1946750
Bug-Debian: https://bugs.debian.org/996241
Forwarded: https://github.com/g-truc/glm/pull/1087#issuecomment-942299144
Author: Andrea Pappacoda <andrea@pappacoda.it>
Last-Update: 2022-01-23
--- glm.orig/test/CMakeLists.txt
+++ glm/test/CMakeLists.txt
@@ -206,7 +206,7 @@ elseif(CMAKE_CXX_COMPILER_ID MATCHES "GN
message("GLM: GCC - ${CMAKE_CXX_COMPILER_ID} compiler")
endif()
- add_compile_options(-O2)
+ add_compile_options(-O2 -fno-ipa-modref)
add_compile_options(-Wno-long-long)
elseif(CMAKE_CXX_COMPILER_ID MATCHES "Intel")
|