diff --git a/CMakeLists.txt b/CMakeLists.txt index 9c2df6abeff..d59dbbfc8b3 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -447,7 +447,7 @@ if (MAKE_STATIC_LIBRARIES) # It's disabled for ARM because otherwise ClickHouse cannot run on Android. set (CMAKE_CXX_FLAGS_RELWITHDEBINFO "${CMAKE_CXX_FLAGS_RELWITHDEBINFO} -fno-pie") set (CMAKE_C_FLAGS_RELWITHDEBINFO "${CMAKE_C_FLAGS_RELWITHDEBINFO} -fno-pie") - set (CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -Wl,-no-pie") + set (CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -no-pie -Wl,-no-pie") endif () else () set (CMAKE_POSITION_INDEPENDENT_CODE ON)