Skip to content

Commit

Permalink
Revert "Fix CI compilation"
Browse files Browse the repository at this point in the history
This reverts commit 89802bb.
  • Loading branch information
PHILO-HE committed Oct 29, 2023
1 parent 0b09604 commit 4032e68
Show file tree
Hide file tree
Showing 7 changed files with 21 additions and 63 deletions.
27 changes: 13 additions & 14 deletions CMake/Findlz4.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -21,19 +21,18 @@ find_package_handle_standard_args(lz4 DEFAULT_MSG LZ4_LIBRARY LZ4_INCLUDE_DIR)

mark_as_advanced(LZ4_LIBRARY LZ4_INCLUDE_DIR)

get_filename_component(liblz4_ext ${LZ4_LIBRARY} EXT)
if(liblz4_ext STREQUAL ".a")
set(liblz4_type STATIC)
else()
set(liblz4_type SHARED)
endif()

if(NOT TARGET lz4::lz4)
add_library(lz4::lz4 UNKNOWN IMPORTED)
set_target_properties(lz4::lz4 PROPERTIES
INTERFACE_INCLUDE_DIRECTORIES "${LZ4_INCLUDE_DIR}"
IMPORTED_LINK_INTERFACE_LANGUAGES "C"
IMPORTED_LOCATION_RELEASE "${LZ4_LIBRARY_RELEASE}")
set_property(TARGET lz4::lz4 APPEND PROPERTY
IMPORTED_CONFIGURATIONS RELEASE)

if(LZ4_LIBRARY_DEBUG)
set_property(TARGET lz4::lz4 APPEND PROPERTY
IMPORTED_CONFIGURATIONS DEBUG)
set_property(TARGET lz4::lz4 PROPERTY
IMPORTED_LOCATION_DEBUG "${LZ4_LIBRARY_DEBUG}")
endif()
add_library(lz4::lz4 ${liblz4_type} IMPORTED)
set_target_properties(lz4::lz4 PROPERTIES INTERFACE_INCLUDE_DIRECTORIES
"${LZ4_INCLUDE_DIR}")
set_target_properties(
lz4::lz4 PROPERTIES IMPORTED_LINK_INTERFACE_LANGUAGES "C"
IMPORTED_LOCATION "${LZ4_LIBRARIES}")
endif()
15 changes: 5 additions & 10 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -211,15 +211,10 @@ if(VELOX_ENABLE_ABFS)
endif()

if(VELOX_ENABLE_HDFS)
find_package(libhdfs3)
if(libhdfs3_FOUND AND TARGET HDFS::hdfs3)
set(LIBHDFS3 HDFS::hdfs3)
else()
find_library(
LIBHDFS3
NAMES libhdfs3.so libhdfs3.dylib
HINTS "${CMAKE_SOURCE_DIR}/hawq/depends/libhdfs3/_build/src/" REQUIRED)
endif()
find_library(
LIBHDFS3
NAMES libhdfs3.so libhdfs3.dylib
HINTS "${CMAKE_SOURCE_DIR}/hawq/depends/libhdfs3/_build/src/" REQUIRED)
add_definitions(-DVELOX_ENABLE_HDFS3)
endif()

Expand Down Expand Up @@ -385,7 +380,7 @@ resolve_dependency(Boost 1.66.0 COMPONENTS ${BOOST_INCLUDE_LIBRARIES})
# for reference. find_package(range-v3)

set_source(gflags)
resolve_dependency(gflags)
resolve_dependency(gflags COMPONENTS shared)
if(NOT TARGET gflags::gflags)
# This is a bit convoluted, but we want to be able to use gflags::gflags as a
# target even when velox is built as a subproject which uses
Expand Down
2 changes: 0 additions & 2 deletions third_party/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ if(VELOX_ENABLE_ARROW)
set(ARROW_PREFIX "${CMAKE_CURRENT_BINARY_DIR}/arrow_ep")
set(ARROW_CMAKE_ARGS
-DARROW_PARQUET=ON
-DARROW_FILESYSTEM=ON
-DARROW_WITH_LZ4=ON
-DARROW_WITH_SNAPPY=ON
-DARROW_WITH_ZLIB=ON
Expand Down Expand Up @@ -69,7 +68,6 @@ if(VELOX_ENABLE_ARROW)
arrow_ep
PREFIX ${ARROW_PREFIX}
URL ${VELOX_ARROW_SOURCE_URL}
PATCH_COMMAND patch -p1 < ${CMAKE_CURRENT_SOURCE_DIR}/arrow_patches/helpers.patch
URL_HASH ${VELOX_ARROW_BUILD_SHA256_CHECKSUM}
SOURCE_SUBDIR cpp
CMAKE_ARGS ${ARROW_CMAKE_ARGS}
Expand Down
32 changes: 0 additions & 32 deletions third_party/arrow_patches/helpers.patch

This file was deleted.

2 changes: 1 addition & 1 deletion velox/common/process/tests/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -17,4 +17,4 @@ add_executable(velox_process_test TraceContextTest.cpp)
add_test(velox_process_test velox_process_test)

target_link_libraries(velox_process_test PRIVATE velox_process fmt::fmt gtest
gtest_main glog::glog gflags::gflags)
gtest_main)
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ HdfsMiniCluster::HdfsMiniCluster() {
"Failed to find minicluster executable {}'", miniClusterExecutableName);
}
boost::filesystem::path hadoopHomeDirectory = exePath_;
hadoopHomeDirectory.remove_filename().remove_filename();
hadoopHomeDirectory.remove_leaf().remove_leaf();
setupEnvironment(hadoopHomeDirectory.string());
}

Expand Down
4 changes: 1 addition & 3 deletions velox/dwio/parquet/writer/arrow/tests/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -40,9 +40,7 @@ target_link_libraries(
gtest_main
parquet
arrow
arrow_testing
glog::glog
gflags::gflags)
arrow_testing)

add_library(
velox_dwio_arrow_parquet_writer_test_lib
Expand Down

0 comments on commit 4032e68

Please sign in to comment.