I worked more on this, but to no avail. Here is my new set of dependencies,
which seems more correct given the "net" jar and ssl support are both on the
classpath:
dependencies {
compile 'com.google.android:support-v4:r7'
compile 'com.google.code.gson:gson:2.2.4'
compile group: "org.restlet.android", name: "org.restlet", version:
versions.restlet
compile group: "org.restlet.android", name: "org.restlet.ext.json",
version: versions.restlet
compile group: "org.restlet.android", name: "org.restlet.ext.net", version:
versions.restlet
}
This is a Gradle 1.9 build btw, wagged to some extent by my use of Android
Studio 0.4x. I'm ok with the Gradle build, which I mention for the sake of
completeness.
The problem with this set of dependencies is that it does not change the
original error 1002. It also requires, during APK repackaging that I add this
exclusion to the packaging in the build file:
packagingOptions {
exclude 'META-INF/services/org.restlet.engine.ClientHelper'
}
If I do not exclude the META-INF file, I get this when I build:
validateDebugSigning
:packageDebug
Error: duplicate files during packaging of APK
/Users/mpetrovic/Projects/ClipsAndroid/build/apk/ClipsAndroid-debug-unaligned.apk
Path in archive: META-INF/services/org.restlet.engine.ClientHelper
Origin 1:
/Users/mpetrovic/.gradle/caches/modules-2/files-2.1/org.restlet.android/org.restlet.ext.ssl/2.1.6/5c1929b6ed270fe29688f6f76665c281fb898f62/org.restlet.ext.ssl-2.1.6.jar
Origin 2:
/Users/mpetrovic/.gradle/caches/modules-2/files-2.1/org.restlet.android/org.restlet.ext.net/2.1.6/c0b207da17369e94f1eda18aa107e302d09b9fa2/org.restlet.ext.net-2.1.6.jar
You can ignore those files in your build.gradle:
android {
packagingOptions {
exclude 'META-INF/services/org.restlet.engine.ClientHelper'
}
}
:packageDebug FAILED
I'm out of ideas. Please help.
Thanks.
------------------------------------------------------
http://restlet.tigris.org/ds/viewMessage.do?dsForumId=4447&dsMessageId=3071492