I am currently trying to build Android just for learning purpose. But I am facing strange error -
You are attempting to build with the incorrect version of java. Your version is: java version "1.7.0_07". The correct version is: Java SE 1.6.
my java - version gives me
java version "1.7.0_07" Java(TM) SE Runtime Environment (build 1.7.0_07-b10) Java HotSpot(TM) 64-Bit Server VM (build 23.3-b01, mixed mode)
any Idea what went wrong? regards,
1.) If you’ve already installed OpenJDK . Remove it by running this command:
sudo apt-get purge openjdk*
2.) Then:
sudo add-apt-repository ppa:webupd8team/java
Then update:
sudo apt-get update
3.) Select which version you want To install Oracle Java 8:
sudo apt-get install oracle-java8-installer
To install Oracle Java 7:
sudo apt-get install oracle-java7-installer
To install the Java 6:
sudo apt-get install oracle-java6-installer
After upgrade Ubuntu 12.04 to 12.10 - just export path before build Android e.g:
export PATH=/usr/lib/jvm/java-6-openjdk-amd64/bin/:$PATH
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With