ce88e01
# We need to use C++17 to link against the system abseil-cpp, or we get linker
fcd2e4f
# errors.
ce88e01
%global cpp_std 17
acc3813
fcd2e4f
# However, we also get linker errors building the tests if we link against the
fcd2e4f
# copy of gtest in Fedora (compiled with C++11). The exact root cause is not
fcd2e4f
# quite clear. We must therefore bundle a copy of gtest in the source RPM
fcd2e4f
# rather than using the system copy. This is to be discouraged, but there is no
fcd2e4f
# alternative in this case. It is not treated as a bundled library because it
fcd2e4f
# is used only at build time, and contributes nothing to the installed files.
dd1f248
# We take measures to verify this in %%check. As long as we are using our own
dd1f248
# copy, we use the exact same version as upstream.
dd1f248
%global gtest_commit 0e402173c97aea7a00749e825b194bfede4f2e45
dd1f248
#global gtest_version 1.11.0
ce88e01
%bcond_with system_gtest
acc3813
73418ca
# Bootstrapping breaks the circular dependency on python3dist(xds-protos),
73418ca
# which is packaged separately but ultimately generated from grpc sources using
73418ca
# the proto compilers in this package; the consequence is that we cannot build
3cbb553
# the python3-grpcio-admin or python3-grpcio-csds subpackages until after
3cbb553
# bootstrapping.
21e49a3
%bcond_with bootstrap
73418ca
ce88e01
# This must be enabled to get grpc_cli, which is apparently considered part of
ce88e01
# the tests by upstream. This is mentioned in
ce88e01
# https://github.com/grpc/grpc/issues/23432.
ce88e01
%bcond_without core_tests
34ecf95
426ac1e
# A great many of these tests (over 20%) fail. Any help in understanding these
426ac1e
# well enough to fix them or report them upstream is welcome.
426ac1e
%bcond_with python_aio_tests
426ac1e
33f1b89
%ifnarch s390x
33f1b89
%bcond_without python_gevent_tests
33f1b89
%else
9a72967
# A significant number of Python tests pass in test_lite but fail in
33f1b89
# test_gevent, mostly by dumping core without a traceback.  Since it is tedious
33f1b89
# to enumerate these (and it is difficult to implement “suite-specific” skips
33f1b89
# for shared tests, so the tests would have to be skipped in all suites), we
33f1b89
# just skip the gevent suite entirely on this architecture.
426ac1e
%bcond_with python_gevent_tests
33f1b89
%endif
426ac1e
dd1f248
# Running core tests under valgrind may help debug crashes. This is mostly
dd1f248
# ignored if the gdb build conditional is also set.
dd1f248
%bcond_with valgrind
dd1f248
# Running core tests under gdb may help debug crashes.
dd1f248
%bcond_with gdb
dd1f248
3cbb553
# HTML documentation generated with Doxygen and/or Sphinx is not suitable for
281a679
# packaging due to a minified JavaScript bundle inserted by
281a679
# Doxygen/Sphinx/Sphinx themes itself. See discussion at
281a679
# https://bugzilla.redhat.com/show_bug.cgi?id=2006555.
281a679
#
281a679
# Normally we could consider enabling the Doxygen PDF documentation as a lesser
281a679
# substitute, but (after enabling it and working around some Unicode characters
281a679
# in the Markdown input) we get:
281a679
#
281a679
#   ! TeX capacity exceeded, sorry [main memory size=6000000].
281a679
#
281a679
# A similar situation applies to the Sphinx-generated HTML documentation for
281a679
# Python, except that we have not even tried to render it as a PDF because it
281a679
# is too unpleasant to try if we already cannot package the Doxygen-generated
281a679
# documentation. Instead, we have just dropped all documentation.
281a679
87469ef
Name:           grpc
c8f6f84
Version:        1.46.3
1c408ac
Release:        %autorelease
87469ef
Summary:        RPC library and framework
87469ef
dd1f248
%global srcversion %(echo '%{version}' | sed -r 's/~rc/-pre/')
dd1f248
%global pyversion %(echo '%{version}' | tr -d '~')
dd1f248
7adc2b7
# CMakeLists.txt: gRPC_CORE_SOVERSION
dd1f248
%global c_so_version 24
7adc2b7
# CMakeLists.txt: gRPC_CPP_SOVERSION
9a14112
# See https://github.com/abseil/abseil-cpp/issues/950#issuecomment-843169602
dd1f248
# regarding unusual C++ SOVERSION style (not a single number).
dd1f248
%global cpp_so_version 1.46
7adc2b7
87469ef
# The entire source is ASL 2.0 except the following:
87469ef
#
87469ef
# BSD:
dd1f248
#   - third_party/upb/, except third_party/upb/third_party/lunit/ and
dd1f248
#     third_party/upb/third_party/utf8_range/
281a679
#     * Potentially linked into any compiled subpackage (but not pure-Python
281a679
#       subpackages, etc.)
87469ef
#   - third_party/address_sorting/
281a679
#     * Potentially linked into any compiled subpackage (but not pure-Python
281a679
#       subpackages, etc.)
87469ef
#
dd1f248
# MIT:
dd1f248
#   - third_party/upb/third_party/utf8_range
dd1f248
#     * Potentially linked into any compiled subpackage (but not pure-Python
dd1f248
#       subpackages, etc.)
dd1f248
#
87469ef
# as well as the following which do not contribute to the base License field or
87469ef
# any subpackage License field for the reasons noted:
87469ef
#
87469ef
# MPLv2.0:
87469ef
#   - etc/roots.pem
87469ef
#     * Truncated to an empty file in prep; a symlink to the shared system
87469ef
#       certificates is used instead
87469ef
#   - src/android/test/interop/app/src/main/assets/roots.pem
87469ef
#     * Truncated to an empty file in prep
87469ef
# ISC:
dd1f248
#   - src/boringssl/boringssl_prefix_symbols.h
87469ef
#     * Removed in prep; not used when building with system OpenSSL
87469ef
# BSD:
ce88e01
#   - src/objective-c/*.podspec and
ce88e01
#     templates/src/objective-c/*.podspec.template
87469ef
#     * Unused since the Objective-C bindings are not currently built
87469ef
# MIT:
87469ef
#   - third_party/cares/ares_build.h
87469ef
#     * Removed in prep; header from system C-Ares used instead
87469ef
#   - third_party/rake-compiler-dock/
87469ef
#     * Removed in prep, since we build no containers
87469ef
#   - third_party/upb/third_party/lunit/
87469ef
#     * Removed in prep, since there is no obvious way to run the upb tests
dd1f248
License:        ASL 2.0 and BSD and MIT
ef054cb
URL:            https://www.grpc.io
ef054cb
%global forgeurl https://github.com/grpc/grpc/
acc3813
# Used only at build time (not a bundled library); see notes at definition of
dd1f248
# gtest_commit/gtest_version macro for explanation and justification.
6abb104
%global gtest_url https://github.com/google/googletest
dd1f248
%global gtest_archivename googletest-%{gtest_commit}
dd1f248
#global gtest_archivename googletest-release-#{gtest_version}
dd1f248
Source0:        %{forgeurl}/archive/v%{srcversion}/grpc-%{srcversion}.tar.gz
dd1f248
Source1:        %{gtest_url}/archive/%{gtest_commit}/%{gtest_archivename}.tar.gz
dd1f248
#Source1:        #{gtest_url}/archive/release-#{gtest_version}/#{gtest_archivename}.tar.gz
87469ef
ce88e01
# Downstream grpc_cli man pages; hand-written based on “grpc_cli help” output.
ef054cb
Source100:      grpc_cli.1
ef054cb
Source101:      grpc_cli-ls.1
ef054cb
Source102:      grpc_cli-call.1
ef054cb
Source103:      grpc_cli-type.1
ef054cb
Source104:      grpc_cli-parse.1
ef054cb
Source105:      grpc_cli-totext.1
ef054cb
Source106:      grpc_cli-tojson.1
ef054cb
Source107:      grpc_cli-tobinary.1
ef054cb
Source108:      grpc_cli-help.1
ce88e01
87469ef
# ~~~~ C (core) and C++ (cpp) ~~~~
87469ef
87469ef
BuildRequires:  gcc-c++
34ecf95
BuildRequires:  cmake
34ecf95
BuildRequires:  ninja-build
ce88e01
%if %{with core_tests}
ce88e01
# Used on grpc_cli:
87469ef
BuildRequires:  chrpath
ce88e01
%endif
87469ef
5ab84a2
BuildRequires:  pkgconfig(zlib)
5ab84a2
BuildRequires:  cmake(gflags)
5ab84a2
BuildRequires:  pkgconfig(protobuf)
87469ef
BuildRequires:  protobuf-compiler
ce88e01
BuildRequires:  pkgconfig(re2)
5ab84a2
BuildRequires:  pkgconfig(openssl)
5ab84a2
BuildRequires:  cmake(c-ares)
ce88e01
BuildRequires:  abseil-cpp-devel
ec47db2
# Sets XXH_INCLUDE_ALL, which means xxhash is used as a header-only library
789220e
BuildRequires:  pkgconfig(libxxhash)
789220e
BuildRequires:  xxhash-static
34ecf95
34ecf95
%if %{with core_tests}
5ab84a2
BuildRequires:  cmake(benchmark)
acc3813
%if %{with system_gtest}
5ab84a2
BuildRequires:  cmake(gtest)
5ab84a2
BuildRequires:  pkgconfig(gmock)
34ecf95
%endif
dd1f248
%if %{with valgrind}
dd1f248
BuildRequires:  valgrind
dd1f248
%endif
dd1f248
%if %{with gdb}
dd1f248
BuildRequires:  gdb
dd1f248
%endif
acc3813
%endif
87469ef
87469ef
# ~~~~ Python ~~~~
87469ef
87469ef
BuildRequires:  python3-devel
986bbc8
BuildRequires:  python3dist(setuptools)
986bbc8
986bbc8
# grpcio (setup.py) setup_requires (with
281a679
#     GRPC_PYTHON_ENABLE_DOCUMENTATION_BUILD, which is NOT enabled):
281a679
# BuildRequires:  python3dist(sphinx)
986bbc8
986bbc8
# grpcio (setup.py) setup_requires (with
281a679
#     GRPC_PYTHON_ENABLE_DOCUMENTATION_BUILD, which is NOT enabled):
986bbc8
# grpcio_tests (src/python/grpcio_tests/setup.py) install_requires:
986bbc8
BuildRequires:  python3dist(six) >= 1.10
986bbc8
# grpcio (setup.py) install_requires also has:
986bbc8
#   six>=1.5.2
986bbc8
986bbc8
# grpcio (setup.py) setup_requires (with GRPC_PYTHON_BUILD_WITH_CYTHON, or
986bbc8
# absent generated sources); also needed for grpcio_tools
986bbc8
# (tools/distrib/python/grpcio_tools/setup.py)
3cbb553
BuildRequires:  python3dist(cython) > 0.23
986bbc8
986bbc8
# grpcio (setup.py) install_requires:
986bbc8
# grpcio_tests (src/python/grpcio_tests/setup.py) install_requires:
986bbc8
#   futures>=2.2.0; python_version<'3.2'
986bbc8
986bbc8
# grpcio (setup.py) install_requires:
986bbc8
# grpcio_tests (src/python/grpcio_tests/setup.py) install_requires:
986bbc8
#   enum34>=1.0.4; python_version<'3.4'
986bbc8
2933935
# grpcio_csds (src/python/grpcio_csds/setup.py) install_requires:
986bbc8
# grpcio_channelz (src/python/grpcio_channelz/setup.py) install_requires:
986bbc8
# grpcio_health_checking (src/python/grpcio_health_checking/setup.py)
986bbc8
#     install_requires:
986bbc8
# grpcio_reflection (src/python/grpcio_reflection/setup.py) install_requires:
986bbc8
# grpcio_status (src/python/grpcio_status/setup.py) install_requires:
986bbc8
# grpcio_testing (src/python/grpcio_testing/setup.py) install_requires:
986bbc8
# grpcio_tests (src/python/grpcio_tests/setup.py) install_requires:
dd1f248
# grpcio_tools (tools/distrib/python/grpcio_tools/setup.py) install_requires:
dd1f248
BuildRequires:  python3dist(protobuf) >= 3.12.0
986bbc8
986bbc8
# grpcio_status (src/python/grpcio_status/setup.py) install_requires:
986bbc8
BuildRequires:  python3dist(googleapis-common-protos) >= 1.5.5
986bbc8
2933935
%if %{without bootstrap}
2933935
# grpcio_csds (src/python/grpcio_csds/setup.py) install_requires
2933935
BuildRequires:  python3dist(xds-protos) >= 0.0.7
2933935
%endif
2933935
986bbc8
# Several packages have dependencies on grpcio or grpcio_tools—and grpcio-tests
986bbc8
# depends on all of the other Python packages—which are satisfied within this
986bbc8
# package.
2933935
#
2933935
# Similarly, grpcio_admin depends on grpcio_channelz and grpcio_csds.
986bbc8
986bbc8
# grpcio_tests (src/python/grpcio_tests/setup.py) install_requires:
986bbc8
BuildRequires:  python3dist(coverage) >= 4.0
986bbc8
986bbc8
# grpcio_tests (src/python/grpcio_tests/setup.py) install_requires:
986bbc8
BuildRequires:  python3dist(oauth2client) >= 1.4.7
986bbc8
986bbc8
# grpcio_tests (src/python/grpcio_tests/setup.py) install_requires:
3cbb553
BuildRequires:  python3dist(google-auth) >= 1.17.2
986bbc8
986bbc8
# grpcio_tests (src/python/grpcio_tests/setup.py) install_requires:
3cbb553
BuildRequires:  python3dist(requests) >= 2.14.2
986bbc8
dd1f248
%if %{with python_gevent_tests}
934e38f
# Required for “test_gevent” tests:
934e38f
BuildRequires:  python3dist(gevent)
dd1f248
%endif
87469ef
ce88e01
# For stopping the port server
ce88e01
BuildRequires:  curl
ce88e01
87469ef
# ~~~~ Miscellaneous ~~~~
87469ef
87469ef
# https://bugzilla.redhat.com/show_bug.cgi?id=1893533
87469ef
%global _lto_cflags %{nil}
87469ef
281a679
# Reference documentation, which is *not* enabled
281a679
# BuildRequires:  doxygen
119766d
87469ef
BuildRequires:  ca-certificates
87469ef
# For converting absolute symlinks in the buildroot to relative ones
87469ef
BuildRequires:  symlinks
87469ef
2229437
# Apply Fedora system crypto policies. Since this is Fedora-specific, the patch
2229437
# is not suitable for upstream.
87469ef
# https://docs.fedoraproject.org/en-US/packaging-guidelines/CryptoPolicies/#_cc_applications
2933935
#
2933935
# In fact, this may not be needed, since only testing code is patched.
dd1f248
Patch:          grpc-1.39.0-system-crypto-policies.patch
ce88e01
# Add an option GRPC_PYTHON_BUILD_SYSTEM_ABSL to go with the gRPC_ABSL_PROVIDER
ce88e01
# option already provided upstream. See
ce88e01
# https://github.com/grpc/grpc/issues/25559.
dd1f248
Patch:          grpc-1.40.0-python-grpcio-use-system-abseil.patch
53fe707
# Fix errors like:
53fe707
#   TypeError: super(type, obj): obj must be an instance or subtype of type
53fe707
# It is not clear why these occur.
dd1f248
Patch:          grpc-1.36.4-python-grpcio_tests-fixture-super.patch
53fe707
# Skip tests requiring non-loopback network access when the
53fe707
# FEDORA_NO_NETWORK_TESTS environment variable is set.
dd1f248
Patch:          grpc-1.40.0-python-grpcio_tests-make-network-tests-skippable.patch
53fe707
# A handful of compression tests miss the compression ratio threshold. It seems
53fe707
# to be inconsistent which particular combinations fail in a particular test
53fe707
# run. It is not clear that this is a real problem. Any help in understanding
53fe707
# the actual cause well enough to fix this or usefully report it upstream is
53fe707
# welcome.
dd1f248
Patch:          grpc-1.36.4-python-grpcio_tests-skip-compression-tests.patch
ce88e01
# The upstream requirement to link gtest/gmock from grpc_cli is spurious.
ce88e01
# Remove it. We still have to build the core tests and link a test library
ce88e01
# (libgrpc++_test_config.so…)
dd1f248
Patch:          grpc-1.37.0-grpc_cli-do-not-link-gtest-gmock.patch
2933935
# Fix confusion about path to python_wrapper.sh in httpcli/httpscli tests. I
2933935
# suppose that the unpatched code must be correct for how upstream runs the
2933935
# tests, somehow.
dd1f248
Patch:          grpc-1.45.0-python_wrapper-path.patch
dd1f248
# Do not segfault when peer CN is absent
dd1f248
Patch:          %{forgeurl}/pull/29359.patch
dd1f248
# Fix a segfault in client_lb_end2end_test
dd1f248
#
dd1f248
# In the SubchannelStreamClient constructor, do not initialize an
dd1f248
# absl::string_view with a null pointer; this lead to strlen() being
dd1f248
# called on the null pointer. Let the absl::string_view be empty in this
dd1f248
# case instead.
dd1f248
#
dd1f248
# Fixes #29567.
d8f3851
#
dd1f248
# “Segfault in client_lb_end2end_test due to absl::string_view(nullptr)”
dd1f248
# https://github.com/grpc/grpc/issues/29567
dd1f248
Patch:          %{forgeurl}/pull/29568.patch
131fe89
# Use gRPC_INSTALL_LIBDIR for pkgconfig files
131fe89
# https://github.com/grpc/grpc/pull/29826
131fe89
#
131fe89
# Fixes:
131fe89
#
131fe89
# Should install pkgconfig files under gRPC_INSTALL_LIBDIR
131fe89
# https://github.com/grpc/grpc/issues/25635
131fe89
Patch:          %{forgeurl}/pull/29826.patch
c95fe27
# Replace deprecated Python “inspect.getargspec”
c95fe27
# https://github.com/grpc/grpc/pull/29963
c95fe27
#
c95fe27
# Fixes:
c95fe27
#
c95fe27
# Uses deprecated “inspect.getargspec”, removed in Python 3.11
c95fe27
# https://github.com/grpc/grpc/issues/29962
c95fe27
#
c95fe27
# Partially fixes:
c95fe27
#
c95fe27
# grpc fails to build with Python 3.11: AttributeError: module 'inspect' has no
c95fe27
#   attribute 'getargspec'
c95fe27
# https://bugzilla.redhat.com/show_bug.cgi?id=2095027
c95fe27
Patch:          %{forgeurl}/pull/29963.patch
2884d9b
# Skip failing ChannelzServicerTest tests on Python 3.11
2884d9b
#
2884d9b
# Partially works around:
2884d9b
#
2884d9b
# grpc fails to build with Python 3.11: AttributeError: module 'inspect' has no
2884d9b
#   attribute 'getargspec'
2884d9b
# https://bugzilla.redhat.com/show_bug.cgi?id=2095027
2884d9b
#
2884d9b
# TODO: Attempt to reproduce this outside the RPM build environment and submit
2884d9b
# a useful/actionable upstream bug report.
2884d9b
Patch:          grpc-1.46.3-ChannelzServicerTest-python3.11-regressions.patch
87469ef
ef054cb
Requires:       grpc-data = %{version}-%{release}
87469ef
87469ef
# Upstream https://github.com/protocolbuffers/upb does not support building
87469ef
# with anything other than Bazel, and Bazel is not likely to make it into
87469ef
# Fedora anytime soon due to its nightmarish collection of dependencies.
87469ef
# Monitor this at https://bugzilla.redhat.com/show_bug.cgi?id=1470842.
ce88e01
# Therefore upb cannot be packaged for Fedora, and we must use the bundled
ce88e01
# copy.
87469ef
#
87469ef
# Note that upstream has never chosen a version, and it is not clear from which
87469ef
# commit the bundled copy was taken or forked.
87469ef
#
87469ef
# Note also that libupb is installed in the system-wide linker path, which will
87469ef
# be a problem if upb is ever packaged separately. We will cross that bridge if
87469ef
# we get there.
87469ef
Provides:       bundled(upb)
dd1f248
# The bundled upb itself bundles https://github.com/cyb70289/utf8; we follow
dd1f248
# upstream in styling this as “utf8_range”. It cannot reasonably be unbundled
dd1f248
# because the original code is not structured for distribution as a library (it
dd1f248
# does not even include header files). It is not clear which upstream commit
dd1f248
# was used.
dd1f248
Provides:       bundled(utf8_range)
87469ef
87469ef
# Regarding third_party/address_sorting: this looks a bit like a bundled
87469ef
# library, but it is not. From a source file comment:
87469ef
#   This is an adaptation of Android's implementation of RFC 6724 (in Android’s
87469ef
#   getaddrinfo.c). It has some cosmetic differences from Android’s
87469ef
#   getaddrinfo.c, but Android’s getaddrinfo.c was used as a guide or example
87469ef
#   of a way to implement the RFC 6724 spec when this was written.
b3bb2c6
bf7e9a8
%description
bf7e9a8
gRPC is a modern open source high performance RPC framework that can run in any
bf7e9a8
environment. It can efficiently connect services in and across data centers
bf7e9a8
with pluggable support for load balancing, tracing, health checking and
bf7e9a8
authentication. It is also applicable in last mile of distributed computing to
bf7e9a8
connect devices, mobile applications and browsers to backend services.
bf7e9a8
bf7e9a8
The main usage scenarios:
bf7e9a8
ce88e01
  • Efficiently connecting polyglot services in microservices style
