口味😋: 修复run和build共存不报错(universalApk true)
This commit is contained in:
parent
a6251cbc2d
commit
82eeccd2a4
@ -115,15 +115,22 @@ android {
|
||||
versionName flutterVersionName
|
||||
|
||||
signingConfig signingConfigs.pre
|
||||
// 为减少体积,使用不同架构分包发布编译选项 flutter build apk --split-per-abi
|
||||
// 所以需要禁用ndk在同一个个包中包含多个架构
|
||||
|
||||
// 为减少体积,使用不同架构分包发布编译选项 flutter build apk --split-per-abi
|
||||
// 所以需要禁用ndk在同一个个包中包含多个架构
|
||||
// 但是禁用NDK配置,又无法使用flutter run 命令了,因为编译完成它按照名称匹配找不到.apk包
|
||||
ndk {
|
||||
//设置支持的SO库架构(开发者可以根据需要,选择一个或多个平台的so)
|
||||
abiFilters "armeabi", "armeabi-v7a", "arm64-v8a", "x86","x86_64"
|
||||
}
|
||||
splits {
|
||||
abi {
|
||||
enable true
|
||||
reset()
|
||||
// x86_64,x86,armeabi-v7a,armeabi,arm64-v8a
|
||||
// x86_64,x86,armeabi-v7a,armeabi,arm64-v8a
|
||||
include "armeabi", "armeabi-v7a", "arm64-v8a", "x86","x86_64"
|
||||
universalApk true
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -75,4 +75,4 @@
|
||||
</intent-filter>
|
||||
</receiver>
|
||||
</application>
|
||||
</manifest>
|
||||
</manifest>
|
||||
Loading…
x
Reference in New Issue
Block a user