Android Studio Error when adding Adobe Creative SDK

前端 未结 2 1252
后悔当初
后悔当初 2021-01-28 20:55

This is my build.gradle file. I have followed this tutorial.

repositories {
    mavenCentral()
    jcenter()
    mavenLocal()
    maven {
               


        
相关标签:
2条回答
  • 2021-01-28 21:49

    Put downloaded sdk into root directory and add

    maven {
             url "${project.rootDir}/creativesdk-repo"//your sdk name as it is
          } 
    

    in Application's build.grade file under the "allprojects/repositories" section: as follow

    allprojects {
        repositories {
            mavenCentral()
            jcenter()
    
            maven {
                url "${project.rootDir}/creativesdk-repo" 
            }
        }
    }
    

    make sure to add the packaging options to the Application's build.grade file under the "android" section:

    packagingOptions {
            exclude 'META-INF/DEPENDENCIES'
            exclude 'META-INF/NOTICE'
            exclude 'META-INF/NOTICE.txt'
            exclude 'META-INF/LICENSE.txt'
            exclude 'META-INF/LICENSE'
        }
    
    0 讨论(0)
  • 2021-01-28 21:58

    I have downloaded Adobe Creative SDK and put it inside the project folder in workspace. The folder name is "creativesdk-repo". Changed the URL in build.gradle file to this:

    url "${project.rootDir}/creativesdk-repo"

    (or whatever the name of the folder is)

    Sync the build.gradle file and it works.

    Don't forget to add this..

    android {
        ....
        packagingOptions {
            exclude 'META-INF/DEPENDENCIES'
            exclude 'META-INF/NOTICE'
            exclude 'META-INF/NOTICE.txt'
            exclude 'META-INF/LICENSE.txt'
            exclude 'META-INF/LICENSE'
        }
        ....
    }
    
    0 讨论(0)
提交回复
热议问题