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

Depends on a proto lib with well known protos #59

Closed
junghoahnsc opened this issue Jan 24, 2017 · 2 comments
Closed

Depends on a proto lib with well known protos #59

junghoahnsc opened this issue Jan 24, 2017 · 2 comments

Comments

@junghoahnsc
Copy link

Hello,

I have a proto lib A that imports descriptor.proto and a proto lib B that depends on A.

go_proto_library(
    name = "a_proto_go",
    importmap = {
        "google/protobuf/descriptor.proto": "github.com/golang/protobuf/protoc-gen-go/descriptor",
    },
    imports = [
        "../../external/com_github_google_protobuf/src",
    ],
    protos = ["x/a.proto"],
    deps = [
      "@com_github_golang_protobuf//protoc-gen-go/descriptor:go_default_library",
    ],
)

go_proto_library(
    name = "b_proto_go",
    protos = ["x/b.proto"],
    deps = [
        ":a_proto_go",
    ],
)

I could compile a_proto_go, but for b_proto_go I had to add the same imports to compile.
Is this expected? Is there any way to use the imports of the dependencies automatically?

Thanks,

@pcj
Copy link
Contributor

pcj commented Jan 24, 2017

Hi @junghoahnsc thanks, I agree these should transitively propagate. Will plan to fix.

@pcj
Copy link
Contributor

pcj commented Dec 7, 2018

Note: these rules have been re-written and migrated to https://github.com/stackb/rules_proto. Please re-open there if issue persists, thanks.

Cleaning up all issues on this repo, apologies in advance for closing without proper response.

@pcj pcj closed this as completed Dec 7, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants