Rename Label.Bp_text to OriginalModuleName.
OriginalModuleName is a clearer name for what the field represents.
Also document it.
Follow-up from aosp/1675466.
Test: TH
Change-Id: Ie1152b5ae63f388164582be70e193a91ef96c89c
diff --git a/genrule/genrule.go b/genrule/genrule.go
index 3a9aecc..77dae75 100644
--- a/genrule/genrule.go
+++ b/genrule/genrule.go
@@ -856,8 +856,8 @@
cmd = strings.Replace(cmd, "$(locations)", fmt.Sprintf("$(locations %s)", tools.Value.Includes[0].Label), -1)
}
for _, l := range allReplacements.Includes {
- bpLoc := fmt.Sprintf("$(location %s)", l.Bp_text)
- bpLocs := fmt.Sprintf("$(locations %s)", l.Bp_text)
+ bpLoc := fmt.Sprintf("$(location %s)", l.OriginalModuleName)
+ bpLocs := fmt.Sprintf("$(locations %s)", l.OriginalModuleName)
bazelLoc := fmt.Sprintf("$(location %s)", l.Label)
bazelLocs := fmt.Sprintf("$(locations %s)", l.Label)
cmd = strings.Replace(cmd, bpLoc, bazelLoc, -1)