-
Notifications
You must be signed in to change notification settings - Fork 27.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support APKs with 32-bit and 64-bit binaries within them #18494
Comments
AFAIK, currently, Flutter will only add libflutter.so to one selected platform folder in the release APK. The workaround which worked for me was to force build.gradle to do 32bit only (excluding all 64bit libraries + Intel)
|
cc @Hixie |
@swavkulinski how would you release the to apks to the playstore? |
…ter recognized x64 ABIS and build the whole project trageting that CPU Architecture. However that caused startup failure on non-x64 CPUS --> only included the armeabi-v7 instead of all types - Also APK size shrinked to 50% See: flutter/flutter#18494
Similar to #18939 |
Have the same problem - but flutter.so not included in "armeabi-v7a folder. APK without specify arch and not include libraries APK with libraries and no arm spec APK with specify arch and include libraries Any suggestion how to debug further steps? |
This comment has been minimized.
This comment has been minimized.
I have the same problem, building for 32-bit will exclude 64-bit devices, it runs on them though. Building for 64 by specifying Flutter Team, please resolve this basic issue! |
This comment has been minimized.
This comment has been minimized.
So am I wrong by saying that flutter can only support release apk’s for either 32 or 64 bit, but not both? |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
I am also having the same issue. In all of my dependencies, I isolated at least one package causing the issue, I filled a bug report accordingly: azihsoyn/flutter_mlkit#36 To isolate the problem, for each of my dependency / plugin:
the package example code (ex: https://pub.dartlang.org/packages/flutter_html_view#-example-tab-)
It turned out that the one creating was flutter_mlkit. I want to be able to target both 32 & 64 architectures. |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
lots of third SDK not working, i think it's urgent |
I can reproduce this when adding Mapbox to the android application. |
I have the same problem too.I use baiduMap in my Project,bebug model is ok,release crash. |
Similar to https://github.com/azihsoyn/flutter_mlkit/issues/36 , it works for me , the apk can run in both 32bit and 64bit phone. @peace2knowledge |
this should be very important problem for release apk |
is there a work around for this issue? |
android {
...
buildTypes {
release {
// TODO: Add your own signing config for the release build.
// Signing with the debug keys for now, so `flutter run --release` works.
signingConfig signingConfigs.debug
ndk {
abiFilters "arm"
}
}
debug {
ndk {
abiFilters "arm"
}
}
}
} |
For NDK, the 64-bit toolchain requires minSdkVersion >= 21. This unblocked me (with proper minSdkVersion set): minSdkVersion=16
minSdkVersion=21
|
Delete all abiFilters, it works for me. |
Anyone else got a mail from Google today, saying
although already publishing both 32bit and 64bit versions? It says
I guess, Google's "best estimate" is not correct? |
Thanks for Flutter team. I upgrade Flutter and build on stable channel and the warning is gone. |
Thanks Team Flutter, upgrading Flutter with the hotfix fixes this issue when building .aab |
Thanks to the flutter team for this achievement. Now to continue programmed! |
@abdullayev007 - thanks! I would suggest you to take a look at #35838, it might be somehow related. |
I tried the latest version of flutter from dev channel - v1.8.4. I created a fresh project too - vanilla flutter project and tried building a release signed version out of it. It builds and app size is just 10.4 mb. But tried all above steps in this trail, nothing helping out. Can some one give a clear set of sequence of steps to take a build that we can push to playstore with aab or apk with emulator and local device from flutter. Its been more than a week, we have project built on flutter not moving to prod on android, but we are able to publish to appstore on ios. Some help will be great. `[✓] Flutter (Channel dev, v1.8.4, on Mac OS X 10.14.5, locale en-US) [!] Android toolchain - develop for Android devices (Android SDK version 29.0.1) [✓] Xcode - develop for iOS and macOS (Xcode 10.3) [✓] Android Studio (version 3.4) [✓] VS Code (version 1.36.1) [✓] Connected device (3 available) |
@muthufmass, please file a new issue with details of what's not working and how to reproduce the failure. Thanks! |
|
These steps are already followed, its not working on the prod release build. debug build works! I clearly find a difference, in debug build, the .so files of flutter are present, but not with the release version. Those are ones, creating problem to install the apk to emulator or to devices with signed apk. |
I hope I have shared cleared steps above. Fresh app creation using flutter create - vanilla code with latest flutter sdk. Unable to build a release version, while debug versions runs smooth. Significant difference between prod and dev version of apk on size. Tried all the above steps, unable to build a release version that runs. Build happens super fast and file comes less than 11 mb with release, while with debug apk it comes around 40mb+. Debug apk works, while prod release signed apk doesnt install even. |
@muthufmass when you file the new issue, please include the Android SDK version, device model, the doctor output, and steps starting from |
@muthufmass as well as adb logcat output. This issue is closed - please file a new issue so we can track it properly. |
raised a separate ticket now #37935 |
how can I do this in adobe animate cc |
Google play console recently has started disabling the rollout button because of various warnings. And one of those warnings is using apk instead of .aab file. There are solutions to make .aab file if the project has been created in Android Studio or Unity. But what if apk has been created by Animate CC or Haxe/Flash Develop? Is there any way to convert? |
@newapproach it's not clear to me if your comment has anything to do with Flutter? Would you be willing to file a new issue with more details? Thanks! |
I has find this error too, it is fixed?? Could help me? |
I recommend asking on Stack Overflow, or opening a new bug. I doubt this closed bug will be the right place for folks to help you resolve the above issue. Thanks! |
doesn't work.. when I view it on playstore on pixel 2 it says not supported for this device |
It does work, many well-known apps have been deploying multiple APKs this way and letting the Play Store serve the appropriate one to the appropriate device for a long time. App bundles are the modern way to do this, though. |
I don’t know why it’s not showing up on pixel 2 playstore for me then... I folllowr exactly , twice, just incase.. |
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 |
using
flutter build apk --release --flavor pro
make apk file , but arm64-v8a do not include libflutter.so file.so app launch fail.when I add
--target-platform=android-arm64
:flutter build apk --release --flavor pro --target-platform=android-arm64
,apk file include so flie. But app launch fail on 32 bit cpu.what can i do, apk file can run on 64 and 32 cpu @mravn-google
I create new project, debug or releas, work well. diffrece from new project from my project is that i add thrid party
so
filewhere is the problem ?
The text was updated successfully, but these errors were encountered: