aboutsummaryrefslogtreecommitdiffstats
path: root/CMakeLists.txt
diff options
context:
space:
mode:
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r--CMakeLists.txt7
1 files changed, 7 insertions, 0 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 29d309080..aa66b075a 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -123,6 +123,13 @@ IF(ENABLE_STATIC MATCHES "ON")
SET(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -static")
SET(LINK_TYPE "STATIC")
SET(NO_SHARED "ON")
+ # Dirty hack for cmake
+ SET(CMAKE_EXE_LINK_DYNAMIC_C_FLAGS) # remove -Wl,-Bdynamic
+ SET(CMAKE_EXE_LINK_DYNAMIC_CXX_FLAGS)
+ SET(CMAKE_SHARED_LIBRARY_C_FLAGS) # remove -fPIC
+ SET(CMAKE_SHARED_LIBRARY_CXX_FLAGS)
+ SET(CMAKE_SHARED_LIBRARY_LINK_C_FLAGS) # remove -rdynamic
+ SET(CMAKE_SHARED_LIBRARY_LINK_CXX_FLAGS)
ELSE(ENABLE_STATIC MATCHES "ON")
IF (NO_SHARED MATCHES "OFF")
SET(LINK_TYPE "SHARED")