diff options
author | Colin Cross <ccross@android.com> | 2017-09-19 10:52:23 -0700 |
---|---|---|
committer | Colin Cross <ccross@android.com> | 2017-09-19 12:19:36 -0700 |
commit | 945c000aacc679664310a2073d4719076bbb7ae5 (patch) | |
tree | cb0a0f7902efcc797c6fc31f652dcfcb9d11ccda /java/config | |
parent | 8eded0ac865bbe3df12a62afcbce0091320cddf3 (diff) | |
download | build_soong-945c000aacc679664310a2073d4719076bbb7ae5.tar.gz build_soong-945c000aacc679664310a2073d4719076bbb7ae5.tar.bz2 build_soong-945c000aacc679664310a2073d4719076bbb7ae5.zip |
Add -XDskipDuplicateBridges=true flag to javac
Turbine leaves out bridges which can cause javac to unnecessarily insert
them into subclasses. Setting this flag causes our custom javac to
assume that the missing bridges will exist at runtime and not recreate
them in subclasses. If a different javac is used the flag will be
ignored and extra bridges will be inserted, which should be harmless.
The flag is implemented by https://android-review.googlesource.com/c/486427
Test: m -j checkbuild
Test: check core-libart for extra methods
Bug: 65645120
Change-Id: I6e2babe4a5a24cda4903845ae895c369343ec55b
Diffstat (limited to 'java/config')
-rw-r--r-- | java/config/config.go | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/java/config/config.go b/java/config/config.go index 5773164a..69d6fc39 100644 --- a/java/config/config.go +++ b/java/config/config.go @@ -40,6 +40,12 @@ func init() { `-encoding UTF-8`, `-sourcepath ""`, `-g`, + // Turbine leaves out bridges which can cause javac to unnecessarily insert them into + // subclasses (b/65645120). Setting this flag causes our custom javac to assume that + // the missing bridges will exist at runtime and not recreate them in subclasses. + // If a different javac is used the flag will be ignored and extra bridges will be inserted. + // The flag is implemented by https://android-review.googlesource.com/c/486427 + `-XDskipDuplicateBridges=true`, }, " ")) pctx.StaticVariable("DefaultJavaVersion", "1.8") |