Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
devel/grpc142: Fix build with protobuf 22+
- Loading branch information
Showing
2 changed files
with
67 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,66 @@ | ||
--- CMakeLists.txt.orig 2021-11-16 23:39:48 UTC | ||
+++ CMakeLists.txt | ||
@@ -191,7 +191,7 @@ endif() | ||
|
||
# Add c++11 flags | ||
if (NOT DEFINED CMAKE_CXX_STANDARD) | ||
- set(CMAKE_CXX_STANDARD 11) | ||
+ set(CMAKE_CXX_STANDARD 17) | ||
else() | ||
if (CMAKE_CXX_STANDARD LESS 11) | ||
message(FATAL_ERROR "CMAKE_CXX_STANDARD is less than 11, please specify at least SET(CMAKE_CXX_STANDARD 11)") | ||
--- src/compiler/config_protobuf.h.orig 2021-11-16 23:39:48 UTC | ||
+++ src/compiler/config_protobuf.h | ||
@@ -50,7 +50,7 @@ | ||
#endif | ||
|
||
#ifndef GRPC_CUSTOM_CSHARP_GETCLASSNAME | ||
-#include <google/protobuf/compiler/csharp/csharp_names.h> | ||
+#include <google/protobuf/compiler/csharp/names.h> | ||
#define GRPC_CUSTOM_CSHARP_GETCLASSNAME \ | ||
::google::protobuf::compiler::csharp::GetClassName | ||
#define GRPC_CUSTOM_CSHARP_GETFILENAMESPACE \ | ||
--- src/compiler/objective_c_generator.cc.orig 2021-11-16 23:39:48 UTC | ||
+++ src/compiler/objective_c_generator.cc | ||
@@ -22,7 +22,7 @@ | ||
#include <set> | ||
#include <sstream> | ||
|
||
-#include <google/protobuf/compiler/objectivec/objectivec_helpers.h> | ||
+#include <google/protobuf/compiler/objectivec/names.h> | ||
|
||
#include "src/compiler/config.h" | ||
#include "src/compiler/objective_c_generator_helpers.h" | ||
--- src/compiler/objective_c_generator_helpers.h.orig 2021-11-16 23:39:48 UTC | ||
+++ src/compiler/objective_c_generator_helpers.h | ||
@@ -21,7 +21,7 @@ | ||
|
||
#include <map> | ||
|
||
-#include <google/protobuf/compiler/objectivec/objectivec_helpers.h> | ||
+#include <google/protobuf/compiler/objectivec/names.h> | ||
|
||
#include "src/compiler/config.h" | ||
#include "src/compiler/generator_helpers.h" | ||
--- src/compiler/objective_c_plugin.cc.orig 2021-11-16 23:39:48 UTC | ||
+++ src/compiler/objective_c_plugin.cc | ||
@@ -20,7 +20,7 @@ | ||
|
||
#include <memory> | ||
|
||
-#include <google/protobuf/compiler/objectivec/objectivec_helpers.h> | ||
+#include <google/protobuf/compiler/objectivec/names.h> | ||
|
||
#include "src/compiler/config.h" | ||
#include "src/compiler/objective_c_generator.h" | ||
--- include/grpcpp/impl/codegen/config_protobuf.h.orig 2021-11-16 23:39:48 UTC | ||
+++ include/grpcpp/impl/codegen/config_protobuf.h | ||
@@ -69,7 +69,7 @@ | ||
#include <google/protobuf/util/json_util.h> | ||
#include <google/protobuf/util/type_resolver_util.h> | ||
#define GRPC_CUSTOM_JSONUTIL ::google::protobuf::util | ||
-#define GRPC_CUSTOM_UTIL_STATUS ::google::protobuf::util::Status | ||
+#define GRPC_CUSTOM_UTIL_STATUS ::absl::Status | ||
#endif | ||
|
||
namespace grpc { |