dependencies - Gradle build error with Simpleframework -


i upload library module jcenter , use module application project.

i try build application returns error.

i searched issue , issue due aware of simpleframework.

i have use library both library module , application module.

how can solve problem?

gradle error msg below

trouble processing "javax/xml/stream/events/startelement.class": ill-advised or mistaken usage of core class (java.* or javax.*) when not building core library. due inadvertently including core library file in application's project, when using ide (such eclipse). if sure you're not intentionally defining core class, explanation of what's going on. however, might trying define class in core namespace, source of may have taken, example, non-android virtual machine project. assuredly not work. @ minimum, jeopardizes compatibility of app future versions of platform. of questionable legality. if intend build core library -- appropriate part of creating full virtual machine distribution, opposed compiling application -- use "--core-library" option suppress error message. if go ahead , use "--core-library" in fact building application, forewarned application still fail build or run, @ point. please prepared angry customers find, example, application ceases function once upgrade operating system. blame problem. if legitimately using code happens in core package, easiest safe alternative have repackage code. is, move classes in question own package namespace. means never in conflict core system classes. jarjar tool may in endeavor. if find cannot this, indication path on lead pain, suffering, grief, , lamentation. 1 error; aborting error:execution failed task ':app:predexdebug'.

com.android.ide.common.process.processexception: org.gradle.process.internal.execexception: process 'command 'c:\jdk1.7.0\bin\java.exe'' finished non-zero exit value 1

my library build.gradle dependencies below.

dependencies {     compile filetree(dir: 'libs', include: ['*.jar'])     compile 'com.mcxiaoke.volley:library:1.0.+'     compile 'com.google.code.gson:gson:2.2.4'     compile ('org.simpleframework:simple-xml:2.7.+') {         exclude module: 'stax'         exclude module: 'stax-api'         exclude module: 'xpp3'     } } 

my application dependencies below :

dependencies {     compile 'com.android.support:support-v4:19.+'     compile 'com.google.android.gms:play-services:5.+'     compile 'com.jakewharton:butterknife:5.1.2'     compile 'com.jakewharton.timber:timber:3.1.0'     compile 'commons-io:commons-io:2.4'     compile 'commons-net:commons-net:3.3'     compile 'org.apache.httpcomponents:httpmime:4.2.5'     /*compile 'com.mcxiaoke.volley:library:1.0.+'     compile 'com.google.code.gson:gson:2.2.4'     compile('org.simpleframework:simple-xml:2.7.+') {         exclude module: 'stax'         exclude module: 'stax-api'         exclude module: 'xpp3'     }*/     compile 'org.jsoup:jsoup:1.7.2+'     compile 'com.effectivelife:cokcok-support:1.0.0' } 

i solved problem.

i add configurations application project.

so application build.gradle file below.

configurations {     compile.exclude module: 'stax'     compile.exclude module: 'stax-api'     compile.exclude module: 'xpp3' }  dependencies {     compile 'com.android.support:support-v4:19.+'     compile 'com.google.android.gms:play-services:5.+'     compile 'com.jakewharton:butterknife:5.1.2'     compile 'com.jakewharton.timber:timber:3.1.0'     compile 'commons-io:commons-io:2.4'     compile 'commons-net:commons-net:3.3'     compile 'org.apache.httpcomponents:httpmime:4.2.5'     compile 'org.jsoup:jsoup:1.7.2+'     compile 'com.effectivelife:cokcok-support:1.0.1' } 

Comments

Popular posts from this blog

Magento/PHP - Get phones on all members in a customer group -

php - Bypass Geo Redirect for specific directories -

php - .htaccess mod_rewrite for dynamic url which has domain names -