Skip to content

flutter build apk --split-per-abi generates apk with wrong version code #39817

Closed

Description

@PandaGeek1024

Steps to Reproduce

  1. update pubspec.yaml with version: 0.8.0+10
  2. runs 'flutter build apk --split-per-abi' on terminal
  3. open generated apks and inspect AndroidManifest.xml
    results:
    arm64-v8a.apk . versionCode='2010'
    armeabi-v7a.apk . versionCode='1010'

However, when I simply runs 'flutter build apk', the generated apk shows correct versionCode 10.

image
image
image

Logs

[✓] Flutter (Channel stable, v1.7.8+hotfix.4, on Mac OS X 10.14.5 18F132, locale en-NZ)
    • Flutter version 1.7.8+hotfix.4 at /Users/pengfeihuang/Developer/Flutter/flutter
    • Framework revision 20e59316b8 (7 weeks ago), 2019-07-18 20:04:33 -0700
    • Engine revision fee001c93f
    • Dart version 2.4.0

 
[✓] Android toolchain - develop for Android devices (Android SDK version 28.0.3)
    • Android SDK at /Users/pengfeihuang/Library/Android/sdk
    • Android NDK location not configured (optional; useful for native profiling support)
    • Platform android-28, build-tools 28.0.3
    • ANDROID_HOME = /Users/pengfeihuang/Library/Android/sdk
    • Java binary at: /Applications/Android Studio.app/Contents/jre/jdk/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build 1.8.0_202-release-1483-b49-5587405)
    • All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS (Xcode 10.2.1)
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • Xcode 10.2.1, Build version 10E1001
    • CocoaPods version 1.6.1

[✓] iOS tools - develop for iOS devices
    • ios-deploy 1.9.4

[✓] Android Studio (version 3.5)
    • Android Studio at /Applications/Android Studio.app/Contents
    • Flutter plugin version 38.2.3
    • Dart plugin version 191.8423
    • Java version OpenJDK Runtime Environment (build 1.8.0_202-release-1483-b49-5587405)

[!] IntelliJ IDEA Community Edition (version 2018.3.5)
    • IntelliJ at /Applications/IntelliJ IDEA CE.app
    ✗ Flutter plugin not installed; this adds Flutter specific functionality.
    ✗ Dart plugin not installed; this adds Dart specific functionality.
    • For information about installing plugins, see
      https://flutter.dev/intellij-setup/#installing-the-plugins

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

[✓] Connected device (1 available)
    • Nexus 5 • 098ab956028b4d80 • android-arm • Android 6.0.1 (API 23)

! Doctor found issues in 1 category.

Activity

  1. added
    t: gradle"flutter build" and "flutter run" on Android
    toolAffects the "flutter" command-line tool. See also t: labels.
    on Sep 4, 2019
  2. zanderso commented on Sep 4, 2019

    @zanderso
    Member
  3. PandaGeek1024 commented on Sep 6, 2019

    @PandaGeek1024
    Author

    no one has got this issue?

  4. blasten commented on Sep 6, 2019

    @blasten

    @PandaGeek1024 This is the intended behavior. See https://developer.android.com/studio/build/configure-apk-splits#configure-APK-versions for more about versioning multiple APKs. Alternatively, you can build app bundles. The APKs generated from an app bundle will have the same version.

  5. fzyzcjy commented on Aug 12, 2021

    @fzyzcjy
    Contributor

    Hi I only want it to support one abi, so how can I make that one abi to do not be increased by 1000? Thanks!

  6. github-actions commented on Aug 26, 2021

    @github-actions

    This thread has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar issue, please open a new bug, including the output of flutter doctor -v and a minimal reproduction of the issue.

  7. locked as resolved and limited conversation to collaborators on Aug 26, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    t: gradle"flutter build" and "flutter run" on AndroidtoolAffects 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