Skip to content

[tool] [Proposal] Support compileSdk for Android apps #137621

@navaronbracke

Description

@navaronbracke

Is there an existing issue for this?

Use case

I am using com.android.tools.build:gradle:8.1.2 and distributionUrl=https\://services.gradle.org/distributions/gradle-8.1.1-bin.zip in a Flutter plugin project.

Upon opening the example app's Android build.gradle, I noticed a deprecation warning for compileSdkVersion.
Apparently it is being renamed to compileSdk.

Screenshot 2023-10-31 at 14 28 32

IIRC this was not the case yet in Gradle 8.0 and Android SDK 33

Just filing this for visibility.

[✓] Flutter (Channel stable, 3.13.8, on macOS 14.0 23A344 darwin-x64, locale
    en-BE)
    • Flutter version 3.13.8 on channel stable at
      /Users/navaronbracke/Documents/flutter
    • Upstream repository [email protected]:navaronbracke/flutter.git
    • FLUTTER_GIT_URL = [email protected]:navaronbracke/flutter.git
    • Framework revision 6c4930c4ac (13 days ago), 2023-10-18 10:57:55 -0500
    • Engine revision 767d8c75e8
    • Dart version 3.1.4
    • DevTools version 2.25.0

[✓] Android toolchain - develop for Android devices (Android SDK version 34.0.0)
    • Android SDK at /Users/navaronbracke/Library/Android/sdk
    • Platform android-34, build-tools 34.0.0
    • ANDROID_HOME = /Users/navaronbracke/Library/Android/sdk
    • Java binary at: /Applications/Android
      Studio.app/Contents/jbr/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build
      17.0.6+0-17.0.6b829.9-10027231)
    • All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS (Xcode 15.0.1)
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • Build 15A507
    • CocoaPods version 1.13.0

[✓] Chrome - develop for the web
    • Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome

[✓] Android Studio (version 2022.3)
    • Android Studio at /Applications/Android Studio.app/Contents
    • Flutter plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/6351-dart
    • Java version OpenJDK Runtime Environment (build
      17.0.6+0-17.0.6b829.9-10027231)

[✓] VS Code (version 1.83.1)
    • VS Code at /Applications/Visual Studio Code.app/Contents
    • Flutter extension version 3.74.0

[✓] Connected device (2 available)
    • macOS (desktop) • macos  • darwin-x64     • macOS 14.0 23A344 darwin-x64
    • Chrome (web)    • chrome • web-javascript • Google Chrome 118.0.5993.117

[✓] Network resources
    • All expected network resources are available.

• No issues found!

Proposal

Support both compileSdkVersion and compileSdk in the tool.

Metadata

Metadata

Assignees

No one assigned

    Labels

    c: new featureNothing broken; request for a new capabilityc: proposalA detailed proposal for a change to Flutterplatform-androidAndroid applications specificallyteam-toolOwned by Flutter Tool teamtoolAffects the "flutter" command-line tool. See also t: labels.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions