mirror of
https://github.com/hanzoai/datastore.git
synced 2026-10-30 14:48:37 +00:00
project(Datastore) renamed the CMake auto-vars ClickHouse_SOURCE_DIR/BINARY_DIR; the contrib *-cmake glue + top-level CMakeLists submodule check still referenced the old names -> undefined -> false 'submodules not initialized'. Renamed all CMake refs (incl contrib glue). Found by spark build.
24 lines
729 B
CMake
24 lines
729 B
CMake
# lz4 is the main compression method, cannot be disabled.
|
|
|
|
set (LIBRARY_DIR "${Datastore_SOURCE_DIR}/contrib/lz4")
|
|
set (SRCS
|
|
"${LIBRARY_DIR}/lib/lz4.c"
|
|
"${LIBRARY_DIR}/lib/lz4hc.c"
|
|
"${LIBRARY_DIR}/lib/lz4frame.c"
|
|
"${LIBRARY_DIR}/lib/xxhash.c"
|
|
)
|
|
|
|
add_library (_lz4 ${SRCS})
|
|
add_library (ch_contrib::lz4 ALIAS _lz4)
|
|
|
|
target_compile_definitions (_lz4 PRIVATE LZ4_FAST_DEC_LOOP=1)
|
|
|
|
if(ARCH_S390X)
|
|
target_compile_definitions(_lz4 PRIVATE LZ4_STATIC_LINKING_ONLY_ENDIANNESS_INDEPENDENT_OUTPUT)
|
|
endif()
|
|
|
|
if (SANITIZE STREQUAL "undefined" OR SANITIZE STREQUAL "address,undefined")
|
|
target_compile_options (_lz4 PRIVATE -fno-sanitize=undefined)
|
|
endif ()
|
|
target_include_directories(_lz4 PUBLIC "${LIBRARY_DIR}/lib")
|