turing-tech / MaterialScrollBar

An Android library that brings the Material Design 5.1 sidebar to pre-5.1 devices.
Apache License 2.0
781 stars 126 forks source link

Build error after upgrade to v 13.2.0 #109

Closed silent10 closed 6 years ago

silent10 commented 6 years ago

I have just upgraded to the latest version 13.2.0 and I am getting these build errors:

Error:com.android.builder.dexing.DexArchiveBuilderException: Failed to process C:\Users\we\.gradle\caches\transforms-1\files-1.1\MaterialScrollBar-13.2.0.aar\ad64a5be3ca6b2e73298e987496ac8dd\jars\classes.jar

Error:com.android.builder.dexing.DexArchiveBuilderException: Error while dexing com/turingtechnologies/materialscrollbar/TouchScrollBar.class

Error:com.android.dx.cf.code.SimException: invalid opcode ba (invokedynamic requires --min-sdk-version >= 26)

`Error:Execution failed for task ':app:transformClassesWithDexBuilderForDebug'.

com.android.build.api.transform.TransformException: com.android.builder.dexing.DexArchiveBuilderException: com.android.builder.dexing.DexArchiveBuilderException: Failed to process C:\Users\we.gradle\caches\transforms-1\files-1.1\MaterialScrollBar-13.2.0.aar\ad64a5be3ca6b2e73298e987496ac8dd\jars\classes.jar`

I have tried invalidating caches and restarting Android Studio but the project is still not building.

turing-tech commented 6 years ago

You didn't finish reading the error. Include the following in your Gradle:

android { compileOptions { sourceCompatibility JavaVersion.VERSION_1_8 targetCompatibility JavaVersion.VERSION_1_8 } }

I may go back and remove Java 8 features to avoid this. Pretty stupid design by the Android team if you ask me.