mirror of
https://github.com/microsoft/vcpkg.git
synced 2024-11-28 01:19:00 +08:00
[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
This commit is contained in:
parent
20562031cd
commit
d6150f960c
@ -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 {
|
||||
|
@ -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()
|
15
ports/clickhouse-cpp/fix-error-C4996.patch
Normal file
15
ports/clickhouse-cpp/fix-error-C4996.patch
Normal file
@ -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
|
13
ports/clickhouse-cpp/fix-error-c2668.patch
Normal file
13
ports/clickhouse-cpp/fix-error-c2668.patch
Normal file
@ -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);
|
||||
}
|
@ -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)
|
||||
|
@ -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
|
||||
}
|
||||
]
|
||||
}
|
||||
|
@ -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",
|
||||
|
@ -1,5 +1,10 @@
|
||||
{
|
||||
"versions": [
|
||||
{
|
||||
"git-tree": "14c4074d1a59fbe8b01ebe934698519c63885b8b",
|
||||
"version": "1.5.0",
|
||||
"port-version": 0
|
||||
},
|
||||
{
|
||||
"git-tree": "a748366b06afe85b514215e2d27832304581b811",
|
||||
"version-string": "2019-05-22",
|
||||
|
Loading…
Reference in New Issue
Block a user