I have a problem when I try to launch my app in debug mode on actual devices (Galaxy S7 and Galaxy Tab 2 tested). During install, a dialog box appears indicating that the installation has failed with a "INSTALL_PARSE_FAILED_MANIFEST_MALFORMED" error. The error message continues with "<activity>
doesnot have a valid android:name". Line 23 of the manifest file reproduced below is incriminated (the line corresponds to the line just below the "<application
" line). As far as I can see, the name I give to my activity is totally correct.
What is even more strange is that, when launched on an emulator, the app get installed and works perfectly...
I can add that the dialog box suggests I should uninstall a previous version potentially installed, but I don't have one, and if I answer to remove it, it fails to uninstall it (which, this time, looks normal).
Any idea about what could cause this problem?
The manifest file :
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="GL.MesContacts"
android:versionCode="1"
android:versionName="1.0" >
<uses-sdk
android:minSdkVersion="21"
android:targetSdkVersion="26">
</uses-sdk>
<uses-permission android:name="android.permission.CALL_PHONE"/>
<uses-permission android:name="android.permission.READ_PHONE_STATE"/>
<uses-permission android:name="android.permission.RECEIVE_MMS"/>
<uses-permission android:name="android.permission.RECEIVE_SMS"/>
<uses-permission android:name="android.permission.SEND_SMS"/>
<application
android:allowBackup="true"
android:icon="@drawable/ic_launcher"
android:label="@string/app_name"
android:theme="@style/AppTheme">
<activity
android:name="GL.MesContacts.ActivitePrincipale"
android:label="@string/app_name">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<receiver
android:enabled="true"
android:exported="false"
android:label="string resource"
android:name="GL.MesContacts.RecepteurChangementEtatTelephone">
<intent-filter>
<action
android:name="android.intent.action.PHONE_STATE">
</action>
</intent-filter>
</receiver>
</application>