ce88e01
    architecture
56e498c
  • Connecting mobile devices, browser clients to backend services
56e498c
  • Generating efficient client libraries
bf7e9a8
bf7e9a8
Core Features that make it awesome:
bf7e9a8
56e498c
  • Idiomatic client libraries in 10 languages
56e498c
  • Highly efficient on wire and with a simple service definition framework
56e498c
  • Bi-directional streaming with http/2 based transport
56e498c
  • Pluggable auth, tracing, load balancing and health checking
87469ef
87469ef
This package provides the shared C core library.
87469ef
87469ef
87469ef
%package data
87469ef
Summary:        Data for gRPC bindings
87469ef
License:        ASL 2.0
87469ef
BuildArch:      noarch
87469ef
87469ef
Requires:       ca-certificates
87469ef
87469ef
%description data
87469ef
Common data for gRPC bindings: currently, this contains only a symbolic link to
87469ef
the system shared TLS certificates.
87469ef
87469ef
87469ef
%package doc
87469ef
Summary:        Documentation and examples for gRPC
87469ef
License:        ASL 2.0
87469ef
BuildArch:      noarch
87469ef
119766d
Obsoletes:      python-grpcio-doc < 1.26.0-13
119766d
Provides:       python-grpcio-doc = %{version}-%{release}
2933935
Provides:       python-grpcio-admin-doc = %{version}-%{release}
2933935
Provides:       python-grpcio-csds-doc = %{version}-%{release}
119766d
Provides:       python-grpcio-channelz-doc = %{version}-%{release}
119766d
Provides:       python-grpcio-health-checking-doc = %{version}-%{release}
119766d
Provides:       python-grpcio-reflection-doc = %{version}-%{release}
119766d
Provides:       python-grpcio-status-doc = %{version}-%{release}
119766d
Provides:       python-grpcio-testing-doc = %{version}-%{release}
119766d
87469ef
%description doc
281a679
Documentation and examples for gRPC, including Markdown documentation sources
281a679
for the following:
119766d
119766d
  • C (core)
119766d
    ○ API
119766d
    ○ Internals
119766d
  • C++
119766d
    ○ API
119766d
    ○ Internals
119766d
  • Objective C
119766d
    ○ API
119766d
    ○ Internals
119766d
  • Python
119766d
    ○ grpcio
2933935
    ○ grpcio_admin
2933935
    ○ grpcio_csds
119766d
    ○ grpcio_channelz
119766d
    ○ grpcio_health_checking
119766d
    ○ grpcio_reflection
119766d
    ○ grpcio_status
119766d
    ○ grpcio_testing
87469ef
281a679
For rendered HTML documentation, please see https://grpc.io/docs/.
281a679
87469ef
87469ef
%package cpp
87469ef
Summary:        C++ language bindings for gRPC
87469ef
# License:        same as base package
71f7178
6c62f34
Requires:       grpc%{?_isa} = %{version}-%{release}
2b22037
Requires:       grpc-cpp%{?_isa} = %{version}-%{release}
87469ef
71f7178
Provides:       bundled(upb)
dd1f248
Provides:       bundled(utf8_range)
71f7178
87469ef
%description cpp
87469ef
C++ language bindings for gRPC.
bf7e9a8
bf7e9a8
bf7e9a8
%package plugins
87469ef
Summary:        Protocol buffers compiler plugins for gRPC
87469ef
# License:        same as base package
71f7178
6c62f34
Requires:       grpc%{?_isa} = %{version}-%{release}
2b22037
Requires:       grpc-cpp%{?_isa} = %{version}-%{release}
87469ef
Requires:       protobuf-compiler
bf7e9a8
71f7178
Provides:       bundled(upb)
dd1f248
Provides:       bundled(utf8_range)
71f7178
bf7e9a8
%description plugins
bf7e9a8
Plugins to the protocol buffers compiler to generate gRPC sources.
bf7e9a8
87469ef
bf7e9a8
%package cli
87469ef
Summary:        Command-line tool for gRPC
87469ef
# License:        same as base package
71f7178
6c62f34
Requires:       grpc%{?_isa} = %{version}-%{release}
09de79a
Requires:       grpc-cpp%{?_isa} = %{version}-%{release}
bf7e9a8
71f7178
Provides:       bundled(upb)
dd1f248
Provides:       bundled(utf8_range)
71f7178
bf7e9a8
%description cli
87469ef
The command line tool can do the following things:
87469ef
56e498c
  • Send unary rpc.
56e498c
  • Attach metadata and display received metadata.
56e498c
  • Handle common authentication to server.
56e498c
  • Infer request/response types from server reflection result.
56e498c
  • Find the request/response types from a given proto file.
56e498c
  • Read proto request in text form.
56e498c
  • Read request in wire form (for protobuf messages, this means serialized
87469ef
    binary form).
56e498c
  • Display proto response in text form.
56e498c
  • Write response in wire form to a file.
87469ef
bf7e9a8
bf7e9a8
%package devel
87469ef
Summary:        Development files for gRPC library
87469ef
# License:        same as base package
6c62f34
Requires:       grpc%{?_isa} = %{version}-%{release}
6c62f34
Requires:       grpc-cpp%{?_isa} = %{version}-%{release}
ce88e01
ce88e01
# grpc/impl/codegen/port_platform.h includes linux/version.h
ce88e01
Requires:       kernel-headers%{?_isa}
ce88e01
# grpcpp/impl/codegen/config_protobuf.h includes google/protobuf/…
ce88e01
Requires:       pkgconfig(protobuf)
ce88e01
# grpcpp/test/mock_stream.h includes gmock/gmock.h
ce88e01
Requires:       pkgconfig(gmock)
ce88e01
# grpcpp/impl/codegen/sync.h includes absl/synchronization/mutex.h
ce88e01
# grpc.pc has -labsl_[…]
ce88e01
Requires:       abseil-cpp-devel%{?_isa}
ce88e01
# grpc.pc has -lre2
ce88e01
Requires:       pkgconfig(re2)
ce88e01
# grpc.pc has -lcares
ce88e01
Requires:       cmake(c-ares)
ce88e01
# grpc.pc has -lz
ce88e01
Requires:       pkgconfig(zlib)
ce88e01
bf7e9a8
%description devel
87469ef
Development headers and files for gRPC libraries (both C and C++).
87469ef
bf7e9a8
637ef64
%package -n python3-grpcio
87469ef
Summary:        Python language bindings for gRPC
87469ef
# License:        same as base package
87469ef
87469ef
# Note that the Python package has no runtime dependency on the base C library;
71f7178
# everything it needs is linked statically. It is not practical to change this,
71f7178
# and since they both come from the same source RPM, we do not need to attempt
71f7178
# to do so.
6c62f34
Requires:       grpc-data = %{version}-%{release}
637ef64
71f7178
Provides:       bundled(upb)
dd1f248
Provides:       bundled(utf8_range)
71f7178
637ef64
%description -n python3-grpcio
87469ef
Python language bindings for gRPC (HTTP/2-based RPC framework).
87469ef
87469ef
dd1f248
%global grpcio_egg %{python3_sitearch}/grpcio-%{pyversion}-py%{python3_version}.egg-info
3cbb553
%{?python_extras_subpkg:%python_extras_subpkg -n python3-grpcio -i %{grpcio_egg} protobuf}
bc86f71
bc86f71
87469ef
%package -n python3-grpcio-tools
87469ef
Summary:       Package for gRPC Python tools
87469ef
# License:        same as base package
87469ef
71f7178
Provides:       bundled(upb)
dd1f248
Provides:       bundled(utf8_range)
71f7178
87469ef
%description -n python3-grpcio-tools
87469ef
Package for gRPC Python tools.
87469ef
87469ef
2933935
%if %{without bootstrap}
2933935
%package -n python3-grpcio-admin
2933935
Summary:        A collection of admin services
2933935
License:        ASL 2.0
2933935
BuildArch:      noarch
2933935
2933935
%description -n python3-grpcio-admin
2933935
gRPC Python Admin Interface Package
2933935
===================================
2933935
2933935
Debugging gRPC library can be a complex task. There are many configurations and
2933935
internal states, which will affect the behavior of the library. This Python
2933935
package will be the collection of admin services that are exposing debug
2933935
information. Currently, it includes:
2933935
2933935
* Channel tracing metrics (grpcio-channelz)
2933935
* Client Status Discovery Service (grpcio-csds)
2933935
2933935
Here is a snippet to create an admin server on "localhost:50051":
2933935
2933935
    server = grpc.server(ThreadPoolExecutor())
2933935
    port = server.add_insecure_port('localhost:50051')
2933935
    grpc_admin.add_admin_servicers(self._server)
2933935
    server.start()
