[myTouch 3G, Magic Android Development] iamerror:
iWnnIME working as a standalone

This method is now obsolete, grab the update.zip made by jashsu on page 3.

After some digging around, I was able to get iWnnIME working on my G1. Wasn't sure where to post it, but figured since I got it from jmaurice's dump, this would be the best place. I would think the steps would be identical on a Sapphire, but I don't have one so there's no way for me to tell. Report back if it works! I'll do my best to help troubleshoot but I'm not an expert by any stretch so just keep that in mind. This is pretty much one of those "Here's how I did it, it works for me, and if it doesn't for you, then, well.. I dunno."

Just copypasting with some minor edits from my blog:

Things you will need:

1. The ROM dump, graciously uploaded by jmaurice

2. A computer running some flavor of *nix (OSX + xcode kit works too, it's what I used)

3. unyaffs

4. The android dev environment, namely adb. Although this probably isn't *required*; you could potentially do everything after unyaffs-ing by copying the requisite files to the sd card and copying via the terminal emulator.

Some notes before getting started:

-A problem you may run into is lack of space on the /system partition. I'm currently using one of the Rogers Dream ROMs and I had to delete the HTC_CIME.apk to free up enough space to copy all the files over (there are quite a few). Depending on which version of Android you are running, this may not be a problem at all, or it may be a major obstacle; YMMV. Deleting HTC_CIME is as easy as rm -r HTC_CIME.apk from the shell and rebooting. No ill side effects other than not being able to use that particular IME, but I don't have a need for Chinese input so it was a non-issue.

-Didn't need to fix any permissions, just copied and it worked

-I'm writing this mostly from memory and it's a bunch of pseudocode, definitely not a "step-by-step" guide. If you don't know what you are doing then you should probably stop now.

-If you mess up your phone I am not responsible, proceed at your own risk. You know the drill.

Now the walkthrough:

1. Get all of the above things, and compile unyaffs for your box with gcc and all that jazz

2. unyaffs data.img and system.img

3. There are only 2 things we need from data.img. First is the jp.co.omronsoft.iwnnime folder in /data/data, copy it to the same location on your phone (make sure to preserve the subfolder structure). There is also a system@app@iWnnIME.apk@classes.dex in the dalvik-cache folder, copy that over too.

4. Now for the fun part with the multitude of files needed from system.img. I'm a total nub when it comes to this stuff, so not all of these may be required. All I know is that they are all referenced by entries in some of the lib files so for completeness I copied them all over. It may be possible to omit some to save space but it's beyond my ability to tell. First, the files in the /system/lib folder:

libiwnn.so

lib_dic.conf.so

lib_dic_e.conf.so

libEnjcon.so

libEnjemailuri.so

libEnjlearn.so

libEnjlearnL.so

libEnjlearnM.so

libEnjrel.so

libEnjyomi.so

libkaomoji_kihon.so

libkaomoji_tyukyu.so

libnjaddress.so

libnjcon.so

libnjemoji.so

libnjexyomi.so

libnjexyomi_new.so

libnjexyomi_re.so

libnjfzk.so

libnjname.so

libnjtan.so

libnjubase1.so

libnjubase2.so

Copy these to /system/lib

5. Now take DroidSansJapanese.ttf from /system/fonts and copy that over to the same folder on your phone.

6. And finally, copy over iWnnIME.apk to your sd card and run it to install it.

7. Go to your locale settings and you should have a nice new iWnnIME to use.

The only limitation I have experienced with the IME is that it doesn't seem to play too well in landscape mode. It works, but sometimes it gets a little confused. This appears to be limitation of the software though, and not a result of using it on the Dream platform. Even romaji input works a charm using the hardware keyboard on the G1, although it suffers from some of the same issues described above.

Credit goes out to jmaurice for providing the ROM dump, and to the great community at xda for the wealth of info that allowed even a nub like me to be able to pull something like this off.

Feel free to skip over this rant unless you are planning on selling this

/rant on

And last but not least, it has come to my attention that there are certain companies out there that have been and will continue to make commercial profits off of the hard work done by the fine folks here on xda, particularly in the realm of selling mobiles in the United States that have been reflashed with Japanese firmwares or other localized apps. What I've done isn't anything amazing compared to what people like Haykuro have done, but I can say with confidence that there are a few companies out there that I can think of off the top of my head that will certainly jump on this and start pawning it off to less savvy customers as their own work. It might not be much, but as a contributor I'm proud of my work, and all I can say is that hacking these ROMs as a hobbyist is one thing, but when I see this method commercialized there will be some people at Omron that won't be too happy.

/rant off