-
Notifications
You must be signed in to change notification settings - Fork 15.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Need to expose generated protobuf C++ headers #1959
Need to expose generated protobuf C++ headers #1959
Conversation
… accessed from other libraries.
Thanks for your pull request. The automated tests will run as soon as one of the admins verifies this change is ok to test. |
Thanks for your pull request. It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA). 📝 Please visit https://cla.developers.google.com/ to sign. Once you've signed, please reply here (e.g.
|
How would you use this with, say, a cc_library? Would you just include it in deps as ":<proto_library>"? |
Exactly:
I actually use it like this when working downstream with Bazel workers. That's what it is needed for. |
We signed it! |
@abergmeier You probably need to make another pull request using that account that signed the CLA? |
On the bazel repo it was only necessary to run the cla-bot again. Tadaaaaa. |
CLAs look good, thanks! |
@davidzchen So are you tracking this manually then? |
Anyone looking at that? |
Thanks for your pull request. The automated tests will run as soon as one of the admins verifies this change is ok for us to run on our infrastructure. |
LG. Thanks! |
@davidzchen ping |
For others who are trying to integrate C++ protobufs using Bazel into their own projects. I was able to invoke protobuf's protobuf.bzl file with the following recipe: Under
Under your BUILD bazel file in your local project:
Then, in the command line, simply do: ... and Bazel will automatically generate the file. When including headers, make sure to include relative to where the WORKSPACE file is located. For me, to access the autogenerated protobuf files, I did:
As noted in the |
… so they can actually be accessed from other libraries.