Situation:
I have copied the JRE & JAVA SDK folder and set the environment variable . (without installing java, make it as
like an installed). with this one, I am able to compile android checkout.
I have checked the version of the java. its version is JDK_1.0.5_19;
Once I tried to install eclipse, then old version or updated version is installed in my laptop ,
so I couldnt be able to compile android source code and got the error as follows:
Error: You are attempting with incorrect version of javac in Ubuntu while building android source code
Solution:
We can get current java version by typing "java -version". I found that the java version is different from working version (android compiled code);
So we have to remove the recently installed version and reinstall the java .
We have to search the recently installed version by typing the command:
"aptitude search jdk"
it will lists out the JDK packages.
Remove all the JDK packages (Our JDK package doesnt need installation) by typing the following command:
aptitude purge $1 ($1 is the package listed in "aptitude search jdk")
install java_1_5_0_19 .bin file and then now try recompiling the code.Now it is working.
No comments:
Post a Comment