Skip to content Skip to sidebar Skip to footer

Android Studio - Android.jar And Rt.jar Conflicts

I’m developing an Android Application with Android Studio 2.1.2. In one of the classes of an external library (in particular the Watson library of IBM Bluemix, com.ibm.watson.dev

Solution 1:

You cannot use rt.jar with an Android application (and somewhat overlaps with android.jar). That is the runtime library for the desktop JRE, not Android. Please see the Android API reference for a list of available packages (you'll notice that javax.naming is not one of them.

Clearly that IBM framework is not Android compatible.

My earlier assessment is inaccurate as the README clearly states that it is:

The library supports Android 2.3 and above. For Java, the minimum requirement is 1.7. It depends on OkHttp and gson.

Source.

However, I suspect the issue is related to incorrectly configured credentials (see here) causing the library to then attempt JNDI lookup as a fallback (which definitely isn't supported by Android).


Post a Comment for "Android Studio - Android.jar And Rt.jar Conflicts"