Oppo Releases ColorOS for the Find 5… Poorly

Almost every OEM has taken the liberty of creating its own incarnation of the Android OS. … more

XDA LG Development Challenge Winners

Almost 3months ago, we set out with LGto findtwo amazing apps that developers could put together … more

Wearable Apps w/ Andreas Göransson – XDA:DevCon 2014

XDA:DevCon 2014 in Manchester, UK featured quite a few interesting topics as … more

Browse Your Files with Ease using MK Explorer

Google has made quite an effort in perfecting the powerful and multi-faceted OS that we know as … more

Welcome to XDA

Search to go directly to your device's forum

Register an account

Unlock full posting privileges

Ask a question

No registration required
Post Reply

[How-To](UPDATED 11/1/10)Working Marketplace in 2.2 Emulator (no system.img)(ROOTED)

OP dbzfanatic

28th October 2010, 10:17 AM   |  #1  
dbzfanatic's Avatar
OP Senior Member
Thanks Meter: 282
 
1,063 posts
Join Date:Joined: Jun 2010
Donate to Me
More
This all started out as an experiment to get my nandroid system.img file running in the adb emulator. Well sadly I haven't been able to do that (yet) but I have found something useful. I've Seen several people all over asking how to get a working marketplace app in 2.2 on the adb emulator. After a lot of researching (and trial and error) I've managed to get one. Here are the steps I've taken. (Steps 5 and 6 optional, you can just use the included build.prop if you prefer)

1) Create an avd running 2.2 (froyo,plenty of places explain how to do this so I won't)
2) Download the file (attached below, root files included)
3) Unzip to a location that's easy to remember and find.
4) Load your emulated phone (allow it to load fully)
5) enter this command in a command prompt/terminal window (make sure you "cd" to the directory where you extracted the files)
Code:
adb pull /system/build.prop
6) Remove or comment "ro.config.nocheckin=yes" (no quotes, might be able to just change it to "no" but I haven't tried it that way)
7) enter these commands

Winblows (I mean windows)
Code:
adb remount
adb push build.prop /system/build.prop
adb install GoogleServicesFramework.apk
adb install Vending.apk
adb install Gmail.apk (optional but sometimes signing in here lets the market sign in)
adb shell rm /system/app/SdkSetup.apk
Linux
Code:
adb remount
adb push ./build.prop /system/build.prop
adb install ./GoogleServicesFramework.apk
adb install ./Vending.apk
adb install ./Gmail.apk
adb shell rm /system/app/SdkSetup.apk
8) Sign in. If it works you're done if not reboot and try again, sometimes it takes 3 or 4 reboots to set. If your emulated phone has a data signal from your computer (you'll see a 3G and network icon in the notification area) just wait for it to sign in. The cancel button should grey out within a minute. If it says it can't connect restart the emulator and try again, be patient.

There is a known bug that not all apps show up in the marketplace. I'm not sure why so if someone here knows how to fix that by all means leave a post and let me know. If I see it I'll add it to the first post (provided it works of course :P)

Edit: Working on getting root on the emulator (just for the hell of it:P). So far I have su in the xbin directory and superuser.apk installed. Not 100% sure what else I need to do to get the su requests to go through though, I'll probably PM a more experienced member and post back when I have more. Got root? I do:P (got it working.) Here are the steps you need to take.

Rooting the standard android image on the emulator
1) Open a command prompt (cd to the directoy where you extracted the files)
2) enter these commands
Code:
adb shell mount -o rw,remount -t yaffs2 /dev/block/mtdblock03 /system
adb push su /system/xbin/su
adb shell chmod 06755 /system
adb shell chmod 06755 /system/xbin/su
adb install superuser.apk
That's it! You now have a rooted, market-enabled android emulator.

New! N00b-friendly method
1) create your avd
2) download the emulator files archive attached to this post
3) extract somewhere easy to find
4) open command prompt/terminal and cd to the extracted location
5) start your avd
6) Run your script (windows.bat or linux.sh)
7) sign into market and enjoy root!

Note:
You may have to chmod su again upon restarting the emulator.
To get root back simply run the re-root script for your OS (bat for windows,sh for linux)
To install busybox simply run the re-root script, it will automatically install if you're using the script to install on a new avd.
Attached Files
File Type: rar Emulator Files.rar - [Click for QR Code] (3.43 MB, 6301 views)
Last edited by dbzfanatic; 1st November 2010 at 12:31 PM. Reason: updated Emulator files.rar,added information
The Following User Says Thank You to dbzfanatic For This Useful Post: [ View ]
28th October 2010, 01:49 PM   |  #2  
dbzfanatic's Avatar
OP Senior Member
Thanks Meter: 282
 
