-
Notifications
You must be signed in to change notification settings - Fork 30.2k
Open
Description
Environment
- Flutter: (run
flutter --versionand paste here) - Android Gradle Plugin: 8.1+
- Gradle: (check android/gradle/wrapper/gradle-wrapper.properties)
- OS: Windows
Problem
Release build fails with two related errors:
android.bundle.enableUncompressedNativeLibsoption deprecated and removed in AGP 8.1Release app bundle failed to strip debug symbols from native libraries
Steps to Reproduce
- Run
flutter build appbundle --release - Build fails at
bundleReleaseGradle task
Error Output
Release app bundle failed to strip debug symbols from native libraries.
Please run flutter doctor and ensure that the Android toolchain does not
report any issues.
Root Cause
packagingOptionsblock is deprecated in AGP 8.1+ (replaced bypackaging)- NDK debug symbol stripping conflicts with Flutter's default Gradle config
Fix Applied
- Replaced
packagingOptionswithpackaginginbuild.gradle.kts - Removed
ndk { debugSymbolLevel = "NONE" }from release buildTypes - Moved
importstatements aboveplugins {}block
Expected Behavior
flutter build appbundle --release completes successfully.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels