ClickHouse/cmake/find/zstd.cmake

28 lines
1.1 KiB
CMake
Raw Normal View History

option (USE_INTERNAL_ZSTD_LIBRARY "Set to FALSE to use system zstd library instead of bundled" ${NOT_UNBUNDLED})
2019-05-15 17:19:39 +00:00
if(NOT EXISTS "${ClickHouse_SOURCE_DIR}/contrib/zstd/lib/zstd.h")
if(USE_INTERNAL_ZSTD_LIBRARY)
message(WARNING "submodule contrib/zstd is missing. to fix try run: \n git submodule update --init --recursive")
message (${RECONFIGURE_MESSAGE_LEVEL} "Can't find internal zstd library")
set(USE_INTERNAL_ZSTD_LIBRARY 0)
2019-05-15 17:19:39 +00:00
endif()
set(MISSING_INTERNAL_ZSTD_LIBRARY 1)
endif()
zstd, lz4 as submodule (#1214) * Contrib: use zstd, lz4 as submodule * fix shared build * re-test me. * wip * Update CHANGELOG_RU.md * Update CHANGELOG.md * Update CHANGELOG_RU.md * Whitespaces [#CLICKHOUSE-2]. * Implemented TODO [#CLICKHOUSE-2]. * Whitespaces [#CLICKHOUSE-2]. * Remove wrong test * Implemented TODO [#CLICKHOUSE-2]. * Moved chown to correct place [#CLICKHOUSE-2]. * Resolves #1273. Exception safe users update. [#CLICKHOUSE-3] * Less noisy logging. [#CLICKHOSUE-2] * Add metrics for RWLockFIFO. [#CLICKHOUSE-3246] * Executable dictionaries: fail if program returns non zero exit code (#CLICKHOUSE-3171) * Add better logging if OPTIMIZE cannot be executed. [#CLICKHOUSE-2] * test me * Fixing documentation fragment about "default" user. It is not mandatory anymore. * append yurial/clickhouse-client to docs/interfaces * Fixed FREEZE PARTITION: using only active data parts; acquire snapshot of parts [#CLICKHOUSE-3369]. * Removed tcp_ssl_port by default [#CLICKHOUSE-2]. * Update MergeTreeDataMerger.cpp * Update ShellCommand.cpp * Disable part sendings and fetches before ALTER. [#CLICKHOUSE-3343] * Update ExecutableDictionarySource.cpp * Update ExecutableDictionarySource.cpp * Miscellaneous changes after merge [#CLICKHOUSE-2]. * Improve tests: allow redefine some values (clickhouse path, ports, ...) * Received signal Segmentation fault (#1300) (#1302) * Received signal Segmentation fault (#1300) * Add test * Tests: Use new possibly redefined values from env (in 2 tests) * Proper fix for the issue: better exception message [#CLICKHOUSE-2]. * Split GatherUtils.cpp for faster compile (#1312) * Split GatherUtils.cpp for faster compile * remove GatherUtils.cpp * Fix array writing (#1314) * changed MergedBlockOutputStream [#CLICKHOUSE-3341] * fix build [#CLICKHOUSE-3341] * fix build [#CLICKHOUSE-3341] * fix build [#CLICKHOUSE-3341] * fix build [#CLICKHOUSE-3341] * fix build [#CLICKHOUSE-3341] * fix build [#CLICKHOUSE-3341] * fix build [#CLICKHOUSE-3341] * fix build [#CLICKHOUSE-3341] * fix build [#CLICKHOUSE-3341] * disabled checkNoMultidimensionalArrays [#CLICKHOUSE-3341] * fix IMergedBlockOutputStream::writeDataImpl [#CLICKHOUSE-3341] * fix IMergedBlockOutputStream::writeDataImpl [#CLICKHOUSE-3341] * fix IMergedBlockOutputStream::writeDataImpl [#CLICKHOUSE-3341] * fix IMergedBlockOutputStream::writeDataImpl [#CLICKHOUSE-3341] * added test [#CLICKHOUSE-3341] * fixed test [#CLICKHOUSE-3341] * refactoring and comments [#CLICKHOUSE-3341] * fix build [#CLICKHOUSE-3341] * Update ColumnArray.h * Update ActionBlocker.h * Fix section tabulation * Fixed infinite recursion in expression analyzer. [#CLICKHOUSE-3125] * Update ActionBlocker.h * Improvement [#CLICKHOUSE-2]. * Try fix strange terminate (#1329) * Tests: External: rename --use_http => --no_http and fix * Try fix strange terminate * Misc [#CLICKHOUSE-2]. * Fix compile CallPointInPolygon on clang4 (Thanks to @vavrusa) (#1333) * Fix compile with boost 1.65.1+ and clang 3.8 ( https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=222439 ) * Fix compile CallPointInPolygon on clang4 (Thanks to @vavrusa) * Fix complex queries with GLOBAL IN and UNION ALL (#CLICKHOUSE-3356) (#1339) * TEST only: why initQueryAnalyzer ? * Better tests * missing file * Missing file * Add test * Test fixes * Fixed FREEZE PARTITION: using only active data parts; acquire snapshot of parts [#CLICKHOUSE-3369]. * Removed tcp_ssl_port by default [#CLICKHOUSE-2]. * Better tests * comment * clean * REmove wrong code * clean * dbms: Added compression level for ZSTD. [#METR-26742] * dbms: CompressionSettingsSelector. [#METR-21516] * dbms: Minor fix. [#METR-21516] * Fix SummingMergeTree argument checking logic. This patch fixes the Nested Column Name checking logic, which allows nested columns be explicitly specified in SummingMergeTree engine.
2017-10-13 18:52:23 +00:00
if (NOT USE_INTERNAL_ZSTD_LIBRARY)
find_library (ZSTD_LIBRARY zstd)
find_path (ZSTD_INCLUDE_DIR NAMES zstd.h PATHS ${ZSTD_INCLUDE_PATHS})
if (NOT ZSTD_LIBRARY OR NOT ZSTD_INCLUDE_DIR)
message (${RECONFIGURE_MESSAGE_LEVEL} "Can't find system zstd library")
endif ()
endif ()
if (ZSTD_LIBRARY AND ZSTD_INCLUDE_DIR)
2019-05-15 17:19:39 +00:00
elseif (NOT MISSING_INTERNAL_ZSTD_LIBRARY)
set (USE_INTERNAL_ZSTD_LIBRARY 1)
set (ZSTD_LIBRARY zstd)
2019-01-25 12:45:35 +00:00
set (ZSTD_INCLUDE_DIR ${ClickHouse_SOURCE_DIR}/contrib/zstd/lib)
endif ()
message (STATUS "Using zstd: ${ZSTD_INCLUDE_DIR} : ${ZSTD_LIBRARY}")