Post Reply

AOSP now requires Java 7, and works with OpenJDK

OP xdp

30th March 2014, 04:29 AM   |  #1  
OP Senior Member
Thanks Meter: 94
 
594 posts
Join Date:Joined: Nov 2010
I was just looking at the build instructions page for AOSP and noticed a significant change that must've just happened in the last week or so. Apparently Java 7 is now required, and Google officially recommends using OpenJDK. Under where it says "To develop for older versions..." it lists Java 6 next to KitKat, meaning this is apparently for code newer than KitKat. I don't think OpenJDK was compatible before, so that plus the move to Java 7 seems noteworthy. Can anybody who watches AOSP commits comment on when this change occurred? Is this signifying a non-minor update is coming after KitKat?

For reference, here is the relevant text of the current page at http://source.android.com/source/initializing.html:

Code:
Installing the JDK

The latest version of Android in the Android Open Source Project (AOSP) requires Java 7. On Ubuntu, use OpenJDK.

Java 7: For the latest version of Android

$ sudo apt-get update
$ sudo apt-get install openjdk-7-jdk
Optionally, update the default Java version by running:

$ sudo update-alternatives --config java
$ sudo update-alternatives --config javac
To develop older versions of Android, download and install the corresponding version of the Java JDK:
Java 6: for Gingerbread through KitKat
Java 5: for Cupcake through Froyo
And this is what it said on Feb. 16 according to Wayback Machine:

Code:
Installing the JDK

The Sun JDK is no longer in Ubuntu's main package repository. In order to download it, you need to add the appropriate repository and indicate to the system which JDK should be used.

Java 6: for Gingerbread and newer

$ sudo add-apt-repository "deb http://archive.canonical.com/ lucid partner"
$ sudo apt-get update
$ sudo apt-get install sun-java6-jdk
Java 5: for Froyo and older

$ sudo add-apt-repository "deb http://archive.ubuntu.com/ubuntu hardy main multiverse"
$ sudo add-apt-repository "deb http://archive.ubuntu.com/ubuntu hardy-updates main multiverse"
$ sudo apt-get update
$ sudo apt-get install sun-java5-jdk
The Following User Says Thank You to xdp For This Useful Post: [ View ]
8th April 2014, 04:05 PM   |  #2  
Senior Member
Thanks Meter: 921
 
643 posts
Join Date:Joined: Oct 2010
Donate to Me
Quote:
Originally Posted by xdp

Can anybody who watches AOSP commits comment on when this change occurred? Is this signifying a non-minor update is coming after KitKat?

Here's the change: https://android.googlesource.com/pla...500db70cbc82b2

Since this is already online, I wouldn't expect this to be a sign for a big update. One of the beasts that needed JDK6 was chromium. I took a quick look into the changes and didn't see really much. Only some fixes to be able to compile with JDK7. I'll give it a try if it compiles.
The Following User Says Thank You to C-o-M For This Useful Post: [ View ]
Post Reply Subscribe to Thread
Previous Thread Next Thread
Thread Tools
Display Modes


Top Threads in Android Software and Hacking General [Developers Only] by ThreadRank