diff options
| author | 2020-02-14 21:55:40 +0000 | |
|---|---|---|
| committer | 2020-02-14 21:55:40 +0000 | |
| commit | 1d62b1c5362b70b958bbc035cf0e9e4fa97bd4b3 (patch) | |
| tree | b694d22310f2682f935051d075293d29b59821f0 /java/java.go | |
| parent | f1366a339ee1a5e31d6beb764f387585b6362324 (diff) | |
| parent | 33b6654eeace28ceeb8f8328c01722abc4cdc6c6 (diff) | |
Merge "Turn on the instrumentation by default for the java code in APEXes"
Diffstat (limited to 'java/java.go')
| -rw-r--r-- | java/java.go | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/java/java.go b/java/java.go index ceedd8971..41fd8da97 100644 --- a/java/java.go +++ b/java/java.go @@ -1510,6 +1510,11 @@ 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 + if android.DirectlyInAnyApex(ctx, ctx.ModuleName()) && !j.IsForPlatform() { + j.properties.Instrument = true + } + if j.shouldInstrument(ctx) { outputFile = j.instrument(ctx, flags, outputFile, jarName) } |