diff options
author | Googler <noreply@google.com> | 2018-08-13 04:00:32 -0700 |
---|---|---|
committer | Copybara-Service <copybara-piper@google.com> | 2018-08-13 04:02:40 -0700 |
commit | 5d46f327041ade0a6314ba0859baef919730c796 (patch) | |
tree | 90476b5313a7771d0c686332dba3cefa502d7c49 /src/main/java/com/google/devtools/build/lib/rules/proto/SupportData.java | |
parent | 08968ed56a0d5ff7f983edc7f5ebbfe85a72b8e0 (diff) |
bazel: handle proto_src_root when dealing with proto includes, generated files and C++ headers
This change completes the handling of proto_src_root when it comes to inclusion of protos, generating the proto files in the right place and adding the generated headers to the include paths.
WANT_LGTM=elenairina
RELNOTES: None.
PiperOrigin-RevId: 208457740
Diffstat (limited to 'src/main/java/com/google/devtools/build/lib/rules/proto/SupportData.java')
-rw-r--r-- | src/main/java/com/google/devtools/build/lib/rules/proto/SupportData.java | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/main/java/com/google/devtools/build/lib/rules/proto/SupportData.java b/src/main/java/com/google/devtools/build/lib/rules/proto/SupportData.java index c3bc3aa553..b3644d4c17 100644 --- a/src/main/java/com/google/devtools/build/lib/rules/proto/SupportData.java +++ b/src/main/java/com/google/devtools/build/lib/rules/proto/SupportData.java @@ -35,6 +35,7 @@ public abstract class SupportData { NestedSet<Artifact> protosInDirectDeps, NestedSet<Artifact> transitiveImports, NestedSet<String> transitiveProtoPathFlags, + String protoSourceRoot, NestedSet<String> directProtoSourceRoots, boolean hasProtoSources) { return new AutoValue_SupportData( @@ -43,6 +44,7 @@ public abstract class SupportData { transitiveImports, protosInDirectDeps, transitiveProtoPathFlags, + protoSourceRoot, directProtoSourceRoots, hasProtoSources); } @@ -64,6 +66,9 @@ public abstract class SupportData { */ public abstract NestedSet<String> getTransitiveProtoPathFlags(); + /** The {@code proto_source_root} of the current library. */ + public abstract String getProtoSourceRoot(); + /** * The {@code proto_source_root}'s collected from the current library and the direct dependencies. */ |