Search code examples
javaandroiddependenciesaviaryokhttp

Android dependencies with libraries


So a library I want to use depends on OkHttp 1.2.1, and I am currently using the newest version of OkHttp 2.0.

This naturally results in a compilation error as multiple dex files are generated for the same classes.

I don't quite want to manually update the library, and I do require the newest version of OkHttp.

Is there a way to somehow prioritize the latest version of OkHttp for any of my classes, and have the library continue to use the old version?


Solution

  • Ended up just renaming the namespace for the newer version of the library and including it!