diff --git a/CMakeLists.txt b/CMakeLists.txt index b5f2a88f702..8c4802295a7 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -178,7 +178,7 @@ include (cmake/use_libcxx.cmake) # This is intended for more control of what we are linking. set (DEFAULT_LIBS "") -if (OS_LINUX AND NOT UNBUNDLED) +if (OS_LINUX AND NOT UNBUNDLED AND (GLIBC_COMPATIBILITY OR USE_LIBCXX)) # Note: this probably has no effect, but I'm not an expert in CMake. set (CMAKE_C_IMPLICIT_LINK_LIBRARIES "") set (CMAKE_CXX_IMPLICIT_LINK_LIBRARIES "") diff --git a/dbms/src/Functions/FunctionsRound.h b/dbms/src/Functions/FunctionsRound.h index bff8248b3ea..d9d0bcae037 100644 --- a/dbms/src/Functions/FunctionsRound.h +++ b/dbms/src/Functions/FunctionsRound.h @@ -119,6 +119,8 @@ struct IntegerRoundingComputation return x; } } + + __builtin_unreachable(); } static ALWAYS_INLINE T compute(T x, T scale) @@ -132,6 +134,8 @@ struct IntegerRoundingComputation case ScaleMode::Negative: return computeImpl(x, scale); } + + __builtin_unreachable(); } static ALWAYS_INLINE void compute(const T * __restrict in, size_t scale, T * __restrict out) diff --git a/dbms/tests/queries/0_stateless/00823_capnproto_input.sh b/dbms/tests/queries/0_stateless/00823_capnproto_input.sh index c33b185311a..cf0e2739abd 100755 --- a/dbms/tests/queries/0_stateless/00823_capnproto_input.sh +++ b/dbms/tests/queries/0_stateless/00823_capnproto_input.sh @@ -1,6 +1,6 @@ #!/usr/bin/env bash -set -e +set -e CURDIR=$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd) . $CURDIR/../shell_config.sh @@ -35,7 +35,7 @@ struct CapnProto nestedone @2 : NestedOne; nestedtwo @3 : NestedTwo; nestedthree @4 : NestedNestedTwo; -}" > test.capnp +}" > ${CLICKHOUSE_TMP}/test.capnp $CLICKHOUSE_CLIENT -q "DROP TABLE IF EXISTS test.capnproto_input" $CLICKHOUSE_CLIENT -q "CREATE TABLE test.capnproto_input @@ -50,10 +50,10 @@ $CLICKHOUSE_CLIENT -q "CREATE TABLE test.capnproto_input nestedtwo_nestedtext String ) ENGINE = Memory" -echo -ne '\x00\x00\x00\x00\x15\x00\x00\x00\x00\x00\x00\x00\x01\x00\x04\x00\x01\x00\x00\x00\x00\x00\x00\x00\x0d\x00\x00\x00\x12\x00\x00\x00\x0c\x00\x00\x00\x01\x00\x02\x00\x20\x00\x00\x00\x00\x00\x03\x00\x34\x00\x00\x00\x00\x00\x01\x00\x32\x00\x00\x00\x00\x00\x00\x00\x05\x00\x00\x00\x00\x00\x00\x00\x04\x00\x00\x00\x01\x00\x00\x00\x04\x00\x00\x00\x00\x00\x01\x00\x03\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00\x12\x00\x00\x00\x34\x00\x00\x00\x00\x00\x00\x00\x08\x00\x00\x00\x01\x00\x00\x00\x08\x00\x00\x00\x00\x00\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x06\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00\x12\x00\x00\x00\x37\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00\x12\x00\x00\x00\x39\x00\x00\x00\x00\x00\x00\x00' | $CLICKHOUSE_CLIENT --stacktrace --format_schema='test:CapnProto' --query="INSERT INTO test.capnproto_input FORMAT CapnProto"; +echo -ne '\x00\x00\x00\x00\x15\x00\x00\x00\x00\x00\x00\x00\x01\x00\x04\x00\x01\x00\x00\x00\x00\x00\x00\x00\x0d\x00\x00\x00\x12\x00\x00\x00\x0c\x00\x00\x00\x01\x00\x02\x00\x20\x00\x00\x00\x00\x00\x03\x00\x34\x00\x00\x00\x00\x00\x01\x00\x32\x00\x00\x00\x00\x00\x00\x00\x05\x00\x00\x00\x00\x00\x00\x00\x04\x00\x00\x00\x01\x00\x00\x00\x04\x00\x00\x00\x00\x00\x01\x00\x03\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00\x12\x00\x00\x00\x34\x00\x00\x00\x00\x00\x00\x00\x08\x00\x00\x00\x01\x00\x00\x00\x08\x00\x00\x00\x00\x00\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x06\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00\x12\x00\x00\x00\x37\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00\x12\x00\x00\x00\x39\x00\x00\x00\x00\x00\x00\x00' | $CLICKHOUSE_CLIENT --stacktrace --format_schema="${CLICKHOUSE_TMP}/test:CapnProto" --query="INSERT INTO test.capnproto_input FORMAT CapnProto"; $CLICKHOUSE_CLIENT -q "SELECT * FROM test.capnproto_input" $CLICKHOUSE_CLIENT -q "DROP TABLE test.capnproto_input" # remove the schema file -rm test.capnp +rm ${CLICKHOUSE_TMP}/test.capnp