aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/main/java/com/google/devtools/build/lib/rules/extra
diff options
context:
space:
mode:
authorGravatar Kristina Chodorow <kchodorow@google.com>2016-07-27 16:34:27 +0000
committerGravatar Adam Michael <ajmichael@google.com>2016-07-28 18:36:29 -0400
commita1a31ff6d16811dc72df32861bd1c1a98e104f02 (patch)
treeea94d4c1e7fa41f38be174a73f618152e18f1d65 /src/main/java/com/google/devtools/build/lib/rules/extra
parentb6b1a3f0670c7e62cec408b06a13ae02bbe1b42f (diff)
Rename some PackageId and RepositoryName fields/methods in prep for deep execroot change
This is in prep for making the execution root path for external repositories ../repo_name (instead of external/repo_name). Right now, the getRunfilesPath() returns that path, so that is renamed getExecRoot() (since the runfiles are really just a reflection of the execRoot structure). getSourceRoot() replaces getPathFragment, which has always been a confusing name (it's not clear from the name what the difference is between it and getPackageFragment()). It returns the relative path to source files for external repositories (external/repo_name). Also renamed/moved to more sensible class a few static RepositoryName fields. -- MOS_MIGRATED_REVID=128594419
Diffstat (limited to 'src/main/java/com/google/devtools/build/lib/rules/extra')
-rw-r--r--src/main/java/com/google/devtools/build/lib/rules/extra/ExtraActionSpec.java2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/main/java/com/google/devtools/build/lib/rules/extra/ExtraActionSpec.java b/src/main/java/com/google/devtools/build/lib/rules/extra/ExtraActionSpec.java
index 36e2794613..e8115e813d 100644
--- a/src/main/java/com/google/devtools/build/lib/rules/extra/ExtraActionSpec.java
+++ b/src/main/java/com/google/devtools/build/lib/rules/extra/ExtraActionSpec.java
@@ -195,7 +195,7 @@ public final class ExtraActionSpec implements TransitiveInfoProvider {
}
private Artifact getRootRelativePath(String template, RuleContext ruleContext) {
- PathFragment extraActionPackageFragment = label.getPackageIdentifier().getPathFragment();
+ PathFragment extraActionPackageFragment = label.getPackageIdentifier().getSourceRoot();
PathFragment extraActionPrefix = extraActionPackageFragment.getRelative(label.getName());
PathFragment rootRelativePath = new PathFragment("extra_actions")
.getRelative(extraActionPrefix)