The application could not be installed: INSTALL_PARSE_FAILED_MANIFEST_MALFORMED

Session 'app': Installation did not succeed.
            The application could not be installed: INSTALL_PARSE_FAILED_MANIFEST_MALFORMEDandroid

出现这种异常,通常就是AndroidManifest.xml存在格式问题了,检查一下包名、类名等格式是否正确。session

    我在实践过程当中出现过以下状况:app

Failed to commit install session 830464444 with command cmd package install-commit 830464444. Error: INSTALL_PARSE_FAILED_MANIFEST_MALFORMED: Failed parse during installPackageLI: /data/app/vmdl830464444.tmp/base.apk (at Binary XML file line #50): Invalid process name statCore in package com.tamic.statsdkdemo: must have at least one '.' separatorspa

事实上我本身的AndroidManifest.xml是没有问题的,可是依赖的aar库之中的AndroidManifest.xml存在问题,致使merge以后的AndroidManifest.xml存在格式问题。xml

至于aar中的AndroidManifest.xml怎么会出现格式问题,这个未知。可是aar是能够修改AndroidManifest.xml文件的,这里将blog

android:process="statCore"cmd

加上'.'改成it

android:process=".statCore"io

再保存到aar就OK了。ast