Use an interface instead of a string to retrieve the value for $(location) or $(locations) expansions in genrules to allow delaying the evaluation until the RuleBuilderCommand is available. This allows using helpers like RuleBuilderCommand.PathForInputs to properly rewrite the values for sandboxing. Also remove the standalone SboxPathFor* methods that don't operate on a specific RuleBuilderCommand that are now unnecessary. Test: genrule_test.go Change-Id: I8bb2647332ef118204a216cead23d062517e2b8c
26 lines
489 B
Plaintext
26 lines
489 B
Plaintext
package {
|
|
default_applicable_licenses: ["Android-Apache-2.0"],
|
|
}
|
|
|
|
bootstrap_go_package {
|
|
name: "soong-genrule",
|
|
pkgPath: "android/soong/genrule",
|
|
deps: [
|
|
"blueprint",
|
|
"blueprint-pathtools",
|
|
"sbox_proto",
|
|
"soong",
|
|
"soong-android",
|
|
"soong-bazel",
|
|
"soong-shared",
|
|
],
|
|
srcs: [
|
|
"genrule.go",
|
|
"locations.go",
|
|
],
|
|
testSrcs: [
|
|
"genrule_test.go",
|
|
],
|
|
pluginFor: ["soong_build"],
|
|
}
|