diff --git a/dbms/tests/queries/0_stateless/00385_storage_file_and_clickhouse-local_app.reference b/dbms/tests/queries/0_stateless/00385_storage_file_and_clickhouse-local_app.reference index 20e4523fe7a..f6b229492b6 100644 --- a/dbms/tests/queries/0_stateless/00385_storage_file_and_clickhouse-local_app.reference +++ b/dbms/tests/queries/0_stateless/00385_storage_file_and_clickhouse-local_app.reference @@ -1,7 +1,7 @@ -7785028801797101796 7785028801797101796 7785028801797101796 7785028801797101796 -7785028801797101796 7785028801797101796 7785028801797101796 7785028801797101796 -7785028801797101796 7785028801797101796 7785028801797101796 7785028801797101796 +0 0 0 +0 0 0 +0 0 0 -4030087544159056847 4030087544159056847 4030087544159056847 4030087544159056847 -4030087544159056847 4030087544159056847 4030087544159056847 4030087544159056847 -4030087544159056847 4030087544159056847 4030087544159056847 4030087544159056847 +0 0 0 +0 0 0 +0 0 0 diff --git a/dbms/tests/queries/0_stateless/00385_storage_file_and_clickhouse-local_app.sh b/dbms/tests/queries/0_stateless/00385_storage_file_and_clickhouse-local_app.sh index 716bf2613f5..3d9ee1c9c3f 100755 --- a/dbms/tests/queries/0_stateless/00385_storage_file_and_clickhouse-local_app.sh +++ b/dbms/tests/queries/0_stateless/00385_storage_file_and_clickhouse-local_app.sh @@ -17,14 +17,14 @@ function pack_unpack_compare() local res_db_file=$(clickhouse-client --max_threads=1 --query "SELECT $TABLE_HASH FROM test.buf_file") clickhouse-client --max_threads=1 --query "SELECT * FROM test.buf FORMAT $3" > "$buf_file" - local res_ch_local1=$(clickhouse-local --structure "$2" --file "$buf_file" --table "my super table" --input-format "$3" --output-format TabSeparated --query "SELECT $TABLE_HASH FROM \`my super table\`" 2>/dev/null) - local res_ch_local2=$(clickhouse-local --structure "$2" --table "my super table" --input-format "$3" --output-format TabSeparated --query "SELECT $TABLE_HASH FROM \`my super table\`" < "$buf_file" 2>/dev/null) + local res_ch_local1=$(clickhouse-local --structure "$2" --file "$buf_file" --table "my super table" --input-format "$3" --output-format TabSeparated --query "SELECT $TABLE_HASH FROM \`my super table\`" 2>stderr || cat stderr 1>&2) + local res_ch_local2=$(clickhouse-local --structure "$2" --table "my super table" --input-format "$3" --output-format TabSeparated --query "SELECT $TABLE_HASH FROM \`my super table\`" < "$buf_file" 2>stderr || cat stderr 1>&2) clickhouse-client --query "DROP TABLE IF EXISTS test.buf" clickhouse-client --query "DROP TABLE IF EXISTS test.buf_file" - rm -f "$buf_file" + rm -f "$buf_file" stderr - echo $res_orig $res_db_file $res_ch_local1 $res_ch_local2 + echo $((res_orig - res_db_file)) $((res_orig - res_ch_local1)) $((res_orig - res_ch_local2)) } pack_unpack_compare "SELECT number FROM system.numbers LIMIT 10000" "number UInt64" "TabSeparated" diff --git a/debian/clickhouse-benchmark.install b/debian/clickhouse-benchmark.install deleted file mode 100644 index 912a5c11420..00000000000 --- a/debian/clickhouse-benchmark.install +++ /dev/null @@ -1 +0,0 @@ -/usr/bin/clickhouse-benchmark diff --git a/debian/clickhouse-client.install b/debian/clickhouse-client.install index ce64b6cad36..94f0fa0974a 100644 --- a/debian/clickhouse-client.install +++ b/debian/clickhouse-client.install @@ -1,2 +1 @@ /etc/clickhouse-client/config.xml -/usr/bin/clickhouse-client diff --git a/debian/clickhouse-client.links b/debian/clickhouse-client.links new file mode 100644 index 00000000000..52c0d6a1b54 --- /dev/null +++ b/debian/clickhouse-client.links @@ -0,0 +1,3 @@ +/usr/bin/clickhouse /usr/bin/clickhouse-client +/usr/bin/clickhouse /usr/bin/clickhouse-benchmark +/usr/bin/clickhouse /usr/bin/clickhouse-local diff --git a/debian/clickhouse-local.install b/debian/clickhouse-local.install deleted file mode 100644 index c88c7476e92..00000000000 --- a/debian/clickhouse-local.install +++ /dev/null @@ -1 +0,0 @@ -/usr/bin/clickhouse-local diff --git a/debian/daemons b/debian/daemons index c70a58ed410..73123bfb997 100644 --- a/debian/daemons +++ b/debian/daemons @@ -1,6 +1,4 @@ compressor clickhouse-client clickhouse-server -clickhouse-benchmark -clickhouse-local config-processor diff --git a/debian/rules b/debian/rules index 4ad4d2c2483..ec5176062d9 100755 --- a/debian/rules +++ b/debian/rules @@ -7,6 +7,8 @@ ifndef THREADS_COUNT THREADS_COUNT=`grep -c ^processor /proc/cpuinfo` endif +BUILD_TARGETS=clickhouse $(DAEMONS) + configure-stamp: dh_testdir rm -rf build @@ -25,14 +27,13 @@ build-stamp: configure-stamp # последовательно запускаем make для каждой из целей. # т.к. при параллельном запуске (make target1 target2) несколько раз одновременно создаются бинарники # и возникает raise с custom_command, использующие эти бинарники - for daemon in clickhouse ${DAEMONS}; do $(MAKE) -j$(THREADS_COUNT) -C build $$daemon; done + for target in ${BUILD_TARGETS}; do $(MAKE) -j$(THREADS_COUNT) -C build $$target; done touch $@ clean: dh_testdir dh_testroot - rm -f configure-stamp - rm -f build-stamp + rm -f configure-stamp build-stamp rm -rf build # Удалим созданные для dh_installinit файлы find ./debian/ -name "*.init" -type l -delete @@ -50,9 +51,7 @@ install: build dh_testroot dh_prep cd build && \ - for daemon in clickhouse ${DAEMONS}; do\ - DESTDIR=../debian/tmp cmake -DCOMPONENT=$$daemon -P cmake_install.cmake;\ - done + for target in ${BUILD_TARGETS}; do DESTDIR=../debian/tmp cmake -DCOMPONENT=$$target -P cmake_install.cmake; done # Создаём нужные файлы для dh_installinit, т.к. он их понимает только внутри debian/ for I in debian/tmp/etc/init.d/*; do echo $$I; ln -s tmp/etc/init.d/`basename $$I` debian/`basename $$I`.init; done diff --git a/release_lib.sh b/release_lib.sh index cc4929dd9fa..5fadf985cd8 100644 --- a/release_lib.sh +++ b/release_lib.sh @@ -39,13 +39,13 @@ function make_control { add_daemon_impl clickhouse-server-common "clickhouse-server-base(=1.1.$REVISION)" 'Common configuration files for clickhouse-server-base package' ;; 'clickhouse-client' ) - add_daemon_impl clickhouse-client "clickhouse-server-base(=1.1.$REVISION)" "ClickHouse client" + add_daemon_impl clickhouse-client "clickhouse-server-base(=1.1.$REVISION)" "ClickHouse client and additional tools such as clickhouse-local and clickhouse-benchmark." ;; 'clickhouse-benchmark' ) - add_daemon_impl clickhouse-benchmark "clickhouse-server-base(=1.1.$REVISION)" "ClickHouse benchmark tool" + #skip it explicitly ;; 'clickhouse-local' ) - add_daemon_impl clickhouse-local "clickhouse-server-base(=1.1.$REVISION)" "ClickHouse local server application" + #skip it explicitly ;; * ) add_daemon_impl "${DAEMON_PKG}-metrika-yandex"