As far as I know this isn't going to work nor would supporting it be easy. The compile SDK version points to the android.jar in the associated folder of the SDK. This jar is used as the bootclasspath when invoking javac for which there is only allowed to be one. Since the source files in the flavor are joined with the source files from the active build type and the main source tree, having a configuration like this could result in compile SDK version disagreements for some combinations of these three contributors to a variant.
Why do you need this? In practice you should always be compiling with the latest platform APIs regardless of the API level range for which the product flavor is targeting. On Tue, Jul 22, 2014 at 5:18 PM, <[email protected]> wrote: > We are trying to dynamically set the compileSdkVersion based on > productFlavors. Currently, I am trying to use android.setCompileSdkVersion > for each flavor, but this is not updating the value appropriately. I've > also tried looking into preprocessing tasks, but would like to avoid this > if possible. > > Thank you for the help! > > -- > You received this message because you are subscribed to the Google Groups > "adt-dev" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > For more options, visit https://groups.google.com/d/optout. > -- You received this message because you are subscribed to the Google Groups "adt-dev" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
