Set Up the Android P SDK

Posted on

Set Up the Android P SDK

Android P is the subsequent main launch of the Android, with a wide range of nice new methods you’ll be able to prolong your app. Android P additionally consists of habits modifications to assist enhance battery life, safety, and privateness, and these will have an effect on your app on units operating the brand new model of Android.

To developer with Android P APIs and check your app with the Android P habits modifications, comply with the directions on this web page to arrange the Android P Preview SDK in Android Studio and construct and run your app on Android P.

Get Android Studio 3.1 or increased

The Android P Preview SDK consists of modifications that aren’t suitable with Android Studio 3.0.

You possibly can compile and check Android P apps utilizing Android Studio 3.1, however some customers of the Android P Preview SDK might encounter Gradle sync failures and additions of out-dated dependencies with Android Studio 3.1.

For one of the best improvement expertise with the Android P Preview SDK, we suggest that you simply set up the most recent Android Studio 3.2 canary.

GET ANDROID STUDIO 3.2 CANARY

You possibly can maintain your present model of Android Studio put in as a result of you’ll be able to set up a number of variations aspect by aspect.

Get the Android P Preview SDK

After you put in and open Android Studio 3.2, set up the Android P Preview SDK as follows:

  1. Click on Instruments > SDK Supervisor.
  2. Within the SDK Platforms tab, choose Android P Preview.
  3. Within the SDK Instruments tab, choose Android SDK Construct-Instruments 28-rc2 (or increased).
  4. Click on OK to start set up.

Replace your construct configuration

To totally check your app’s compatibility with Android P and start utilizing new APIs, open your module-level construct.gradle file and replace the compileSdkVersion and targetSdkVersion as proven right here:

Notice: Beginning with model 3.0.Zero of the Android Plugin for Gradle, you don’t have to declare buildToolsVersion anymore. To be taught concerning the modifications in Android P that may have an effect on your app and start testing them, learn Android P Conduct Modifications.

To be taught extra about new APIs accessible in Android P, learn Android P Options and APIs.