Reputation: 11097
I have two questions
1.) I want to know why do we need different-2 map api keys for different-2 machine. Can't we use same key for any machine.
2.) When I need different-2 map api keys for different-2 machines so how & why Maps works fine on mobile devices when I install an apk file for my app which is created from any machine.
Hope you got my problem
Thanks in advance
Upvotes: 2
Views: 1009
Reputation: 82535
You can create a new debug.keystore and share that between machines.
To use it in Eclipse, go to Preferences -> Android -> Build and set the Custom debug keystore appropriately.
You will have to create a separate keystore for the release key. And then you have to figure out how you want to ensure that the right API key is used at runtime. (There are several ways to handle this, but no good way as far as I can tell.)
Upvotes: 0
Reputation: 10938
Different machines have different debug certificates that are used to sign the build when running/debugging - they're stored in c:\users\your_user.android\debug.keystore
A Map api key that is linked to such a debug certificate won't work if you use a different certificate. You can share your certificate so you use the same one, or generate another map api key based on your debug.keystore.
When you release to the market place, you generate a new .keystore that you sign your release builds with - that has to be registered for its own map api key as well.
Upvotes: 3