diff --git a/grpc-build.diff b/grpc-build.diff new file mode 100644 index 0000000..30a2302 --- /dev/null +++ b/grpc-build.diff @@ -0,0 +1,26 @@ +From: Jan Engelhardt +Date: 2017-12-12 00:32:39.501708666 +0100 + +openSUSE's c-ares has no c-aresConfig.cmake or c-ares-config.cmake. +Work around it. +--- + CMakeLists.txt | 6 +----- + 1 file changed, 1 insertion(+), 5 deletions(-) + +Index: grpc-1.7.3/CMakeLists.txt +=================================================================== +--- grpc-1.7.3.orig/CMakeLists.txt ++++ grpc-1.7.3/CMakeLists.txt +@@ -144,11 +144,7 @@ if("${gRPC_CARES_PROVIDER}" STREQUAL "mo + set(gRPC_INSTALL FALSE) + endif() + elseif("${gRPC_CARES_PROVIDER}" STREQUAL "package") +- find_package(c-ares REQUIRED CONFIG) +- if(TARGET c-ares::cares) +- set(_gRPC_CARES_LIBRARIES c-ares::cares) +- endif() +- set(_gRPC_FIND_CARES "if(NOT c-ares_FOUND)\n find_package(c-ares CONFIG)\nendif()") ++ set(_gRPC_CARES_LIBRARIES -lcares) + endif() + + if("${gRPC_PROTOBUF_PROVIDER}" STREQUAL "module") diff --git a/grpc-protobuf.diff b/grpc-protobuf.diff deleted file mode 100644 index fda4c5c..0000000 --- a/grpc-protobuf.diff +++ /dev/null @@ -1,24 +0,0 @@ - -[ 12s] CMakeFiles/grpc_plugin_support.dir/src/compiler/csharp_generator.cc.o: In function `grpc_csharp_generator::(anonymous namespace)::GetMethodRequestParamMaybe(google::protobuf::MethodDescriptor const*, bool)': -[ 12s] /home/abuild/rpmbuild/BUILD/grpc-1.2.3/src/compiler/csharp_generator.cc:236: undefined reference to `google::protobuf::compiler::csharp::GetClassName[abi:cxx11](google::protobuf::Descriptor const*)' - ---- - CMakeLists.txt | 5 +++++ - 1 file changed, 5 insertions(+) - -Index: grpc-1.2.3/CMakeLists.txt -=================================================================== ---- grpc-1.2.3.orig/CMakeLists.txt -+++ grpc-1.2.3/CMakeLists.txt -@@ -166,6 +166,11 @@ elseif("${gRPC_PROTOBUF_PROVIDER}" STREQ - set(_gRPC_FIND_PROTOBUF "if(NOT protobuf_FOUND)\n find_package(protobuf CONFIG)\nendif()") - else() - find_package(Protobuf MODULE) -+ if(PROTOBUF_FOUND) -+ set(_gRPC_PROTOBUF_PROTOC_LIBRARIES ${PROTOBUF_PROTOC_LIBRARIES}) -+ set(_gRPC_PROTOBUF_PROTOC ${PROTOBUF_PROTOC_EXECUTABLE}) -+ set(_gRPC_PROTOBUF_LIBRARIES ${PROTOBUF_LIBRARIES}) -+ endif() - set(_gRPC_FIND_PROTOBUF "if(NOT Protobuf_FOUND)\n find_package(Protobuf)\nendif()") - endif() - endif() diff --git a/grpc-versioning.diff b/grpc-versioning.diff index 19ad246..670f48d 100644 --- a/grpc-versioning.diff +++ b/grpc-versioning.diff @@ -4,46 +4,46 @@ Date: 2017-04-19 10:07:43.563879307 +0200 Unversioned libraries are an ABI nightmare, so work around that in short order. --- - CMakeLists.txt | 10 ++++++++++ - 1 file changed, 10 insertions(+) + CMakeLists.txt | 11 +++++++++++ + 1 file changed, 11 insertions(+) -Index: grpc-1.2.3/CMakeLists.txt +Index: grpc-1.8.2/CMakeLists.txt =================================================================== ---- grpc-1.2.3.orig/CMakeLists.txt -+++ grpc-1.2.3/CMakeLists.txt -@@ -735,6 +735,7 @@ add_library(gpr - src/core/lib/support/tmpfile_windows.c - src/core/lib/support/wrap_memcpy.c +--- grpc-1.8.2.orig/CMakeLists.txt ++++ grpc-1.8.2/CMakeLists.txt +@@ -825,6 +825,7 @@ add_library(gpr + src/core/lib/support/tmpfile_windows.cc + src/core/lib/support/wrap_memcpy.cc ) +set_target_properties(gpr PROPERTIES OUTPUT_NAME "gpr-${PACKAGE_VERSION}") if(WIN32 AND MSVC) set_target_properties(gpr PROPERTIES COMPILE_PDB_NAME "gpr" -@@ -1083,6 +1084,7 @@ add_library(grpc - src/core/ext/census/tracing.c - src/core/plugin_registry/grpc_plugin_registry.c +@@ -1205,6 +1206,7 @@ add_library(grpc + src/core/ext/filters/workarounds/workaround_utils.cc + src/core/plugin_registry/grpc_plugin_registry.cc ) +set_target_properties(grpc PROPERTIES OUTPUT_NAME "grpc-${PACKAGE_VERSION}") if(WIN32 AND MSVC) set_target_properties(grpc PROPERTIES COMPILE_PDB_NAME "grpc" -@@ -1364,6 +1366,7 @@ add_library(grpc_cronet - src/core/ext/load_reporting/load_reporting_filter.c - src/core/plugin_registry/grpc_cronet_plugin_registry.c +@@ -1519,6 +1521,7 @@ add_library(grpc_cronet + src/core/ext/filters/load_reporting/server_load_reporting_plugin.cc + src/core/plugin_registry/grpc_cronet_plugin_registry.cc ) +set_target_properties(grpc_cronet PROPERTIES OUTPUT_NAME "grpc_cronet-${PACKAGE_VERSION}") if(WIN32 AND MSVC) set_target_properties(grpc_cronet PROPERTIES COMPILE_PDB_NAME "grpc_cronet" -@@ -1909,6 +1912,7 @@ add_library(grpc_unsecure - src/core/ext/census/tracing.c - src/core/plugin_registry/grpc_unsecure_plugin_registry.c +@@ -2361,6 +2364,7 @@ add_library(grpc_unsecure + src/core/ext/filters/workarounds/workaround_utils.cc + src/core/plugin_registry/grpc_unsecure_plugin_registry.cc ) +set_target_properties(grpc_unsecure PROPERTIES OUTPUT_NAME "grpc_unsecure-${PACKAGE_VERSION}") if(WIN32 AND MSVC) set_target_properties(grpc_unsecure PROPERTIES COMPILE_PDB_NAME "grpc_unsecure" -@@ -2110,6 +2114,7 @@ add_library(grpc++ +@@ -2576,6 +2580,7 @@ add_library(grpc++ src/cpp/util/time_cc.cc src/cpp/codegen/codegen_init.cc ) @@ -51,7 +51,7 @@ Index: grpc-1.2.3/CMakeLists.txt if(WIN32 AND MSVC) set_target_properties(grpc++ PROPERTIES COMPILE_PDB_NAME "grpc++" -@@ -2479,6 +2484,7 @@ add_library(grpc++_cronet +@@ -3062,6 +3067,7 @@ add_library(grpc++_cronet third_party/nanopb/pb_decode.c third_party/nanopb/pb_encode.c ) @@ -59,7 +59,15 @@ Index: grpc-1.2.3/CMakeLists.txt if(WIN32 AND MSVC) set_target_properties(grpc++_cronet PROPERTIES COMPILE_PDB_NAME "grpc++_cronet" -@@ -2700,6 +2706,7 @@ add_library(grpc++_reflection +@@ -3262,6 +3268,7 @@ add_library(grpc++_error_details + ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/status/status.grpc.pb.h + src/cpp/util/error_details.cc + ) ++set_target_properties(grpc++_error_details PROPERTIES OUTPUT_NAME "grpc++_error_details-${PACKAGE_VERSION}") + + if(WIN32 AND MSVC) + set_target_properties(grpc++_error_details PROPERTIES COMPILE_PDB_NAME "grpc++_error_details" +@@ -3388,6 +3395,7 @@ add_library(grpc++_reflection ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/reflection/v1alpha/reflection.pb.h ${_gRPC_PROTO_GENS_DIR}/src/proto/grpc/reflection/v1alpha/reflection.grpc.pb.h ) @@ -67,15 +75,15 @@ Index: grpc-1.2.3/CMakeLists.txt if(WIN32 AND MSVC) set_target_properties(grpc++_reflection PROPERTIES COMPILE_PDB_NAME "grpc++_reflection" -@@ -2967,6 +2974,7 @@ add_library(grpc++_unsecure - src/cpp/util/time_cc.cc +@@ -3515,6 +3523,7 @@ add_library(grpc++_test_util + test/cpp/util/test_credentials_provider.cc src/cpp/codegen/codegen_init.cc ) +set_target_properties(grpc++_unsecure PROPERTIES OUTPUT_NAME "grpc++_unsecure-${PACKAGE_VERSION}") if(WIN32 AND MSVC) - set_target_properties(grpc++_unsecure PROPERTIES COMPILE_PDB_NAME "grpc++_unsecure" -@@ -3226,6 +3234,7 @@ add_library(grpc_plugin_support + set_target_properties(grpc++_test_util PROPERTIES COMPILE_PDB_NAME "grpc++_test_util" +@@ -4124,6 +4133,7 @@ add_library(grpc_plugin_support src/compiler/python_generator.cc src/compiler/ruby_generator.cc ) @@ -83,7 +91,7 @@ Index: grpc-1.2.3/CMakeLists.txt if(WIN32 AND MSVC) set_target_properties(grpc_plugin_support PROPERTIES COMPILE_PDB_NAME "grpc_plugin_support" -@@ -3703,6 +3712,7 @@ endif (gRPC_BUILD_TESTS) +@@ -4633,6 +4643,7 @@ endif (gRPC_BUILD_TESTS) add_library(grpc_csharp_ext SHARED src/csharp/ext/grpc_csharp_ext.c ) diff --git a/grpc-zlib.diff b/grpc-zlib.diff deleted file mode 100644 index 66ddca9..0000000 --- a/grpc-zlib.diff +++ /dev/null @@ -1,37 +0,0 @@ -[ 24s] CMakeFiles/grpc_unsecure.dir/src/core/lib/compression/message_compress.c.o: In function `zlib_compress': -[ 24s] /home/abuild/rpmbuild/BUILD/grpc-1.2.3/src/core/lib/compression/message_compress.c:112: undefined reference to `deflateInit2_' - ---- - CMakeLists.txt | 5 +++-- - 1 file changed, 3 insertions(+), 2 deletions(-) - -Index: grpc-1.2.3/CMakeLists.txt -=================================================================== ---- grpc-1.2.3.orig/CMakeLists.txt -+++ grpc-1.2.3/CMakeLists.txt -@@ -121,7 +121,7 @@ if("${gRPC_ZLIB_PROVIDER}" STREQUAL "mod - elseif("${gRPC_ZLIB_PROVIDER}" STREQUAL "package") - find_package(ZLIB) - if(TARGET ZLIB::ZLIB) -- set(_gRPC_ZLIB_LIBRARIES ZLIB::ZLIB) -+ set(_gRPC_ZLIB_LIBRARIES ${ZLIB_LIBRARIES}) - endif() - set(_gRPC_FIND_ZLIB "if(NOT ZLIB_FOUND)\n find_package(ZLIB)\nendif()") - endif() -@@ -242,7 +242,7 @@ if(NOT MSVC) - endif() - - if(UNIX) -- set(_gRPC_ALLTARGETS_LIBRARIES dl rt m pthread) -+ set(_gRPC_ALLTARGETS_LIBRARIES dl rt m pthread z) - endif() - - if(WIN32 AND MSVC) -@@ -1392,6 +1392,7 @@ target_link_libraries(grpc_cronet - ${_gRPC_BASELIB_LIBRARIES} - ${_gRPC_SSL_LIBRARIES} - ${_gRPC_ALLTARGETS_LIBRARIES} -+ ${ZLIB_LIBRARIES} - gpr - ) - diff --git a/grpc.changes b/grpc.changes index 70582ab..e0c5cdf 100644 --- a/grpc.changes +++ b/grpc.changes @@ -1,3 +1,27 @@ +------------------------------------------------------------------- +Tue Jan 2 12:11:18 UTC 2018 - crrodriguez@opensuse.org + +- version 1.8.3 + * Eliminate superfluous log error messages + +------------------------------------------------------------------- +Thu Dec 21 12:05:39 UTC 2017 - jengelh@inai.de + +- Update to new upstream release 1.8.2 + * Several LB policies fixes (grpclb and pick_first) + +------------------------------------------------------------------- +Mon Dec 11 23:23:19 UTC 2017 - jengelh@inai.de + +- Update to new upstream release 1.7.3 + * Bugfixes in Load Balancing policies + * Add flow-control and bugfixes to in-process transport + * (C++) Async API extensions to improve multithreading support + and reduce the need for explicit synchronization + * (C++) Unary call API for generic (non-protobuf) RPCs +- Drop grpc-zlib.diff, grpc-protobuf.diff (fix included upstream) +- Add grpc-build.diff + ------------------------------------------------------------------- Wed Apr 19 11:57:55 UTC 2017 - jengelh@inai.de diff --git a/grpc.spec b/grpc.spec index 16f2631..ab2778c 100644 --- a/grpc.spec +++ b/grpc.spec @@ -1,7 +1,7 @@ # # spec file for package grpc # -# Copyright (c) 2017 SUSE LINUX GmbH, Nuernberg, Germany. +# Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany. # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -16,23 +16,23 @@ # -%define lname libgrpc-1_2_3 +%define lname libgrpc-1_8_3 Name: grpc -Version: 1.2.3 +Version: 1.8.3 Release: 0 Summary: HTTP/2-based Remote Procedure Call implementation -License: BSD-3-Clause +License: Apache-2.0 Group: Development/Tools/Building Url: http://grpc.io/ Source: https://github.com/grpc/grpc/archive/v%version.tar.gz -Patch1: grpc-protobuf.diff -Patch2: grpc-zlib.diff -Patch3: grpc-versioning.diff +Patch1: grpc-build.diff +Patch2: grpc-versioning.diff BuildRequires: cmake BuildRequires: gcc-c++ BuildRequires: pkg-config +BuildRequires: pkgconfig(libcares) BuildRequires: pkgconfig(openssl) >= 1.0.1 -BuildRequires: pkgconfig(protobuf) >= 3 +BuildRequires: pkgconfig(protobuf) >= 3.5 BuildRequires: pkgconfig(zlib) BuildRoot: %{_tmppath}/%{name}-%{version}-build @@ -61,7 +61,7 @@ applications that want to make use of the gRPC reference implementation. %prep %setup -q -%patch -P 1 -P 2 -P 3 -p1 +%patch -P 1 -P 2 -p1 %build make LIBDIR=x CONFIG=opt \ @@ -70,7 +70,11 @@ make LIBDIR=x CONFIG=opt \ %cmake \ -DgRPC_PROTOBUF_PROVIDER=package \ -DgRPC_SSL_PROVIDER=package \ - -DgRPC_ZLIB_PROVIDER=package + -DgRPC_ZLIB_PROVIDER=package \ + -DgRPC_CARES_PROVIDER=package \ + -DgRPC_INSTALL_BINDIR="%_bindir" \ + -DgRPC_INSTALL_INCLUDEDIR="%_includedir" \ + -DgRPC_INSTALL_LIBDIR="%_libdir" #[ 36%] Running gRPC C++ protocol buffer compiler on src/proto/grpc/reflection/v1alpha/reflection.proto #cd /home/abuild/rpmbuild/BUILD/grpc-1.2.3 && /usr/bin/protoc --grpc_out=/home/abuild/rpmbuild/BUILD/grpc-1.2.3/build/gens --cpp_out=/home/abuild/rpmbuild/BUILD/grpc-1.2.3/build/gens --plugin=protoc-gen-grpc=/home/abuild/rpmbuild/BUILD/grpc-1.2.3/build/grpc_cpp_plugin -I . src/proto/grpc/reflection/v1alpha/reflection.proto @@ -88,23 +92,23 @@ for i in "$b/%_libdir"/libg*-%version.so; do ln -s "${i##*/}" "${i%%-%version.so}.so" done -%post -n libgrpc-1_2_3 -p /sbin/ldconfig -%postun -n libgrpc-1_2_3 -p /sbin/ldconfig +%post -n %lname -p /sbin/ldconfig +%postun -n %lname -p /sbin/ldconfig -%files -n libgrpc-1_2_3 +%files -n %lname %defattr(-,root,root) %_libdir/libg*-%version.so %files devel %defattr(-,root,root) -%doc LICENSE PATENTS +%doc LICENSE %_bindir/* %_includedir/* -%_libdir/cmake/ %_libdir/pkgconfig/*.pc %_libdir/libgpr.so %_libdir/libgrpc++.so %_libdir/libgrpc++_cronet.so +%_libdir/libgrpc++_error_details.so %_libdir/libgrpc++_reflection.so %_libdir/libgrpc++_unsecure.so %_libdir/libgrpc.so @@ -112,5 +116,6 @@ done %_libdir/libgrpc_csharp_ext.so %_libdir/libgrpc_plugin_support.so %_libdir/libgrpc_unsecure.so +/usr/lib/cmake %changelog diff --git a/v1.2.3.tar.gz b/v1.2.3.tar.gz deleted file mode 100644 index ca0f17e..0000000 --- a/v1.2.3.tar.gz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:e07ac5a2c657c25d5628529ec051f2ae3fa69a1d8802125810cba0c35fed9adf -size 4453354 diff --git a/v1.8.3.tar.gz b/v1.8.3.tar.gz new file mode 100644 index 0000000..7897d37 --- /dev/null +++ b/v1.8.3.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c14bceddc6475a09927a815811a8161cdfa7acb445262835da6bc24da9842c92 +size 4629844