Reputation: 3574
When I install my application on device using Eclipse, my app works as expected. Then in Eclipse I export signed app using platform tools. However, when I install this signed apk file using adb in shell or by opening link to apk in internet it does not work as expected. It launches and runs, but some functionality does not work. The app just crushes.
What am I missing?
Upvotes: 1
Views: 121
Reputation: 45493
A signed build usually goes through a Proguard step. In your app's project.properties
file, there's probably an entry that looks like:
proguard.config=proguard.cfg
or
proguard.config=proguard-project.txt
The file after the equals sign contains the Proguard configuration, which, amongst other things, defines rules for what parts of your Java code may be optimized, obfuscated and stripped. You can customize the configuration to make it keep certain elements for which Proguard couldn't automatically determine the correct dependencies. Quite commonly this involves code that is dynamically loaded at runtime, e.g. through reflection. Alternatively, you could disable the Proguard step by putting a dash (#
) in front of the relevant line above.
Upvotes: 2