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,
compile files ('C:/Program Files/Java/jdk1.8.0_77/jre/lib/rt.jar')
Error:Execution failed for task ':app:transformClassesWithMultidexlistForDebug'.
> com.android.build.api.transform.TransformException: com.android.ide.common.process.ProcessException: org.gradle.process.internal.ExecException: Process 'command 'C:\Program Files\Java\jdk1.8.0_77\bin\java.exe'' finished with non-zero exit value 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.
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).