[TIMOB-26435] Android: Update gradle to support JDK 11
GitHub Issue | n/a |
---|---|
Type | Improvement |
Priority | High |
Status | Closed |
Resolution | Fixed |
Resolution Date | 2018-10-12T18:12:08.000+0000 |
Affected Version/s | Release 7.4.1 |
Fix Version/s | Release 7.5.0 |
Components | Android |
Labels | n/a |
Reporter | Hans Knöchel |
Assignee | Ewan Harris |
Created | 2018-10-03T21:00:35.000+0000 |
Updated | 2018-11-20T04:38:48.000+0000 |
Description
When running an app with Java 11, the build fails:
[ERROR] Failed to run dexer:
[ERROR]
[ERROR] FAILURE: Build failed with an exception.
[ERROR]
[ERROR] * What went wrong:
[ERROR] Could not determine java version from '11'.
[ERROR]
[ERROR] * Try:
[ERROR] Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.
[ERROR]
[ERROR] * Get more help at https://help.gradle.org
The Java version check:
$ java --version
java 11 2018-09-25
Java(TM) SE Runtime Environment 18.9 (build 11+28)
Java HotSpot(TM) 64-Bit Server VM 18.9 (build 11+28, mixed mode)
This is currently blocking our Titanium development. ping [~eharris] so the team knows about this! Workaround is to downgrade to JDK 10, but that's not ideal.
[~hknoechel] I've just tested locally and changing this line https://github.com/appcelerator/titanium_mobile/blob/75294d039e323da40e43f362eb1dd11ad1ce1b36/android/templates/gradle/gradle/wrapper/gradle-wrapper.properties#L5 to
distributionUrl=http\://services.gradle.org/distributions/gradle-4.10.2-all.zip
allows me to build with Java 11So it's the same issue like for RN? It would be great to see this in the next official release.
https://github.com/appcelerator/titanium_mobile/pull/10369
PR Merged.
*Closing ticket.* Verified improvement in SDK version:
7.5.0.v20181015122219
. Test and other information can found at: https://github.com/appcelerator/titanium_mobile/pull/10369