Google maps api key jar signing on G1...fail

by Clay » Fri, 02 Jan 2009 13:33:54 GMT


Sponsored Links
 ello Everyone,

I am here with my hat in hand begging for a clue. So have tried to
follow the directions for release keys and jar signing to the letter,
and I am still in fail mode. Here are my references:

http://code.google.com/android/toolbox/apis/mapkey.html

http://code.google.com/android/devel/sign-publish.html

http://code.google.com/android/maps-api-signup.html


Here is the cookbook:

1. ant release.

Buildfile: C:\home\cgraham\projects\noi-momentarynow-android\build.xml
dirs:
[echo] Creating output directories if needed...
[mkdir] Created dir: C:\home\cgraham\projects\noi-momentarynow-
android\bin\classes
resource-src:
[echo] Generating R.java / Manifest.java from the resources...
aidl:
[echo] Compiling aidl files into Java classes...
compile:
[javac] Compiling 143 source files to C:\home\cgraham\projects\noi-
momentarynow-android\bin\classes
[javac] Note: Some input files use unchecked or unsafe operations.
[javac] Note: Recompile with -Xlint:unchecked for details.
dex:
[echo] Converting compiled files and external libraries into bin/
classes.dex...
package-res:
package-res-no-assets:
[echo] Packaging resources...
release:
[echo] Packaging bin/noi-momentarynow-android-unsigned.apk for
release...
[echo] It will need to be signed with jarsigner before being
published.
BUILD SUCCESSFUL
Total time: 7 seconds

2. sign the unsigned jar.

2a. create the key

c:\home\cgraham\projects\noi-momentarynow-android\bin>keytool -genkey -
v -keystore momentarynow-android-release-key.keystore -alias
mn_android -keyalg RSA -validity 10000

2b. update the key for the release key supplied by google

c:\home\cgraham\projects\noi-momentarynow-android\bin>keytool -list -
keystore momentarynow-android-release-key.keystore
Enter keystore password:

<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout android:layout_width="wrap_content"
android:layout_height="wrap_content"
xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/map_layout">
<RelativeLayout android:id="@+id/map_display_layout"
android:layout_width="wrap_content" android:layout_height="92px"
android:visibility="gone">
</RelativeLayout>
<RelativeLayout android:id="@+id/map_layout"
android:layout_below="@+id/map_display_layout"
android:layout_height="fill_parent"
android:layout_width="fill_parent">
<!-- release -->
<com.google.android.maps.MapView
android:layout_below="@id/map_display_layout"
android:id="@+id/maplocator_activity"
android:enabled="true"
android:clickable="true"

android:apiKey="SUPPLIEDBYGOOGLE-basedonMD5-from-momentarynow-
android-release-key.keystore"
android:layout_height="fill_parent"
android:layout_width="fill_parent"/>

</RelativeLayout>
</RelativeLayout>

c:\home\cgraham\projects\noi-momentarynow-android\bin>copy noi-
momentarynow-android-unsigned.apk noi-mo



Google maps api key jar signing on G1...fail

by Clay » Sat, 03 Jan 2009 01:11:57 GMT


 ne more thing... I did install a version of the APK on the phone with
a different key, but I fully uninstalled before installing this
version. could there be a G1 keystore issue?

Clay

On Jan 1, 9:33pm, Clay <claytan...@gmail.com> wrote:
--~--~---------~--~----~------------~-------~--~----~


Sponsored Links


Google maps api key jar signing on G1...fail

by Clay » Sat, 03 Jan 2009 02:52:09 GMT


 o for some unknown reason this resolved itself, I did a clean sweep
and uninstall, regened the keys and followed the above cookbook
identically, and it now works

at least I created an ok tutorial.

Clay


On Jan 2, 9:11am, Clay <claytan...@gmail.com> wrote:
--~--~---------~--~----~------------~-------~--~----~



Other Threads

1. Insert and delete SIM contacs working but it needs to be phone restart to update the changes

Hi All,

I am able to insert the contacts into SIM card and delete from it. But
it needs to be phone restart to update the changes.

The below is the code woks for delete the conatcs,

Uri simUri = Uri.parse("content://icc/adn");
                        Cursor cur = context.getContentResolver().query(simUri, 
null,
null, null, null);
                        prn("Number of SIM Contacts are.."+cur.getCount());
                        int row =0;
                        while(cur.moveToNext()){
                                String name = 
cur.getString(cur.getColumnIndex("name"));
                                prn("Name..."+name);
                                String data = 
cur.getString(cur.getColumnIndex("number"));
                                if(!data.equals(""))
                                        prn("Number.."+data);
                                String where = null;
                                if(!name.equals("") && !data.equals("")){
                                        where = "tag =" + name + "AND" + 
"number =" +data;
                                }
                                else if(name.equals("") && !data.equals("")){
                                        where = "number ="+data;
                                }
                                else {
                                        where = "tag ="+name+ "AND" 
+"number="+null;
                                }

                                context.getContentResolver().delete(simUri, 
where, null);
                                row++;
                        }
                        prn(row+" are deleted");
                        cur.close();
                        cur = null;

Please look into this issue and give suggestions on this.

Thanks,
Girish G M

-- 

2. Behavior of "Just In" in Market

Hi,

When I publish update to my app, sometimes, the app does not feature
in the "Just In". But sometimes it does too. Have anyone faced this
issue?

What might be going wrong?

Thanks in advance for your answer.

-- 

3. Displays on emulator, not on phone

4. logcat of video capture using MediaRecorder

5. Programmatically start / launch VPN connection

6. GLSurfaceView on app widget?

7. problem in large screen resolution