[TIMOB-18483] Android: Upgrade version of JDK on jenkins.appcelerator.org
| GitHub Issue | n/a |
|---|---|
| Type | Story |
| Priority | Low |
| Status | Closed |
| Resolution | Done |
| Resolution Date | 2018-08-15T03:30:30.000+0000 |
| Affected Version/s | n/a |
| Fix Version/s | n/a |
| Components | Android |
| Labels | n/a |
| Reporter | Ingo Muschenetz |
| Assignee | Ashraf Abu |
| Created | 2015-01-30T20:07:52.000+0000 |
| Updated | 2018-08-15T03:30:30.000+0000 |
Description
During compilation of titanium_mobile, we have a number of errors like:
"[javac] warning: android/text/method/DialerKeyListener.class(android/text/method:DialerKeyListener.class): major version 51 is newer than 50, the highest major version supported by this compiler.
[javac] It is recommended that the compiler be upgraded."
The current version used for compilation is JDK 6. Recommend upgrading to JDK 7.
This is a tooling ticket (as opposed to a DevOps ticket) as it _could_ have ramifications on Android.
Tried doing this (had to use JDK8), and got the following: http://jenkins.appcelerator.org/job/titanium_mobile_master/3836/console
It appears there are at least a few issues to resolve.[javac] Note: [KrollBindingGen] Generating JSON: file:/var/lib/jenkins/jobs/titanium_mobile_master/workspace/dist/android/json/org/appcelerator/titanium/bindings/titanium.json [copy] Copying 18 files to /var/lib/jenkins/jobs/titanium_mobile_master/workspace/dist/android/classes/titanium [copy] Copied 21 empty directories to 9 empty directories under /var/lib/jenkins/jobs/titanium_mobile_master/workspace/dist/android/classes/titanium [javac] Compiling 105 source files to /var/lib/jenkins/jobs/titanium_mobile_master/workspace/dist/android/classes/titanium [javac] warning: [options] bootstrap class path not set in conjunction with -source 1.6 [javac] /var/lib/jenkins/jobs/titanium_mobile_master/workspace/android/titanium/src/java/org/appcelerator/titanium/TiBlob.java:561: error: cannot access BinaryEncoder [javac] return new String(Base64.encodeBase64(getBytes())); [javac] ^ [javac] class file for org.apache.commons.codec.BinaryEncoder not found [javac] Note: Some input files use or override a deprecated API. [javac] Note: Recompile with -Xlint:deprecation for details. [javac] Note: Some input files use unchecked or unsafe operations. [javac] Note: Recompile with -Xlint:unchecked for details. [javac] 1 error [javac] 1 warningJDK 1.7 was EOL'd in March with the end of updates in April. Any chance we'll see support for 1.8 soon? http://www.oracle.com/technetwork/java/javase/downloads/eol-135779.html
[~skypanther] This ticket is for using JDK 1.8 for compilation of the SDK. Is that what you are interested in?
Yep. I had to downgrade the version of the JDK on my computer to build the SDK from source.
I cloned off a blocking ticket for fixing the JDK 8+ compile issue: TIMOB-19648 That ticket has an open PR against master. Once merged, I assume we can update the JDK on the build server (for master builds).