mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-12-11 17:02:25 +00:00
Build fixes (freebsd) (#4696)
This commit is contained in:
parent
f983282fe0
commit
8c70de3bc7
@ -20,11 +20,12 @@ if (NOT GTEST_SRC_DIR AND NOT GTEST_INCLUDE_DIRS AND NOT MISSING_INTERNAL_GTEST_
|
|||||||
set (USE_INTERNAL_GTEST_LIBRARY 1)
|
set (USE_INTERNAL_GTEST_LIBRARY 1)
|
||||||
set (GTEST_MAIN_LIBRARIES gtest_main)
|
set (GTEST_MAIN_LIBRARIES gtest_main)
|
||||||
set (GTEST_LIBRARIES gtest)
|
set (GTEST_LIBRARIES gtest)
|
||||||
|
set (GTEST_BOTH_LIBRARIES ${GTEST_MAIN_LIBRARIES} ${GTEST_LIBRARIES})
|
||||||
set (GTEST_INCLUDE_DIRS ${ClickHouse_SOURCE_DIR}/contrib/googletest/googletest)
|
set (GTEST_INCLUDE_DIRS ${ClickHouse_SOURCE_DIR}/contrib/googletest/googletest)
|
||||||
endif ()
|
endif ()
|
||||||
|
|
||||||
if((GTEST_INCLUDE_DIRS AND GTEST_MAIN_LIBRARIES) OR GTEST_SRC_DIR)
|
if((GTEST_INCLUDE_DIRS AND GTEST_BOTH_LIBRARIES) OR GTEST_SRC_DIR)
|
||||||
set(USE_GTEST 1)
|
set(USE_GTEST 1)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
message (STATUS "Using gtest=${USE_GTEST}: ${GTEST_INCLUDE_DIRS} : ${GTEST_LIBRARIES}, ${GTEST_MAIN_LIBRARIES} : ${GTEST_SRC_DIR}")
|
message (STATUS "Using gtest=${USE_GTEST}: ${GTEST_INCLUDE_DIRS} : ${GTEST_BOTH_LIBRARIES} : ${GTEST_SRC_DIR}")
|
||||||
|
@ -184,7 +184,9 @@ target_link_libraries (clickhouse_common_io
|
|||||||
string_utils
|
string_utils
|
||||||
widechar_width
|
widechar_width
|
||||||
${LINK_LIBRARIES_ONLY_ON_X86_64}
|
${LINK_LIBRARIES_ONLY_ON_X86_64}
|
||||||
|
PUBLIC
|
||||||
${DOUBLE_CONVERSION_LIBRARIES}
|
${DOUBLE_CONVERSION_LIBRARIES}
|
||||||
|
PRIVATE
|
||||||
pocoext
|
pocoext
|
||||||
PUBLIC
|
PUBLIC
|
||||||
${Poco_Net_LIBRARY}
|
${Poco_Net_LIBRARY}
|
||||||
@ -351,6 +353,6 @@ if (ENABLE_TESTS AND USE_GTEST)
|
|||||||
# attach all dbms gtest sources
|
# attach all dbms gtest sources
|
||||||
grep_gtest_sources(${ClickHouse_SOURCE_DIR}/dbms dbms_gtest_sources)
|
grep_gtest_sources(${ClickHouse_SOURCE_DIR}/dbms dbms_gtest_sources)
|
||||||
add_executable(unit_tests_dbms ${dbms_gtest_sources})
|
add_executable(unit_tests_dbms ${dbms_gtest_sources})
|
||||||
target_link_libraries(unit_tests_dbms PRIVATE gtest_main dbms clickhouse_common_zookeeper)
|
target_link_libraries(unit_tests_dbms PRIVATE ${GTEST_BOTH_LIBRARIES} dbms clickhouse_common_zookeeper)
|
||||||
add_check(unit_tests_dbms)
|
add_check(unit_tests_dbms)
|
||||||
endif ()
|
endif ()
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
if(USE_GTEST)
|
if(USE_GTEST)
|
||||||
add_executable(column_unique column_unique.cpp)
|
add_executable(column_unique column_unique.cpp)
|
||||||
target_link_libraries(column_unique PRIVATE dbms gtest_main)
|
target_link_libraries(column_unique PRIVATE dbms ${GTEST_BOTH_LIBRARIES})
|
||||||
endif()
|
endif()
|
@ -7,5 +7,5 @@ target_link_libraries (data_type_string PRIVATE dbms)
|
|||||||
|
|
||||||
if(USE_GTEST)
|
if(USE_GTEST)
|
||||||
add_executable(data_type_get_common_type data_type_get_common_type.cpp)
|
add_executable(data_type_get_common_type data_type_get_common_type.cpp)
|
||||||
target_link_libraries(data_type_get_common_type PRIVATE dbms gtest_main)
|
target_link_libraries(data_type_get_common_type PRIVATE dbms ${GTEST_BOTH_LIBRARIES})
|
||||||
endif()
|
endif()
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
add_executable(clickhouse-zookeeper-cli zookeeper-cli.cpp)
|
add_executable(clickhouse-zookeeper-cli zookeeper-cli.cpp)
|
||||||
target_link_libraries(clickhouse-zookeeper-cli PRIVATE clickhouse_common_zookeeper ${LINE_EDITING_LIBS})
|
target_link_libraries(clickhouse-zookeeper-cli PRIVATE clickhouse_common_zookeeper ${Poco_Foundation_LIBRARY} ${LINE_EDITING_LIBS})
|
||||||
if (READLINE_INCLUDE_DIR)
|
if (READLINE_INCLUDE_DIR)
|
||||||
target_include_directories (clickhouse-zookeeper-cli SYSTEM PRIVATE ${READLINE_INCLUDE_DIR})
|
target_include_directories (clickhouse-zookeeper-cli SYSTEM PRIVATE ${READLINE_INCLUDE_DIR})
|
||||||
endif ()
|
endif ()
|
||||||
|
Loading…
Reference in New Issue
Block a user