AnsweredAssumed Answered

Eclipse fail to import smack 4.1 by gradle

Question asked by Jimmy on Apr 23, 2015
Latest reply on Apr 26, 2015 by Jimmy

Hi all,

     I got News that smack 4.1 support Android natively. So, i upgrade from asmack-android-16 to smack 4.1.

I follow Smack 4.1 Readme and Upgrade Guide · igniterealtime/Smack Wiki · GitHub  to upgrade my project.

Unfortunately, i can't smoothly upgrade it. I got some error message when got the lib by using gradle.

 

 

Error message :

 

 

My build.grade

 

buildscript {

    repositories {

        maven {

            url 'https://oss.sonatype.org/content/repositories/snapshots'

          }

       

          jcenter()

    }

    dependencies {

        //classpath 'com.android.tools.build:gradle:0.5.+'

        classpath 'com.android.tools.build:gradle:1.0.+'

     

    }

}

 

apply plugin: 'eclipse'

 

dependencies {

 

   compile fileTree(dir: 'libs', include: '*.jar')

   compile "org.igniterealtime.smack:smack-android-extensions:4.1.1-SNAPSHOT"

   compile "org.igniterealtime.smack:smack-experimental:4.1.1-SNAPSHOT"

   compile "org.igniterealtime.smack:smack-tcp:4.1.1-SNAPSHOT"

  

}

 

android {

    compileSdkVersion 19

    buildToolsVersion "18.1.0"

 

    sourceSets {

        main {

            manifest.srcFile 'AndroidManifest.xml'

            java.srcDirs = []

            resources.srcDirs = []

            aidl.srcDirs = []

            renderscript.srcDirs = []

            res.srcDirs = ['res']

            assets.srcDirs = ['assets']

        }

 

        // Move the tests to tests/java, tests/res, etc...

        instrumentTest.setRoot('tests')

    }

}

 

 

Can any one give some suggestion?@

Outcomes