Damien Martin-Guillerez | f88f4d8 | 2015-09-25 13:56:55 +0000 | [diff] [blame] | 1 | // Copyright 2014 The Bazel Authors. All rights reserved. |
Han-Wen Nienhuys | d08b27f | 2015-02-25 16:45:20 +0100 | [diff] [blame] | 2 | // |
| 3 | // Licensed under the Apache License, Version 2.0 (the "License"); |
| 4 | // you may not use this file except in compliance with the License. |
| 5 | // You may obtain a copy of the License at |
| 6 | // |
| 7 | // http://www.apache.org/licenses/LICENSE-2.0 |
| 8 | // |
| 9 | // Unless required by applicable law or agreed to in writing, software |
| 10 | // distributed under the License is distributed on an "AS IS" BASIS, |
| 11 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 12 | // See the License for the specific language governing permissions and |
| 13 | // limitations under the License. |
| 14 | // |
| 15 | // Definitions for dependency reports. |
| 16 | |
| 17 | syntax = "proto2"; |
| 18 | |
| 19 | package blaze_deps; |
| 20 | |
| 21 | option java_package = "com.google.devtools.build.lib.view.proto"; |
| 22 | |
| 23 | // A specific location within a source file. |
| 24 | message SourceLocation { |
| 25 | required string path = 1; |
| 26 | optional int32 line = 2; |
| 27 | optional int32 column = 3; |
| 28 | } |
| 29 | |
| 30 | message Dependency { |
| 31 | |
| 32 | enum Kind { |
Liam Miller-Cushon | bd8898a | 2016-04-01 19:13:21 +0000 | [diff] [blame] | 33 | // Dependency used explicitly in the source. |
Han-Wen Nienhuys | d08b27f | 2015-02-25 16:45:20 +0100 | [diff] [blame] | 34 | EXPLICIT = 0; |
Liam Miller-Cushon | bd8898a | 2016-04-01 19:13:21 +0000 | [diff] [blame] | 35 | // Dependency that is implicitly loaded and used by the compiler. |
Han-Wen Nienhuys | d08b27f | 2015-02-25 16:45:20 +0100 | [diff] [blame] | 36 | IMPLICIT = 1; |
| 37 | // Unused dependency. |
| 38 | UNUSED = 2; |
Googler | c07af7a | 2016-09-21 04:20:51 +0000 | [diff] [blame] | 39 | // Implicit dependency considered by the compiler but not completed. |
| 40 | INCOMPLETE = 3; |
Han-Wen Nienhuys | d08b27f | 2015-02-25 16:45:20 +0100 | [diff] [blame] | 41 | } |
| 42 | |
| 43 | // Path to the artifact representing this dependency. |
| 44 | required string path = 1; |
| 45 | |
| 46 | // Dependency kind |
| 47 | required Kind kind = 2; |
| 48 | |
| 49 | // Source file locations: compilers can pinpoint the uses of a dependency. |
| 50 | repeated SourceLocation location = 3; |
| 51 | } |
| 52 | |
| 53 | // Top-level message found in .deps artifacts |
| 54 | message Dependencies { |
| 55 | repeated Dependency dependency = 1; |
| 56 | |
| 57 | // Name of the rule being analyzed. |
| 58 | optional string rule_label = 2; |
| 59 | |
| 60 | // Whether the action was successful; even when compilation fails, partial |
| 61 | // dependency information can be useful. |
| 62 | optional bool success = 3; |
Googler | 9b61b0f | 2016-10-31 05:43:34 +0000 | [diff] [blame] | 63 | |
| 64 | // Packages contained in the output jar, sorted alphabetically. |
| 65 | repeated string contained_package = 4; |
Googler | 4654b87 | 2019-01-16 03:04:11 -0800 | [diff] [blame] | 66 | |
| 67 | // If the Java action was started with a reduced classpath and an error |
| 68 | // occurred suggesting that it should be rerun with the full classpath, this |
| 69 | // will be true. |
| 70 | optional bool requires_reduced_classpath_fallback = 5; |
Han-Wen Nienhuys | d08b27f | 2015-02-25 16:45:20 +0100 | [diff] [blame] | 71 | } |