Skip to content
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

Support the .srcjar suffix for archived generated code #576

Closed
shahms opened this issue Jul 8, 2015 · 2 comments
Closed

Support the .srcjar suffix for archived generated code #576

shahms opened this issue Jul 8, 2015 · 2 comments

Comments

@shahms
Copy link

shahms commented Jul 8, 2015

This is specifically to simplify compatibility with Bazel, which expects .jar files to contain compiled code and .srcjar to contain source code. When using bazel to generate Java code from a protocol buffer, some minor-but-annoying workarounds are required to use the requisite '.srcjar' suffix. Adding support to protoc seems like it would be pretty straightforward.

@xfxyjwf xfxyjwf assigned BSBandme and unassigned xfxyjwf Jul 2, 2018
@BSBandme BSBandme added the P3 label Jul 9, 2018
taoso pushed a commit to taoso/protobuf that referenced this issue Aug 1, 2018
An earlier change inadvertendly made the import_path flag stop setting
the package name. In addition, we intentionally removed the behavior where
a go_package option in one file would set the package name for other
generated files, in anticipation of allowing a single compilation action
to generate code for many packages.

This change restores the import_path behavior. It also permits a go_package
option in one file to affect other files *in the same package*. (Every
source file should include a go_package option, which makes this case moot,
but this minimizes the amount of breaking change that we're introducing.)

Also tweak assignment of import paths to allow the import_path flag to
set the import path for all generated files.
@simuons
Copy link

simuons commented Aug 27, 2020

I think this is resolved by #7190 at https://github.com/protocolbuffers/protobuf/pull/7190/files#diff-5f83a7f49398fa05465b00c6ec8e7477R890 and released in 3.12.0

@elharo
Copy link
Contributor

elharo commented Oct 1, 2021

fixed

@elharo elharo closed this as completed Oct 1, 2021
adellahlou pushed a commit to adellahlou/protobuf that referenced this issue Apr 20, 2023
…ents to reflection namespaces, see protocolbuffers#576; Also added Namespace#getEnum for completeness, see protocolbuffers#576; Made pbjs use loadSync for deterministic outputs, see protocolbuffers#573
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants