如何在不卸载的情况下处理INSTALL_PARSE_FAILED_INCONSISTENT_CERTIFICATES? [英] How to deal with INSTALL_PARSE_FAILED_INCONSISTENT_CERTIFICATES without uninstall?
问题描述
我试图重新安装apk
I tried to reinstall an apk
$adb install -r new.apk
它显示了错误:
Failure [INSTALL_PARSE_FAILED_INCONSISTENT_CERTIFICATES]
一种解决方案是卸载并安装new.apk,效果很好.
One solution is to uninstall and install the new.apk, that works fine.
但是我想知道是否可以在不卸载的情况下重新构建apk并重新安装.例如.更改AndroidManifest.xml中的某些配置,或不对APK进行签名等.
But I'm wondering whether I could re-build an apk and re-install without the uninstallation. Eg. change some config in the AndroidManifest.xml, or not sign the APK, etc.
如果您能告诉我"INSTALL_PARSE_FAILED_INCONSISTENT_CERTIFICATES"的全部含义,将不胜感激.
It would be great appreciated if you could tell me the whole meaning of the "INSTALL_PARSE_FAILED_INCONSISTENT_CERTIFICATES".
推荐答案
这表示您的应用程序的新副本(在您的开发计算机上)是用与您的应用程序的旧副本(安装在设备上)不同的签名密钥签名的/仿真器).例如,如果这是一台设备,则可能是从其他开发机器(例如,其他开发者的机器)上放置了旧副本.或者,旧的使用您的生产密钥签名,而新的使用您的调试密钥签名.
It means the new copy of your application (on your development machine) was signed with a different signing key than the old copy of your application (installed on the device/emulator). For example, if this is a device, you might have put the old copy on from a different development machine (e.g., some other developer's machine). Or, the old one is signed with your production key and the new one is signed with your debug key.
这篇关于如何在不卸载的情况下处理INSTALL_PARSE_FAILED_INCONSISTENT_CERTIFICATES?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!