Skip to content

Commit

Permalink
build without neon libs
Browse files Browse the repository at this point in the history
  • Loading branch information
deckerst committed Aug 23, 2023
1 parent 8e01f30 commit bdd37a4
Show file tree
Hide file tree
Showing 3 changed files with 27 additions and 9 deletions.
7 changes: 7 additions & 0 deletions android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,13 @@ android {
disable 'InvalidPackage'
}

packagingOptions {
// The Amazon Developer console mistakenly considers the app to not be 64-bit compatible
// if there are some libs in `lib/armeabi-v7a` unmatched by libs in `lib/arm64-v8a`,
// so we exclude the extra `neon` libs bundled by `FFmpegKit`.
exclude 'lib/armeabi-v7a/*_neon.so'
}

sourceSets {
main.java.srcDirs += 'src/main/kotlin'
}
Expand Down
24 changes: 17 additions & 7 deletions android/app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -32,32 +32,42 @@

<!-- to access media with original metadata with scoped storage (API >=29) -->
<uses-permission android:name="android.permission.ACCESS_MEDIA_LOCATION" />
<!-- to analyze media in a service -->
<uses-permission android:name="android.permission.FOREGROUND_SERVICE" />
<!-- to fetch map tiles -->
<!-- TODO TLAD still needed to fetch map tiles / reverse geocoding / else ? check in release mode -->
<uses-permission android:name="android.permission.INTERNET" />
<!-- from Android 12 (API 31), users can optionally grant access to the media management special permission -->
<uses-permission
android:name="android.permission.MANAGE_MEDIA"
tools:ignore="ProtectedPermissions" />
<!-- to show foreground service progress via notification -->
<!-- to show analysis service progress via notification -->
<uses-permission android:name="android.permission.POST_NOTIFICATIONS" />
<!-- to change wallpaper -->
<uses-permission android:name="android.permission.SET_WALLPAPER" />
<!-- to unlock vaults (API >=28) -->
<uses-permission android:name="android.permission.USE_BIOMETRIC" />
<!-- TODO TLAD remove this permission when this is fixed: https://github.com/flutter/flutter/issues/42451 -->
<uses-permission android:name="android.permission.WAKE_LOCK" />

<uses-permission
android:name="com.android.launcher.permission.INSTALL_SHORTCUT"
android:maxSdkVersion="25" />

<!-- additional permissions added by plugins:
`{package}.DYNAMIC_RECEIVER_NOT_EXPORTED_PERMISSION` by `androidx.appcompat:appcompat`
`android.permission.ACCESS_NETWORK_STATE`,
`android.permission.FOREGROUND_SERVICE`,
`android.permission.RECEIVE_BOOT_COMPLETED`,
`android.permission.WAKE_LOCK` by `androidx.work:work-runtime-ktx`, to analyze media in a service
`android.permission.ACCESS_NETWORK_STATE` by `dev.fluttercommunity.plus.connectivity`, TODO TLAD still needed?
`android.permission.USE_BIOMETRIC` by `io.flutter.plugins.localauth`, to unlock vaults (API >=28)
-->

<!--
allow install on API 19, despite the `minSdkVersion` declared in dependencies:
- Google Maps is from API 20
- the Security library is from API 21
- FFmpegKit for Flutter is from API 24
- FFmpegKit for Flutter is from API 24 (when not LTS)
-->
<uses-sdk tools:overrideLibrary="io.flutter.plugins.googlemaps, androidx.security:security-crypto, com.arthenica.ffmpegkit.flutter" />

Expand Down
5 changes: 3 additions & 2 deletions lib/model/app/dependencies.dart
Original file line number Diff line number Diff line change
Expand Up @@ -69,8 +69,9 @@ class Dependencies {
),
Dependency(
name: 'Dynamic Color',
license: bsd3,
sourceUrl: 'https://github.com/material-foundation/material-dynamic-color-flutter',
license: apache2,
licenseUrl: 'https://github.com/material-foundation/flutter-packages/blob/main/packages/dynamic_color/LICENSE',
sourceUrl: 'https://github.com/material-foundation/flutter-packages/tree/main/packages/dynamic_color',
),
Dependency(
name: 'Floating',
Expand Down

0 comments on commit bdd37a4

Please sign in to comment.