Salut à toutes et tous,
Je migre une application FMX compilée avec Delphi 10.4.2, avec pour cible Android 64 ou Windows 64.
Windows : OK 0 problème
Android : passé les quelques autres soucis de version de Java et de chemins pas bien récupérés par le setup, et corrigés, je builde : OK
Je déploie : OK
mais au lancement j'ai cette erreur :
Le projet XXX.apk a déclenché la classe d'exception EJNIException avec le message 'java.lang.SecurityException: Settings key: <bluetooth_name> is only readable to apps with targetSdkVersion lower than or equal to: 31'.
Précision : JE N'AI PAS de BLUETOOTH dans mon fichier AndroidManifest.
1 - Je ne sais donc pas d'où il sort ce bluetooth_name qui n'ai dans aucun fichier de mes dossiers d'ailleurs.
ci-dessous mon fichier androidmanifest.xml déployé.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63
| <?xml version="1.0" encoding="utf-8"?>
<!-- BEGIN_INCLUDE(manifest) -->
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
package="fr.YYY.XXX.dev"
android:versionCode="1"
android:versionName="1.0.0"
android:installLocation="auto">
<uses-sdk android:minSdkVersion="23" android:targetSdkVersion="31" />
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" android:maxSdkVersion="31" />
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" android:maxSdkVersion="31" />
<uses-feature android:glEsVersion="0x00020000" android:required="true"/>
<application android:persistent="False"
android:restoreAnyVersion="False"
android:label="XXX"
android:debuggable="true"
android:largeHeap="False"
android:icon="@drawable/ic_launcher"
android:theme="@style/AppTheme"
android:hardwareAccelerated="true"
android:resizeableActivity="false"
android:requestLegacyExternalStorage="true"
android:usesCleartextTraffic="true"
android:networkSecurityConfig="@xml/network_security_config">
<!-- Trigger Google Play services to install the backported photo picker module. -->
<service
android:name="com.google.android.gms.metadata.ModuleDependencies"
android:enabled="false"
android:exported="false"
tools:ignore="MissingClass">
<intent-filter>
<action android:name="com.google.android.gms.metadata.MODULE_DEPENDENCIES" />
</intent-filter>
<meta-data android:name="photopicker_activity:0:required" android:value="" />
</service>
<!-- Our activity is a subclass of the built-in NativeActivity framework class.
This will take care of integrating with our NDK code. -->
<activity
android:name="com.embarcadero.firemonkey.FMXNativeActivity"
android:exported="true"
android:label="CompaCare"
android:configChanges="orientation|keyboard|keyboardHidden|screenSize|screenLayout|uiMode"
android:launchMode="singleTask">
<!-- Tell NativeActivity the name of our .so -->
<meta-data android:name="android.app.lib_name" android:value="XXX" />
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<receiver android:name="com.embarcadero.rtl.notifications.NotificationAlarm" />
</application>
</manifest>
<!-- END_INCLUDE(manifest) --> |
Par défaut le targetSdkVersion était = 34, je l'ai mis à 31. idem.
Est-ce que une bonne âme aurait une solution svp ?
Merci !
Partager