The docs claim a build.gradle
like this works:
android {
compileSdkVersion 'android-N'
buildToolsVersion 24.0.0
...
defaultConfig {
minSdkVersion 'N'
targetSdkVersion 'N'
...
}
...
}
That gives me failed to find Build Tools revision 24.0.0
, when using 'com.android.tools.build:gradle:1.5.0'
for the Android Plugin for Gradle and Gradle 2.5.
If I look in build-tools/
in my Android SDK installation, I see 24.0.0-preview
, not 24.0.0
. However, if I switch my build.gradle
to use buildToolsVersion "24.0.0-preview"
, I get Invalid revision: 24.0.0-preview
.
So, what combination of build.gradle
values works to build a project to compile against the N Developer Preview SDK?
The project configuration determines what build settings and compiler options are used when you build the project. To create, select, modify, or delete a configuration, you can use the Configuration Manager. To open it, on the menu bar, choose Build > Configuration Manager, or just type Configuration in the search box.
If a project configuration doesn't specify a platform or specifies just one platform, then a solution configuration whose name matches that of the new project configuration is either found or added. The default name of this solution configuration does not include a platform name; it takes the form <project configuration name>.
The configuration and platform that a project targets are used together to specify the build settings and compiler options to use when it's built. A project can have different settings for each combination of configuration and platform.
The default project configuration settings, defined in the Project Configuration Editor, are provided below. To access the Project Configuration Editor in Developer, right-click the project source and choose Project Configuration. Create or edit a description of the project. Click the Modify button to alter three different properties: 1. Security
Based on one of the sample apps, I am now using:
'com.android.tools.build:gradle:2.1.0-alpha1'
for the Android Plugin for Gradle (goes in your top-level build.gradle
file)buildToolsVersion "24.0.0 rc1"
This seems to be holding up, including with Android Studio 1.5.1.
UPDATE: Now that N Developer Preview 4 has been released, we can start using 24
in place of "N"
and "android-N"
:
android {
compileSdkVersion 24
buildToolsVersion "24.0.0"
defaultConfig {
minSdkVersion 24
targetSdkVersion 24
}
}
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