1- From 7e5a75da29016e533d59971ba84931b33e072a81 Mon Sep 17 00:00:00 2001
1+ From 98c9e687ba0480cbec1df2b2a64817c0c08add7e Mon Sep 17 00:00:00 2001
22From: Andreas Sturmlechner <asturm@gentoo.org>
33Date: Tue, 3 Dec 2024 19:46:01 +0100
44Subject: [PATCH] Thanks, but no thanks
@@ -9,10 +9,19 @@ Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>
99 1 file changed, 4 insertions(+), 4 deletions(-)
1010
1111diff --git a/CMakeLists.txt b/CMakeLists.txt
12- index a3b591512..31071aeef 100644
12+ index 8e2153462..dd2d64788 100644
1313--- a/CMakeLists.txt
1414+++ b/CMakeLists.txt
15- @@ -364,7 +364,7 @@ if (ANDROID)
15+ @@ -363,7 +363,7 @@ if (UNIX)
16+ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fdata-sections -ffunction-sections")
17+ set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -Wl,--gc-sections")
18+ endif()
19+ - endif(UNIX)
20+ + endif()
21+
22+ # Optimize binary size by dropping unneeded symbols at linking stage
23+ if (ANDROID)
24+ @@ -372,7 +372,7 @@ if (ANDROID)
1625 endif ()
1726
1827 # Add security (hardening flags)
@@ -21,16 +30,7 @@ index a3b591512..31071aeef 100644
2130 SET(SEC_COMP_FLAGS "${SEC_COMP_FLAGS} -fstack-protector-all -Wcast-align -fPIE")
2231 # This is ill-defined, but I searched for a solution for quite a long time to no avail
2332 # - FORTIFY_SOURCE generates a warning when there is no code optimization, and warnings will become errors at some point
24- @@ -396,7 +396,7 @@ IF (UNIX OR APPLE OR ANDROID)
25- ENDIF ()
26-
27- # Clang Format support
28- - IF (UNIX OR APPLE)
29- + IF (0)
30- SET(FORMAT_CODE OFF CACHE BOOL "Enable Clang Format")
31- IF (FORMAT_CODE MATCHES ON)
32- FILE(GLOB_RECURSE ALL_SOURCE_FILES *.c *.cpp *.h)
33- @@ -417,7 +417,7 @@ ENDIF ()
33+ @@ -405,7 +405,7 @@ ENDIF ()
3434
3535 SET(FIX_WARNINGS OFF CACHE BOOL "Enable strict compilation mode to turn compiler warnings to errors")
3636 # Warning, debug and linker flags
@@ -39,7 +39,7 @@ index a3b591512..31071aeef 100644
3939 SET(COMP_FLAGS "")
4040 SET(LINKER_FLAGS "")
4141 # Verbose warnings and turns all to errors
42- @@ -481 ,7 +481 ,7 @@ ENDIF ()
42+ @@ -469 ,7 +469 ,7 @@ ENDIF ()
4343
4444 # Sanitizer support
4545 SET(SANITIZERS OFF CACHE BOOL "Sanitizer support for gcc and Clang")
@@ -49,5 +49,5 @@ index a3b591512..31071aeef 100644
4949 (APPLE AND (CMAKE_CXX_COMPILER_ID STREQUAL "AppleClang" OR CMAKE_COMPILER_IS_GNUCXX))))
5050 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fsanitize=address,undefined -fno-omit-frame-pointer")
5151- -
52- 2.51 .0
52+ 2.53 .0
5353
0 commit comments