Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(111)

Issue 2082693002: Plugin support for protobuf compiler (protoc) targets. (Closed)

Created:
4 years, 6 months ago by kraynov
Modified:
4 years, 5 months ago
CC:
chromium-reviews
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Plugin support for protobuf compiler (protoc) targets. Until now the protobuf generator targets in the build files did hard-code the unconditional generation of C++ and python stubs. There are two new upcoming use cases, that are, bit.ly/TracingV2 (see BUG) and gRPC, where we need to generate C++ stubs using a custom protoc plugin. This CL introduces the plumbing necessary to the GYP/GN build files to be able to pass an arbitrary plugin to the protoc invocation. See crrev.com/2083373002 as an example of how this will be used in upcoming CLs. BUG=622680 Committed: https://crrev.com/b241e6e5fa05e90eaa4199d4bc497869e3cf08e1 Cr-Commit-Position: refs/heads/master@{#403981}

Patch Set 1 #

Total comments: 2

Patch Set 2 : cc_generator_suffix #

Patch Set 3 : more flexible targets and revert of protoc_wrapper #

Total comments: 13

Patch Set 4 : minor fixes #

Patch Set 5 #

Total comments: 3

Patch Set 6 : comments #

Total comments: 1

Patch Set 7 : comment #

Total comments: 1

Patch Set 8 : hard_dependency #

Patch Set 9 : rebase #

Unified diffs Side-by-side diffs Delta from patch set Stats (+136 lines, -54 lines) Patch
M build/protoc.gypi View 1 2 3 4 5 6 7 4 chunks +56 lines, -15 lines 0 comments Download
M third_party/protobuf/proto_library.gni View 1 2 3 4 5 6 7 8 5 chunks +80 lines, -39 lines 0 comments Download

Messages

