User-agent: Mediapartners-Google Disallow: User-agent: * Disallow: /search Allow: / Sitemap: http://nano7mobile.blogspot.com/sitemap.xml Nano Mobile: [Q] Signing as a system app - failed to install - CyanogenMod topic

[Q] Signing as a system app - failed to install - CyanogenMod topic






Hi!

I'm preparing a plugin for a vendor of ROM (a small phone manufacturer) and I need this plugin to have system permission. I've tested this on a rooted Cyanogenmod install by putting the app into /system/priv-app directory and it works.

Taking this a step further, I signed the application with Cyanogenmod platform keys from the source repository (platform.pk8 and platform.x509.pem). I've successfully verified that the key used to sign release build is indeed the one from platform.x509.pem.

When I try to install this application via "adb install" I get the following error: Failure [INSTALL_FAILED_INVALID_INSTALL_LOCATION]

Investigating further, it seems that installation of applications signed with platform key is not allowed (anymore): http://stackoverflow.com/questions/1...-to-user-space
Looking in the source of PackageManagerService.java in the current Android source[1], I don't see this restriction, but I doo see it in CyanogenMod source tree[2] with this commit[3].

The question is: is this the correct approach for non-CM ROMs? What is the preferred way to work around this for CM (apart from building a custom ROM and removing this piece of code, that is)?

Regards,
Miha.

[1]: http://grepcode.com/file/repository....rService.java/
[2]: https://github.com/CyanogenMod/andro...ice.java#L4592
[3]: https://github.com/CyanogenMod/andro...729e69f34297f6






Aucun commentaire:

Enregistrer un commentaire