0

I've started using the RadiusNetworks API 1.0.1 and I've followed the setup guide in the following link:

http://www.proximitykit.com/kits/279/download/android

When I've finished the setup I click the "Make Project" button and I have the following error:

Error: duplicate files during packaging of APK /Users/charly.murillo/AndroidStudioProjects/IbeaconsProDemo/app/build/apk/app-debug-unaligned.apk

Error: Execution failed for task ':app:packageDebug'.

Duplicate files copied in APK META-INF/LGPL2.1 File 1: /Users/charly.murillo/AndroidStudioProjects/IbeaconsProDemo/app/build/exploded-bundles/ComRadiusnetworksAndroidProximityLibrary1.aar/libs/jackson-core-lgpl-1.9.13.jar File 2: /Users/charly.murillo/AndroidStudioProjects/IbeaconsProDemo/app/build/exploded-bundles/ComRadiusnetworksAndroidProximityLibrary1.aar/libs/jackson-core-lgpl-1.9.13.jar

Anyone knows how to fix this??

Thanks in advance!

davidgyoung
  • 63,876
  • 14
  • 121
  • 204
  • I see from another channel that you are using Android Studio 0.4.0. I am going to try this version to see if I can reproduce the problem. – davidgyoung Jan 02 '14 at 23:22

1 Answers1

0

I have reproduced this problem. It seems to have been introduced by a change in Android Studio 0.4.0. As a work-around, please add a packagingOptions block to your build.gradle file as so:

android {
    compileSdkVersion 18
    buildToolsVersion "18.1.1"

    defaultConfig {
        minSdkVersion 18
        targetSdkVersion 19
    }
    sourceSets {
        main {
            resources.srcDirs = ['src/main/java']
        }
    }
    android {
        packagingOptions {
            exclude 'META-INF/LGPL2.1'
            exclude 'META-INF/LICENSE'
            exclude 'META-INF/NOTICE'
        }
    }
}

I will work on a better fixed in the next release.

davidgyoung
  • 63,876
  • 14
  • 121
  • 204