Total messages: 50 (20 generated)
kraynov
Update of //third_party/protobuf/README.chromium is not required because nothing changed to upstream.
4 years, 6 months ago (2016-06-20 16:36:28 UTC) #1
kraynov
Please take a look. Thanks!
4 years, 6 months ago (2016-06-20 18:41:21 UTC) #4
xyzzyz
https://codereview.chromium.org/2082693002/diff/1/third_party/protobuf/proto_library.gni File third_party/protobuf/proto_library.gni (right): https://codereview.chromium.org/2082693002/diff/1/third_party/protobuf/proto_library.gni#newcode29 third_party/protobuf/proto_library.gni:29: # Plugin executable name. Expected .pb.h and .pb.cc as ...
4 years, 6 months ago (2016-06-20 20:17:47 UTC) #5
kraynov
https://codereview.chromium.org/2082693002/diff/1/third_party/protobuf/proto_library.gni File third_party/protobuf/proto_library.gni (right): https://codereview.chromium.org/2082693002/diff/1/third_party/protobuf/proto_library.gni#newcode29 third_party/protobuf/proto_library.gni:29: # Plugin executable name. Expected .pb.h and .pb.cc as ...
4 years, 6 months ago (2016-06-20 20:19:47 UTC) #6
kraynov
On 2016/06/20 20:19:47, kraynov wrote: > https://codereview.chromium.org/2082693002/diff/1/third_party/protobuf/proto_library.gni > File third_party/protobuf/proto_library.gni (right): > > https://codereview.chromium.org/2082693002/diff/1/third_party/protobuf/proto_library.gni#newcode29 > ...
4 years, 6 months ago (2016-06-21 11:19:06 UTC) #7
kraynov
protoc_wrapper.py is reverted. Found the way to implement the feature in GN and GYP only.
4 years, 6 months ago (2016-06-21 13:40:47 UTC) #10
Primiano Tucci (use gerrit)
Ok some comments. Overall seems to have a good shape. I'll leave the final round ...
4 years, 6 months ago (2016-06-21 14:15:10 UTC) #11
kraynov
https://codereview.chromium.org/2082693002/diff/40001/third_party/protobuf/proto_library.gni File third_party/protobuf/proto_library.gni (right): https://codereview.chromium.org/2082693002/diff/40001/third_party/protobuf/proto_library.gni#newcode111 third_party/protobuf/proto_library.gni:111: out_dir = "$root_gen_dir/" + proto_out_dir On 2016/06/21 14:15:09, Primiano ...
4 years, 6 months ago (2016-06-21 14:40:49 UTC) #12
kraynov
https://codereview.chromium.org/2082693002/diff/40001/build/protoc.gypi File build/protoc.gypi (right): https://codereview.chromium.org/2082693002/diff/40001/build/protoc.gypi#newcode128 build/protoc.gypi:128: 'protoc-gen-plugin=<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)<(generator_plugin)<(EXECUTABLE_SUFFIX)', On 2016/06/21 14:15:09, Primiano Tucci wrote: > I ...
4 years, 6 months ago (2016-06-21 14:50:12 UTC) #13
kraynov
4 years, 6 months ago (2016-06-21 16:25:44 UTC) #14
xyzzyz
https://codereview.chromium.org/2082693002/diff/80001/build/protoc.gypi File build/protoc.gypi (right): https://codereview.chromium.org/2082693002/diff/80001/build/protoc.gypi#newcode59 build/protoc.gypi:59: 'generator_plugin%': '', Could you rename it to "cc_generator_plugin" to ...
4 years, 6 months ago (2016-06-21 20:29:44 UTC) #15
kraynov
Please review. Thanks!
4 years, 6 months ago (2016-06-22 15:14:49 UTC) #18
kraynov
Please review. Thanks!
4 years, 6 months ago (2016-06-22 15:14:49 UTC) #19
xyzzyz
lgtm https://codereview.chromium.org/2082693002/diff/100001/third_party/protobuf/proto_library.gni File third_party/protobuf/proto_library.gni (right): https://codereview.chromium.org/2082693002/diff/100001/third_party/protobuf/proto_library.gni#newcode35 third_party/protobuf/proto_library.gni:35: # Target name of plugin which generates custom ...
4 years, 6 months ago (2016-06-22 17:29:31 UTC) #20
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/2082693002/120001
4 years, 6 months ago (2016-06-22 17:48:59 UTC) #23
commit-bot: I haz the power
No L-G-T-M from a valid reviewer yet. CQ run can only be started by full ...
4 years, 6 months ago (2016-06-22 17:49:01 UTC) #25
Nico
Two people asked me to comment on this, so here's a drive-by not lgtm: It's ...
4 years, 6 months ago (2016-06-22 21:08:48 UTC) #27
kraynov
proto_libarary targe was hardcoded to generate .cc and python stubs. As described in crbug.com/622680 there ...
4 years, 6 months ago (2016-06-23 14:00:15 UTC) #29
Primiano Tucci (use gerrit)
I am not a build file expert, nor at owner, but the changes LGTM. Plz ...
4 years, 6 months ago (2016-06-23 16:29:28 UTC) #31
Primiano Tucci (use gerrit)
Nico, can you PTAL to the revised CL? (kraynov is OOO but should be back ...
4 years, 5 months ago (2016-06-29 17:34:29 UTC) #34
brettw
LGTM, but you'll need to merge my recent changes to the proto_library.gni file. Hopefully it's ...
4 years, 5 months ago (2016-07-01 18:25:16 UTC) #35
Primiano Tucci (use gerrit)
On 2016/07/01 18:25:16, brettw (plz ping after 24h) wrote: > LGTM, but you'll need to ...
4 years, 5 months ago (2016-07-05 09:42:33 UTC) #36
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2082693002/160001
4 years, 5 months ago (2016-07-05 09:42:53 UTC) #39
commit-bot: I haz the power
A disapproval has been posted by following reviewers: thakis@chromium.org. Please make sure to get positive ...
4 years, 5 months ago (2016-07-05 09:42:57 UTC) #41
xyzzyz
On 2016/07/05 09:42:57, commit-bot: I haz the power wrote: > A disapproval has been posted ...
4 years, 5 months ago (2016-07-06 16:43:58 UTC) #42
Nico
This CL lgtm, but please send out a design doc to chromium-dev before actually a ...
4 years, 5 months ago (2016-07-06 20:48:09 UTC) #43
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2082693002/160001
4 years, 5 months ago (2016-07-06 22:16:40 UTC) #45
commit-bot: I haz the power
Committed patchset #9 (id:160001)
4 years, 5 months ago (2016-07-06 23:39:22 UTC) #47
commit-bot: I haz the power
CQ bit was unchecked.
4 years, 5 months ago (2016-07-06 23:40:12 UTC) #48
commit-bot: I haz the power
4 years, 5 months ago (2016-07-06 23:42:03 UTC) #50
Message was sent while issue was closed.
Patchset 9 (id:??) landed as
https://crrev.com/b241e6e5fa05e90eaa4199d4bc497869e3cf08e1
Cr-Commit-Position: refs/heads/master@{#403981}

Powered by Google App Engine
This is Rietveld 408576698