diff --git a/cpp/core/CMakeLists.txt b/cpp/core/CMakeLists.txt index fbf4288a5a85..c42c37b77620 100644 --- a/cpp/core/CMakeLists.txt +++ b/cpp/core/CMakeLists.txt @@ -213,14 +213,11 @@ file(MAKE_DIRECTORY ${root_directory}/releases) add_library(gluten SHARED ${SPARK_COLUMNAR_PLUGIN_SRCS}) add_dependencies(gluten jni_proto) -if(ENABLE_GLUTEN_VCPKG) - # Hide symbols of some static dependencies. Otherwise, if such dependencies - # are already statically linked to libvelox.so, a runtime error will be - # reported: xxx is being linked both statically and dynamically. - target_link_options( - gluten PRIVATE -Wl,--version-script=${CMAKE_CURRENT_SOURCE_DIR}/symbols.map) - target_link_libraries(gluten PRIVATE google::glog) -endif() +# Hide symbols of some static dependencies. Otherwise, if such dependencies +# are already statically linked to libvelox.so, a runtime error will be +# reported: xxx is being linked both statically and dynamically. +target_link_options( + gluten PRIVATE -Wl,--version-script=${CMAKE_CURRENT_SOURCE_DIR}/symbols.map) if(CMAKE_CXX_COMPILER_VERSION VERSION_LESS 9.0) execute_process( @@ -318,6 +315,7 @@ endif() target_link_libraries(gluten PUBLIC Arrow::parquet Arrow::arrow Arrow::arrow_bundled_dependencies) +target_link_libraries(gluten PRIVATE google::glog) install(TARGETS gluten DESTINATION ${CMAKE_INSTALL_LIBDIR}) install(FILES ${CMAKE_CURRENT_SOURCE_DIR}/resources/libhdfs.so