1,063 posts
Join Date:Joined: Jun 2010
Donate to Me
More
Post 2

[reserved for updates, explanations, pictures, present/future tweaks in progress, etc]

Pictures:
Superuser list,Marketplace (I like solitaire><), Terminal with su permissions, and re-rooted Terminal


Tweaks:
1: root (done!)
2: busybox (done!)
Last edited by dbzfanatic; 1st November 2010 at 12:32 PM. Reason: added picture and info
31st October 2010, 05:29 PM   |  #3  
Member
Thanks Meter: 0
 
38 posts
Join Date:Joined: Jan 2008
Wow nice....
31st October 2010, 05:36 PM   |  #4  
dbzfanatic's Avatar
OP Senior Member
Thanks Meter: 282
 
1,063 posts
Join Date:Joined: Jun 2010
Donate to Me
More
Thank you the root resets after reboot, working on making it stick but its not hard to do it again, just start with the "-wipe-data" command and redo the root, market works after reboot though. Still working on getting a dumped system.img to boot, ill post that in its own thread when i get it. Glad you like this.

Sent from my ROOTED T-Mobile myTouch 3G Slide using XDA App

Edit: see first post on how to get root back,no data-wipe!
Last edited by dbzfanatic; 1st November 2010 at 10:46 AM. Reason: updated info
31st October 2010, 10:48 PM   |  #5  
bcbaluga's Avatar
Junior Member
Flag Funchal
Thanks Meter: 8
 
17 posts
Join Date:Joined: Oct 2010
so cool!! Good job man!
1st November 2010, 07:13 AM   |  #6  
dbzfanatic's Avatar
OP Senior Member
Thanks Meter: 282
 
1,063 posts
Join Date:Joined: Jun 2010
Donate to Me
More
Thanks ^_^ let me know if you find any problems that I haven't already mentioned and I'll see if I can fix them or if they're just an emulator quirk.
1st November 2010, 12:34 PM   |  #7  
dbzfanatic's Avatar
OP Senior Member
Thanks Meter: 282
 
1,063 posts
Join Date:Joined: Jun 2010
Donate to Me
More
Sorry for the double post but I wanted to let you all know busybox is now included! Installation can be performed through scripts (included in the "Emulator Files.rar" archive) or manually. If you wish to do it manually simply open the script in a text editor to see what's going on and enter the commands in a command prompt/terminal window.
2nd November 2010, 11:02 AM   |  #8  
Junior Member
Thanks Meter: 0
 
8 posts
Join Date:Joined: Apr 2010
I'm not able to make this work, not with a toolkit downloaded yesterday anyway.

Pulling of build.prop works, but pushing fails with a directory related error.
"adb shell" followed by "cd /system" and "ls -l" gives a list of files that does not include build.prop, neither as a file nor as a directory.
"ls -l build.prop" works though, and lists a file with 0644 permissions.

Install of all apks different from Gmail fails, with an error that says that those apks are already installed. Uninstalling them through adb doesn't work, netting instead a simple generic error.

Does anyone know whether I'm doing something wrong or Google has modified the emulator images so to render the Market workaround unusable? If so, where could I download an earlier version of the 2.2 system image?

Many thanks
Rocco
2nd November 2010, 12:49 PM   |  #9  
dbzfanatic's Avatar
OP Senior Member
Thanks Meter: 282
 
1,063 posts
Join Date:Joined: Jun 2010
Donate to Me
More
I actually had this issue as well. Try re-making the avd, worked for me. You could also try running the scripts to install, might work. If it doesnt post back and ill post the system.img from my sdk.

Sent from my ROOTED T-Mobile myTouch 3G Slide using XDA App
2nd November 2010, 02:14 PM   |  #10  
Senior Member
Thanks Meter: 28
 
380 posts
Join Date:Joined: Apr 2010
I have the same problem as ropi. Remade the avd several times with different properties, still no go.

I would really appreciate it if someone could upload a fully set-up avd somewhere.

Post Reply Subscribe to Thread

Tags
2.2, adb, emulator, marketplace, root
Previous Thread Next Thread
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes