# HG changeset patch # User Sebastien Jodogne # Date 1561023502 -7200 # Node ID 11368fbbce2abd242b81837c53e9318c605ddbeb # Parent b388b9d81a1b6b293bc5be5e96623b2ea045e03f upgrade google-cloud-cpp to 0.10.0 diff -r b388b9d81a1b -r 11368fbbce2a Resources/CMake/GoogleCloudPlatform.cmake --- a/Resources/CMake/GoogleCloudPlatform.cmake Tue Jun 18 16:29:03 2019 +0200 +++ b/Resources/CMake/GoogleCloudPlatform.cmake Thu Jun 20 11:38:22 2019 +0200 @@ -1,13 +1,16 @@ +# From: google-cloud-cpp-0.10.0/google/cloud/CMakeLists.txt set(GOOGLE_CLOUD_CPP_VERSION_MAJOR 0) -set(GOOGLE_CLOUD_CPP_VERSION_MINOR 7) +set(GOOGLE_CLOUD_CPP_VERSION_MINOR 8) set(GOOGLE_CLOUD_CPP_VERSION_PATCH 0) + +# From: google-cloud-cpp-0.10.0/google/cloud/storage/CMakeLists.txt set(STORAGE_CLIENT_VERSION_MAJOR 1) -set(STORAGE_CLIENT_VERSION_MINOR 0) +set(STORAGE_CLIENT_VERSION_MINOR 1) set(STORAGE_CLIENT_VERSION_PATCH 0) -set(GCP_SOURCES_DIR ${CMAKE_BINARY_DIR}/google-cloud-cpp-0.9.0) -set(GCP_URL "http://orthanc.osimis.io/ThirdPartyDownloads/dicom-web/google-cloud-cpp-0.9.0.tar.gz") -set(GCP_MD5 "b7546b6b11d23dad6cf0c77ddf6c567b") +set(GCP_SOURCES_DIR ${CMAKE_BINARY_DIR}/google-cloud-cpp-0.10.0) +set(GCP_URL "http://orthanc.osimis.io/ThirdPartyDownloads/dicom-web/google-cloud-cpp-0.10.0.tar.gz") +set(GCP_MD5 "871aea324c95411cb98d407a6a6f6fb8") if (IS_DIRECTORY "${GCP_SOURCES_DIR}") set(FirstRun OFF) @@ -19,7 +22,7 @@ execute_process( COMMAND ${PATCH_EXECUTABLE} -p0 -N -i - ${CMAKE_CURRENT_LIST_DIR}/../Patches/google-cloud-cpp-0.9.0.patch + ${CMAKE_CURRENT_LIST_DIR}/../Patches/google-cloud-cpp-0.10.0.patch WORKING_DIRECTORY ${CMAKE_BINARY_DIR} RESULT_VARIABLE Failure ) diff -r b388b9d81a1b -r 11368fbbce2a Resources/Patches/google-cloud-cpp-0.10.0.patch --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/Resources/Patches/google-cloud-cpp-0.10.0.patch Thu Jun 20 11:38:22 2019 +0200 @@ -0,0 +1,33 @@ +diff -urEb google-cloud-cpp-0.10.0.orig/google/cloud/storage/internal/curl_wrappers.h google-cloud-cpp-0.10.0/google/cloud/storage/internal/curl_wrappers.h +--- google-cloud-cpp-0.10.0.orig/google/cloud/storage/internal/curl_wrappers.h 2019-06-20 11:35:05.764399365 +0200 ++++ google-cloud-cpp-0.10.0/google/cloud/storage/internal/curl_wrappers.h 2019-06-20 11:35:33.244398885 +0200 +@@ -15,6 +15,8 @@ + #ifndef GOOGLE_CLOUD_CPP_GOOGLE_CLOUD_STORAGE_INTERNAL_CURL_WRAPPERS_H_ + #define GOOGLE_CLOUD_CPP_GOOGLE_CLOUD_STORAGE_INTERNAL_CURL_WRAPPERS_H_ + ++#undef BUILDING_LIBCURL // Necessary for static linking against curl ++ + #include "google/cloud/storage/client_options.h" + #include "google/cloud/storage/internal/http_response.h" + #include "google/cloud/storage/version.h" +diff -urEb google-cloud-cpp-0.10.0.orig/google/cloud/storage/internal/openssl_util.cc google-cloud-cpp-0.10.0/google/cloud/storage/internal/openssl_util.cc +--- google-cloud-cpp-0.10.0.orig/google/cloud/storage/internal/openssl_util.cc 2019-06-20 11:35:05.760399365 +0200 ++++ google-cloud-cpp-0.10.0/google/cloud/storage/internal/openssl_util.cc 2019-06-20 11:36:06.432398304 +0200 +@@ -141,7 +141,7 @@ + } + + std::unique_ptr source( +- BIO_new_mem_buf(str.data(), static_cast(str.size())), &BIO_free); ++ BIO_new_mem_buf(const_cast(str.data()), static_cast(str.size())), &BIO_free); + auto bio = PushBase64Transcoding(std::move(source)); + + // We could compute the exact buffer size by looking at the number of padding +@@ -205,7 +205,7 @@ + } + + auto pem_buffer = std::unique_ptr( +- BIO_new_mem_buf(pem_contents.data(), ++ BIO_new_mem_buf(const_cast(pem_contents.data()), + static_cast(pem_contents.length())), + &BIO_free); + if (!pem_buffer) {