I have two flavors of my app, one debug and one release. The reason why these are different flavors is that I want to allow others to download the debug version to test out new features. So it should be possible to have both apps installed at once.
My app uses GCM which has created some problems with the new security features in Android Lollipop.
This is what I get when I have one flavor install, and try to install the other flavor:
Failure [INSTALL_FAILED_DUPLICATE_PERMISSION perm=com.example.test.permission.C2D_MESSAGE pkg=com.example.test]
I have tried to change the permission in the debug flavor by adding this to its Android Manifest:
<permission
android:name="com.example.test.debug.permission.C2D_MESSAGE"
android:protectionLevel="signature" />
<uses-permission android:name="com.example.test.debug.permission.C2D_MESSAGE" />
But I still get the same error. Anyone know how to solve this?
In the link provided by Sunil Mishra it is said that it will work when they are signed by the same key. In my case they were not since one was signed with the release key and the other with the debug key. When releasing my apps for testing they will be signed by the same key.
Thanks Sunil!
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With