2933935
2933935
Welcome to explore the admin services with CLI tool "grpcdebug":
2933935
https://github.com/grpc-ecosystem/grpcdebug.
2933935
2933935
For any issues or suggestions, please send to
2933935
https://github.com/grpc/grpc/issues.
2933935
%endif
2933935
2933935
2933935
%if %{without bootstrap}
2933935
%package -n python3-grpcio-csds
2933935
Summary:        xDS configuration dump library
2933935
License:        ASL 2.0
2933935
BuildArch:      noarch
2933935
2933935
%description -n python3-grpcio-csds
2933935
gRPC Python Client Status Discovery Service package
2933935
===================================================
2933935
2933935
CSDS is part of the Envoy xDS protocol:
2933935
https://www.envoyproxy.io/docs/envoy/latest/api-v3/service/status/v3/csds.proto.
2933935
It allows the gRPC application to programmatically expose the received traffic
2933935
configuration (xDS resources). Welcome to explore with CLI tool "grpcdebug":
2933935
https://github.com/grpc-ecosystem/grpcdebug.
2933935
2933935
For any issues or suggestions, please send to
2933935
https://github.com/grpc/grpc/issues.
2933935
%endif
2933935
2933935
87469ef
%package -n python3-grpcio-channelz
87469ef
Summary:        Channel Level Live Debug Information Service for gRPC
87469ef
License:        ASL 2.0
87469ef
BuildArch:      noarch
87469ef
87469ef
%description -n python3-grpcio-channelz
2933935
gRPC Python Channelz package
2933935
============================
2933935
87469ef
Channelz is a live debug tool in gRPC Python.
87469ef
87469ef
87469ef
%package -n python3-grpcio-health-checking
87469ef
Summary:        Standard Health Checking Service for gRPC
87469ef
License:        ASL 2.0
87469ef
BuildArch:      noarch
87469ef
87469ef
%description -n python3-grpcio-health-checking
2933935
gRPC Python Health Checking
2933935
===========================
2933935
87469ef
Reference package for GRPC Python health checking.
87469ef
87469ef
87469ef
%package -n python3-grpcio-reflection
87469ef
Summary:        Standard Protobuf Reflection Service for gRPC
87469ef
License:        ASL 2.0
87469ef
BuildArch:      noarch
87469ef
87469ef
%description -n python3-grpcio-reflection
2933935
gRPC Python Reflection package
2933935
==============================
2933935
87469ef
Reference package for reflection in GRPC Python.
87469ef
87469ef
87469ef
%package -n python3-grpcio-status
87469ef
Summary:        Status proto mapping for gRPC
87469ef
License:        ASL 2.0
87469ef
BuildArch:      noarch
87469ef
87469ef
%description -n python3-grpcio-status
2933935
gRPC Python Status Proto
2933935
===========================
2933935
87469ef
Reference package for GRPC Python status proto mapping.
87469ef
87469ef
87469ef
%package -n python3-grpcio-testing
87469ef
Summary:        Testing utilities for gRPC Python
87469ef
License:        ASL 2.0
87469ef
BuildArch:      noarch
87469ef
87469ef
%description -n python3-grpcio-testing
2933935
gRPC Python Testing Package
2933935
===========================
2933935
87469ef
Testing utilities for gRPC Python.
87469ef
87469ef
bf7e9a8
%prep
dd1f248
%autosetup -p1 -n grpc-%{srcversion}
dd1f248
dd1f248
cp -p third_party/upb/third_party/utf8_range/LICENSE LICENSE-utf8_range
87469ef
fe0a859
echo '===== Patching grpcio_tools for system protobuf =====' 2>&1
fe0a859
# Build python3-grpcio_tools against system protobuf packages instead of
fe0a859
# expecting a git submodule. Must also add requisite linker flags using
fe0a859
# GRPC_PYTHON_LDFLAGS. This was formerly done by
fe0a859
# grpc-VERSION-python-grpcio_tools-use-system-protobuf.patch, but it had to be
fe0a859
# tediously but trivially rebased every patch release as the CC_FILES list
fe0a859
# changed, so we automated the patch.
fe0a859
sed -r -i \
fe0a859
    -e "s/^(# AUTO-GENERATED .*)/\\1\\n\
fe0a859
# Then, modified by hand to build with an external system protobuf\
fe0a859
# installation./" \
fe0a859
    -e 's/^(CC_FILES=\[).*(\])/\1\2/' \
fe0a859
    -e "s@^((CC|PROTO)_INCLUDE=')[^']+'@\1%{_includedir}'@" \
fe0a859
    -e '/^PROTOBUF_SUBMODULE_VERSION=/d' \
fe0a859
    'tools/distrib/python/grpcio_tools/protoc_lib_deps.py'
fe0a859
2933935
echo '===== Preparing gtest/gmock =====' 2>&1
acc3813
%if %{without system_gtest}
acc3813
# Copy in the needed gtest/gmock implementations.
dd1f248
%setup -q -T -D -b 1 -n grpc-%{srcversion}
acc3813
rm -rvf 'third_party/googletest'
6abb104
mv '../%{gtest_archivename}' 'third_party/googletest'
acc3813
%else
acc3813
# Patch CMakeLists for external gtest/gmock.
acc3813
#
acc3813
#  1. Create dummy sources, adding a typedef so the translation unit is not
acc3813
#     empty, rather than removing references to these sources from
acc3813
#     CMakeLists.txt. This is so that we do not end up with executables with no
acc3813
#     sources, only libraries, which is a CMake error.
acc3813
#  2. Either remove references to the corresponding include directories, or
acc3813
#     create the directories and leave them empty.
acc3813
#  3. “Stuff” the external library into the target_link_libraries() for each
acc3813
#     test by noting that GMock/GTest/GFlags are always used together.
acc3813
for gwhat in test mock
acc3813
do
acc3813
  mkdir -p "third_party/googletest/google${gwhat}/src" \
acc3813
      "third_party/googletest/google${gwhat}/include"
acc3813
  echo "typedef int dummy_${gwhat}_type;" \
acc3813
      > "third_party/googletest/google${gwhat}/src/g${gwhat}-all.cc"
acc3813
done
acc3813
sed -r -i 's/^([[:blank:]]*)(\$\{_gRPC_GFLAGS_LIBRARIES\})/'\
acc3813
'\1\2\n\1gtest\n\1gmock/' CMakeLists.txt
acc3813
%endif
acc3813
2933935
echo '===== Removing bundled xxhash =====' 2>&1
ce88e01
# Remove bundled xxhash
ce88e01
rm -rvf third_party/xxhash
ec47db2
# Since grpc sets XXH_INCLUDE_ALL wherever it uses xxhash, it is using xxhash
ec47db2
# as a header-only library. This means we can replace it with the system copy
ec47db2
# by doing nothing further; xxhash.h is in the system include path and will be
ec47db2
# found instead, and there are no linker flags to add. See also
ec47db2
# https://github.com/grpc/grpc/issues/25945.
9af26a9
2933935
echo '===== Fixing permissions =====' 2>&1
7307de3
# https://github.com/grpc/grpc/pull/27069
7307de3
find . -type f -perm /0111 \
7307de3
    -exec gawk '!/^#!/ { print FILENAME }; { nextfile }' '{}' '+' |
7307de3
  xargs -r chmod -v a-x
87469ef
2933935
echo '===== Removing selected unused sources =====' 2>&1
87469ef
# Remove unused sources that have licenses not in the License field, to ensure
87469ef
# they are not accidentally used in the build. See the comment above the base
87469ef
# package License field for more details.
87469ef
rm -rfv \
dd1f248
    src/boringssl/boringssl_prefix_symbols.h \
87469ef
    third_party/cares/ares_build.h \
87469ef
    third_party/rake-compiler-dock \
87469ef
    third_party/upb/third_party/lunit
87469ef
# Since we are replacing roots.pem with a symlink to the shared system
87469ef
# certificates, we do not include its license (MPLv2.0) in any License field.
87469ef
# We remove its contents so that, if we make a packaging mistake, we will have
87469ef
# a bug but not an incorrect License field.
87469ef
echo '' > etc/roots.pem
87469ef
87469ef
# Remove Android sources and examples. We do not need these on Linux, and they
87469ef
# have some issues that will be flagged when reviewing the package, such as:
87469ef
#   - Another copy of the MPLv2.0-licensed certificate bundle from
87469ef
#     etc/roots.pem, in src/android/test/interop/app/src/main/assets/roots.pem
87469ef
#   - Pre-built jar files at
87469ef
#     src/android/test/interop/gradle/wrapper/gradle-wrapper.jar and
87469ef
#     examples/android/helloworld/gradle/wrapper/gradle-wrapper.jar
87469ef
rm -rvf examples/android src/android
87469ef
6cc5506
# Drop the NodeJS example’s package-lock.json file, which will hopefully keep
6cc5506
# us from having bugs filed due to CVE’s in its (unpackaged) recursive
6cc5506
# dependencies.
6cc5506
rm -vf examples/node/package-lock.json
6cc5506
87469ef
# Remove unwanted .gitignore files, generally in examples. One could argue that
87469ef
# a sample .gitignore file is part of the example, but, well, we’re not going
87469ef
# to do that.
87469ef
find . -type f -name .gitignore -print -delete
87469ef
2933935
echo '===== Fixing shebangs =====' 2>&1
87469ef
# Find executables with /usr/bin/env shebangs in the examples, and fix them.
791e0d2
find . -type f -perm /0111 -exec gawk \
791e0d2
    '/^#!\/usr\/bin\/env[[:blank:]]/ { print FILENAME }; { nextfile }' \
791e0d2
    '{}' '+' |
dd1f248
  xargs -r sed -r -i '1{s|^(#!/usr/bin/)env[[:blank:]]+([^[:blank:]]+)|\1\2|}'
87469ef
2933935
echo '===== Fixing hard-coded C++ standard =====' 2>&1
ce88e01
# We need to adjust the C++ standard to avoid abseil-related linker errors. For
ce88e01
# the main C++ build, we can use CMAKE_CXX_STANDARD. For extensions, examples,
ce88e01
# etc., we must patch.
ce88e01
sed -r -i 's/(std=c\+\+)11/\1%{cpp_std}/g' \
ef054cb
    setup.py grpc.gyp Rakefile \
ce88e01
    examples/cpp/*/Makefile \
ce88e01
    examples/cpp/*/CMakeLists.txt \
ce88e01
    tools/run_tests/artifacts/artifact_targets.py \
ce88e01
    tools/distrib/python/grpcio_tools/setup.py
ce88e01
bf7e9a8
bf7e9a8
%build
87469ef
# ~~~~ C (core) and C++ (cpp) ~~~~
87469ef
2933935
echo '===== Building C (core) and C++ components =====' 2>&1
34ecf95
# We could use either make or ninja as the backend; ninja is faster and has no
34ecf95
# disadvantages (except a small additional BR, given we already need Python)
ce88e01
#
ce88e01
# We need to adjust the C++ standard to avoid abseil-related linker errors.
34ecf95
%cmake \
e1dddac
    -DgRPC_INSTALL:BOOL=ON \
ce88e01
    -DCMAKE_CXX_STANDARD:STRING=%{cpp_std} \
ce88e01
    -DCMAKE_SKIP_INSTALL_RPATH:BOOL=ON \
e1dddac
    -DgRPC_INSTALL_BINDIR:PATH=%{_bindir} \
e1dddac
    -DgRPC_INSTALL_LIBDIR:PATH=%{_libdir} \
e1dddac
    -DgRPC_INSTALL_INCLUDEDIR:PATH=%{_includedir} \
ef054cb
    -DgRPC_INSTALL_CMAKEDIR:PATH=%{_libdir}/cmake/grpc \
ef054cb
    -DgRPC_INSTALL_SHAREDIR:PATH=%{_datadir}/grpc \
34ecf95
    -DgRPC_BUILD_TESTS:BOOL=%{?with_core_tests:ON}%{?!with_core_tests:OFF} \
34ecf95
    -DgRPC_BUILD_CODEGEN:BOOL=ON \
e1dddac
    -DgRPC_BUILD_CSHARP_EXT:BOOL=ON \
34ecf95
    -DgRPC_BACKWARDS_COMPATIBILITY_MODE:BOOL=OFF \
34ecf95
    -DgRPC_ZLIB_PROVIDER:STRING='package' \
34ecf95
    -DgRPC_CARES_PROVIDER:STRING='package' \
ce88e01
    -DgRPC_RE2_PROVIDER:STRING='package' \
34ecf95
    -DgRPC_SSL_PROVIDER:STRING='package' \
34ecf95
    -DgRPC_PROTOBUF_PROVIDER:STRING='package' \
34ecf95
    -DgRPC_PROTOBUF_PACKAGE_TYPE:STRING='MODULE' \
34ecf95
    -DgRPC_BENCHMARK_PROVIDER:STRING='package' \
ce88e01
    -DgRPC_ABSL_PROVIDER:STRING='package' \
e1dddac
    -DgRPC_USE_PROTO_LITE:BOOL=OFF \
e1dddac
    -DgRPC_BUILD_GRPC_CPP_PLUGIN:BOOL=ON \
e1dddac
    -DgRPC_BUILD_GRPC_CSHARP_PLUGIN:BOOL=ON \
e1dddac
    -DgRPC_BUILD_GRPC_NODE_PLUGIN:BOOL=ON \
e1dddac
    -DgRPC_BUILD_GRPC_OBJECTIVE_C_PLUGIN:BOOL=ON \
e1dddac
    -DgRPC_BUILD_GRPC_PHP_PLUGIN:BOOL=ON \
e1dddac
    -DgRPC_BUILD_GRPC_PYTHON_PLUGIN:BOOL=ON \
e1dddac
    -DgRPC_BUILD_GRPC_RUBY_PLUGIN:BOOL=ON \
e1dddac
    -GNinja
34ecf95
%cmake_build
87469ef
# ~~~~ Python ~~~~
87469ef
2933935
echo '===== Building Python grpcio package =====' 2>&1
9a72967
# Since there are some interdependencies in the Python packages (e.g., many
9a72967
# have setup_requires: grpcio-tools), we do temporary installs of built
9a72967
# packages into a local directory as needed, and add it to the PYTHONPATH.
87469ef
PYROOT="${PWD}/%{_vpath_builddir}/pyroot"
87469ef
if [ -n "${PYTHONPATH-}" ]; then PYTHONPATH="${PYTHONPATH}:"; fi
87469ef
PYTHONPATH="${PYTHONPATH-}${PYROOT}%{python3_sitelib}"
87469ef
PYTHONPATH="${PYTHONPATH}:${PYROOT}%{python3_sitearch}"
87469ef
export PYTHONPATH
87469ef
87469ef
# ~~ grpcio ~~
ce88e01
# Note that we had to patch in the GRPC_PYTHON_BUILD_SYSTEM_ABSL option.
ce88e01
export GRPC_PYTHON_BUILD_WITH_CYTHON='True'
ce88e01
export GRPC_PYTHON_BUILD_SYSTEM_OPENSSL='True'
ce88e01
export GRPC_PYTHON_BUILD_SYSTEM_ZLIB='True'
ce88e01
export GRPC_PYTHON_BUILD_SYSTEM_CARES='True'
ce88e01
export GRPC_PYTHON_BUILD_SYSTEM_RE2='True'
ce88e01
export GRPC_PYTHON_BUILD_SYSTEM_ABSL='True'
ce88e01
export GRPC_PYTHON_DISABLE_LIBC_COMPATIBILITY='True'
281a679
export GRPC_PYTHON_ENABLE_DOCUMENTATION_BUILD='False'
7796406
# We must set GRPC_PYTHON_CFLAGS to avoid unwanted defaults. We take the
7796406
# upstream flags except that we remove -std=c99, which is inapplicable to the
7796406
# C++ parts of the extension.
7796406
#
7796406
# We must set GRPC_PYTHON_LDFLAGS to avoid unwanted defaults. The upstream
7796406
# flags attempt to statically link libgcc, so we do not need any of them. Since
7796406
# we forcibly unbundle protobuf, we need to add linker flags for protobuf
7796406
# ourselves.
7796406
export GRPC_PYTHON_CFLAGS="-fvisibility=hidden -fno-wrapv -fno-exceptions $(
7796406
  pkg-config --cflags protobuf
