Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[native] Switch to using the Velox mono static library #24343

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion presto-native-execution/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ option(PRESTO_ENABLE_GCS "Build GCS support" OFF)
option(PRESTO_ENABLE_ABFS "Build ABFS support" OFF)

# Forwards user input to VELOX_ENABLE_PARQUET.
option(PRESTO_ENABLE_PARQUET "Enable Parquet support" OFF)
option(PRESTO_ENABLE_PARQUET "Enable Parquet support" ON)

# Forwards user input to VELOX_ENABLE_REMOTE_FUNCTIONS.
option(PRESTO_ENABLE_REMOTE_FUNCTIONS "Enable remote function support" OFF)
Expand Down Expand Up @@ -204,6 +204,7 @@ include_directories(${CMAKE_BINARY_DIR})
# set this for backwards compatibility, will be overwritten in velox/
set(VELOX_GTEST_INCUDE_DIR "velox/third_party/googletest/googletest/include")

set(VELOX_MONO_LIBRARY ON)
add_subdirectory(velox)

if(PRESTO_ENABLE_TESTING)
Expand Down
35 changes: 2 additions & 33 deletions presto-native-execution/presto_cpp/main/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -51,37 +51,7 @@ target_link_libraries(
presto_http
presto_operators
presto_velox_conversion
velox_abfs
velox_aggregates
velox_caching
velox_common_base
velox_core
velox_dwio_common_exception
velox_dwio_dwrf_reader
velox_dwio_dwrf_writer
velox_dwio_orc_reader
velox_dwio_parquet_reader
velox_dwio_parquet_writer
velox_encode
velox_exec
velox_file
velox_functions_lib
velox_functions_prestosql
velox_gcs
velox_hdfs
velox_hive_connector
velox_hive_iceberg_splitreader
velox_hive_partition_function
velox_presto_serializer
velox_s3fs
velox_serialization
velox_time
velox_type_parser
velox_type
velox_type_fbhive
velox_type_tz
velox_vector
velox_window
velox
${RE2}
${FOLLY_WITH_DEPENDENCIES}
${GLOG}
Expand All @@ -104,8 +74,7 @@ add_executable(presto_server PrestoMain.cpp)
# results in multiple link errors similar to the one below only on GCC.
# "undefined reference to `vtable for velox::connector::tpch::TpchTableHandle`"
# TODO: Fix these errors.
target_link_libraries(presto_server presto_server_lib velox_hive_connector
velox_tpch_connector)
target_link_libraries(presto_server presto_server_lib velox)

if(PRESTO_ENABLE_REMOTE_FUNCTIONS)
add_library(presto_server_remote_function JsonSignatureParser.cpp
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,11 @@
add_library(presto_exception Exception.cpp)
add_library(presto_common Counters.cpp Utils.cpp ConfigReader.cpp Configs.cpp)

target_link_libraries(presto_exception velox_exception)
target_link_libraries(presto_exception velox)
set_property(TARGET presto_exception PROPERTY JOB_POOL_LINK
presto_link_job_pool)

target_link_libraries(presto_common velox_common_config velox_core
velox_exception)
target_link_libraries(presto_common velox)
set_property(TARGET presto_common PROPERTY JOB_POOL_LINK presto_link_job_pool)

if(PRESTO_ENABLE_TESTING)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,7 @@ target_link_libraries(
presto_http
http_filters
presto_common
velox_memory
velox_exception
velox
${PROXYGEN_LIBRARIES}
${LIBSODIUM_LIBRARY}
${OPENSSL_SSL_LIBRARY}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,11 +25,7 @@ add_library(
target_link_libraries(
presto_operators
presto_common
velox_core
velox_exec
velox_presto_serializer
velox_vector
velox_row_fast)
velox)

if(PRESTO_ENABLE_TESTING)
add_subdirectory(tests)
Expand Down
10 changes: 4 additions & 6 deletions presto-native-execution/presto_cpp/main/types/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -18,21 +18,19 @@ add_library(
presto_types OBJECT
PrestoToVeloxQueryPlan.cpp PrestoToVeloxExpr.cpp VeloxPlanValidator.cpp
PrestoToVeloxSplit.cpp PrestoToVeloxConnector.cpp)
add_dependencies(presto_types presto_operators presto_type_converter velox_type
velox_type_fbhive)
add_dependencies(presto_types presto_operators presto_type_converter velox)

target_link_libraries(presto_types presto_type_converter velox_type_fbhive
velox_hive_partition_function velox_tpch_gen)
target_link_libraries(presto_types presto_type_converter velox)

set_property(TARGET presto_types PROPERTY JOB_POOL_LINK presto_link_job_pool)

add_library(presto_function_metadata OBJECT FunctionMetadata.cpp)

target_link_libraries(presto_function_metadata velox_function_registry)
target_link_libraries(presto_function_metadata velox)

add_library(presto_velox_conversion OBJECT VeloxPlanConversion.cpp)

target_link_libraries(presto_velox_conversion velox_type)
target_link_libraries(presto_velox_conversion velox)

if(PRESTO_ENABLE_TESTING)
add_subdirectory(tests)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ add_library(
presto_protocol OBJECT presto_protocol.cpp Base64Util.cpp core/DataSize.cpp
core/Duration.cpp core/ConnectorProtocol.cpp)

target_link_libraries(presto_protocol velox_type velox_presto_serializer ${RE2})
target_link_libraries(presto_protocol velox_type velox ${RE2})

if(PRESTO_ENABLE_TESTING)
add_subdirectory(tests)
Expand Down
Loading