Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[cpr] Update to 1.6.2 #18386

Merged
merged 12 commits into from
Jun 21, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 3 additions & 4 deletions ports/cpr/001-cpr-config.patch
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
diff --git a/cpr/CMakeLists.txt b/cpr/CMakeLists.txt
index 563b785..20f8a54 100644
index 8061a14..e8daf19 100644
--- a/cpr/CMakeLists.txt
+++ b/cpr/CMakeLists.txt
@@ -20,6 +20,7 @@ add_library(cpr
@@ -21,6 +21,7 @@ add_library(cpr

add_library(cpr::cpr ALIAS cpr)

+target_include_directories(cpr PUBLIC $<INSTALL_INTERFACE:include>)
target_link_libraries(cpr PUBLIC CURL::libcurl) # todo should be private, but first dependencys in ssl_options need to be removed

# Set version for shared libraries.
@@ -28,4 +29,18 @@ set_target_properties(cpr
@@ -29,4 +30,18 @@ set_target_properties(cpr
VERSION ${${PROJECT_NAME}_VERSION}
SOVERSION ${${PROJECT_NAME}_VERSION_MAJOR})

Expand All @@ -30,4 +30,3 @@ index 563b785..20f8a54 100644
+if (NOT DISABLE_INSTALL_HEADERS)
+ install(DIRECTORY ${CMAKE_CURRENT_LIST_DIR}/../include/cpr DESTINATION include)
+endif()
\ No newline at end of file
5 changes: 0 additions & 5 deletions ports/cpr/CONTROL

This file was deleted.

17 changes: 0 additions & 17 deletions ports/cpr/enable-install.patch

This file was deleted.

13 changes: 13 additions & 0 deletions ports/cpr/fix-uwp.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 8575b2f..87de55c 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -46,7 +46,7 @@ message(STATUS "=======================================================")
include(GNUInstallDirs)
include(FetchContent)
include(cmake/code_coverage.cmake)
-include(cmake/sanitizer.cmake)
+#include(cmake/sanitizer.cmake)
include(cmake/gcc_analyze.cmake)

# SSL
13 changes: 9 additions & 4 deletions ports/cpr/portfile.cmake
Original file line number Diff line number Diff line change
@@ -1,21 +1,26 @@
vcpkg_check_linkage(ONLY_STATIC_LIBRARY)

if(VCPKG_TARGET_IS_UWP)
set(UWP_PATCH fix-uwp.patch)
endif()

vcpkg_from_github(
OUT_SOURCE_PATH SOURCE_PATH
REPO whoshuu/cpr
REF 41fbaca90160950f1397e0ffc6b58bd81063f131 # v1.5.2
SHA512 0c493eef3069c1067f2492e6bc91e20b415a03a9392cbe70d4fb40f64a71b601ec62a9bcf5ca7e5b5a6e74449904f3121503421f4653f5b55df6702121806977
REF f4622efcb59d84071ae11404ae61bd821c1c344b # v1.6.2
SHA512 7835b7613529798b5edaefc99c907bbc7144133a1fac62a2c9af09c8c7a09b2ea1864544c4c0385969ad3dc64806b8d258abbcd39add2004ed8428741286ff20
HEAD_REF master
PATCHES
001-cpr-config.patch
${UWP_PATCH}
)

vcpkg_configure_cmake(
SOURCE_PATH ${SOURCE_PATH}
PREFER_NINJA
OPTIONS
-DBUILD_CPR_TESTS=OFF
-DUSE_SYSTEM_CURL=ON
-DCPR_BUILD_TESTS=OFF
-DCPR_FORCE_USE_SYSTEM_CURL=ON
OPTIONS_DEBUG
-DDISABLE_INSTALL_HEADERS=ON
)
Expand Down
12 changes: 12 additions & 0 deletions ports/cpr/vcpkg.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
{
"name": "cpr",
"version-semver": "1.6.2",
"description": "C++ Requests is a simple wrapper around libcurl inspired by the excellent Python Requests project.",
"homepage": "https://github.com/whoshuu/cpr",
"dependencies": [
{
"name": "curl",
"default-features": false
}
]
}
2 changes: 1 addition & 1 deletion versions/baseline.json
Original file line number Diff line number Diff line change
Expand Up @@ -1469,7 +1469,7 @@
"port-version": 1
},
"cpr": {
"baseline": "1.5.2",
"baseline": "1.6.2",
"port-version": 0
},
"cpu-features": {
Expand Down
5 changes: 5 additions & 0 deletions versions/c-/cpr.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
{
"versions": [
{
"git-tree": "96762dddaeb7d520833ddc1d47a30f26c35c9f67",
"version-semver": "1.6.2",
"port-version": 0
},
{
"git-tree": "0a3303682963a35032b7203c69051cf2edfaf41a",
"version-string": "1.5.2",
Expand Down