2018-03-14 23:04:35 +00:00
|
|
|
#!/bin/bash
|
2018-01-15 18:57:10 +00:00
|
|
|
|
|
|
|
# Manual run:
|
|
|
|
# env CXX=g++-7 CC=gcc-7 utils/travis/normal.sh
|
|
|
|
# env CXX=clang++-5.0 CC=clang-5.0 utils/travis/normal.sh
|
|
|
|
|
2018-03-14 23:04:35 +00:00
|
|
|
CUR_DIR=$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)
|
2018-05-25 20:52:20 +00:00
|
|
|
CXX=${CXX=g++}
|
|
|
|
CC=${CC=gcc}
|
2018-03-14 23:04:35 +00:00
|
|
|
|
2018-01-15 18:57:10 +00:00
|
|
|
set -e
|
|
|
|
set -x
|
|
|
|
|
2018-02-08 14:38:36 +00:00
|
|
|
date
|
2018-01-15 18:57:10 +00:00
|
|
|
|
2018-01-16 13:44:45 +00:00
|
|
|
# clean not used ~600mb
|
|
|
|
[ -n "$TRAVIS" ] && rm -rf .git contrib/poco/openssl
|
|
|
|
|
2018-01-15 18:57:10 +00:00
|
|
|
ccache -s
|
2018-02-08 14:38:36 +00:00
|
|
|
ccache -M ${CCACHE_SIZE:=4G}
|
2018-01-16 13:44:45 +00:00
|
|
|
df -h
|
|
|
|
|
2018-02-08 14:38:36 +00:00
|
|
|
date
|
|
|
|
|
2018-01-15 18:57:10 +00:00
|
|
|
mkdir -p build
|
|
|
|
cd build
|
2018-05-17 17:55:07 +00:00
|
|
|
cmake $CUR_DIR/../.. -DCMAKE_CXX_COMPILER=`which $DEB_CXX $CXX` -DCMAKE_C_COMPILER=`which $DEB_CC $CC` \
|
2018-01-16 13:44:45 +00:00
|
|
|
`# Does not optimize to speedup build, skip debug info to use less disk` \
|
2018-05-17 17:55:07 +00:00
|
|
|
-DCMAKE_C_FLAGS_ADD="-O0 -g0" -DCMAKE_CXX_FLAGS_ADD="-O0 -g0" \
|
2018-01-16 13:44:45 +00:00
|
|
|
`# ignore ccache disabler on trusty` \
|
2018-05-17 17:55:07 +00:00
|
|
|
-DCMAKE_C_COMPILER_LAUNCHER=`which ccache` -DCMAKE_CXX_COMPILER_LAUNCHER=`which ccache` \
|
2018-01-15 18:57:10 +00:00
|
|
|
`# Use all possible contrib libs from system` \
|
2018-05-17 17:55:07 +00:00
|
|
|
-DUNBUNDLED=1 \
|
2018-01-15 18:57:10 +00:00
|
|
|
`# Disable all features` \
|
2018-10-16 09:30:51 +00:00
|
|
|
-DENABLE_CAPNP=0 -DENABLE_RDKAFKA=0 -DENABLE_EMBEDDED_COMPILER=0 -DUSE_INTERNAL_LLVM_LIBRARY=0 -DENABLE_JEMALLOC=0 -DENABLE_UNWIND=0 -DENABLE_MYSQL=0 -DENABLE_POCO_ODBC=0 -DENABLE_ODBC=0 $CMAKE_FLAGS
|
2018-08-21 16:34:05 +00:00
|
|
|
|
2018-08-23 12:28:45 +00:00
|
|
|
ninja clickhouse-bundle
|
2018-08-21 15:56:50 +00:00
|
|
|
|
2018-08-23 12:28:45 +00:00
|
|
|
# Skip tests:
|
|
|
|
# 00281 requires internal compiler
|
|
|
|
# 00428 requires sudo (not all vms allow this)
|
|
|
|
# 00385 runs infinitly (TODO: fix it)
|
2018-08-21 15:56:50 +00:00
|
|
|
[ ! ${TEST_RUN=1} ] || ( ( cd $CUR_DIR/../.. && env TEST_OPT="--skip long compile 00428 00385 $TEST_OPT" TEST_PORT_RANDOM= TEST_PERF= TEST_SERVER_STARTUP_WAIT=10 bash -x dbms/tests/clickhouse-test-server ) || ${TEST_TRUE=false} )
|
2018-02-08 14:38:36 +00:00
|
|
|
|
|
|
|
date
|