I imported a github module to Android Studio and the build.gradle compile section.
The module is - https://github.com/go-ive/steam-api
Whenever I try to run the application I get this error:
Error:Error converting bytecode to dex:
Cause: Dex cannot parse version 52 byte code.
This is caused by library dependencies that have been compiled using Java 8 or above.
If you are using the 'java' gradle plugin in a library submodule add
targetCompatibility = '1.7'
sourceCompatibility = '1.7'
to that submodule's build.gradle file.
I tried adding those two lines and tried numerous of other options but it still doesnt work. Is there something I can add that will make this specific module work? Thank you.
The build.gradle looks like this (Excluding the top):
dependencies {
compile fileTree(include: ['*.jar'], dir: 'libs')
androidTestCompile('com.android.support.test.espresso:espresso-core:2.2.2', {
exclude group: 'com.android.support', module: 'support-annotations'
})
compile 'com.android.support:appcompat-v7:24.2.1'
compile 'com.github.go-ive:steam-api:4.2'
testCompile 'junit:junit:4.12'
}