summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author Vinh Tran <vinhdaitran@google.com> 2022-09-23 13:08:34 -0400
committer Vinh Tran <vinhdaitran@google.com> 2022-09-23 14:18:20 -0400
commit32a98a5d555056511ba38f0b1154ddadfa1360d0 (patch)
tree7d5ebc5dfca0add9c7e459fbb73525ba53c474d4
parent7574afb67fcd852ad2dd484c0029ff36b039a6cc (diff)
Convert genDir to RULEDIR in gensrcs's cmd
Test: CI Change-Id: I5ecc19dc73559bb518871080737b28a649edc162
-rw-r--r--android/allowlists/allowlists.go3
-rw-r--r--genrule/genrule.go8
2 files changed, 3 insertions, 8 deletions
diff --git a/android/allowlists/allowlists.go b/android/allowlists/allowlists.go
index 534a6c4fd..4609577f8 100644
--- a/android/allowlists/allowlists.go
+++ b/android/allowlists/allowlists.go
@@ -571,6 +571,8 @@ var (
"libnativeloader",
"libEGL_getProcAddress",
"libEGL_blobCache",
+
+ "protoc-gen-cppstream",
}
Bp2buildModuleTypeAlwaysConvertList = []string{
@@ -637,7 +639,6 @@ var (
"conscrypt", // TODO(b/210751803), we don't handle path property for filegroups
"conscrypt-for-host", // TODO(b/210751803), we don't handle path property for filegroups
"host-libprotobuf-java-full", // TODO(b/210751803), we don't handle path property for filegroups
- "libprotobuf-internal-protos", // TODO(b/210751803), we don't handle path property for filegroups
"libprotobuf-internal-python-srcs", // TODO(b/210751803), we don't handle path property for filegroups
"libprotobuf-java-full", // TODO(b/210751803), we don't handle path property for filegroups
"libprotobuf-java-util-full", // TODO(b/210751803), we don't handle path property for filegroups
diff --git a/genrule/genrule.go b/genrule/genrule.go
index 01279ebf9..d4ed36301 100644
--- a/genrule/genrule.go
+++ b/genrule/genrule.go
@@ -909,13 +909,7 @@ func (m *Module) ConvertWithBp2build(ctx android.TopDownMutatorContext) {
cmd = strings.Replace(*m.properties.Cmd, "$(in)", "$(SRCS)", -1)
cmd = strings.Replace(cmd, "$(out)", "$(OUTS)", -1)
}
-
- genDir := "$(RULEDIR)"
- if ctx.ModuleType() == "gensrcs" {
- genDir = "$(GENDIR)"
- }
-
- cmd = strings.Replace(cmd, "$(genDir)", genDir, -1)
+ cmd = strings.Replace(cmd, "$(genDir)", "$(RULEDIR)", -1)
if len(tools.Value.Includes) > 0 {
cmd = strings.Replace(cmd, "$(location)", fmt.Sprintf("$(location %s)", tools.Value.Includes[0].Label), -1)
cmd = strings.Replace(cmd, "$(locations)", fmt.Sprintf("$(locations %s)", tools.Value.Includes[0].Label), -1)