Merge changes Ibaf383c4,I2b1c0736 am: 139fa4320f
am: e45d4d1612
Change-Id: Iba51fa72f9232cd5ce9826550fc7b2072280fad4
This commit is contained in:
@@ -1521,6 +1521,14 @@ func (j *Module) compile(ctx android.ModuleContext, aaptSrcJar android.Path) {
|
||||
j.headerJarFile = j.implementationJarFile
|
||||
}
|
||||
|
||||
// Force enable the instrumentation for java code that is built for APEXes ...
|
||||
// except for the jacocoagent itself (because instrumenting jacocoagent using jacocoagent
|
||||
// doesn't make sense)
|
||||
isJacocoAgent := ctx.ModuleName() == "jacocoagent"
|
||||
if android.DirectlyInAnyApex(ctx, ctx.ModuleName()) && !isJacocoAgent && !j.IsForPlatform() {
|
||||
j.properties.Instrument = true
|
||||
}
|
||||
|
||||
if j.shouldInstrument(ctx) {
|
||||
outputFile = j.instrument(ctx, flags, outputFile, jarName)
|
||||
}
|
||||
|
Reference in New Issue
Block a user