From cccbdacc47a27d103fe250a05de5f14ec5fa5161 Mon Sep 17 00:00:00 2001 From: Arkady Shapkin Date: Thu, 7 Sep 2017 14:56:04 +0300 Subject: [PATCH] [grpc] Update version to 1.6.0 --- ports/grpc/CONTROL | 2 +- ports/grpc/disable-csharp-ext.patch | 22 ++++++++++------------ ports/grpc/portfile.cmake | 15 +++++++++++---- ports/grpc/revert-c019e05.patch | 18 ------------------ 4 files changed, 22 insertions(+), 35 deletions(-) delete mode 100644 ports/grpc/revert-c019e05.patch diff --git a/ports/grpc/CONTROL b/ports/grpc/CONTROL index d9654cddf..dca18735f 100644 --- a/ports/grpc/CONTROL +++ b/ports/grpc/CONTROL @@ -1,4 +1,4 @@ Source: grpc -Version: 1.4.1 +Version: 1.6.0 Build-Depends: zlib, openssl, protobuf, c-ares Description: An RPC library and framework \ No newline at end of file diff --git a/ports/grpc/disable-csharp-ext.patch b/ports/grpc/disable-csharp-ext.patch index 6cb9090ab..3b887c8b4 100644 --- a/ports/grpc/disable-csharp-ext.patch +++ b/ports/grpc/disable-csharp-ext.patch @@ -1,31 +1,29 @@ -diff --git a/CMakeLists.txt b/CMakeLists.txt -index c85a20a..99b2897 100644 ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -3694,6 +3694,7 @@ target_link_libraries(qps +--- a/CMakeLists.txt Tue Aug 29 22:24:15 2017 ++++ b/CMakeLists.txt Mon Sep 04 00:43:56 2017 +@@ -4574,6 +4574,8 @@ endif (gRPC_BUILD_TESTS) +option(gRPC_INSTALL_CSHARP_EXT "" ON) ++ add_library(grpc_csharp_ext SHARED src/csharp/ext/grpc_csharp_ext.c ) -@@ -3702,7 +3703,7 @@ if(WIN32 AND MSVC) +@@ -4582,7 +4584,7 @@ set_target_properties(grpc_csharp_ext PROPERTIES COMPILE_PDB_NAME "grpc_csharp_ext" COMPILE_PDB_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}" ) - if (gRPC_INSTALL) + if (gRPC_INSTALL AND gRPC_INSTALL_CSHARP_EXT) install(FILES ${CMAKE_CURRENT_BINARY_DIR}/grpc_csharp_ext.pdb - DESTINATION ${CMAKE_INSTALL_LIBDIR} OPTIONAL + DESTINATION ${gRPC_INSTALL_LIBDIR} OPTIONAL ) -@@ -3728,8 +3729,7 @@ target_link_libraries(grpc_csharp_ext - ) +@@ -4613,7 +4615,7 @@ + -- -if (gRPC_INSTALL) +if (gRPC_INSTALL AND gRPC_INSTALL_CSHARP_EXT) install(TARGETS grpc_csharp_ext EXPORT gRPCTargets - RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR} - LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} + RUNTIME DESTINATION ${gRPC_INSTALL_BINDIR} + LIBRARY DESTINATION ${gRPC_INSTALL_LIBDIR} diff --git a/ports/grpc/portfile.cmake b/ports/grpc/portfile.cmake index e26c758d0..49d64b909 100644 --- a/ports/grpc/portfile.cmake +++ b/ports/grpc/portfile.cmake @@ -12,17 +12,24 @@ endif() vcpkg_from_github( OUT_SOURCE_PATH SOURCE_PATH REPO grpc/grpc - REF v1.4.1 - SHA512 5028e4f881a41e4c4ddf770bd824d1d5de825f86d68dbbfab22e2a34ec0e46b27754b0f5b40cfc02b0d22a756b08056b100837b590745b5fdbdce9a803e59f8d + REF v1.6.0 + SHA512 70a68fecca43cfe8c94206fd39ad8f86e055eb2185ae8c90040cc35928f1102016775c66e83c3cc76690e44598764b215d884a206f8466d45b00e2c54593e682 HEAD_REF master ) +# fix from PR https://github.com/grpc/grpc/pull/12411 +vcpkg_download_distfile(CMAKE_ERROR_FIX_DIFF + URLS "https://github.com/grpc/grpc/commit/74c139a83987087f9e2d2e6b5d44c240d719061d.diff" + FILENAME "grpc-cmake-error-fix.diff" + SHA512 38cdff0e6db12276400cf4eec66aafdbfe34912a78a0604ced3b216d3a60e5b87464f9083fa5e5dfb4df1490ef10565cbe04d3f750f59c7e7e1a05334c0b528e +) + # Issue: https://github.com/grpc/grpc/issues/10759 vcpkg_apply_patches( SOURCE_PATH ${SOURCE_PATH} PATCHES - ${CMAKE_CURRENT_LIST_DIR}/revert-c019e05.patch ${CMAKE_CURRENT_LIST_DIR}/disable-csharp-ext.patch + ${CMAKE_ERROR_FIX_DIFF} ) if(VCPKG_CRT_LINKAGE STREQUAL static) @@ -52,7 +59,7 @@ vcpkg_configure_cmake( set(ENV{PATH} "$ENV{PATH};${CURRENT_INSTALLED_DIR}/bin;${CURRENT_INSTALLED_DIR}/debug/bin") vcpkg_install_cmake() -vcpkg_fixup_cmake_targets() +vcpkg_fixup_cmake_targets(CONFIG_PATH "lib/cmake/grpc") file(INSTALL ${SOURCE_PATH}/LICENSE DESTINATION ${CURRENT_PACKAGES_DIR}/share/grpc RENAME copyright) diff --git a/ports/grpc/revert-c019e05.patch b/ports/grpc/revert-c019e05.patch deleted file mode 100644 index afb5cfa71..000000000 --- a/ports/grpc/revert-c019e05.patch +++ /dev/null @@ -1,18 +0,0 @@ -diff --git a/CMakeLists.txt b/CMakeLists.txt -index b7555b1bc3..edbffea76c 100644 ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -14204,6 +14204,13 @@ endif (gRPC_BUILD_TESTS) - - - -+if (gRPC_INSTALL) -+ install(EXPORT gRPCTargets -+ DESTINATION ${CMAKE_INSTALL_CMAKEDIR} -+ NAMESPACE gRPC:: -+ ) -+endif() -+ - foreach(_config gRPCConfig gRPCConfigVersion) - configure_file(tools/cmake/${_config}.cmake.in - ${_config}.cmake @ONLY)