7796406
)"
7796406
export GRPC_PYTHON_LDFLAGS="$(pkg-config --libs protobuf)"
87469ef
%py3_build
87469ef
%{__python3} %{py_setup} %{?py_setup_args} install \
87469ef
    -O1 --skip-build --root "${PYROOT}"
87469ef
87469ef
# ~~ grpcio-tools ~~
2933935
echo '===== Building Python grpcio_tools package =====' 2>&1
87469ef
pushd "tools/distrib/python/grpcio_tools/" >/dev/null
87469ef
# When copying more things in here, make sure the subpackage License field
87469ef
# stays correct. We need copies, not symlinks, so that the “graft” in
87469ef
# MANIFEST.in works.
ef054cb
mkdir -p grpc_root/src
87469ef
for srcdir in compiler
87469ef
do
ef054cb
  cp -rp "../../../../src/${srcdir}" "grpc_root/src/"
87469ef
done
ef054cb
cp -rp '../../../../include' 'grpc_root/'
7796406
# We must set GRPC_PYTHON_CFLAGS and GRPC_PYTHON_LDFLAGS again; grpcio_tools
7796406
# does not have the same default upstream flags as grpcio does, and it needs to
7796406
# link the protobuf compiler library.
7796406
export GRPC_PYTHON_CFLAGS="-fno-wrapv -frtti $(pkg-config --cflags protobuf)"
7796406
export GRPC_PYTHON_LDFLAGS="$(pkg-config --libs protobuf) -lprotoc"
7796406
%py3_build
87469ef
# Remove unwanted shebang from grpc_tools.protoc source file, which will be
87469ef
# installed without an executable bit:
87469ef
find . -type f -name protoc.py -execdir sed -r -i '1{/^#!/d}' '{}' '+'
87469ef
%{__python3} %{py_setup} %{?py_setup_args} install \
87469ef
    -O1 --skip-build --root "${PYROOT}"
87469ef
popd >/dev/null
87469ef
2933935
echo '===== Building pure-Python packages =====' 1>&2
2933935
for suffix in channelz %{?!with_bootstrap:csds admin} health_checking \
2933935
    reflection status testing tests
87469ef
do
87469ef
  echo "----> grpcio_${suffix} <----" 1>&2
87469ef
  pushd "src/python/grpcio_${suffix}/" >/dev/null
2933935
  if ! echo "${suffix}" | grep -E "^(admin|csds)$" >/dev/null
2933935
  then
2933935
    %{__python3} %{py_setup} %{?py_setup_args} preprocess
2933935
  fi
2933935
  if ! echo "${suffix}" | grep -E "^(admin|csds|testing)$" >/dev/null
7796406
  then
7796406
    %{__python3} %{py_setup} %{?py_setup_args} build_package_protos
7796406
  fi
87469ef
  %py3_build
87469ef
  %{__python3} %{py_setup} %{?py_setup_args} install \
87469ef
      -O1 --skip-build --root "${PYROOT}"
87469ef
  popd >/dev/null
87469ef
done
87469ef
637ef64
bf7e9a8
%install
87469ef
# ~~~~ C (core) and C++ (cpp) ~~~~
34ecf95
%cmake_install
ce88e01
ce88e01
%if %{with core_tests}
dc22a8a
# For some reason, grpc_cli is not installed. Do it manually.
ef054cb
install -t '%{buildroot}%{_bindir}' -p -D '%{_vpath_builddir}/grpc_cli'
dc22a8a
# grpc_cli build does not respect CMAKE_INSTALL_RPATH
dc22a8a
# https://github.com/grpc/grpc/issues/25176
ef054cb
chrpath --delete '%{buildroot}%{_bindir}/grpc_cli'
ce88e01
ce88e01
# This library is also required for grpc_cli; it is built as part of the test
ce88e01
# code.
ce88e01
install -t '%{buildroot}%{_libdir}' -p \
dd1f248
    '%{_vpath_builddir}/libgrpc++_test_config.so.%{cpp_so_version}'
dd1f248
chrpath --delete \
dd1f248
    '%{buildroot}%{_libdir}/libgrpc++_test_config.so.%{cpp_so_version}'
ce88e01
ce88e01
install -d '%{buildroot}/%{_mandir}/man1'
ce88e01
install -t '%{buildroot}/%{_mandir}/man1' -p -m 0644 \
ce88e01
    %{SOURCE100} %{SOURCE101} %{SOURCE102} %{SOURCE103} %{SOURCE104} \
ce88e01
    %{SOURCE106} %{SOURCE107} %{SOURCE108}
34ecf95
%endif
ce88e01
87469ef
# Remove any static libraries that may have been installed against our wishes
87469ef
find %{buildroot} -type f -name '*.a' -print -delete
87469ef
# Fix wrong permissions on installed headers
ef054cb
find %{buildroot}%{_includedir}/grpc* -type f -name '*.h' -perm /0111 \
87469ef
    -execdir chmod -v a-x '{}' '+'
87469ef
87469ef
# ~~~~ Python ~~~~
87469ef
87469ef
# Since several packages have an install_requires: grpcio-tools, we must ensure
87469ef
# the buildroot Python site-packages directories are in the PYTHONPATH.
87469ef
pushd '%{buildroot}'
87469ef
PYROOT="${PWD}"
87469ef
popd
87469ef
if [ -n "${PYTHONPATH-}" ]; then PYTHONPATH="${PYTHONPATH}:"; fi
87469ef
PYTHONPATH="${PYTHONPATH-}${PYROOT}%{python3_sitelib}"
87469ef
PYTHONPATH="${PYTHONPATH}:${PYROOT}%{python3_sitearch}"
87469ef
export PYTHONPATH
87469ef
87469ef
# ~~ grpcio ~~
87469ef
%py3_install
87469ef
87469ef
# ~~ grpcio-tools ~~
87469ef
pushd "tools/distrib/python/grpcio_tools/" >/dev/null
637ef64
%py3_install
87469ef
popd >/dev/null
87469ef
87469ef
# ~~ pure-python modules grpcio-* ~~
2933935
for suffix in channelz %{?!with_bootstrap:csds admin} health_checking \
2933935
    reflection status testing
87469ef
do
87469ef
  pushd "src/python/grpcio_${suffix}/" >/dev/null
87469ef
  %py3_install
87469ef
  popd >/dev/null
87469ef
done
91ffc30
# The grpcio_tests package should not be installed; it would provide top-level
91ffc30
# packages with generic names like “tests” or “tests_aio”.
87469ef
87469ef
# ~~~~ Miscellaneous ~~~~
87469ef
87469ef
# Replace copies of the certificate bundle with symlinks to the shared system
87469ef
# certificates. This has the following benefits:
87469ef
#   - Reduces duplication and save space
87469ef
#   - Respects system-wide administrative trust configuration
87469ef
#   - Keeps “MPLv2.0” from having to be added to a number of License fields
87469ef
%global sysbundle %{_sysconfdir}/pki/ca-trust/extracted/pem/tls-ca-bundle.pem
87469ef
# We do not own this file; we temporarily install it in the buildroot so we do
87469ef
# not have dangling symlinks.
87469ef
install -D -t "%{buildroot}$(dirname '%{sysbundle}')" -m 0644 '%{sysbundle}'
87469ef
87469ef
find '%{buildroot}' -type f -name 'roots.pem' |
87469ef
  while read -r fn
87469ef
  do
87469ef
    ln -s -f "%{buildroot}%{sysbundle}" "${fn}"
87469ef
    symlinks -c -o "${fn}"
87469ef
  done
87469ef
13d2166
rm -rvf "%{buildroot}$(dirname '%{sysbundle}')"
13d2166
87469ef
# ~~ documentation and examples ~~
87469ef
87469ef
install -D -t '%{buildroot}%{_pkgdocdir}' -m 0644 -p AUTHORS *.md
281a679
cp -rvp doc examples '%{buildroot}%{_pkgdocdir}'
87469ef
87469ef
87469ef
%check
951e7fa
%ifarch %{ix86}
951e7fa
951e7fa
cat <<'EOF'
951e7fa
Since the following changes are accepted for F37:
951e7fa
951e7fa
https://fedoraproject.org/wiki/Changes/RetireARMv7
951e7fa
https://fedoraproject.org/wiki/Changes/EncourageI686LeafRemoval
951e7fa
951e7fa
…we still build for i686 since this is not a leaf packages, but skip tests so
951e7fa
we do not have to keep track of 32-bit-specific issues.
951e7fa
EOF
951e7fa
951e7fa
%else
951e7fa
53fe707
export FEDORA_NO_NETWORK_TESTS=1
53fe707
ce88e01
%if %{with core_tests}
ce88e01
PORT_SERVER_PORT="$(awk '
ce88e01
  /_PORT_SERVER_PORT[[:blank:]]*=[[:blank:]]*[[:digit:]]+$/ { print $NF }
