diff --git a/pkgs/servers/clickhouse/default.nix b/pkgs/servers/clickhouse/default.nix index 58a178a8b2ea..10de85b0d365 100644 --- a/pkgs/servers/clickhouse/default.nix +++ b/pkgs/servers/clickhouse/default.nix @@ -1,30 +1,35 @@ -{ stdenv, fetchFromGitHub, cmake, libtool, boost, cctz, double-conversion, gperftools -, icu, lz4, mysql, openssl, poco, re2, rdkafka, readline, sparsehash, unixODBC, zstd +{ stdenv, fetchFromGitHub, cmake, libtool +, boost, capnproto, cctz, clang-unwrapped, double-conversion, gperftools, icu +, libcpuid, libxml2, lld, llvm, lz4 , mysql, openssl, poco, re2, rdkafka +, readline, sparsehash, unixODBC, zstd }: stdenv.mkDerivation rec { name = "clickhouse-${version}"; - version = "1.1.54385"; + version = "18.1.0"; src = fetchFromGitHub { owner = "yandex"; repo = "ClickHouse"; rev = "v${version}-stable"; - sha256 = "0s290xnx9dil2lbxdir5p5zmakvq5h523gdwax2cb37606wg8yj7"; + sha256 = "1vsfnggf69xh91ndycdxwfz6m2bs7psaxf2bh04svgk1vzj2z4l0"; }; - patches = [ ./find-mysql.patch ./termcap.patch ]; - nativeBuildInputs = [ cmake libtool ]; buildInputs = [ - boost cctz double-conversion gperftools icu lz4 mysql.connector-c openssl poco - re2 rdkafka readline sparsehash unixODBC zstd + boost capnproto cctz clang-unwrapped double-conversion gperftools icu + libcpuid libxml2 lld llvm lz4 mysql.connector-c openssl poco re2 rdkafka + readline sparsehash unixODBC zstd ]; cmakeFlags = [ "-DENABLE_TESTS=OFF" "-DUNBUNDLED=ON" "-DUSE_STATIC_LIBRARIES=OFF" ]; + postInstall = '' + rm -rf $out/share/clickhouse-test + ''; + meta = with stdenv.lib; { homepage = https://clickhouse.yandex/; description = "Column-oriented database management system"; diff --git a/pkgs/servers/clickhouse/find-mysql.patch b/pkgs/servers/clickhouse/find-mysql.patch deleted file mode 100644 index 3a5ec5181d1a..000000000000 --- a/pkgs/servers/clickhouse/find-mysql.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- a/libs/libmysqlxx/cmake/find_mysqlclient.cmake -+++ b/libs/libmysqlxx/cmake/find_mysqlclient.cmake -@@ -24,7 +24,7 @@ if (ENABLE_MYSQL) - if (USE_STATIC_LIBRARIES) - find_library (STATIC_MYSQLCLIENT_LIB mariadbclient mysqlclient PATHS ${MYSQL_LIB_PATHS}) - else () -- find_library (MYSQLCLIENT_LIBRARIES mariadbclient mysqlclient PATHS ${MYSQL_LIB_PATHS}) -+ find_library (MYSQLCLIENT_LIBRARIES mariadbclient mysqlclient PATH_SUFFIXES mysql PATHS ${MYSQL_LIB_PATHS}) - endif () - - if (MYSQL_INCLUDE_DIR AND (STATIC_MYSQLCLIENT_LIB OR MYSQLCLIENT_LIBRARIES)) diff --git a/pkgs/servers/clickhouse/termcap.patch b/pkgs/servers/clickhouse/termcap.patch deleted file mode 100644 index e030d0956900..000000000000 --- a/pkgs/servers/clickhouse/termcap.patch +++ /dev/null @@ -1,25 +0,0 @@ -From c2105ecdf6a6cc1fbb4c1ae01475db6a65fee32f Mon Sep 17 00:00:00 2001 -From: Orivej Desh -Date: Mon, 27 Mar 2017 01:39:11 +0000 -Subject: [PATCH] Search for termcap in ncurses - ---- - cmake/find_readline_edit.cmake | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/cmake/find_readline_edit.cmake b/cmake/find_readline_edit.cmake -index 26f2768..f520ece 100644 ---- a/cmake/find_readline_edit.cmake -+++ b/cmake/find_readline_edit.cmake -@@ -7,7 +7,7 @@ endif () - - list(APPEND CMAKE_FIND_LIBRARY_SUFFIXES .so.2) - --find_library (TERMCAP_LIB NAMES termcap) -+find_library (TERMCAP_LIB NAMES ncurses) - find_library (EDIT_LIB NAMES edit) - - set(READLINE_INCLUDE_PATHS "/var/empty/local/var/empty/readline/include") --- -2.12.0 - diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 77dc96884b86..fa555153e572 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -12721,7 +12721,9 @@ with pkgs; clamsmtp = callPackage ../servers/mail/clamsmtp { }; - clickhouse = callPackage ../servers/clickhouse { }; + clickhouse = callPackage ../servers/clickhouse { + inherit (llvmPackages_6) clang-unwrapped lld llvm; + }; couchdb = callPackage ../servers/http/couchdb { spidermonkey = spidermonkey_1_8_5;