0

I've been looking around the internet for hours now on how to solve this issue. There are many people who posted this on StackOverflow and many other websites but none of the solutions worked for me. I think that many of them are outdated.

Here is what I've tried:

  • Putting the libraries in libs/ and letting the project automatically handle them (Add them as a reference, convert with Dalvik, etc)
  • Adding them like I would for a normal Java project using Build Path settings (Add external jars-->Go to order and export-->Check the checkbox for all jars)
  • I tried the last step but without checking their checkboxes
  • I even tried someone's suggestion to put them in the assets/ folder
  • I tried putting them in the libs/ folder and adding them as internal jars in Build Path settings
  • Deleting bin/-->Cleaning-->Rebuilding ...And much more

I'm guessing my issue is when I am deploying my app, the jars aren't being packaged in the apk like they are supposed to. I am using many different jars. I'm trying to use jReddit and it has A LOT of dependencies.

P.S. Also, there are several solutions that I tried but I didn't mention because when I went to run the program, they caused a Dex Loader error. I also tried many things to remove this problem as well but then it caused the NoClassDefFound error all over again.

Edit: Just wanted to mention that I am using Eclipse.

vedi0boy
  • 1,030
  • 4
  • 11
  • 32
  • Do you have inside your dependencies, inside of your build.gradle file, some lines like this: `compile fileTree(dir: 'libs', include: ['*.jar'])` and `compile files('libs/yourJAR.jar')` ? – Joaquin Iurchuk Jan 05 '16 at 19:03
  • Sry, I just added an edit. I am using eclipse without Gradle. I was having a lot of issues using some dependencies in Gradle, they weren't properly up to date. – vedi0boy Jan 05 '16 at 19:04
  • **Oh, Eclipse? Really?** Is a deprecated IDE, did you know? Consider migration to Android Studio ASAP! – Joaquin Iurchuk Jan 05 '16 at 19:06
  • I was using Android Studio but I can't stand it. I ran into many more issues than I am now. Also, I hate that there is no shortcut for auto-import. It would be too big of a hassle to switch. – vedi0boy Jan 05 '16 at 19:06
  • Give it a second chance. Everything is easier and the migration is worth the hassle. You'll have some problems just the first hours. I insist, Eclipse is deprecated. – Joaquin Iurchuk Jan 05 '16 at 19:08
  • 1
    Ok, I will give it another chance. I am still up for solutions on Eclipse though. – vedi0boy Jan 05 '16 at 19:09
  • I also recommend switching to Android Studio and Gradle; totally worth though might be painful at first – Eenvincible Jan 05 '16 at 19:09
  • You can put it as an answer and I'll accept it. I guess people need to start converting. – vedi0boy Jan 05 '16 at 20:11
  • 1
    @joaquin - Eclipse itself is not a deprecated IDE. The Android Development Tools plugin for it is. – OneCricketeer Jan 08 '16 at 15:56
  • @cricket_007 You're right, I misspoke. – Joaquin Iurchuk Jan 08 '16 at 16:00
  • Either way I understood what he meant. Eclipse isn't being deprecated anytime soon. – vedi0boy Jan 08 '16 at 19:26

1 Answers1

0

The solution was switching to another IDE. Eclipse is no longer supported by Google for android development and this is probably why I was having this issue. I switched to Android Studio and it worked. Thanks joaquin!

Community
  • 1
  • 1
vedi0boy
  • 1,030
  • 4
  • 11
  • 32