ce88e01
' tools/run_tests/python_utils/start_port_server.py)"
ce88e01
ee2d9c9
# Note that no tests are actually found by ctest:
34ecf95
%ctest
ee2d9c9
ce88e01
# Exclude tests that are known to hang or otherwise fail. Assistance welcome in
ce88e01
# figuring out what is wrong with these.  Note, however, that we are running
ce88e01
# the tests very differently from upstream, which uses scripts in
ce88e01
# tools/run_tests/ that rebuild the entire source and use Docker, so it is
ce88e01
# likely to be difficult to get help from upstream for any failures here. Note
ce88e01
# that some of these tests would never work in an environment without Internet
ce88e01
# access.
603761e
{ sed -r -e '/^(#|$)/d' -e 's|^(.*)$|%{_vpath_builddir}/\1_test|' <<'EOF'
603761e
ce88e01
# Requires (or may require) network:
ce88e01
resolve_address_using_ares_resolver
ce88e01
resolve_address_using_ares_resolver_posix
ce88e01
resolve_address_using_native_resolver
ce88e01
resolve_address_using_native_resolver_posix
ce88e01
ssl_transport_security
ce88e01
ce88e01
# Seems to require privilege:
ce88e01
flaky_network
ce88e01
ce88e01
%ifarch s390x
ce88e01
# Unexplained:
ce88e01
#
ce88e01
# [ RUN      ] AddressSortingTest.TestSorterKnowsIpv6LoopbackIsAvailable
dd1f248
# /builddir/build/BUILD/grpc-1.46.0/test/cpp/naming/address_sorting_test.cc:809: Failure
ce88e01
# Expected equality of these values:
ce88e01
#   source_addr_output->sin6_family
ce88e01
#     Which is: 0
ce88e01
#   10
dd1f248
# /builddir/build/BUILD/grpc-1.46.0/test/cpp/naming/address_sorting_test.cc:819: Failure
ce88e01
# Expected equality of these values:
ce88e01
#   source_addr_str
ce88e01
#     Which is: "::"
ce88e01
#   "::1"
dd1f248
# [  FAILED  ] AddressSortingTest.TestSorterKnowsIpv6LoopbackIsAvailable (2 ms)
2933935
#
dd1f248
# Confirmed in 1.46.0 2022-05-06
ce88e01
address_sorting
0cc3ce6
%endif
ce88e01
0cc3ce6
%ifarch s390x
ce88e01
# Unexplained:
ce88e01
#
ce88e01
# Status is not ok: Setting authenticated associated data failed
dd1f248
# E0506 15:48:55.586625401 4020849 aes_gcm_test.cc:77]         assertion failed: status == GRPC_STATUS_OK
dd1f248
# *** SIGABRT received at time=1651852135 on cpu 1 ***
dd1f248
# PC: @      0x3ff89d98096  (unknown)  __pthread_kill_implementation
dd1f248
#     @      0x3ff89c82544  (unknown)  (unknown)
dd1f248
#     @      0x3ff89c827e0  (unknown)  (unknown)
dd1f248
#     @      0x3ff8a9fe490  (unknown)  (unknown)
dd1f248
#     @      0x3ff89d98096  (unknown)  __pthread_kill_implementation
dd1f248
#     @      0x3ff89d48530  (unknown)  gsignal
dd1f248
#     @      0x3ff89d2b5c0  (unknown)  abort
dd1f248
#     @      0x2aa28f84818  (unknown)  gsec_assert_ok()
dd1f248
#     @      0x2aa28f84944  (unknown)  gsec_test_random_encrypt_decrypt()
dd1f248
#     @      0x2aa28f82536  (unknown)  main
dd1f248
#     @      0x3ff89d2b872  (unknown)  __libc_start_call_main
dd1f248
#     @      0x3ff89d2b950  (unknown)  __libc_start_main@GLIBC_2.2
dd1f248
#     @      0x2aa28f836f0  (unknown)  (unknown)
2933935
#
dd1f248
# Confirmed in 1.46.0 2022-05-06
ce88e01
alts_crypt
0cc3ce6
%endif
ce88e01
0cc3ce6
%ifarch s390x
ce88e01
# Unexplained:
ce88e01
#
ce88e01
# (aborted without output)
2933935
#
dd1f248
# Confirmed in 1.46.0 2022-05-06
ce88e01
alts_crypter
0cc3ce6
%endif
ce88e01
0cc3ce6
%ifarch s390x
ce88e01
# Unexplained:
ce88e01
#
33f1b89
# [ RUN      ] AltsConcurrentConnectivityTest.TestBasicClientServerHandshakes
dd1f248
# E0506 20:38:59.376480159 4049276 alts_grpc_privacy_integrity_record_protocol.cc:107] Failed to unprotect, More bytes written than expected. Frame decryption failed.
dd1f248
# [… 11 similar lines omitted …]
dd1f248
# /builddir/build/BUILD/grpc-1.46.0/test/core/tsi/alts/handshaker/alts_concurrent_connectivity_test.cc:244: Failure
33f1b89
# Expected equality of these values:
33f1b89
#   ev.type
33f1b89
#     Which is: 1
33f1b89
#   GRPC_OP_COMPLETE
33f1b89
#     Which is: 2
dd1f248
# connect_loop runner:0x3fffa47d718 got ev.type:1 i:0
dd1f248
# [  FAILED  ] AltsConcurrentConnectivityTest.TestBasicClientServerHandshakes (5004 ms)
33f1b89
# [ RUN      ] AltsConcurrentConnectivityTest.TestConcurrentClientServerHandshakes
dd1f248
# E0506 20:39:04.393443259 4049343 alts_grpc_privacy_integrity_record_protocol.cc:107] Failed to unprotect, More bytes written than expected. Frame decryption failed.
dd1f248
# [… 1033 similar lines omitted …]
dd1f248
# /builddir/build/BUILD/grpc-1.46.0/test/core/tsi/alts/handshaker/alts_concurrent_connectivity_test.cc:244: Failure
dd1f248
# Expected equality of these values:
dd1f248
#   ev.type
dd1f248
#     Which is: 1
dd1f248
#   GRPC_OP_COMPLETE
dd1f248
#     Which is: 2
dd1f248
# connect_loop runner:0x2aa06421b00 got ev.type:1 i:0
dd1f248
# [ … 343 lines with 49 similar errors omitted …]
dd1f248
# [  FAILED  ] AltsConcurrentConnectivityTest.TestConcurrentClientServerHandshakes (15017 ms)
dd1f248
# [ RUN      ] AltsConcurrentConnectivityTest.TestHandshakeFailsFastWhenPeerEndpointClosesConnectionAfterAccepting
dd1f248
# [       OK ] AltsConcurrentConnectivityTest.TestHandshakeFailsFastWhenPeerEndpointClosesConnectionAfterAccepting (4519 ms)
dd1f248
# [ RUN      ] AltsConcurrentConnectivityTest.TestHandshakeFailsFastWhenHandshakeServerClosesConnectionAfterAccepting
dd1f248
# E0506 20:39:23.930152511 4049976 alts_handshaker_client.cc:223] recv_buffer is nullptr in alts_tsi_handshaker_handle_response()
dd1f248
# [… 193 similar lines omitted …]
dd1f248
# [       OK ] AltsConcurrentConnectivityTest.TestHandshakeFailsFastWhenHandshakeServerClosesConnectionAfterAccepting (2237 ms)
dd1f248
# [ RUN      ] AltsConcurrentConnectivityTest.TestHandshakeFailsFastWhenHandshakeServerHangsAfterAccepting
dd1f248
# [       OK ] AltsConcurrentConnectivityTest.TestHandshakeFailsFastWhenHandshakeServerHangsAfterAccepting (244 ms)
dd1f248
# [----------] 5 tests from AltsConcurrentConnectivityTest (27024 ms total)
33f1b89
# [----------] Global test environment tear-down
dd1f248
# [==========] 5 tests from 1 test suite ran. (27024 ms total)
33f1b89
# [  PASSED  ] 3 tests.
33f1b89
# [  FAILED  ] 2 tests, listed below:
33f1b89
# [  FAILED  ] AltsConcurrentConnectivityTest.TestBasicClientServerHandshakes
33f1b89
# [  FAILED  ] AltsConcurrentConnectivityTest.TestConcurrentClientServerHandshakes
33f1b89
#  2 FAILED TESTS
dd1f248
# E0506 20:39:36.394518375 4049271 test_config.cc:175]         Timeout in waiting for gRPC shutdown
33f1b89
#
dd1f248
# Confirmed in 1.46.0 2022-05-06
33f1b89
alts_concurrent_connectivity
33f1b89
%endif
33f1b89
33f1b89
%ifarch s390x
33f1b89
# Unexplained:
33f1b89
#
ce88e01
# (aborted without output)
2933935
#
dd1f248
# Confirmed in 1.46.0 2022-05-06
ce88e01
alts_frame_protector
0cc3ce6
%endif
ce88e01
0cc3ce6
%ifarch s390x
ce88e01
# Unexplained:
ce88e01
#
dd1f248
# E0506 21:49:20.855933553 1468251 alts_grpc_integrity_only_record_protocol.cc:109] Failed to protect, Setting authenticated associated data failed
dd1f248
# E0506 21:49:20.856134615 1468251 alts_grpc_record_protocol_test.cc:283] assertion failed: status == TSI_OK
dd1f248
# *** SIGABRT received at time=1651873760 on cpu 0 ***
dd1f248
# PC: @      0x3ff85598096  (unknown)  __pthread_kill_implementation
dd1f248
#     @      0x3ff85482544  (unknown)  (unknown)
dd1f248
#     @      0x3ff854827e0  (unknown)  (unknown)
dd1f248
#     @      0x3ff861fe490  (unknown)  (unknown)
dd1f248
#     @      0x3ff85598096  (unknown)  __pthread_kill_implementation
dd1f248
#     @      0x3ff85548530  (unknown)  gsignal
dd1f248
#     @      0x3ff8552b5c0  (unknown)  abort
dd1f248
#     @      0x2aa1888375e  (unknown)  random_seal_unseal()
dd1f248
#     @      0x2aa18884008  (unknown)  alts_grpc_record_protocol_tests()
dd1f248
#     @      0x2aa1888258c  (unknown)  main
dd1f248
#     @      0x3ff8552b872  (unknown)  __libc_start_call_main
dd1f248
#     @      0x3ff8552b950  (unknown)  __libc_start_main@GLIBC_2.2
dd1f248
#     @      0x2aa18882680  (unknown)  (unknown)
33f1b89
#
dd1f248
# Confirmed in 1.46.0 2022-05-06
ce88e01
alts_grpc_record_protocol
0cc3ce6
%endif
ce88e01
0cc3ce6
%ifarch s390x
ce88e01
# Unexplained:
ce88e01
#
ce88e01
# (aborted without output)
2933935
#
dd1f248
# Confirmed in 1.46.0 2022-05-06
ce88e01
alts_iovec_record_protocol
0cc3ce6
%endif
ce88e01
0cc3ce6
%ifarch s390x
ce88e01
# Unexplained:
ce88e01
#
dd1f248
# E0507 14:19:47.146439950 2465022 alts_grpc_integrity_only_record_protocol.cc:109] Failed to protect, Setting authenticated associated data failed
dd1f248
# E0507 14:19:47.146597694 2465022 alts_zero_copy_grpc_protector_test.cc:184] assertion failed: tsi_zero_copy_grpc_protector_protect( sender, &var->original_sb, &var->protected_sb) == TSI_OK
dd1f248
# *** SIGABRT received at time=1651933187 on cpu 0 ***
dd1f248
# PC: @      0x3ff89498096  (unknown)  __pthread_kill_implementation
dd1f248
#     @      0x3ff89382544  (unknown)  (unknown)
dd1f248
#     @      0x3ff893827e0  (unknown)  (unknown)
dd1f248
#     @      0x3ff8a0fe490  (unknown)  (unknown)
dd1f248
#     @      0x3ff89498096  (unknown)  __pthread_kill_implementation
dd1f248
#     @      0x3ff89448530  (unknown)  gsignal
dd1f248
#     @      0x3ff8942b5c0  (unknown)  abort
dd1f248
#     @      0x2aa1a0032d0  (unknown)  seal_unseal_small_buffer()
dd1f248
#     @      0x2aa1a003478  (unknown)  alts_zero_copy_protector_seal_unseal_small_buffer_tests()
dd1f248
#     @      0x2aa1a00254a  (unknown)  main
dd1f248
#     @      0x3ff8942b872  (unknown)  __libc_start_call_main
dd1f248
#     @      0x3ff8942b950  (unknown)  __libc_start_main@GLIBC_2.2
dd1f248
#     @      0x2aa1a002630  (unknown)  (unknown)
33f1b89
#
dd1f248
# Confirmed in 1.46.0 2022-05-06
ce88e01
alts_zero_copy_grpc_protector
0cc3ce6
%endif
ce88e01
dd1f248
# Unexplained, flaky:
3cbb553
#
dd1f248
# (hangs indefinitely, timeout triggered)
f67c551
#
dd1f248
# Confirmed in 1.46.1 2022-05-14 (on at least ppc64le)
f67c551
client_ssl
f67c551
951e7fa
%ifarch x86_64
0cc3ce6
# Unexplained:
0cc3ce6
#
0cc3ce6
# [ RUN      ] ExamineStackTest.AbseilStackProvider
dd1f248
# /builddir/build/BUILD/grpc-1.46.0/test/core/gprpp/examine_stack_test.cc:75: Failure
0cc3ce6
# Value of: stack_trace->find("GetCurrentStackTrace") != std::string::npos
0cc3ce6
#   Actual: false
0cc3ce6
# Expected: true
0cc3ce6
# [  FAILED  ] ExamineStackTest.AbseilStackProvider (0 ms)
0cc3ce6
#
dd1f248
# Confirmed in 1.46.0 2022-05-09
0cc3ce6
examine_stack
0cc3ce6
%endif
0cc3ce6
0cc3ce6
%ifarch s390x
ce88e01
# Unexplained:
ce88e01
#
dd1f248
# E0509 15:02:47.269422552 2434394 cq_verifier.cc:228]         no event received, but expected:tag(257) GRPC_OP_COMPLETE success=1 /builddir/build/BUILD/grpc-1.46.0/test/core/end2end/goaway_server_test.cc:279
dd1f248
# tag(769) GRPC_OP_COMPLETE success=1 /builddir/build/BUILD/grpc-1.46.0/test/core/end2end/goaway_server_test.cc:280
dd1f248
# *** SIGABRT received at time=1652108567 on cpu 1 ***
dd1f248
# PC: @      0x3ffb6e98096  (unknown)  __pthread_kill_implementation
dd1f248
#     @      0x3ffb6d82544  (unknown)  (unknown)
dd1f248
#     @      0x3ffb6d827e0  (unknown)  (unknown)
dd1f248
#     @      0x3ffb7cfe490  (unknown)  (unknown)
dd1f248
#     @      0x3ffb6e98096  (unknown)  __pthread_kill_implementation
dd1f248
#     @      0x3ffb6e48530  (unknown)  gsignal
dd1f248
#     @      0x3ffb6e2b5c0  (unknown)  abort
dd1f248
#     @      0x2aa1b406a72  (unknown)  cq_verify()
dd1f248
#     @      0x2aa1b404f9a  (unknown)  main
dd1f248
#     @      0x3ffb6e2b872  (unknown)  __libc_start_call_main
dd1f248
#     @      0x3ffb6e2b950  (unknown)  __libc_start_main@GLIBC_2.2
dd1f248
#     @      0x2aa1b405720  (unknown)  (unknown)
33f1b89
#
dd1f248
# Confirmed in 1.46.0 2022-05-09
ce88e01
goaway_server
0cc3ce6
%endif
ce88e01
33f1b89
# Unexplained:
33f1b89
#
33f1b89
# [ RUN      ] GrpcToolTest.CallCommandWithTimeoutDeadlineSet
dd1f248
# [libprotobuf ERROR google/protobuf/text_format.cc:335] Error parsing text-format grpc.testing.SimpleRequest: 1:7: Message type "grpc.testing.SimpleRequest" has no field named "redhat".
33f1b89
# Failed to convert text format to proto.
33f1b89
# Failed to parse request.
dd1f248
# /builddir/build/BUILD/grpc-1.46.0/test/cpp/util/grpc_tool_test.cc:915: Failure
33f1b89
# Value of: 0 == GrpcToolMainLib(ArraySize(argv), argv, TestCliCredentials(), std::bind(PrintStream, &output_stream, std::placeholders::_1))
33f1b89
#   Actual: false
33f1b89
# Expected: true
dd1f248
# /builddir/build/BUILD/grpc-1.46.0/test/cpp/util/grpc_tool_test.cc:920: Failure
33f1b89
# Value of: nullptr != strstr(output_stream.str().c_str(), "message: \"true\"")
33f1b89
#   Actual: false
33f1b89
# Expected: true
33f1b89
# [  FAILED  ] GrpcToolTest.CallCommandWithTimeoutDeadlineSet (4 ms)
33f1b89
#
dd1f248
# Confirmed in 1.46.0 2022-05-09
33f1b89
grpc_tool
33f1b89
0cc3ce6
%ifarch s390x
ce88e01
# Unexplained:
ce88e01
#
dd1f248
# *** SIGABRT received at time=1652104042 on cpu 1 ***
dd1f248
# PC: @      0x3ffa5398096  (unknown)  __pthread_kill_implementation
dd1f248
#     @      0x3ffa5282544  (unknown)  (unknown)
dd1f248
#     @      0x3ffa52827e0  (unknown)  (unknown)
dd1f248
#     @      0x3ffa59fe490  (unknown)  (unknown)
dd1f248
#     @      0x3ffa5398096  (unknown)  __pthread_kill_implementation
dd1f248
#     @      0x3ffa5348530  (unknown)  gsignal
dd1f248
#     @      0x3ffa532b5c0  (unknown)  abort
dd1f248
#     @      0x2aa2b40145e  (unknown)  verification_test()
dd1f248
#     @      0x2aa2b4011e8  (unknown)  main
dd1f248
#     @      0x3ffa532b872  (unknown)  __libc_start_call_main
dd1f248
#     @      0x3ffa532b950  (unknown)  __libc_start_main@GLIBC_2.2
dd1f248
#     @      0x2aa2b401270  (unknown)  (unknown)
33f1b89
#
dd1f248
# Confirmed in 1.46.0 2022-05-09
ce88e01
murmur_hash
0cc3ce6
%endif
ce88e01
951e7fa
%ifarch x86_64
ce88e01
# Unexplained:
ce88e01
#
0cc3ce6
# [ RUN      ] StackTracerTest.Basic
dd1f248
# /builddir/build/BUILD/grpc-1.46.0/test/core/util/stack_tracer_test.cc:36: Failure
0cc3ce6
# Value of: absl::StrContains(stack_trace, "Basic")
0cc3ce6
#   Actual: false
0cc3ce6
# Expected: true
dd1f248
# [  FAILED  ] StackTracerTest.Basic (0 ms)
2933935
#
dd1f248
# Confirmed in 1.46.0 2022-05-09
0cc3ce6
stack_tracer
ce88e01
%endif
ce88e01
dd1f248
%ifarch aarch64 x86_64 ppc64le
ce88e01
# Unexplained:
ce88e01
#
dd1f248
# This may be flaky and sometimes succeed; this was known to be the case on
dd1f248
# ppc64le in older versions.
ce88e01
#
dd1f248
# [ RUN      ] CredentialsTest.TestOauth2TokenFetcherCredsParsingEmptyHttpBody
dd1f248
# E0509 16:23:59.122730405 3124460 oauth2_credentials.cc:165]  Call to http server ended with error 401 [{"access_token":"ya29.AHES6ZRN3-HlhAPya30GnW_bHSb_", "expires_in":3599,  "token_type":"Bearer"}].
dd1f248
# *** SIGSEGV received at time=1652113439 on cpu 3 ***
dd1f248
# PC: @     0x7f13bf51165c  (unknown)  __strlen_evex
dd1f248
#     @               0x33  (unknown)  (unknown)
2933935
#
dd1f248
# Confirmed in 1.46.0 2022-05-09
0cc3ce6
test_core_security_credentials
dd1f248
%endif
ce88e01
dd1f248
# It looks like server_key_log has the right lines, but in an unexpected order.
dd1f248
# It is not immediately obvious if this a real problem, or an implementation
dd1f248
# quirk. Opinions about whether, or how, to report this upstream are welcome!
dd1f248
#
dd1f248
# [ RUN      ] TlsKeyLogging/TlsKeyLoggingEnd2EndTest.KeyLogging/TestScenario__num_listening_ports_5__share_tls_key_log_file_false__enable_tls_key_logging_true
dd1f248
# /builddir/build/BUILD/grpc-1.45.2/test/cpp/end2end/tls_key_export_test.cc:277: Failure
dd1f248
# Value of: server_key_log
dd1f248
# Expected: is equal to "SERVER_HANDSHAKE_TRAFFIC_SECRET cbe6c0edbc9729ca0ac78c15a707661c13efbf9c88d702f9746771e38e478b97 e2d3f9cb30e7eef95f95e3bca6f5e4258e42cc7903c424529730f2397ea6444b8c5e6e8c40b6f8d2060141a045ef814c\rEXPORTER_SECRET cbe6c0edbc9729ca0ac78c15a707661c13efbf9c88d702f9746771e38e478b97 820a4529b3e9614df378adb43a712ebc472b7fc91b6a92ff3421fb5870dd18782e7fb47e261eca093d9b8285e4ff17e0\rSERVER_TRAFFIC_SECRET_0 cbe6c0edbc9729ca0ac78c15a707661c13efbf9c88d702f9746771e38e478b97 dfac76dd16ed221785dc5e41fb1243430bddd70d78fe33344c8cc899d1e1b3f56d6865a2506044674063e9d32902588e\rCLIENT_HANDSHAKE_TRAFFIC_SECRET cbe6c0edbc9729ca0ac78c15a707661c13efbf9c88d702f9746771e38e478b97 f2f276c097044d63448a3413109702cd6413e6bbd75b3a40208c3fb5a9a0c8ca86d4a0460e1a04dcc025571e1edbb927\rCLIENT_TRAFFIC_SECRET_0 cbe6c0edbc9729ca0ac78c15a707661c13efbf9c88d702f9746771e38e478b97 8abeb453616823875792497d98bc6032f772a6f4cd75716209c49c4abc4ef470e6fd4ab274b7019162a6c584ff94ec4b\r"
dd1f248
#   Actual: "SERVER_HANDSHAKE_TRAFFIC_SECRET cbe6c0edbc9729ca0ac78c15a707661c13efbf9c88d702f9746771e38e478b97 e2d3f9cb30e7eef95f95e3bca6f5e4258e42cc7903c424529730f2397ea6444b8c5e6e8c40b6f8d2060141a045ef814c\rCLIENT_HANDSHAKE_TRAFFIC_SECRET cbe6c0edbc9729ca0ac78c15a707661c13efbf9c88d702f9746771e38e478b97 f2f276c097044d63448a3413109702cd6413e6bbd75b3a40208c3fb5a9a0c8ca86d4a0460e1a04dcc025571e1edbb927\rEXPORTER_SECRET cbe6c0edbc9729ca0ac78c15a707661c13efbf9c88d702f9746771e38e478b97 820a4529b3e9614df378adb43a712ebc472b7fc91b6a92ff3421fb5870dd18782e7fb47e261eca093d9b8285e4ff17e0\rSERVER_TRAFFIC_SECRET_0 cbe6c0edbc9729ca0ac78c15a707661c13efbf9c88d702f9746771e38e478b97 dfac76dd16ed221785dc5e41fb1243430bddd70d78fe33344c8cc899d1e1b3f56d6865a2506044674063e9d32902588e\rCLIENT_TRAFFIC_SECRET_0 cbe6c0edbc9729ca0ac78c15a707661c13efbf9c88d702f9746771e38e478b97 8abeb453616823875792497d98bc6032f772a6f4cd75716209c49c4abc4ef470e6fd4ab274b7019162a6c584ff94ec4b\r"
dd1f248
# /builddir/build/BUILD/grpc-1.45.2/test/cpp/end2end/tls_key_export_test.cc:277: Failure
dd1f248
# Value of: server_key_log
dd1f248
# Expected: is equal to "SERVER_HANDSHAKE_TRAFFIC_SECRET f3f5bb032b5283139d8e69c5e7d408b0e58b32b857b790c28bb81083c1f08751 aaa28bd7a945c3fccb1248bd024a604e2825891009af24bf44376d0ba36983dc243c7cb272e8f403db8762d6f44f1c3c\rEXPORTER_SECRET f3f5bb032b5283139d8e69c5e7d408b0e58b32b857b790c28bb81083c1f08751 c4a36ba53829243df5fccf0bf416c889e9c8813353a4487615e33dd443e5f196267c0fb7bacb8ee5b23f9c8c38c46b2e\rSERVER_TRAFFIC_SECRET_0 f3f5bb032b5283139d8e69c5e7d408b0e58b32b857b790c28bb81083c1f08751 89765e5e4cbd62a3be738f4c2ceb4be2e3fe204245f9765cab0f026ea1ec2e686d0df06291a1ae44b744a50e9493f944\rCLIENT_HANDSHAKE_TRAFFIC_SECRET f3f5bb032b5283139d8e69c5e7d408b0e58b32b857b790c28bb81083c1f08751 6ce17c81bb29ef1660e4404ac61755ba438a4c26bb93e812602e86329c03c6d63b6db282d9e6d0827025a43e2a6db507\rCLIENT_TRAFFIC_SECRET_0 f3f5bb032b5283139d8e69c5e7d408b0e58b32b857b790c28bb81083c1f08751 6a816d2d67967d1d455b69894ee731e41794b3fe299220bae615e66727d112f58d8982675a5d533d49dc0378bf9fb103\r"
dd1f248
#   Actual: "SERVER_HANDSHAKE_TRAFFIC_SECRET f3f5bb032b5283139d8e69c5e7d408b0e58b32b857b790c28bb81083c1f08751 aaa28bd7a945c3fccb1248bd024a604e2825891009af24bf44376d0ba36983dc243c7cb272e8f403db8762d6f44f1c3c\rCLIENT_HANDSHAKE_TRAFFIC_SECRET f3f5bb032b5283139d8e69c5e7d408b0e58b32b857b790c28bb81083c1f08751 6ce17c81bb29ef1660e4404ac61755ba438a4c26bb93e812602e86329c03c6d63b6db282d9e6d0827025a43e2a6db507\rEXPORTER_SECRET f3f5bb032b5283139d8e69c5e7d408b0e58b32b857b790c28bb81083c1f08751 c4a36ba53829243df5fccf0bf416c889e9c8813353a4487615e33dd443e5f196267c0fb7bacb8ee5b23f9c8c38c46b2e\rSERVER_TRAFFIC_SECRET_0 f3f5bb032b5283139d8e69c5e7d408b0e58b32b857b790c28bb81083c1f08751 89765e5e4cbd62a3be738f4c2ceb4be2e3fe204245f9765cab0f026ea1ec2e686d0df06291a1ae44b744a50e9493f944\rCLIENT_TRAFFIC_SECRET_0 f3f5bb032b5283139d8e69c5e7d408b0e58b32b857b790c28bb81083c1f08751 6a816d2d67967d1d455b69894ee731e41794b3fe299220bae615e66727d112f58d8982675a5d533d49dc0378bf9fb103\r"
dd1f248
# /builddir/build/BUILD/grpc-1.45.2/test/cpp/end2end/tls_key_export_test.cc:277: Failure
dd1f248
# Value of: server_key_log
dd1f248
# Expected: is equal to "SERVER_HANDSHAKE_TRAFFIC_SECRET 7c9ff52917c484e1296e07db3ebe639b0451d53e4e96ba49b6e2f730b08dbecc 4faa820090880462e1b2e9a3bb83e2f09744986e72e26e57d6c9ac7bb72058b57adac41c123de64e4b3b72719bc8eea4\rEXPORTER_SECRET 7c9ff52917c484e1296e07db3ebe639b0451d53e4e96ba49b6e2f730b08dbecc e43c4527fbe9b5a552604b7cc92f47ab79cdf6f58804b06f0e02a634eb252f95b78b202634d084c46b24b132187e603d\rSERVER_TRAFFIC_SECRET_0 7c9ff52917c484e1296e07db3ebe639b0451d53e4e96ba49b6e2f730b08dbecc 2da0bcf4584dd9cb1795f2d8adc4e766c0d6c2d0295cdd5f6ec0e9eed057613d81ab386e96bf1a4d2364d66a677acc3c\rCLIENT_HANDSHAKE_TRAFFIC_SECRET 7c9ff52917c484e1296e07db3ebe639b0451d53e4e96ba49b6e2f730b08dbecc 95beadcad1b17f86e504b4bf525406c6a29a2251867567aa93ce23b531b62f9b0c2c7e82d061c2a741edd96d84874ad5\rCLIENT_TRAFFIC_SECRET_0 7c9ff52917c484e1296e07db3ebe639b0451d53e4e96ba49b6e2f730b08dbecc 0f047139f6c4dfafb590f3a62ee812cefc8550aaa2f15edca843f0365d5a17b4507ad5f63a369974e83cd1ec0fdb5049\r"
dd1f248
#   Actual: "SERVER_HANDSHAKE_TRAFFIC_SECRET 7c9ff52917c484e1296e07db3ebe639b0451d53e4e96ba49b6e2f730b08dbecc 4faa820090880462e1b2e9a3bb83e2f09744986e72e26e57d6c9ac7bb72058b57adac41c123de64e4b3b72719bc8eea4\rCLIENT_HANDSHAKE_TRAFFIC_SECRET 7c9ff52917c484e1296e07db3ebe639b0451d53e4e96ba49b6e2f730b08dbecc 95beadcad1b17f86e504b4bf525406c6a29a2251867567aa93ce23b531b62f9b0c2c7e82d061c2a741edd96d84874ad5\rEXPORTER_SECRET 7c9ff52917c484e1296e07db3ebe639b0451d53e4e96ba49b6e2f730b08dbecc e43c4527fbe9b5a552604b7cc92f47ab79cdf6f58804b06f0e02a634eb252f95b78b202634d084c46b24b132187e603d\rSERVER_TRAFFIC_SECRET_0 7c9ff52917c484e1296e07db3ebe639b0451d53e4e96ba49b6e2f730b08dbecc 2da0bcf4584dd9cb1795f2d8adc4e766c0d6c2d0295cdd5f6ec0e9eed057613d81ab386e96bf1a4d2364d66a677acc3c\rCLIENT_TRAFFIC_SECRET_0 7c9ff52917c484e1296e07db3ebe639b0451d53e4e96ba49b6e2f730b08dbecc 0f047139f6c4dfafb590f3a62ee812cefc8550aaa2f15edca843f0365d5a17b4507ad5f63a369974e83cd1ec0fdb5049\r"
dd1f248
# /builddir/build/BUILD/grpc-1.45.2/test/cpp/end2end/tls_key_export_test.cc:277: Failure
dd1f248
# Value of: server_key_log
dd1f248
# Expected: is equal to "SERVER_HANDSHAKE_TRAFFIC_SECRET 59fd362f394bf867a5bcf4c6dd600790bd784424bdea837a47698c85082eebff d09d807afd55f9c1582e6879d97a262fa26f19db06cb57a14ce53f6be372dbb70ed036f8bf7d5f6a3168771eb2e4de30\rEXPORTER_SECRET 59fd362f394bf867a5bcf4c6dd600790bd784424bdea837a47698c85082eebff 5e76f891f0bbf4fa51a6fc5cc52aadf150995804a3ab81a185efb3ff02a6847ba7945cdd9a3a4c99ab3a657d150e1ca6\rSERVER_TRAFFIC_SECRET_0 59fd362f394bf867a5bcf4c6dd600790bd784424bdea837a47698c85082eebff 4c2839a7d98111e43bccabc839fd76ca6fc35b6bf294d93e800d8d0c8536b5b71eb11b6b2e5233227f42f2e4ba04645e\rCLIENT_HANDSHAKE_TRAFFIC_SECRET 59fd362f394bf867a5bcf4c6dd600790bd784424bdea837a47698c85082eebff 920fc5885c48f5aa5d79fc6749e29f9bc8841f73a87a949888e7bbfbabaff970bf54ed668e86c591b5d11c2ff59720e4\rCLIENT_TRAFFIC_SECRET_0 59fd362f394bf867a5bcf4c6dd600790bd784424bdea837a47698c85082eebff a1691a7847eb12b18d58152bb2b849ae588abf54b6f9ff019abebedb3e749e13bbe039526137d6b5ae2d6e630bb4589c\r"
dd1f248
#   Actual: "SERVER_HANDSHAKE_TRAFFIC_SECRET 59fd362f394bf867a5bcf4c6dd600790bd784424bdea837a47698c85082eebff d09d807afd55f9c1582e6879d97a262fa26f19db06cb57a14ce53f6be372dbb70ed036f8bf7d5f6a3168771eb2e4de30\rCLIENT_HANDSHAKE_TRAFFIC_SECRET 59fd362f394bf867a5bcf4c6dd600790bd784424bdea837a47698c85082eebff 920fc5885c48f5aa5d79fc6749e29f9bc8841f73a87a949888e7bbfbabaff970bf54ed668e86c591b5d11c2ff59720e4\rEXPORTER_SECRET 59fd362f394bf867a5bcf4c6dd600790bd784424bdea837a47698c85082eebff 5e76f891f0bbf4fa51a6fc5cc52aadf150995804a3ab81a185efb3ff02a6847ba7945cdd9a3a4c99ab3a657d150e1ca6\rSERVER_TRAFFIC_SECRET_0 59fd362f394bf867a5bcf4c6dd600790bd784424bdea837a47698c85082eebff 4c2839a7d98111e43bccabc839fd76ca6fc35b6bf294d93e800d8d0c8536b5b71eb11b6b2e5233227f42f2e4ba04645e\rCLIENT_TRAFFIC_SECRET_0 59fd362f394bf867a5bcf4c6dd600790bd784424bdea837a47698c85082eebff a1691a7847eb12b18d58152bb2b849ae588abf54b6f9ff019abebedb3e749e13bbe039526137d6b5ae2d6e630bb4589c\r"
dd1f248
# /builddir/build/BUILD/grpc-1.45.2/test/cpp/end2end/tls_key_export_test.cc:277: Failure
dd1f248
# Value of: server_key_log
dd1f248
# Expected: is equal to "SERVER_HANDSHAKE_TRAFFIC_SECRET 770d00f300fc4e6175da566d6d6b8d0fc247a27e7f1ec329b69d575e2a1f7bac e6fedd13291bdc2820ecbe310ffd3c778f4a74ddee894d617fb94bce1ac8ae89c2ea71b34e0036c48e8b7cb410a3ccad\rEXPORTER_SECRET 770d00f300fc4e6175da566d6d6b8d0fc247a27e7f1ec329b69d575e2a1f7bac 50cce74e4c6ac319c384cd9de9b68e0bc299f26a0ed2142d710b0cf361fd188eabb2c7f3bd8113cae2fcb4f3eca66c22\rSERVER_TRAFFIC_SECRET_0 770d00f300fc4e6175da566d6d6b8d0fc247a27e7f1ec329b69d575e2a1f7bac 90d2e703ad1079114b224f53a5f8225fe0305987d6a219527d28903ccae552f27b5ca7089d7790d66da0cccbdfd26645\rCLIENT_HANDSHAKE_TRAFFIC_SECRET 770d00f300fc4e6175da566d6d6b8d0fc247a27e7f1ec329b69d575e2a1f7bac 6b0dcc8075ee0b2188b6cf781662be3c8b3e43476ac48f2ab1257adb8c9e9c74b5824347e18c4f969c6cbb30d5c7207f\rCLIENT_TRAFFIC_SECRET_0 770d00f300fc4e6175da566d6d6b8d0fc247a27e7f1ec329b69d575e2a1f7bac 1acef388db865ac638051ee13f5b6ef7a9ca79822e0436a11aaf64a1af2cb07a72cf26a115cb35556637a0a7c2fd27a2\r"
dd1f248
#   Actual: "SERVER_HANDSHAKE_TRAFFIC_SECRET 770d00f300fc4e6175da566d6d6b8d0fc247a27e7f1ec329b69d575e2a1f7bac e6fedd13291bdc2820ecbe310ffd3c778f4a74ddee894d617fb94bce1ac8ae89c2ea71b34e0036c48e8b7cb410a3ccad\rCLIENT_HANDSHAKE_TRAFFIC_SECRET 770d00f300fc4e6175da566d6d6b8d0fc247a27e7f1ec329b69d575e2a1f7bac 6b0dcc8075ee0b2188b6cf781662be3c8b3e43476ac48f2ab1257adb8c9e9c74b5824347e18c4f969c6cbb30d5c7207f\rEXPORTER_SECRET 770d00f300fc4e6175da566d6d6b8d0fc247a27e7f1ec329b69d575e2a1f7bac 50cce74e4c6ac319c384cd9de9b68e0bc299f26a0ed2142d710b0cf361fd188eabb2c7f3bd8113cae2fcb4f3eca66c22\rSERVER_TRAFFIC_SECRET_0 770d00f300fc4e6175da566d6d6b8d0fc247a27e7f1ec329b69d575e2a1f7bac 90d2e703ad1079114b224f53a5f8225fe0305987d6a219527d28903ccae552f27b5ca7089d7790d66da0cccbdfd26645\rCLIENT_TRAFFIC_SECRET_0 770d00f300fc4e6175da566d6d6b8d0fc247a27e7f1ec329b69d575e2a1f7bac 1acef388db865ac638051ee13f5b6ef7a9ca79822e0436a11aaf64a1af2cb07a72cf26a115cb35556637a0a7c2fd27a2\r"
dd1f248
# [  FAILED  ] TlsKeyLogging/TlsKeyLoggingEnd2EndTest.KeyLogging/TestScenario__num_listening_ports_5__share_tls_key_log_file_false__enable_tls_key_logging_true, where GetParam() = 8-byte object <05-00 00-00 00-01 00-00> (66 ms)
dd1f248
# [ RUN      ] TlsKeyLogging/TlsKeyLoggingEnd2EndTest.KeyLogging/TestScenario__num_listening_ports_5__share_tls_key_log_file_true__enable_tls_key_logging_true
dd1f248
# /builddir/build/BUILD/grpc-1.45.2/test/cpp/end2end/tls_key_export_test.cc:277: Failure
dd1f248
# Value of: server_key_log
dd1f248
# Expected: is equal to "SERVER_HANDSHAKE_TRAFFIC_SECRET 4a8ed2a8c89cd95df5f9d01850058410323c6af346b963681db84235dfa2ec4d 73d93193674a9695da3a647bba6c3f73fbfc97c4aa8ec7c6c5c4fb3bd5c6820ce08c0a1820180e3ce43aab2f75b72aac\rEXPORTER_SECRET 4a8ed2a8c89cd95df5f9d01850058410323c6af346b963681db84235dfa2ec4d 763fa5cb1c97c94afc21ebc009e892dc383e201a6e9e96edc23c17b5cd97f524ba52644a1df4a75615df043de4fbcb39\rSERVER_TRAFFIC_SECRET_0 4a8ed2a8c89cd95df5f9d01850058410323c6af346b963681db84235dfa2ec4d e5f7b8ab7a46968f2ad0dcaf6af74ad22a9da21fb832b5d4bbf307cc791fa5354ba6ba8fc43397b3895b5fc83c8f65f4\rCLIENT_HANDSHAKE_TRAFFIC_SECRET 4a8ed2a8c89cd95df5f9d01850058410323c6af346b963681db84235dfa2ec4d f5f336b8428667b13bf8a67bb0dcb9c21ba2fe8cfe1281d2a41c55b170b49ae79b4a5d1eac5742d9658af5ef547f344d\rCLIENT_TRAFFIC_SECRET_0 4a8ed2a8c89cd95df5f9d01850058410323c6af346b963681db84235dfa2ec4d 6c16bd5f35371de56139a027f06004bc264725922a09bfef8cdf7a33e7b4b8c69f0bf6293e2cb3523c7f22e84410176d\rSERVER_HANDSHAKE_TRAFFIC_SECRET 22d345d7c46834996e8db60793f8dbfe71ea9adc4124ac72934a56418b923736 ea5bed615069634fe81ec1a9f6096e5ee1c74fe321743a65898eecfbfab9956e73d7de35a9eba0fc55b957ba6cdf34ee\rEXPORTER_SECRET 22d345d7c46834996e8db60793f8dbfe71ea9adc4124ac72934a56418b923736 113d480846d1db2326c46f52559f173d5a390220618ea81afd5a63165a64cc911ff011dbf915de20699251a25036655a\rSERVER_TRAFFIC_SECRET_0 22d345d7c46834996e8db60793f8dbfe71ea9adc4124ac72934a56418b923736 443c7cfb34709b1ce2e80592e2192786ee6e1ad86f145a32e1ec9fc076b682b5cdcc7def181fbc51f835cf4888f0f85b\rCLIENT_HANDSHAKE_TRAFFIC_SECRET 22d345d7c46834996e8db60793f8dbfe71ea9adc4124ac72934a56418b923736 8fd27dfdb917133ba4a9dc594821ca3df81fecd60da72dd8f5b779a96cbd3a41ce9e93b435eac4850d29faddb7500dc8\rCLIENT_TRAFFIC_SECRET_0 22d345d7c46834996e8db60793f8dbfe71ea9adc4124ac72934a56418b923736 691969bbf02c386f2758cc5dfd197fc7272430902b0c90a4b365ab3a1cc5066a616bc50ad29ceecba6f23dc85bd277e5\rSERVER_HANDSHAKE_TRAFFIC_SECRET f274f840c4d297c3fdefa0dd5695c4573c9037075b9d79432e88faa4a187385a 3c17149401c2b3878cbe3105164d362bba2e098e0d1de09bf69939568a2c69133c0ddc1c8fa76903e5e293b1197a01fb\rEXPORTER_SECRET f274f840c4d297c3fdefa0dd5695c4573c9037075b9d79432e88faa4a187385a e668b4888a058ce00a93da55ac690365336ee6cf331ad2ae97e0b8c837cf0b449aed4940ee2a3ab56c045056c1d5574d\rSERVER_TRAFFIC_SECRET_0 f274f840c4d297c3fdefa0dd5695c4573c9037075b9d79432e88faa4a187385a 7bd47384a53931188daab512bb59cedfd2f309ed189f80ad737f4465cd00fb472cc11992204c2252d534ffc9b48bc097\rCLIENT_HANDSHAKE_TRAFFIC_SECRET f274f840c4d297c3fdefa0dd5695c4573c9037075b9d79432e88faa4a187385a 6ae0594f0c38c3abf6a65b428f00347c6aee8b60a54fd702458ab439c6f718c58bdf55b92c42b3d968663e385922294b\rCLIENT_TRAFFIC_SECRET_0 f274f840c4d297c3fdefa0dd5695c4573c9037075b9d79432e88faa4a187385a cd9ed62e171e71d65580455e7ce374a2a91e15f3f889441144c23b2a54e6c4b2daf98e09525c317d871686872a5f2d81\rSERVER_HANDSHAKE_TRAFFIC_SECRET 3021d89743e0308f3bfe589aa16ed52d82bafe35506b5bfcdc31863f3fa9aaff 330b459fed7217708e8163baf5eabe6a34a45bbf3d4c1bde32f7bcce29016bec85539ee7724c73d23cbaaa5f8e100a34\rEXPORTER_SECRET 3021d89743e0308f3bfe589aa16ed52d82bafe35506b5bfcdc31863f3fa9aaff cc32ae2d7a1bd46bc38569ebf0987e36b4ef1037f5280099a80e3ee5cf83a0be1d8283f5d925e12c78b27660de63cc9f\rSERVER_TRAFFIC_SECRET_0 3021d89743e0308f3bfe589aa16ed52d82bafe35506b5bfcdc31863f3fa9aaff 2be00b20bdf6157af69c6bac8806d5dfb6c13a3cfa9d314c73d46ead360f3a9c1562eb2eb1a073c86fab2ceda4da2a56\rCLIENT_HANDSHAKE_TRAFFIC_SECRET 3021d89743e0308f3bfe589aa16ed52d82bafe35506b5bfcdc31863f3fa9aaff e106db0914f10fc6612d4b1cbdeb92bffc3ec4c21ab906a17a3a060b7a5d91e805a41b98822f9a6482e8eb510fb37ba4\rCLIENT_TRAFFIC_SECRET_0 3021d89743e0308f3bfe589aa16ed52d82bafe35506b5bfcdc31863f3fa9aaff 7505e76f6398b39352003bbc3268a36a137ef4ecb2a795a8f53e9a77fdf57b5b1e2793f2ed6cb721e991920d87607aa7\rSERVER_HANDSHAKE_TRAFFIC_SECRET 14e07d555479cf6be60e056105482571a0b06a92c686246a0dfecf2c5ef7eb18 c96ade516607c05ac9b5016caf4d554ba26c8b540c37eb5d4c6a4f1849b4e50da20614cf55909d0998e744a4b0e9e276\rEXPORTER_SECRET 14e07d555479cf6be60e056105482571a0b06a92c686246a0dfecf2c5ef7eb18 4e5196a9c611ae860f8b8b7d16f8130fcfdacdf899831997e7a410e18d2d9b19f5eaa2aa79b868b5b6bad29a84e97fff\rSERVER_TRAFFIC_SECRET_0 14e07d555479cf6be60e056105482571a0b06a92c686246a0dfecf2c5ef7eb18 aac75064ad90e8b08818e4c6d0b895639f78f89d5ea9e3bc780b9fc295f2430fd4edb30eef91202bcc61b19774bcbdd9\rCLIENT_HANDSHAKE_TRAFFIC_SECRET 14e07d555479cf6be60e056105482571a0b06a92c686246a0dfecf2c5ef7eb18 658902e283b741d5057db588d38b0d565fe3479bb242a7b93ec614f94d142b86608c9b6e6e93794c28e06ab7a12e3382\rCLIENT_TRAFFIC_SECRET_0 14e07d555479cf6be60e056105482571a0b06a92c686246a0dfecf2c5ef7eb18 062684c5b1bcb1ba7b1997c88694d06f81a250f7bb90b9c0214989753eca11c2308a0e5431d6c80607ad5cd7f83ad98d\r"
dd1f248
#   Actual: "SERVER_HANDSHAKE_TRAFFIC_SECRET 4a8ed2a8c89cd95df5f9d01850058410323c6af346b963681db84235dfa2ec4d 73d93193674a9695da3a647bba6c3f73fbfc97c4aa8ec7c6c5c4fb3bd5c6820ce08c0a1820180e3ce43aab2f75b72aac\rCLIENT_HANDSHAKE_TRAFFIC_SECRET 4a8ed2a8c89cd95df5f9d01850058410323c6af346b963681db84235dfa2ec4d f5f336b8428667b13bf8a67bb0dcb9c21ba2fe8cfe1281d2a41c55b170b49ae79b4a5d1eac5742d9658af5ef547f344d\rEXPORTER_SECRET 4a8ed2a8c89cd95df5f9d01850058410323c6af346b963681db84235dfa2ec4d 763fa5cb1c97c94afc21ebc009e892dc383e201a6e9e96edc23c17b5cd97f524ba52644a1df4a75615df043de4fbcb39\rSERVER_TRAFFIC_SECRET_0 4a8ed2a8c89cd95df5f9d01850058410323c6af346b963681db84235dfa2ec4d e5f7b8ab7a46968f2ad0dcaf6af74ad22a9da21fb832b5d4bbf307cc791fa5354ba6ba8fc43397b3895b5fc83c8f65f4\rCLIENT_TRAFFIC_SECRET_0 4a8ed2a8c89cd95df5f9d01850058410323c6af346b963681db84235dfa2ec4d 6c16bd5f35371de56139a027f06004bc264725922a09bfef8cdf7a33e7b4b8c69f0bf6293e2cb3523c7f22e84410176d\rSERVER_HANDSHAKE_TRAFFIC_SECRET 22d345d7c46834996e8db60793f8dbfe71ea9adc4124ac72934a56418b923736 ea5bed615069634fe81ec1a9f6096e5ee1c74fe321743a65898eecfbfab9956e73d7de35a9eba0fc55b957ba6cdf34ee\rCLIENT_HANDSHAKE_TRAFFIC_SECRET 22d345d7c46834996e8db60793f8dbfe71ea9adc4124ac72934a56418b923736 8fd27dfdb917133ba4a9dc594821ca3df81fecd60da72dd8f5b779a96cbd3a41ce9e93b435eac4850d29faddb7500dc8\rEXPORTER_SECRET 22d345d7c46834996e8db60793f8dbfe71ea9adc4124ac72934a56418b923736 113d480846d1db2326c46f52559f173d5a390220618ea81afd5a63165a64cc911ff011dbf915de20699251a25036655a\rSERVER_TRAFFIC_SECRET_0 22d345d7c46834996e8db60793f8dbfe71ea9adc4124ac72934a56418b923736 443c7cfb34709b1ce2e80592e2192786ee6e1ad86f145a32e1ec9fc076b682b5cdcc7def181fbc51f835cf4888f0f85b\rCLIENT_TRAFFIC_SECRET_0 22d345d7c46834996e8db60793f8dbfe71ea9adc4124ac72934a56418b923736 691969bbf02c386f2758cc5dfd197fc7272430902b0c90a4b365ab3a1cc5066a616bc50ad29ceecba6f23dc85bd277e5\rSERVER_HANDSHAKE_TRAFFIC_SECRET f274f840c4d297c3fdefa0dd5695c4573c9037075b9d79432e88faa4a187385a 3c17149401c2b3878cbe3105164d362bba2e098e0d1de09bf69939568a2c69133c0ddc1c8fa76903e5e293b1197a01fb\rCLIENT_HANDSHAKE_TRAFFIC_SECRET f274f840c4d297c3fdefa0dd5695c4573c9037075b9d79432e88faa4a187385a 6ae0594f0c38c3abf6a65b428f00347c6aee8b60a54fd702458ab439c6f718c58bdf55b92c42b3d968663e385922294b\rEXPORTER_SECRET f274f840c4d297c3fdefa0dd5695c4573c9037075b9d79432e88faa4a187385a e668b4888a058ce00a93da55ac690365336ee6cf331ad2ae97e0b8c837cf0b449aed4940ee2a3ab56c045056c1d5574d\rSERVER_TRAFFIC_SECRET_0 f274f840c4d297c3fdefa0dd5695c4573c9037075b9d79432e88faa4a187385a 7bd47384a53931188daab512bb59cedfd2f309ed189f80ad737f4465cd00fb472cc11992204c2252d534ffc9b48bc097\rCLIENT_TRAFFIC_SECRET_0 f274f840c4d297c3fdefa0dd5695c4573c9037075b9d79432e88faa4a187385a cd9ed62e171e71d65580455e7ce374a2a91e15f3f889441144c23b2a54e6c4b2daf98e09525c317d871686872a5f2d81\rSERVER_HANDSHAKE_TRAFFIC_SECRET 3021d89743e0308f3bfe589aa16ed52d82bafe35506b5bfcdc31863f3fa9aaff 330b459fed7217708e8163baf5eabe6a34a45bbf3d4c1bde32f7bcce29016bec85539ee7724c73d23cbaaa5f8e100a34\rCLIENT_HANDSHAKE_TRAFFIC_SECRET 3021d89743e0308f3bfe589aa16ed52d82bafe35506b5bfcdc31863f3fa9aaff e106db0914f10fc6612d4b1cbdeb92bffc3ec4c21ab906a17a3a060b7a5d91e805a41b98822f9a6482e8eb510fb37ba4\rEXPORTER_SECRET 3021d89743e0308f3bfe589aa16ed52d82bafe35506b5bfcdc31863f3fa9aaff cc32ae2d7a1bd46bc38569ebf0987e36b4ef1037f5280099a80e3ee5cf83a0be1d8283f5d925e12c78b27660de63cc9f\rSERVER_TRAFFIC_SECRET_0 3021d89743e0308f3bfe589aa16ed52d82bafe35506b5bfcdc31863f3fa9aaff 2be00b20bdf6157af69c6bac8806d5dfb6c13a3cfa9d314c73d46ead360f3a9c1562eb2eb1a073c86fab2ceda4da2a56\rCLIENT_TRAFFIC_SECRET_0 3021d89743e0308f3bfe589aa16ed52d82bafe35506b5bfcdc31863f3fa9aaff 7505e76f6398b39352003bbc3268a36a137ef4ecb2a795a8f53e9a77fdf57b5b1e2793f2ed6cb721e991920d87607aa7\rSERVER_HANDSHAKE_TRAFFIC_SECRET 14e07d555479cf6be60e056105482571a0b06a92c686246a0dfecf2c5ef7eb18 c96ade516607c05ac9b5016caf4d554ba26c8b540c37eb5d4c6a4f1849b4e50da20614cf55909d0998e744a4b0e9e276\rCLIENT_HANDSHAKE_TRAFFIC_SECRET 14e07d555479cf6be60e056105482571a0b06a92c686246a0dfecf2c5ef7eb18 658902e283b741d5057db588d38b0d565fe3479bb242a7b93ec614f94d142b86608c9b6e6e93794c28e06ab7a12e3382\rEXPORTER_SECRET 14e07d555479cf6be60e056105482571a0b06a92c686246a0dfecf2c5ef7eb18 4e5196a9c611ae860f8b8b7d16f8130fcfdacdf899831997e7a410e18d2d9b19f5eaa2aa79b868b5b6bad29a84e97fff\rSERVER_TRAFFIC_SECRET_0 14e07d555479cf6be60e056105482571a0b06a92c686246a0dfecf2c5ef7eb18 aac75064ad90e8b08818e4c6d0b895639f78f89d5ea9e3bc780b9fc295f2430fd4edb30eef91202bcc61b19774bcbdd9\rCLIENT_TRAFFIC_SECRET_0 14e07d555479cf6be60e056105482571a0b06a92c686246a0dfecf2c5ef7eb18 062684c5b1bcb1ba7b1997c88694d06f81a250f7bb90b9c0214989753eca11c2308a0e5431d6c80607ad5cd7f83ad98d\r"
dd1f248
# [  FAILED  ] TlsKeyLogging/TlsKeyLoggingEnd2EndTest.KeyLogging/TestScenario__num_listening_ports_5__share_tls_key_log_file_true__enable_tls_key_logging_true, where GetParam() = 8-byte object <05-00 00-00 01-01 00-00> (80 ms)
dd1f248
# [ RUN      ] TlsKeyLogging/TlsKeyLoggingEnd2EndTest.KeyLogging/TestScenario__num_listening_ports_5__share_tls_key_log_file_true__enable_tls_key_logging_false
dd1f248
# [       OK ] TlsKeyLogging/TlsKeyLoggingEnd2EndTest.KeyLogging/TestScenario__num_listening_ports_5__share_tls_key_log_file_true__enable_tls_key_logging_false (71 ms)
dd1f248
# [ RUN      ] TlsKeyLogging/TlsKeyLoggingEnd2EndTest.KeyLogging/TestScenario__num_listening_ports_5__share_tls_key_log_file_false__enable_tls_key_logging_false
dd1f248
# [       OK ] TlsKeyLogging/TlsKeyLoggingEnd2EndTest.KeyLogging/TestScenario__num_listening_ports_5__share_tls_key_log_file_false__enable_tls_key_logging_false (70 ms)
dd1f248
# [----------] 4 tests from TlsKeyLogging/TlsKeyLoggingEnd2EndTest (289 ms total)
dd1f248
#
dd1f248
# [----------] Global test environment tear-down
dd1f248
# [==========] 4 tests from 1 test suite ran. (289 ms total)
dd1f248
# [  PASSED  ] 2 tests.
dd1f248
# [  FAILED  ] 2 tests, listed below:
dd1f248
# [  FAILED  ] TlsKeyLogging/TlsKeyLoggingEnd2EndTest.KeyLogging/TestScenario__num_listening_ports_5__share_tls_key_log_file_false__enable_tls_key_logging_true, where GetParam() = 8-byte object <05-00 00-00 00-01 00-00>
dd1f248
# [  FAILED  ] TlsKeyLogging/TlsKeyLoggingEnd2EndTest.KeyLogging/TestScenario__num_listening_ports_5__share_tls_key_log_file_true__enable_tls_key_logging_true, where GetParam() = 8-byte object <05-00 00-00 01-01 00-00>
dd1f248
#
dd1f248
# Confirmed in 1.46.0 2022-05-10
dd1f248
tls_key_export
dd1f248
dd1f248
# Unexplained, flaky:
33f1b89
#
dd1f248
# [ RUN      ] XdsTest/XdsSecurityTest.TestTlsConfigurationWithRootPluginUpdate/V3XdsCreds
dd1f248
# E0514 12:41:31.427154539 3509119 ssl_transport_security.cc:1910] No match found for server name: server.example.com.
dd1f248
# *** SIGSEGV received at time=1652532091 on cpu 4 ***
dd1f248
# PC: @     0x7f2f65694f88  (unknown)  grpc_core::CertificateProviderStore::CertificateProviderWrapper::interested_parties()
dd1f248
#     @               0x34  (unknown)  (unknown)
33f1b89
#
dd1f248
# Confirmed in 1.46.1 2022-05-14 (on at least x86_64 and s390x)
33f1b89
xds_end2end
33f1b89
ee2d9c9
EOF
603761e
} | xargs -r chmod -v a-x
ee2d9c9
ce88e01
find %{_vpath_builddir} -type f -perm /0111 -name '*_test' | sort |
ee2d9c9
  while read -r testexe
