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

incompatible_disable_proto_source_root: remove the attribute `proto_library.proto_source_root` #7153

Open
lberki opened this Issue Jan 17, 2019 · 1 comment

Comments

Projects
None yet
3 participants
@lberki
Copy link
Contributor

lberki commented Jan 17, 2019

The proto_library.proto_source_root attribute is going away in favor of the more flexible proto_library.strip_import_prefix and proto_library.import_prefix.

In order to migrate your BUILD files, replace proto_source_root with strip_import_prefix: since the only allowed value of that attribute is the package the rule is in, simply replace the name of the attribute and prepend / to its value. For example, the rule (necessarily in foo/bar/BUILD):

proto_library(name="proto", srcs=["proto.proto"], proto_source_root="foo/bar")

Needs to be migrated to:

proto_library(name="proto", srcs=["proto.proto"], strip_import_prefix="/foo/bar")

@hlopko hlopko changed the title Incompatible_disable_proto_source_root: remove the attribute `proto_library.proto_source_root` incompatible_disable_proto_source_root: remove the attribute `proto_library.proto_source_root` Feb 5, 2019

@philwo

This comment has been minimized.

Copy link
Member

philwo commented Feb 6, 2019

This flag was not flipped in time for the Bazel 0.23.0 release and will thus be postponed to Bazel 0.24.0.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment