diff --git a/CMakeLists.txt b/CMakeLists.txt index e98f53239fb..0dbff81a428 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -157,7 +157,7 @@ if(ENABLE_IPO) if(ipo_result) set_property(TARGET kvrocks_objs PROPERTY INTERPROCEDURAL_OPTIMIZATION TRUE) if(CMAKE_CXX_COMPILER_ID STREQUAL "Clang") - set_property(TARGET kvrocks_objs APPEND_STRING PROPERTY LINK_FLAGS " -fuse-ld=lld ") + target_link_libraries(kvrocks_objs PUBLIC "-fuse-ld=lld") endif() else() message(WARNING "IPO is not supported: ${ipo_output}")