ee2d9c9
  do
ee2d9c9
    echo "==== $(date -u --iso-8601=ns): $(basename "${testexe}") ===="
ce88e01
    %{__python3} tools/run_tests/start_port_server.py
dd1f248
dd1f248
%if %{without gdb}
dd1f248
    # There is a history of some tests failing by hanging. We use “timeout” so
dd1f248
    # that a test that does hang breaks the build in a vagurely reasonable
dd1f248
    # amount of time. Some tests really can be slow, so the timeout is long!
dd1f248
    timeout -k 61m -v 60m \
dd1f248
%if %{with valgrind}
dd1f248
        valgrind --trace-children=yes --leak-check=full --track-origins=yes \
dd1f248
%endif
dd1f248
        "${testexe}"
dd1f248
%else
dd1f248
    # Script gdb to run the test file and record any backtrace. Note that this
dd1f248
    # reports an error when tests fail, because there is no stack on which to
dd1f248
    # report a backtrace after the test exits successfully, and that this keeps
dd1f248
    # going after a test fails, because we ignore the mentioned error. A
dd1f248
    # cleverer gdb script would be nice, but this is good enough for the
dd1f248
    # intended purpose.
dd1f248
    tee "${testexe}-script.gdb" <
dd1f248
set pagination off
dd1f248
set logging file ${testexe}-gdb.log
dd1f248
set logging on
dd1f248
file ${testexe}
dd1f248
run
dd1f248
bt -full
dd1f248
set logging off
dd1f248
quit
dd1f248
EOF
dd1f248
    gdb -q -x "${testexe}-script.gdb" --batch 
