aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/cpp/ext
diff options
context:
space:
mode:
authorGravatar Yuchen Zeng <zyc@google.com>2016-07-19 19:12:46 -0700
committerGravatar Yuchen Zeng <zyc@google.com>2016-07-19 19:12:46 -0700
commit6b88b22d9e844254406e8b4d572d4b0476c04cd2 (patch)
treed2abc5b69456a0907bed2fe4c68500fcf0a3c7b4 /src/cpp/ext
parent77b74258b56dcc19c3a6d6be32eca579eac95aae (diff)
Add comments for GRPC_NO_GENERATED_CODE
Diffstat (limited to 'src/cpp/ext')
-rw-r--r--src/cpp/ext/proto_server_reflection.h14
1 files changed, 14 insertions, 0 deletions
diff --git a/src/cpp/ext/proto_server_reflection.h b/src/cpp/ext/proto_server_reflection.h
index 1a9a0c95a8..fa3b9406c6 100644
--- a/src/cpp/ext/proto_server_reflection.h
+++ b/src/cpp/ext/proto_server_reflection.h
@@ -30,12 +30,26 @@
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
*/
+
+/*
+ - If the generated header `grpc++/ext/reflection.grpc.pb.h` needs to be
+ installed, target `grpc++_reflection` in `build.yaml` should use the
+ filegroup `grpc++_reflection_proto`, and GRPC_NO_GENERATED_CODE should not
+ be defined.
+ - If the server reflection library needs to generate `reflection.grpc.pb.h`
+ from `reflection.proto` at the time of making, the generated header
+ `grpc++/ext/reflection.grpc.pb.h` should not be installed. In this case,
+ target `grpc++_reflection` should depend on `grpc++_reflection_codegen`, and
+ GRPC_NO_GENERATED_CODE should be defined.
+*/
+
#ifndef GRPC_INTERNAL_CPP_EXT_PROTO_SERVER_REFLECTION_H
#define GRPC_INTERNAL_CPP_EXT_PROTO_SERVER_REFLECTION_H
#include <unordered_set>
#include <vector>
+// GRPC_NO_GENERATED_CODE indicates generated pb files should not be used
#ifdef GRPC_NO_GENERATED_CODE
#include "src/proto/grpc/reflection/v1alpha/reflection.grpc.pb.h"
#else