Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Importing roottools.jar into Android Studio

I'm trying to import roottools from here: https://code.google.com/p/roottools/ (jar file) to the Android Studio project. So far I've tried the following:

  • copy RootTools-javadoc-3.4.jar into libs directory under my project.
  • Add imports
  • Reorganize imports.
  • Rebuild project

But still I don't have "acces" to it's methods. Is it possible that is only compatible with Eclipse?

like image 809
XorOrNor Avatar asked Dec 07 '25 16:12

XorOrNor


1 Answers

I tried using the JAR available for download and it didn't work either. To get this working, I had to download the project available at github here. Compile and run the task "makeJar" (right click on task makeJar in the gradle.build and select run).

I just added this new jar in the libs and referenced in the gradle.build file.

dependencies {
    ...
    compile files('libs/RootTools.jar')
}

or you can add it via Project Properties.

It worked perfectly (don't forget to sync your the gradle files if you edit it manually).

like image 71
Androiderson Avatar answered Dec 09 '25 19:12

Androiderson



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!