### What changes were proposed in this pull request? This PR adds support for lz4 decompression in CppClient. ### Why are the changes needed? To support reading from Celeborn with CppClient. ### Does this PR introduce _any_ user-facing change? No. ### How was this patch tested? By compilation and UTs. Closes #3402 from Jraaay/feat/cpp_client_lz4_decompression. Authored-by: Jray <1075860716@qq.com> Signed-off-by: SteNicholas <programgeek@163.com>
42 lines
1.1 KiB
CMake
42 lines
1.1 KiB
CMake
# Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
#
|
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
# you may not use this file except in compliance with the License.
|
|
# You may obtain a copy of the License at
|
|
#
|
|
# http://www.apache.org/licenses/LICENSE-2.0
|
|
#
|
|
# Unless required by applicable law or agreed to in writing, software
|
|
# distributed under the License is distributed on an "AS IS" BASIS,
|
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
# See the License for the specific language governing permissions and
|
|
# limitations under the License.
|
|
|
|
# Finds liblz4.
|
|
#
|
|
# This module defines:
|
|
# LZ4_FOUND
|
|
# LZ4_INCLUDE_DIR
|
|
# LZ4_LIBRARY
|
|
#
|
|
|
|
find_path(LZ4_INCLUDE_DIR NAMES lz4.h)
|
|
|
|
find_library(LZ4_LIBRARY_DEBUG NAMES lz4d)
|
|
find_library(LZ4_LIBRARY_RELEASE NAMES lz4)
|
|
|
|
include(SelectLibraryConfigurations)
|
|
SELECT_LIBRARY_CONFIGURATIONS(LZ4)
|
|
|
|
include(FindPackageHandleStandardArgs)
|
|
FIND_PACKAGE_HANDLE_STANDARD_ARGS(
|
|
LZ4 DEFAULT_MSG
|
|
LZ4_LIBRARY LZ4_INCLUDE_DIR
|
|
)
|
|
|
|
if (LZ4_FOUND)
|
|
message(STATUS "Found LZ4: ${LZ4_LIBRARY}")
|
|
endif()
|
|
|
|
mark_as_advanced(LZ4_INCLUDE_DIR LZ4_LIBRARY)
|