dd1f248
%endif
ee2d9c9
  done
ce88e01
ce88e01
# Stop the port server
ce88e01
curl "http://localhost:${PORT_SERVER_PORT}/quitquitquit" || :
34ecf95
%endif
87469ef
87469ef
pushd src/python/grpcio_tests
426ac1e
for suite in \
426ac1e
    test_lite \
426ac1e
    %{?with_python_aio_tests:test_aio} \
ce88e01
    %{?with_python_gevent_tests:test_gevent} \
ce88e01
    test_py3_only
426ac1e
do
2933935
  echo "==== $(date -u --iso-8601=ns): Python ${suite} ===="
426ac1e
  # See the implementation of the %%pytest macro, upon which our environment
2933935
  # setup is based. We add a timeout that is rather long, as it must apply to
2933935
  # the entire test suite. (Patching in a per-test timeout would be harder.)
426ac1e
  env CFLAGS="${CFLAGS:-${RPM_OPT_FLAGS}}" \
426ac1e
      LDFLAGS="${LDFLAGS:-${RPM_LD_FLAGS}}" \
426ac1e
      PATH="%{buildroot}%{_bindir}:$PATH" \
426ac1e
      PYTHONPATH="${PYTHONPATH:-%{buildroot}%{python3_sitearch}:%{buildroot}%{python3_sitelib}}" \
