user992244
user992244

Reputation: 406

Tools.jar is not in Android Studio classpath

I tried installing Android Studio on a Samsung Chromebook Series 3 with an ARM processor, but I'm stuck with the Java. Any help would be appreciated.

Downloaded and extracted Android Studio
Downloaded and extracted Java 1.7.0_21 JDK ARM
Completed the below commands except the javaws commands as they error-ed out doesn't exist

tar xzvf ~/Downloads/jdk-7u21-linux-arm.tar.gz sudo mv jdk1.7.0_21/ /usr/lib/jvm/ 
sudo update-alternatives --install /usr/bin/java java /usr/lib/jvm/jdk1.7.0_21/bin/java 1 
sudo update-alternatives --install /usr/bin/javac javac /usr/lib/jvm/jdk1.7.0_21/bin/javac 1 sudo update-alternatives --install /usr/bin/javaws javaws /usr/lib/jvm/jdk1.7.0_21/bin/javaws 1 
sudo update-alternatives --config java 
sudo update-alternatives --config javaws

I tried the JAVA_HOME=/usr/lib/jvm/jdk1.7.0_21 command and it would still give me the error.

Upvotes: 21

Views: 4550

Answers (3)

Adnama
Adnama

Reputation: 172

No It's not in the studio. What you should do:

  • Change your JRE to use the JRE found inside your JDK
  • Add tools.jar that can be found in the JDK Libraries folder

That's it. It's a known issue, but they're working on it. But this is a workaround.

Upvotes: 1

Omar Faroque Anik
Omar Faroque Anik

Reputation: 2609

Couple of things, you can check: 1. check jdk is in your path 2. from your command line, execute this command: java -version and see what it shows 3. and execute this command: javac -version If both command gives no error then try again otherwise fix those issue.btw, Do not forget to check your system configuration to make sure that it is 32bit or 64 bit

Upvotes: 0

user2648519
user2648519

Reputation: 117

Please check whether your system configuration is 32bit or 64bit and according to that download respective JDK and provide its path in JAVA_HOME

Upvotes: 1

Related Questions