Fix resources in unbundled builds without sdk_version set
Unbundled builds can be performed on modules that don't have
sdk_version set if they are in a platform checkout that has
framework-res. Don't skip calling decodeSdkDep in unbundled
builds.
Bug: 117295826
Test: tapas PackageInstaller && m
Change-Id: I3de093cea05670e0b65e99820c07592973b90b3d
diff --git a/java/aar.go b/java/aar.go
index a49aef0..99e9136 100644
--- a/java/aar.go
+++ b/java/aar.go
@@ -157,11 +157,9 @@
}
func (a *aapt) deps(ctx android.BottomUpMutatorContext, sdkContext sdkContext) {
- if !ctx.Config().UnbundledBuild() {
- sdkDep := decodeSdkDep(ctx, sdkContext)
- if sdkDep.frameworkResModule != "" {
- ctx.AddVariationDependencies(nil, frameworkResTag, sdkDep.frameworkResModule)
- }
+ sdkDep := decodeSdkDep(ctx, sdkContext)
+ if sdkDep.frameworkResModule != "" {
+ ctx.AddVariationDependencies(nil, frameworkResTag, sdkDep.frameworkResModule)
}
}