From 132d917eb04ef857e36ff250c719b5b541932f7f Mon Sep 17 00:00:00 2001 From: Tomi Valkeinen Date: Sat, 1 Oct 2016 18:24:28 +0300 Subject: remove -rdynamic gcc flag This reduces the exe sizes. Signed-off-by: Tomi Valkeinen --- CMakeLists.txt | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/CMakeLists.txt b/CMakeLists.txt index 6306852..d9bc30c 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -32,6 +32,10 @@ if (CMAKE_COMPILER_IS_GNUCC) endif() endif() +# HACK: cmake always adds "-rdynamic", this removes it +SET(CMAKE_SHARED_LIBRARY_LINK_C_FLAGS "") +SET(CMAKE_SHARED_LIBRARY_LINK_CXX_FLAGS "") + set(CMAKE_POSITION_INDEPENDENT_CODE TRUE) # static link libc -- cgit v1.2.3