2017-08-13 30 views
0

我嘗試使用IndoorAtlas Android SDK示例。我遵循this指南。transformClassesWithDexForDebug使用IndoorAtlas Library

但是當我嘗試運行它,我得到這個錯誤:

Error:Uncaught translation error: com.android.dx.cf.code.SimException: local variable type mismatch: attempt to set or access a value of type java.lang.Object[] using a local variable of type com.indooratlas.android.sdk.IAGeofenceRequest. This is symptomatic of .class transformation tools that ignore local variable information.

Error:1 error; aborting

Error:Execution failed for task ':app:transformClassesWithDexForDebug'. com.android.build.api.transform.TransformException: java.lang.RuntimeException: java.lang.RuntimeException: Unable to pre-dex '/Users/xxx/AndroidStudioProjects/IndoorLocalization/app/libs/indooratlas-android-sdk-2.5.1.jar' to '/Users/xxx/AndroidStudioProjects/IndoorLocalization/app/build/intermediates/transforms/dex/debug/folders/1000/10/indooratlas-android-sdk-2.5.1_dbe918a8d06cf55c975257e4802cd6d4f4f48ea4'

我怎樣才能解決這個問題呢?

+0

你可以添加任何細節,如使用的代碼,[我如何問一個好問題?](http://stackoverflow.com/help/how-to-ask),[如何創建一個最小,完整和可驗證示例](http://stackoverflow.com/help/mcve)向社區顯示您嘗試過的內容。 –

回答

1

IndoorAtlas Android SDK 2.5.1有一個錯誤,其中包含proguard opimizations。使用修正了這個錯誤的更新的2.5.2版本。版本2.5.2可以通過指定

dependencies { 
    ... 
    compile 'com.indooratlas.android:indooratlas-android-sdk:2.5.2' 
    ... 
} 

在您的應用程序build.gradle文件中。

+0

好吧,它的作品,謝謝! – Segamoto

相關問題