I'm trying to create a ndk project with android studio according this tutorial and I get this error when I try to sync my gradle:
Gradle DSL method not found: 'flavorGroups()'
I'm using gradle 2.2.1, with android studio 1.0.2. Here is a part of my gradle file:
defaultConfig.versionCode = 1
flavorGroups "abi"
productFlavors {
x86 {
flavorGroup "abi"
ndk {
abiFilter "x86"
}
versionCode = 3
}
arm {
flavorGroup "abi"
ndk {
abiFilter "armeabi-v7a"
}
versionCode = 1
}
mips {
flavorGroup "abi"
ndk {
abiFilter "mips"
}
versionCode = 2
}
fat {
flavorGroup "abi"
versionCode = 0
}
}
applicationVariants.all { variant ->
def abiVersion = variant.productFlavors.get(1).versionCode
variant.mergedFlavor.versionCode = abiVersion * 100000 + defaultConfig.versionCode
}
Thank you for your answers.
The Android Gradle pluging received an update which changed the name of flavorGroups to flavorDimensions. You will also have to change the name of each flavorGroup to flavorDimension. If you make that change then you won't receive that error any more.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With