AdamMc331
AdamMc331

Reputation: 16730

"INSTALL_PARSE_FAILED_MANIFEST_MALFORMED" Error when running project in Android Studio

I realize this may come as a duplicate question, I have found multiple questions looking for the same error but am still unable to solve the issue.

I am working on an Android application and for now only have one activity (a login screen) and when I attempt to run the application an error message appears:

pkg: /data/local/tmp/MyName.myapp
Failure [INSTALL_PARSE_FAILED_MANIFEST_MALFORMED]

As I said, I am dumbfounded. Has anyone experienced this, or notice something out of the ordinary in my manifest file?

<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="AdamMc.myapp" >

    <application
        android:allowBackup="true"
        android:icon="@drawable/ic_launcher"
        android:label="@string/app_name"
        android:theme="@style/AppTheme" >

        <activity
            android:name=".LoginActivity"
            android:label="@string/app_name" >

            <intent-filter>
                <action android:name="android.intent.action.MAIN" />
                <category android:name="android.intent.category.LAUNCHER" />
            </intent-filter>

        </activity>
    </application>
</manifest>

Upvotes: 1

Views: 3382

Answers (2)

AdamMc331
AdamMc331

Reputation: 16730

Aha, I continued to dig and dig and finally found it.

Thanks to this question here I realized it is because the package name cannot have capital letters. I changed my package name to simply 'myappname' instead of 'MyName.myappname' that android studio set it automatically, and was able to build and run.

Thank you to anyone who took the time to look into this.

Upvotes: 6

Rod_Algonquin
Rod_Algonquin

Reputation: 26198

notice something out of the ordinary in my manifest file?

Yes you dont have a target API tag in your manifest, which is needed to check for target device of your choice.

sample:

<uses-sdk
    android:minSdkVersion="14"
    android:targetSdkVersion="18" />

Upvotes: 1

Related Questions