aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJonLiu1993 <63675417+JonLiu1993@users.noreply.github.com>2021-09-17 22:53:30 +0800
committerGitHub <noreply@github.com>2021-09-17 07:53:30 -0700
commitd6150f960cd5f102ae46f27c1f39369cf30da8ae (patch)
tree63bdb1d2dbc71acf67afcbc4f3e0087c889b894e
parent20562031cda81fbd20aad4f542b2af903d4adaa6 (diff)
downloadvcpkg-d6150f960cd5f102ae46f27c1f39369cf30da8ae.tar.gz
vcpkg-d6150f960cd5f102ae46f27c1f39369cf30da8ae.zip
[clickhouse-cpp] update to 1.5.0 (#18330)
* [clickhouse-cpp] update to 1.2.2 * update version * [clickhouse-cpp] update to 1.5.0 * update version * fix error c4996 * update version * merge baseline.json * update baseline.json * add Add patch description * update version * Add patch comment * update version
-rw-r--r--ports/clickhouse-cpp/00001-fix-build.patch42
-rw-r--r--ports/clickhouse-cpp/CMakeLists.txt40
-rw-r--r--ports/clickhouse-cpp/fix-error-C4996.patch15
-rw-r--r--ports/clickhouse-cpp/fix-error-c2668.patch13
-rw-r--r--ports/clickhouse-cpp/portfile.cmake24
-rw-r--r--ports/clickhouse-cpp/vcpkg.json17
-rw-r--r--versions/baseline.json4
-rw-r--r--versions/c-/clickhouse-cpp.json5
8 files changed, 58 insertions, 102 deletions
diff --git a/ports/clickhouse-cpp/00001-fix-build.patch b/ports/clickhouse-cpp/00001-fix-build.patch
deleted file mode 100644
index 8fb57d50e..000000000
--- a/ports/clickhouse-cpp/00001-fix-build.patch
+++ /dev/null
@@ -1,42 +0,0 @@
-diff --git a/clickhouse/base/compressed.cpp b/clickhouse/base/compressed.cpp
-index 6b7af08..c3a6449 100644
---- a/clickhouse/base/compressed.cpp
-+++ b/clickhouse/base/compressed.cpp
-@@ -1,8 +1,8 @@
- #include "compressed.h"
- #include "wire_format.h"
-
--#include <cityhash/city.h>
--#include <lz4/lz4.h>
-+#include <city.h>
-+#include <lz4.h>
-
- #include <system_error>
-
-diff --git a/clickhouse/client.cpp b/clickhouse/client.cpp
-index 1053006..59950ab 100644
---- a/clickhouse/client.cpp
-+++ b/clickhouse/client.cpp
-@@ -8,8 +8,8 @@
-
- #include "columns/factory.h"
-
--#include <cityhash/city.h>
--#include <lz4/lz4.h>
-+#include <city.h>
-+#include <lz4.h>
-
- #include <assert.h>
- #include <atomic>
-diff --git a/clickhouse/types/types.h b/clickhouse/types/types.h
-index 8d453cd..69aa6a4 100644
---- a/clickhouse/types/types.h
-+++ b/clickhouse/types/types.h
-@@ -4,6 +4,7 @@
- #include <memory>
- #include <string>
- #include <vector>
-+#include <stdexcept>
-
- namespace clickhouse {
-
diff --git a/ports/clickhouse-cpp/CMakeLists.txt b/ports/clickhouse-cpp/CMakeLists.txt
deleted file mode 100644
index 08a597b39..000000000
--- a/ports/clickhouse-cpp/CMakeLists.txt
+++ /dev/null
@@ -1,40 +0,0 @@
-cmake_minimum_required(VERSION 3.13)
-project(clickhouse-cpp CXX)
-
-find_package(lz4 CONFIG REQUIRED)
-find_package(cityhash CONFIG REQUIRED)
-
-file(GLOB_RECURSE SOURCES "clickhouse/*.cpp")
-file(GLOB_RECURSE HEADERS RELATIVE "${CMAKE_CURRENT_SOURCE_DIR}" "clickhouse/*.h")
-
-add_library(clickhouse-cpp STATIC ${SOURCES})
-
-target_compile_definitions(clickhouse-cpp PRIVATE LZ4_DISABLE_DEPRECATE_WARNINGS)
-
-set_target_properties(clickhouse-cpp PROPERTIES
- CXX_STANDARD 11
- CXX_STANDARD_REQUIRED ON
-)
-
-target_include_directories(clickhouse-cpp PUBLIC
- $<INSTALL_INTERFACE:include>
- $<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}>
-)
-
-target_link_libraries(clickhouse-cpp
- PRIVATE lz4::lz4
- PRIVATE cityhash
-)
-
-install(TARGETS clickhouse-cpp EXPORT clickhouse-cpp-config
- RUNTIME DESTINATION bin
- ARCHIVE DESTINATION lib
- LIBRARY DESTINATION lib
-)
-
-install(EXPORT clickhouse-cpp-config DESTINATION share/cmake/clickhouse-cpp)
-
-foreach (HEADER ${HEADERS} )
- get_filename_component(HEADER_DIR ${HEADER} DIRECTORY)
- install(FILES ${HEADER} DESTINATION include/${HEADER_DIR})
-endforeach()
diff --git a/ports/clickhouse-cpp/fix-error-C4996.patch b/ports/clickhouse-cpp/fix-error-C4996.patch
new file mode 100644
index 000000000..8da054b57
--- /dev/null
+++ b/ports/clickhouse-cpp/fix-error-C4996.patch
@@ -0,0 +1,15 @@
+diff --git a/clickhouse/CMakeLists.txt b/clickhouse/CMakeLists.txt
+index 7e10ffd..cbbffdc 100644
+--- a/clickhouse/CMakeLists.txt
++++ b/clickhouse/CMakeLists.txt
+@@ -31,6 +31,10 @@ SET ( clickhouse-cpp-lib-src
+ query.cpp
+ )
+
++if (MSVC)
++ add_compile_options(/wd4996)
++endif()
++
+ ADD_LIBRARY (clickhouse-cpp-lib SHARED ${clickhouse-cpp-lib-src})
+ SET_TARGET_PROPERTIES(clickhouse-cpp-lib PROPERTIES LINKER_LANGUAGE CXX)
+ TARGET_LINK_LIBRARIES (clickhouse-cpp-lib
diff --git a/ports/clickhouse-cpp/fix-error-c2668.patch b/ports/clickhouse-cpp/fix-error-c2668.patch
new file mode 100644
index 000000000..4ad1df953
--- /dev/null
+++ b/ports/clickhouse-cpp/fix-error-c2668.patch
@@ -0,0 +1,13 @@
+diff --git a/clickhouse/columns/decimal.cpp b/clickhouse/columns/decimal.cpp
+index 7334bb1..41d43b6 100644
+--- a/clickhouse/columns/decimal.cpp
++++ b/clickhouse/columns/decimal.cpp
+@@ -27,7 +27,7 @@ inline bool mulOverflow(const Int128 & l, const T & r, Int128 * result)
+
+ #else
+ template <typename T>
+-inline bool getSignBit(const T & v)
++inline bool getSignBit(const T & (long double v))
+ {
+ return std::signbit(v);
+ }
diff --git a/ports/clickhouse-cpp/portfile.cmake b/ports/clickhouse-cpp/portfile.cmake
index d6ccf177b..5837fb88f 100644
--- a/ports/clickhouse-cpp/portfile.cmake
+++ b/ports/clickhouse-cpp/portfile.cmake
@@ -2,25 +2,23 @@ vcpkg_check_linkage(ONLY_STATIC_LIBRARY)
vcpkg_from_github(
OUT_SOURCE_PATH SOURCE_PATH
- REPO artpaul/clickhouse-cpp
- REF 1634d8b9e2f3183de1574344563d90557be3b305
- SHA512 bef74f624c2a777f8ec6b7e87ac3cc564e914bcecc639b3889695da56be4c90531309a8fd87054c2777580c36bc3b2d6e9c5690a6345018bf65a5294eeeb3390
+ REPO ClickHouse/clickhouse-cpp
+ REF 1415b5936a2ac2f084850b09057e05fb5798b2f1 #v1.5.0
+ SHA512 222b31b16744af64f0a874ec956568adcecb553e43f8d4a2d16c00d55b31015d917a4dc7bb30d5430a894459b1be5e05b292e2d0918bf6f5609046a60539f80f
HEAD_REF master
- PATCHES 00001-fix-build.patch
+ PATCHES
+ fix-error-c2668.patch
+ fix-error-C4996.patch #fix x64-uwp error:std::uncaught_exception() is deprecated in C++17
)
-file(COPY ${CMAKE_CURRENT_LIST_DIR}/CMakeLists.txt DESTINATION ${SOURCE_PATH})
-
-vcpkg_configure_cmake(
+vcpkg_cmake_configure(
SOURCE_PATH ${SOURCE_PATH}
- PREFER_NINJA
)
-vcpkg_install_cmake()
+vcpkg_cmake_install()
vcpkg_copy_pdbs()
-vcpkg_fixup_cmake_targets(CONFIG_PATH share/cmake/clickhouse-cpp)
-file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/include)
-file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/share)
+file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include")
+file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/share")
-configure_file(${SOURCE_PATH}/LICENSE ${CURRENT_PACKAGES_DIR}/share/clickhouse-cpp/copyright COPYONLY)
+configure_file("${SOURCE_PATH}/LICENSE" "${CURRENT_PACKAGES_DIR}/share/${PORT}/copyright" COPYONLY)
diff --git a/ports/clickhouse-cpp/vcpkg.json b/ports/clickhouse-cpp/vcpkg.json
index 2c5d6a4f3..e3a5b37f1 100644
--- a/ports/clickhouse-cpp/vcpkg.json
+++ b/ports/clickhouse-cpp/vcpkg.json
@@ -1,11 +1,18 @@
{
"name": "clickhouse-cpp",
- "version-string": "2019-05-22",
- "port-version": 1,
- "description": "C++ client for Yandex ClickHouse.",
- "homepage": "https://github.com/artpaul/clickhouse-cpp",
+ "version": "1.5.0",
+ "description": "C++ client for Yandex ClickHouse",
+ "homepage": "https://github.com/ClickHouse/clickhouse-cpp",
"dependencies": [
"cityhash",
- "lz4"
+ "lz4",
+ {
+ "name": "vcpkg-cmake",
+ "host": true
+ },
+ {
+ "name": "vcpkg-cmake-config",
+ "host": true
+ }
]
}
diff --git a/versions/baseline.json b/versions/baseline.json
index 09e0c72cd..1e8fd9aac 100644
--- a/versions/baseline.json
+++ b/versions/baseline.json
@@ -1361,8 +1361,8 @@
"port-version": 0
},
"clickhouse-cpp": {
- "baseline": "2019-05-22",
- "port-version": 1
+ "baseline": "1.5.0",
+ "port-version": 0
},
"clipp": {
"baseline": "2019-04-30",
diff --git a/versions/c-/clickhouse-cpp.json b/versions/c-/clickhouse-cpp.json
index 3da06ee91..12cd74ccb 100644
--- a/versions/c-/clickhouse-cpp.json
+++ b/versions/c-/clickhouse-cpp.json
@@ -1,6 +1,11 @@
{
"versions": [
{
+ "git-tree": "14c4074d1a59fbe8b01ebe934698519c63885b8b",
+ "version": "1.5.0",
+ "port-version": 0
+ },
+ {
"git-tree": "a748366b06afe85b514215e2d27832304581b811",
"version-string": "2019-05-22",
"port-version": 1