426ac1e
      PYTHONDONTWRITEBYTECODE=1 \
2933935
      timeout -k 31m -v 30m \
426ac1e
      %{__python3} %{py_setup} %{?py_setup_args} "${suite}"
426ac1e
done
87469ef
popd
bf7e9a8
951e7fa
%endif
951e7fa
acc3813
%if %{without system_gtest}
acc3813
# As a sanity check for our claim that gtest/gmock are not bundled, check
acc3813
# installed executables for symbols that appear to have come from gtest/gmock.
acc3813
foundgtest=0
acc3813
if find %{buildroot} -type f -perm /0111 \
acc3813
      -execdir objdump --syms --dynamic-syms --demangle '{}' '+' 2>/dev/null |
acc3813
    grep -E '[^:]testing::'
acc3813
then
acc3813
  echo 'Found traces of gtest/gmock' 1>&2
acc3813
  exit 1
acc3813
fi
acc3813
%endif
acc3813
bf7e9a8
bf7e9a8
%files
dd1f248
%license LICENSE NOTICE.txt LICENSE-utf8_range
87469ef
%{_libdir}/libaddress_sorting.so.%{c_so_version}*
87469ef
%{_libdir}/libgpr.so.%{c_so_version}*
ef054cb
%{_libdir}/libgrpc.so.%{c_so_version}*
ef054cb
%{_libdir}/libgrpc_unsecure.so.%{c_so_version}*
87469ef
%{_libdir}/libupb.so.%{c_so_version}*
87469ef
87469ef
87469ef
%files data
87469ef
%license LICENSE NOTICE.txt
ef054cb
%dir %{_datadir}/grpc
ef054cb
%{_datadir}/grpc/roots.pem
87469ef
87469ef
87469ef
%files doc
87469ef
%license LICENSE NOTICE.txt
87469ef
%{_pkgdocdir}
87469ef
87469ef
87469ef
%files cpp
ef054cb
%{_libdir}/libgrpc++.so.%{cpp_so_version}*
ef054cb
%{_libdir}/libgrpc++_alts.so.%{cpp_so_version}*
ef054cb
%{_libdir}/libgrpc++_error_details.so.%{cpp_so_version}*
ef054cb
%{_libdir}/libgrpc++_reflection.so.%{cpp_so_version}*
ef054cb
%{_libdir}/libgrpc++_unsecure.so.%{cpp_so_version}*
ef054cb
%{_libdir}/libgrpc_plugin_support.so.%{cpp_so_version}*
9ce49f9
ef054cb
%{_libdir}/libgrpcpp_channelz.so.%{cpp_so_version}*
87469ef
bf7e9a8
ce88e01
%if %{with core_tests}
bf7e9a8
%files cli
ef054cb
%{_bindir}/grpc_cli
dd1f248
%{_libdir}/libgrpc++_test_config.so.%{cpp_so_version}
ef054cb
%{_mandir}/man1/grpc_cli.1*
ef054cb
%{_mandir}/man1/grpc_cli-*.1*
ce88e01
%endif
87469ef
bf7e9a8
bf7e9a8
%files plugins
ce88e01
# These are for program use and do not offer a CLI for the end user, so they
ce88e01
# should really be in %%{_libexecdir}; however, too many downstream users
ce88e01
# expect them in $PATH to change this for the time being.
ef054cb
%{_bindir}/grpc_*_plugin
87469ef
bf7e9a8
bf7e9a8
%files devel
3b94ecf
%{_libdir}/libaddress_sorting.so
3b94ecf
%{_libdir}/libgpr.so
ef054cb
%{_libdir}/libgrpc.so
ef054cb
%{_libdir}/libgrpc_unsecure.so
3b94ecf
%{_libdir}/libupb.so
ef054cb
%{_includedir}/grpc
87469ef
%{_libdir}/pkgconfig/gpr.pc
ef054cb
%{_libdir}/pkgconfig/grpc.pc
ef054cb
%{_libdir}/pkgconfig/grpc_unsecure.pc
ef054cb
%{_libdir}/cmake/grpc
ef054cb
ef054cb
%{_libdir}/libgrpc++.so
ef054cb
%{_libdir}/libgrpc++_alts.so
ef054cb
%{_libdir}/libgrpc++_error_details.so
ef054cb
%{_libdir}/libgrpc++_reflection.so
ef054cb
%{_libdir}/libgrpc++_unsecure.so
ef054cb
%{_libdir}/libgrpc_plugin_support.so
ef054cb
%{_includedir}/grpc++
ef054cb
%{_libdir}/pkgconfig/grpc++.pc
ef054cb
%{_libdir}/pkgconfig/grpc++_unsecure.pc
ef054cb
ef054cb
%{_libdir}/libgrpcpp_channelz.so
ef054cb
%{_includedir}/grpcpp
87469ef
bf7e9a8
637ef64
%files -n python3-grpcio
dd1f248
%license LICENSE NOTICE.txt LICENSE-utf8_range
637ef64
%{python3_sitearch}/grpc
dd1f248
%{python3_sitearch}/grpcio-%{pyversion}-py%{python3_version}.egg-info
637ef64
87469ef
87469ef
%files -n python3-grpcio-tools
dd1f248
%license LICENSE NOTICE.txt LICENSE-utf8_range
87469ef
%{python3_sitearch}/grpc_tools
dd1f248
%{python3_sitearch}/grpcio_tools-%{pyversion}-py%{python3_version}.egg-info
87469ef
87469ef
2933935
%if %{without bootstrap}
2933935
%files -n python3-grpcio-admin
2933935
%{python3_sitelib}/grpc_admin
dd1f248
%{python3_sitelib}/grpcio_admin-%{pyversion}-py%{python3_version}.egg-info
2933935
%endif
2933935
2933935
87469ef
%files -n python3-grpcio-channelz
87469ef
%{python3_sitelib}/grpc_channelz
dd1f248
%{python3_sitelib}/grpcio_channelz-%{pyversion}-py%{python3_version}.egg-info
87469ef
87469ef
2933935
%if %{without bootstrap}
2933935
%files -n python3-grpcio-csds
2933935
%{python3_sitelib}/grpc_csds
dd1f248
%{python3_sitelib}/grpcio_csds-%{pyversion}-py%{python3_version}.egg-info
2933935
%endif
2933935
2933935
87469ef
%files -n python3-grpcio-health-checking
87469ef
%{python3_sitelib}/grpc_health
dd1f248
%{python3_sitelib}/grpcio_health_checking-%{pyversion}-py%{python3_version}.egg-info
87469ef
87469ef
87469ef
%files -n python3-grpcio-reflection
87469ef
%{python3_sitelib}/grpc_reflection
dd1f248
%{python3_sitelib}/grpcio_reflection-%{pyversion}-py%{python3_version}.egg-info
87469ef
87469ef
87469ef
%files -n python3-grpcio-status
87469ef
%{python3_sitelib}/grpc_status
dd1f248
%{python3_sitelib}/grpcio_status-%{pyversion}-py%{python3_version}.egg-info
87469ef
87469ef
87469ef
%files -n python3-grpcio-testing
87469ef
%{python3_sitelib}/grpc_testing
dd1f248
%{python3_sitelib}/grpcio_testing-%{pyversion}-py%{python3_version}.egg-info
87469ef
87469ef
bf7e9a8
%changelog
1c408ac
%autochangelog