o6E8wBVrqTznsFMlZ4UGmXRoOtr41eXPEINB mHNqLMas6dZIvQxQek+yaLga8qoQRpTkrMefwkeR/PO46WrMq0peLyP9Nr/dCN9m/yvUjP Rr+oNEx031P1wwBPFeWIxQTGSvXV8vGW2nBOku7vYQSyjCLz95U+bRaayKRaWS9AMPbHxi VOq/yo55t/oXSjQdCOUZvUmfJKxjtN68eWIR9K8uXPwm77Une3tBmJAdonSzow== ARC-Authentication-Results: i=1; mx1.freebsd.org; none Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4dghxY6T8Qz1C13 for ; Tue, 30 Dec 2025 18:50:57 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 36d12 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Tue, 30 Dec 2025 18:50:57 +0000 To: ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org From: Guido Falsi Subject: git: 14821d60aad2 - main - databases/clickhouse-cpp: Add new port List-Id: Commit messages for all branches of the ports repository List-Archive: https://lists.freebsd.org/archives/dev-commits-ports-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-ports-all@freebsd.org Sender: owner-dev-commits-ports-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: madpilot X-Git-Repository: ports X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 14821d60aad2335e18bd68eec7cdfd9c3299ca9a Auto-Submitted: auto-generated Date: Tue, 30 Dec 2025 18:50:57 +0000 Message-Id: <69541f11.36d12.e88e767@gitrepo.freebsd.org> The branch main has been updated by madpilot: URL: https://cgit.FreeBSD.org/ports/commit/?id=14821d60aad2335e18bd68eec7cdfd9c3299ca9a commit 14821d60aad2335e18bd68eec7cdfd9c3299ca9a Author: Guido Falsi AuthorDate: 2025-12-30 18:48:29 +0000 Commit: Guido Falsi CommitDate: 2025-12-30 18:48:29 +0000 databases/clickhouse-cpp: Add new port clickhouse-cpp is the official C++ client library for ClickHouse, providing a fast and type-safe interface to ClickHouse using its native binary protocol. --- databases/Makefile | 1 + databases/clickhouse-cpp/Makefile | 41 ++++++++++++++++++++ databases/clickhouse-cpp/distinfo | 3 ++ .../files/patch-clickhouse_base_platform.h | 20 ++++++++++ .../files/patch-clickhouse_base_socket.cpp | 11 ++++++ .../files/patch-clickhouse_base_socket.h | 13 +++++++ databases/clickhouse-cpp/pkg-descr | 3 ++ databases/clickhouse-cpp/pkg-plist | 45 ++++++++++++++++++++++ 8 files changed, 137 insertions(+) diff --git a/databases/Makefile b/databases/Makefile index 6b460e4661e5..fdfd97ee7c56 100644 --- a/databases/Makefile +++ b/databases/Makefile @@ -31,6 +31,7 @@ SUBDIR += cego SUBDIR += cegobridge SUBDIR += clickhouse + SUBDIR += clickhouse-cpp SUBDIR += closql SUBDIR += cockroach SUBDIR += couchdb3 diff --git a/databases/clickhouse-cpp/Makefile b/databases/clickhouse-cpp/Makefile new file mode 100644 index 000000000000..0d049ac2dff8 --- /dev/null +++ b/databases/clickhouse-cpp/Makefile @@ -0,0 +1,41 @@ +PORTNAME= clickhouse-cpp +DISTVERSIONPREFIX= v +DISTVERSION= 2.6.0 +CATEGORIES= databases devel + +MAINTAINER= madpilot@FreeBSD.org +COMMENT= C++ client for ClickHouse +WWW= https://clickhouse.com/ + +LICENSE= APACHE20 + +ONLY_FOR_ARCHS= aarch64 amd64 +ONLY_FOR_ARCHS_REASON= only supported on aarch64 and amd64 + +LIB_DEPENDS= libabsl_base.so:devel/abseil \ + liblz4.so:archivers/liblz4 \ + libzstd.so:archivers/zstd + +USES= cmake +USE_GITHUB= yes +GH_ACCOUNT= clickhouse + +CMAKE_ON= WITH_OPENSSL \ + WITH_SYSTEM_ABSEIL \ + WITH_SYSTEM_LZ4 \ + WITH_SYSTEM_ZSTD + +OPTIONS_DEFINE= TEST +OPTIONS_SUB= yes + +TEST_RUN_DEPENDS= expect>0:lang/expect +TEST_CMAKE_BOOL= ENABLE_TESTS + +.include + +.if ${OPSYS} == FreeBSD +USES+= llvm:min=21 +CFLAGS+=-Wno-error=int-conversion +.endif + +.include diff --git a/databases/clickhouse-cpp/distinfo b/databases/clickhouse-cpp/distinfo new file mode 100644 index 000000000000..74f6c8278cab --- /dev/null +++ b/databases/clickhouse-cpp/distinfo @@ -0,0 +1,3 @@ +TIMESTAMP = 1763643899 +SHA256 (clickhouse-clickhouse-cpp-v2.6.0_GH0.tar.gz) = f694395ab49e7c2380297710761a40718278cefd86f4f692d3f8ce4293e1335f +SIZE (clickhouse-clickhouse-cpp-v2.6.0_GH0.tar.gz) = 1131214 diff --git a/databases/clickhouse-cpp/files/patch-clickhouse_base_platform.h b/databases/clickhouse-cpp/files/patch-clickhouse_base_platform.h new file mode 100644 index 000000000000..17d744498b1b --- /dev/null +++ b/databases/clickhouse-cpp/files/patch-clickhouse_base_platform.h @@ -0,0 +1,20 @@ +--- clickhouse/base/platform.h.orig 2025-09-20 19:59:03 UTC ++++ clickhouse/base/platform.h +@@ -2,6 +2,8 @@ + + #if defined(__linux__) + # define _linux_ ++#elif defined(__FreeBSD__) ++# define _freebsd_ + #elif defined(_WIN64) + # define _win64_ + # define _win32_ +@@ -20,7 +22,7 @@ + # define WIN32_LEAN_AND_MEAN 1 // don't include too much header automatically + #endif + +-#if defined(_linux_) || defined (_darwin_) ++#if defined(_linux_) || defined (_darwin_) || defined(_freebsd_) + # define _unix_ + #endif + diff --git a/databases/clickhouse-cpp/files/patch-clickhouse_base_socket.cpp b/databases/clickhouse-cpp/files/patch-clickhouse_base_socket.cpp new file mode 100644 index 000000000000..8ac3fca86d30 --- /dev/null +++ b/databases/clickhouse-cpp/files/patch-clickhouse_base_socket.cpp @@ -0,0 +1,11 @@ +--- clickhouse/base/socket.cpp.orig 2025-09-20 19:59:03 UTC ++++ clickhouse/base/socket.cpp +@@ -355,7 +355,7 @@ void Socket::SetTcpKeepAlive(int idle, int intvl, int + + #if defined(_unix_) + setsockopt(handle_, SOL_SOCKET, SO_KEEPALIVE, &val, sizeof(val)); +-# if defined(_linux_) ++# if defined(_linux_) || defined(_freebsd_) + setsockopt(handle_, IPPROTO_TCP, TCP_KEEPIDLE, &idle, sizeof(idle)); + # elif defined(_darwin_) + setsockopt(handle_, IPPROTO_TCP, TCP_KEEPALIVE, &idle, sizeof(idle)); diff --git a/databases/clickhouse-cpp/files/patch-clickhouse_base_socket.h b/databases/clickhouse-cpp/files/patch-clickhouse_base_socket.h new file mode 100644 index 000000000000..5831ca229e1e --- /dev/null +++ b/databases/clickhouse-cpp/files/patch-clickhouse_base_socket.h @@ -0,0 +1,13 @@ +--- clickhouse/base/socket.h.orig 2025-09-20 19:59:03 UTC ++++ clickhouse/base/socket.h +@@ -18,6 +18,10 @@ + # include + # include + ++# if defined(__FreeBSD__) ++# include ++# endif ++ + # if !defined(SOCKET) + # define SOCKET int + # endif diff --git a/databases/clickhouse-cpp/pkg-descr b/databases/clickhouse-cpp/pkg-descr new file mode 100644 index 000000000000..ef4c9e29e261 --- /dev/null +++ b/databases/clickhouse-cpp/pkg-descr @@ -0,0 +1,3 @@ +Clickhouse-cpp is the official C++ client library for ClickHouse, +providing a fast and type-safe interface to ClickHouse using its +native binary protocol. diff --git a/databases/clickhouse-cpp/pkg-plist b/databases/clickhouse-cpp/pkg-plist new file mode 100644 index 000000000000..3cc2c38591ed --- /dev/null +++ b/databases/clickhouse-cpp/pkg-plist @@ -0,0 +1,45 @@ +include/clickhouse/base/buffer.h +include/clickhouse/base/compressed.h +include/clickhouse/base/endpoints_iterator.h +include/clickhouse/base/input.h +include/clickhouse/base/open_telemetry.h +include/clickhouse/base/output.h +include/clickhouse/base/platform.h +include/clickhouse/base/projected_iterator.h +include/clickhouse/base/singleton.h +include/clickhouse/base/socket.h +include/clickhouse/base/string_utils.h +include/clickhouse/base/string_view.h +include/clickhouse/base/uuid.h +include/clickhouse/base/wire_format.h +include/clickhouse/block.h +include/clickhouse/client.h +include/clickhouse/columns/array.h +include/clickhouse/columns/column.h +include/clickhouse/columns/date.h +include/clickhouse/columns/decimal.h +include/clickhouse/columns/enum.h +include/clickhouse/columns/factory.h +include/clickhouse/columns/geo.h +include/clickhouse/columns/ip4.h +include/clickhouse/columns/ip6.h +include/clickhouse/columns/itemview.h +include/clickhouse/columns/lowcardinality.h +include/clickhouse/columns/map.h +include/clickhouse/columns/nothing.h +include/clickhouse/columns/nullable.h +include/clickhouse/columns/numeric.h +include/clickhouse/columns/string.h +include/clickhouse/columns/tuple.h +include/clickhouse/columns/utils.h +include/clickhouse/columns/uuid.h +include/clickhouse/error_codes.h +include/clickhouse/exceptions.h +include/clickhouse/protocol.h +include/clickhouse/query.h +include/clickhouse/server_exception.h +include/clickhouse/types/type_parser.h +include/clickhouse/types/types.h +include/clickhouse/version.h +lib/libcityhash.a +lib/libclickhouse-cpp-lib.a