[HACK] (!update 04/26/2010) JIT enabled Dalvik VM on Android 1.6 (Dusted Donuts) - G1 Android Development

Update (fix for /cache/dalvik-cache 04-26-2010): Really only use this if your having issues using the symbolic link fixes posted by other members or are just out of free space on /cache. First the new issues people are experiencing is in cm-based-kernels from 4.2.15.x and not JIT enabled DalvikVM and people using danger/death spl will experience problems faster. Lack of space on /cache is a problem and will cause market downloads to fail as well as email attachments. The other problem is the kernel fails for various and unknown reasons to mount bind /cache/dalvik-cache to /data/dalvik-cache.
The other issue is the use to dalvik-cache clearing scripts and options in RA recovery, stop clearing your dalvik-cache, the .dex files are created when missing and you do not get any benefits by doing so and cause more wearing leveling of NAND, plus the script in RA recovery doesn't appear to look at /cache/dalvik-cache for dex files. This little update script (when installed correctly).
Understand that /cache/dalvik-cache is a newer option as a means to free up space on /data is by using /cache/dalvik-cache as a first storage of dex files then using the standard /data/dalvik-cache for over flow of dex files and newer installed apps. Somewhere along the way something may throw this and you get douplicate dex files in both locations, one way to check is to boot into recovery and
Code:
mount -a
and check dalvik-cache directories in both /cache and /data for douplicate dex files.
The script will fix these issues, or should at least:
Endless loop FCs on boot
broken /cache/dalvik-cache mount
no binded mount
missing user apps
missing system apps
failed market downloads
non-working symlink patches and installers (no need to run these, they will break this patch)
fixes duplicate dex files in both /cache/dalvik-cache and <target>/dalvik-cache (because it deletes /cache/dalvik-cache)
Will not Fix:
your ignorance
your unwillingness to read
your unwillingness to learn
your compulsive ROM flashing disorder
your compulsive dalvik-cache clearing syndrome
version 1.1.1(updated 4/27/2010 @ 10:10 PM) is current and was slapped together from Phonekenstein, it doesn't look for the existance of /cache/dalvik-cache it assumes it's there and deletes it wether it's a directory, a symlink or a file, re-creates a new empty /cache/dalvik-cache with Android default permissions and mount binds it to /data/dalvik-cache (be it a directory, a symlink or another binded mount) /cache/dalvik-cache will follow the target /data/dalvik-cache (no worries for apps2sd users or non-apps2sd users).
Script will turn on the blue LED when booting so you know it executed (if it annoys you then edit the script and make it pink)
Tested on Cyanogen MOD 4.2.15.1 and SuperD 1.10.3:
with and without apps2sd
with and without a /dev/block/mmcblk0p2 (apps2sd script nulled)
with and without a custom /dev/block/mmcblk0p4
with mount binded /ext/dalvik-cache (mmcblk0p4) to /data/dalvik-cache
with /data/dalvik-cache as a symbolic link to /ext/dalvik-cache (mmcblk0p4)
All scenarios experienced no failures as long as you set your permissions correctly on all targets and files and /cache/dalvik-cache followed and binded flawlessly.
install is simple and can be done through terminal:
1. download 86dalvik-cache-fix <--Long press and chose "save link as" (also attached to this post)
2. open terminal and issue these commands:
NOTE: COMMANDS ARE CASE sensitive in LINUX and as such ANDROID!!!!!!
ALL OFF THESE COMMANDS ARE IN lower case. SO Turn off your Auto-Caps options in your keyboard options. These command assume you downloaded the script using your the web browser on your G1/Magic whatever phone and the file is located in /sdcard/download (the default location for web browser downloads).
Code:
su
mount -o rw,remount /system
cp /sdcard/download/86dalvik-cache-fix.txt /system/etc/init.d/86dalvik-cache-fix
chown 0:2000 /system/etc/init.d/86dalvik-cache-fix
chmod 755 /system/etc/init.d/86dalvik-cache-fix
sync
reboot
Why 86dalvik-cache-fix? We want the script to execute after all scripts in /system/etc/init.d/ including /system/sd/userinit.sh (if you are using one) and before script 99. 86 because in 1987 everything got 86'd.
If you are having a problem getting the script to execute, copy it or merge it into /system/sd/userinit.sh (even if you aren't using a mmcblk0p2(ext partition)) it may make it work with FastTest builds, however the permissions on his builds appear to be root everything and I have problems getting the script to execute out of /system/etc/init.d even with root permissions.
--------------------------------------------------------------------------------------------------------------
Primer: Read this about Dalvik VM http://en.wikipedia.org/wiki/Dalvik_virtual_machine
Read this to: Google Groups post about JIT compiler for Dalvik VM from Android-Platform Link
From the post we see that this particular compiled library is ALPHA, so results can vary, but from reading most posts in this thread the results are right near the talked about 3x faster code, stability is going to vary on what apps and or widgets are running. More Widgets = slower performance as these have processes that are eating cycles. When testing with Linpack wait for the advertisement to load first then tap the benchmark button and remove your finger from the touch screen. Background process such that interrupt or having auto-rotate enabled while testing is going to give you slower benchmarks.
In short your apps should load faster and run faster, particularly 3D games. The web browser is faster and you can actually scroll through pages even while graphics are still loading.
The reboot when enabling it is long even appearing to hang at the G1 Screen for 5 minutes or more but once it starts booting past this you will know that your ROM is compatible. The cause is that the dex files are being optimized, after about a third reboot, your ROM should feel pretty snappy and launching apps should be quicker as well as switching apps. The snappiness lasts as well and as some may have said that it's a placebo effect are wrong. Bench mark readings prove it and more importantly a few ROM builders have included this in their 2.1 ROMs as experimental.
The libdvm.so that t3steve cross compiled for the DROID at the time was for Android 2.0, the library works for with newer ROMs Android 1.6 that have some eclair pieces built into the kernel, CyanogenMOD has been using bits and pieces for a while now, if other ROM builders have been using his kernel and framework than a good chance it will work for your phone as well.
I have nothing to do with the compiling of this or the exact functions of enabling JIT except that I had a hunch that the combo might work and it did, so I'm sharing it.
If you aren't good at typing in commands, or don't know how to extract a zip file and understand that a sub folder may or may not exist where you have extracted said zip file to, well.... you may run into some issues, maybe a video tutorial for basic command line on youtube would be a good place to learn.
I wanted to make a very detailed post on www.andoidonroids.com about how to mash the JIT enabled Dalvik VM library into Android 1.6 Donuts I'm calling the hack "Dusted Donuts" and take from the name for what you will. I have been using the JIT enabled Dalvik VM for about two weeks and i runs decent but not perfect. Anyhow a death in the family Sunday has kept me from making a decent post and haven't had the time to get to the website and post and cross post and give credit where due.
No doubt that aaraya1516 broke the news on http://forum.xda-developers.com/showpost.php?p=5703076&postcount=193 as he was first to break the hack on FastTest, not taking anything away from him on that.
My testing goes back two weeks or more even during the 580mhz & 780mhz hack, I was waiting for someone to compile a boot.img with some 2.x stuff and sure enough the carlospants boot.img from ctso worked with enabling JIT for Dalvik VM, but as we know now the overclocking doesn't work at the moment.
Thank Cyanogen and t3hSteve of which may not know that this was entirely possible. Cyanogen mixed in enough Eclair into his Donuts (he's like Willy Wonka) that makes it possible to use the cross compiled JIT enabled Dalvik VM library from 2.1 for the Motorola DROID 2.0.1 libdvm.so that t3hSteve of www.alldroid.com compiled for the custom roms on Droid.
WARNING: Using other methods supplied from other forum members that include replacing the build.prop may cause problems, using the build.prop from the original VMLIBS.ZIP (which is here for reference and original source for libdvm.so) is definitely going to cause ROM and application problems. Hello....use your head here... the VMLIBS.ZIP is for Motorola DROIDS, why would you put the build.prop file for a DROID on your G1 and expect your apps or ROM to work afterwards? It's so simple, you need 1 file, it's called libdvm.so it goes in /system/lib a file by the same name already exists there and it's in your best interest to at least back it up before overwriting it and gives you the ability in the event that your system doesn't boot up you can restore it through recovery console and get your phone to boot past the G1 screen.
FYI: Some ROMs have the option dalvik.vm.execution-mode=int:fast in the /system/build.prop file, this would need to be changed to dalvik.vm.execution-mode=int:jit or commented out or deleted. If you want to play with advanced options create /data/local.prop and fiddle in there with options available from typing dalvikvm -h in your console or terminal app.
Required:
1. Android 1.6 ROMS with a bit Eclair stuff in the Kernel and framework such as Cyanogen ROM 4.2.x, Super D 1.8 - 1.92, WG Y2.6, FastTest, KingKlick Eclair and more.. This libdvm.so works on Android 2.1 as well as it seems it should.. 1 st bootup is slow and I recommend you let it sit even when desktops are up for a couple of minutes and then reboot it, 2nd and 3rd bootups are faster and smoother response overall even for long durations, days.
FIX YOUR FILE SYSTEM FIRST !!!!!! Got to do it from Recovery Console, It's partly the cause of poorly running ROMS and takes seriously longer to type the command than to fix your unknowingly faulty file system. EXT2 is the worst offender and the built in function to repair falls short, even more so when checking EXT4.
Code:
#e2fsck -fcpDC0 /dev/block/mmcblk0p2
#reboot recovery
For the lazy fingers
#e2fsck -fcpDC0 /*/*/*0p2
#reboot recovery
1. Download www.androidonroids.com/dusted-donuts (File has 3 scripts backup, install, restore, 2 folders, 1 libdvm.so)
2. Extract zip to root of /sdcard or where ever you like (the zip has a folder containing the files named dusted-donuts)
3. Open Terminal or go to Recovery Console
FYI when running the install through Terminal your system may freeze or reboot and if it does I highly recommend that you prepare to enter Recovery Mode and check your file system. EXT2 corrupts quickly choosing this for apps2sd to use is not the best option especially if you are using custom ROMs that may lockup or reboot, basically that's a crash.
Code:
$su
#mount -o rw,remount auto /sdcard
#cd /sdcard/dusted-donuts
#sh backup
#sh install
#sync
#reboot
Check the Dalvik VM execution mode. look at the bottom line with_jit means the it is installed , and look at all of those options that can be jammed into your build.prop and local.prop files
Code:
$su
#dalvikvm -h
Phone won't boot past G1 screen? Go to recovery console and restore libdvm.so (give it at least 5 minutes first before giving up)
Code:
#mount -o rw,remount auto /sdcard
#cd /sdcard/dusted-donuts
#sh restore
#sync
#reboot
---------------------------------------------------------------------------------------------------------------------
prefer to use VMLIBS.ZIP from t3hSteve? This is how you can install using that.
Required:
1. Android 1.6 ROMS with a bit Eclair stuff in the Kernel and framework such as Cyanogen ROM 4.2.x, Super D 1.8 - 19.2, WG Y2.6, FastTest, KingKlick Eclair and more.. This libdvm.so works on Android 2.1 as well as it seems it should..
How to install: (easier to go in recovery mode but can be done through terminal)
1. Download the VMLIBS.ZIP from t3hSteve of allroid.com http://alldroid.org/download/file.php?id=1374
2. You only need the libdvm.so file of which appears to be JIT enabled by default.
3. Backup the original libdvm.so #cp /system/lib/libdvm.so /sdcard/libdvm.so
4. Copy the JIT enabled libdvm.so #cp -f /sdcard/vmlibs/libdvm.so /system/lib/libdvm.so
5. Set permissions on the file #chmod 644 /system/lib/libdvm.so
Optional for disabling: (easier to do vi through recovery console, since the back key escapes out of terminal)
To disable JIT MODE but want to keep the libdvm.so create a local.prop in /data and add dalvik.vm.execution-mode=int:fast
#vi /data/local.prop
press the i key to enter vi interactive mode
type dalvik.vm.execution-mode=int:fast
press back key to exit vi interactive mode
to write the file out and quit vi type :wq
or
restore your backed libdvm.so file from the sdcard.
-----------------------------------------------------------------------------------------------------------------------
Enjoi! the dusted donuts,
-Licknuts (me? I'm like Varuca Salt, I want another pony)
Vendor G1 roms around 1.2 Mflops, Custom G1 roms are around 2.4 MFlops/s and with JIT compiled Dalvik VM 3.6 MFlops/s. At most you will see 3.5 MFlops/s fairly consistently with a minimal load on your system and highs at 3.7 Mflops/s. Test before and after using Linpack from the Market, it's free.
The 13.236 Mflops/s is not normal and you will probably not see with your testing, I have seen 5.x & 7.x but these are far and few between and this took a while with tweaked configurations/settings with a persistent app to kill processes, it is attainable and I hope a ROM developer finds the sweet spot to exploit.

Looks nice.
Pre-JIT enabled: 2.194 Mflops/s
Post-enabled: 3.459 Mflops/s
Not quite getting the results you have there.
Running SuperD 1.9.2 Black W/ Nexus Theme. I copied it twice to make sure that the libdvm.so was copied correctly to the directory. Rebooted the phone, same results. Looks very promising though. If I did something wrong, lemme know.
Managed to get #10 on G1 Benchmarks with 3.583 Mflops/s... still nowhere near 13.~ Mflops/s

same here. Running Super D 1.9 on my magic
before JIT I got 1.xxxx Mflops/s
after i have 2.xxxx Mflops/s
how do you get the 13 Mflops/s ?
-edit-
with swap disabled i'm getting 3.5 Mflops/s

h.nocturna said:
Looks nice.
Pre-JIT enabled: 2.194 Mflops/s
Post-enabled: 3.459 Mflops/s
Not quite getting the results you have there.
Running SuperD 1.9.2 Black W/ Nexus Theme. I copied it twice to make sure that the libdvm.so was copied correctly to the directory. Rebooted the phone, same results. Looks very promising though. If I did something wrong, lemme know.
Managed to get #10 on G1 Benchmarks with 3.583 Mflops/s... still nowhere near 13.~ Mflops/s
Click to expand...
Click to collapse
I got 9 seconds on the pi benchmark

What will this do??

samsara00 said:
same here. Running Super D 1.9 on my magic
before JIT I got 1.xxxx Mflops/s
after i have 2.xxxx Mflops/s
how do you get the 13 Mflops/s ?
-edit-
with swap disabled i'm getting 3.5 Mflops/s
Click to expand...
Click to collapse
So I guess this only works with Swap off?
sabin123 said:
What will this do??
Click to expand...
Click to collapse
Speed your *hit up!

it works with and without swap.
Just the benchmark result is better when swap is turned off.
Got nearly the same as samsara00:
Rom: SuperD 1.9.2
Before (swap off): ~ 2.3 MFlops/s
After JIT enabling (swap off): ~ 3.5 MFlops/s
But the increase to 13.x seems so unreal, why is there only one result that high in the toplist of greene.com!?

Now to find out if this actually speeds up everyday use lol
CM4.2.14.1
Before: 2.3
After: 3.5
Wow! This made my 3G connection faster too. Was only getting 1500kbps before, now getting on average 3200kbps. Awesome. I'm located in Toronto, on Rogers.
Question: Is this Google's JIT? Will Myraids Dalvik Turbo be faster?

Doesn't boot past the G1 screen when using Dwangs 1.17.1 Assume thats because it has no Eclair in it, but it was worth the dream .

Waw!! great works!!
left is before - right one is after
on CM 4.2.14.1, enabled Swap 64MB, CC ON, RAM Hacked

So do we copy the zip to the root of our sd card? Do I extract it first and just copy the one file? The instructions are kind of vague.

G1ForFun said:
So do we copy the zip to the root of our sd card? Do I extract it first and just copy the one file? The instructions are kind of vague.
Click to expand...
Click to collapse
Not to be rude, but if you don't understand those directions, this isn't the sort of thing you should try to do yourself. Wait for a ROM builder to add this in. The directions are perfectly clear, you just need to understand command line use.
If you want to learn something about CLI use, install Linux on your computer and learn to use it without the GUI. If you don't want to do that, google for "cygwin" and use the bash shell they provide for Windows based machines.

Personally, I used adb and just pushed the darn file lol works perfectly fine, like everything else I've ever pushed. Just don't forget to set the permissions for the file.

tried in a terminal and with adb getting read-only file system when trying to copy over the libdvm.so file

SilentTweak said:
Personally, I used adb and just pushed the darn file lol works perfectly fine, like everything else I've ever pushed. Just don't forget to set the permissions for the file.
Click to expand...
Click to collapse
Nothing wrong with adb. Hell, I used SSH to do it. Just about anything will work, you just have to know what you're doing.
Damn.... I just rebooted and it took about half the time it used to.
Tried the Linpack benchmark, getting about 3.5 with SuperD 1.9.2 w/Compcache 16M swappiness=10. Fresh reboot, obviously. Lock your CPU to 528 (min and max) for more consistent results. When I have 128min 528max, it gives different results depending on the current CPU speed. SetCPU or Overclock Widget helps a lot here. No instability noticed yet, but this should probably be considered an unstable hack for now till we all get more experience with it. I know OpenEclair removed the JIT VM because of stability problems.

Sgt.EddieWinslow said:
tried in a terminal and with adb getting read-only file system when trying to copy over the libdvm.so file
Click to expand...
Click to collapse
Do "adb remount" first

ttabbal said:
Not to be rude, but if you don't understand those directions, this isn't the sort of thing you should try to do yourself. Wait for a ROM builder to add this in. The directions are perfectly clear, you just need to understand command line use.
If you want to learn something about CLI use, install Linux on your computer and learn to use it without the GUI. If you don't want to do that, google for "cygwin" and use the bash shell they provide for Windows based machines.
Click to expand...
Click to collapse
Obviously they are not clear to me. Why argue the point?
I have worked plenty with cmd type interfaces...so please...put down your know it all stick and be helpful.
edit: hope this helps somebody else...look better instructions posted in the fasttest thread!
download files here and copy them on the sdcard
created a folder /sdcard/jit and put the three files in it
make a folder /sdcard/dalbk and copy the original files
adb pull /system/build.prop .
Open in WordPad/Textpad and add as the last line: dalvik.vm.execution-mode=int:jit
SAVE IT, copy/push it on the /sdcard/jit folder

Sgt.EddieWinslow said:
tried in a terminal and with adb getting read-only file system when trying to copy over the libdvm.so file
Click to expand...
Click to collapse
Code:
C:\Android\tools>adb shell
# su
su
# mount -o rw,remount -t yaffs2 /dev/block/mtdblock3 /system
mount -o rw,remount -t yaffs2 /dev/block/mtdblock3 /system
# chmod 777 /system/lib/libdvm.so
chmod 777 /system/lib/libdvm.so
# cp -f /sdcard/vmlibs/libdvm.so /system/lib/libdvm.so
cp -f /sdcard/vmlibs/libdvm.so /system/lib/libdvm.so
# chmod 644 /system/lib/libdvm.so
chmod 644 /system/lib/libdvm.so
# reboot
Damn.... I just rebooted and it took about half the time it used to.
Click to expand...
Click to collapse
Indeed
Licknuts result : 3.1-3.5 (with Super-D 1.9.2)

My method of installing it:
adb remount
adb push libdvm.so /system/lib/libdvm.so
Then open console and type:
su
chmod 644 /system/lib/libdvm.so
reboot

I'm about to try this myself.. has anyone noticed an overall increase in speed? Benchmarks are great but it's all about how it actually performs!
I'll post my own findings in a bit.

Related

Testers needed - latest busybox compiled for Android

PLEASE NOTE: THIS THREAD IS NOW OBSOLETE, BUSYBOX COMES WITH JUST ABOUT EVERY COOKED ROM
Hi all,
This is my first attempt at compiling anything for the android platform. My reason for doing this is whilst the busybox version does what we need it to do when rooting our HTC Dream's / G1's, as an everyday app it fails because it segfaults all the time.
This isn't a dig at Benno because to be honest, he's a bit of a hero for compiling it the first time round, without him it would have been a lot harder (if not impossible) to root our G1's.
Problem is, his version of busybox was compiled over a year ago (14 nov 2007 if his blog is anything to go by) and segfaults quite a lot (probably because it wasn't compiled for the G1, but more for the Android emulator), particularly if you try and do "ls -al"..
So what I've done is I've compiled the latest stable version of busybox (1.13.1 as of 14 December 2008) for the G1, I've tested this on my own G1 and it seems to work fine, but I could do with some help extensively testing it.
You can grab it here (for G1: long press -> save, for other browsers: right click -> save as / save target)
Installation Instructions:
Download the above file to your G1, it should be saved as /sdcard/download/busybox2.asc
(if you downloaded it with the G1 browser that is, otherwise please copy it to your G1's SD card to that exact path / name)
Remount your /system partition with this command:
Code:
mount -o remount,rw /dev/block/mtdblock3 /system
Copy the busybox binary into the /system/bin/ folder by running this command:
Code:
dd if=/sdcard/download/busybox2.asc of=/system/bin/busybox
Set the busybox binary as executable with suid bit by running this:
Code:
chmod 4755 /system/bin/busybox
Remount your /system/bin partition as read only again (unless you want to create more shortcuts) by doing the following:
Code:
mount -o remount,ro /dev/block/mtdblock3 /system
And thats it! Please test it as thoroughly as you can and let me know in this post if you have any problems
Ps. I take no responsibility for any damage that occurs directly or indirectly from using this program. Although I will try and make amends if something doesn't work as expected, you must acknowledge that you are solely responsible for your actions when modifying the filesystem of your G1.
Please note, this version is compiled as follows:
* It is compiled against regular libC so is 1.8MB big
* It is compiled with the soft links options
I'm investigating compiling it against uClibC to get the size down dramatically, and compiling it with a seperate set of options so it auto-identifies when to use itself when you're shell is busybox sh.
Appears to have installed alright! Haven't had a chance to test it out otherwise, but I'll let you know if my phone explodes.
Excellent going through it now!!!
Thank you!
anybody else get
Code:
/system/bin/busybox: write error: no space left on device, 1045+0 records in , 1044+0 records out, then the speed stats
Im just gonna chmod it anyway, I wonder which file it forgot?
man all my G1 hack went smooth till I tried the market cache move, i got 1 file and 100 force closes, tried moving them back to no avail..HARD RESET, now I messed up this one somehow, Its par for my course these days, f'it...
bhang
edit:
I reran the "dd" command after I freed up almost a meg and it output same write error: no space left on device 1+0 records in 0+0 out, looks like it copied the last file I missed in the first run? do I need to chmod everything again since I dunno which 1 of the files it may have been..
on second thought 'dd' looks like it may have realized it only needed the 1 file but still needed more room cause 0+0 out, I dunno im confused any advice?
good work
installed successfully. so far no problems. does this new version contain commands not found in the previous versions, ie/ the version JesusFreke used in modified rc30 v1.2 (Sauriks' version from here: http://www.telesphoreo.org/pipermail/g1-hackers/2008-November/000032.html)?
edit: just realized that the previous ver i had installed was 1.12.2 (2008-11-16)
I think JesusFreke was compiling the bionic version last night. Might wanna check on that before you spend your time doing if it you have not already.
Darkrift said:
I think JesusFreke was compiling the bionic version last night. Might wanna check on that before you spend your time doing if it you have not already.
Click to expand...
Click to collapse
uninstall is just as easy as installing
-beers!
Bhang, have you installed anything else on your /system partition bar the stock files?
I'm working on a solution at the moment that moves all this to the /data partition to provide some more usability. For now I suggest you delete busybox from /system/bin/ so you don't fill up your /system partition.
syntax?
I could not quite get this to work as stated. I am no command line expert, so I guessed at what might work. I did the following:
Instead of this:
mount -o remount, rw /dev/block/mtdblock3 /system
I did this:
mount -o remount, -rw /dev/block/mtdblock3 /system
At the last I did this:
mount -o remount, -r /dev/block/mtdblock3 /system
Then I rebooted. Everything seems fine. I looked up some busybox commands, but they don't seem to do anything. Any way to know for sure?
my bad, it works!
Excuse a noob, I didn't know you had to type "busybox" in front of the command...
Hi, the link is down, can someone please re-upload? Thank you .
Please note, this is now obsolete as busybox comes with just about every other ROM out there.
foxdie said:
Please note, this is now obsolete as busybox comes with just about every other ROM out there.
Click to expand...
Click to collapse
Unfortunitally there have been people releasing versions without busybox recentl for the mytouch series mainly and we need a good version of Busybox if possible
Hi,
I know that, but I'm having problems getting SUFBS (http://forum.xda-developers.com/showthread.php?t=530271) to work correctly. I read through the thread and someone tried your busybox and it worked. Also, the one I have (using myhero 0.0.7) is using 1.8.1.
You can actually rip the busybox binary out of any of the roms that come with it.
Any instructions? It'd be simpler if foxdie's busybox is re-uploaded though. Thanks!
Wysie said:
Any instructions? It'd be simpler if foxdie's busybox is re-uploaded though. Thanks!
Click to expand...
Click to collapse
try this out, it's what i used http://benno.id.au/blog/2007/11/14/android-busybox
http://www.busybox.net/downloads/snapshots/busybox-snapshot.tar.bz2
can anyone please compile the latest source or explain how to do this with windows and visual studio?
I tried to build busybox latest with android bionic lib and gave up on passwd.
I had problems with bionic umtp, no strchrnul in string.h and no pw_gecos in passwd.
I can not understand how other busybox builds where able to get build. Any experiances?
EDIT: Doh, stupid me. I made 2 big mistakes. I will give it a new try with an other compile.
EDIT2: wich lib was taken to compile busybox? androids c lib bionic was not possible for me.

Debian Working on Hero

So i dont know about others since there are a billion posts and a billion builds.. but i was able to get Debian working on hero today with a few changes to the code and manually typing in the start scrip myself .. i tried to make a stat script but it always fails at mounting. i tried numerous ways of mounting in the script which all fail.. any ideas?
I was having similar issues when I tried this but was able to get it by specifying the fs type of the debian image e.g.
Code:
#mount -t ext2 -o loop debian.img /data/local/mnt
This is assuming of course you are in the directory containing debian.img and you have already created the mnt dir in /data/local. I just tested this from twisted hero 5 but had success on one of the earlier JAC builds and superhero b1. No other modifications were necessary for this and I was able to mount the others listed in the mountonly script included in the 2.1 installer package similarly. I have stopped using the dootdeb script entirely and now just mount and chroot manually when needed.
Hope that helps.
daemontux said:
I was having similar issues when I tried this but was able to get it by specifying the fs type of the debian image e.g.
Code:
#mount -t ext2 -o loop debian.img /data/local/mnt
This is assuming of course you are in the directory containing debian.img and you have already created the mnt dir in /data/local. I just tested this from twisted hero 5 but had success on one of the earlier JAC builds and superhero b1. No other modifications were necessary for this and I was able to mount the others listed in the mountonly script included in the 2.1 installer package similarly. I have stopped using the dootdeb script entirely and now just mount and chroot manually when needed.
Hope that helps.
Click to expand...
Click to collapse
question since debian can run flash player has anyone installed it on there just for kicks
i tried it when i was on 1.2 before cupcake. i got as far as getting debian to work and then use lxde for gui. I got ice weasle installed then install flash which somehow broke my iceweasle browser. I would imagine it would be slower than flash on hero rom though.
superg05 said:
question since debian can run flash player has anyone installed it on there just for kicks
Click to expand...
Click to collapse
While flash is supported on many desktop linux distributions, I have not found an ARM EABI version of it. I was looking when I first put debian on the phone but without finding the correct package and considering iceweasel was painfully slow in the chroot/vnc environment even without the plugin I did not try for long. I was running a class 2 card at the time maybe it is a little better on my class 6 but I think ill wait for adobe to release an android version anyway
@maydaysos was it an armel package you installed? If so where did you find it? I only remember seeing libflash gnash and possibly swfdec in the armel deb repositories

[INFO][32B] [PORT/FIX] for [ROM] JACxHEROSkiv2.1- JAC/CC 2.83.x posted in Dream Forum

This is for those who have a Sapphire 32B who had issues running Compcache in the 2.0/1 JACxHEROSki.
The problem is that the Magic convert script included copies a 32A .img file to the boot flash. I removed the lines that do this and things seem to work fine. This must be done after flashing the new image, but before running the script.
Here are the steps to be done immediately after booting to new image, but BEFORE running MAGIC script:
1. Download the modified MAGIC script attached to this message and rename it to remove the .TXT extension (should be just "MAGIC")
2. Use ADB Push to push the modified MAGIC script to /sdcard
3. Use ADB Shell and enter the following:
su
mount -o remount,rw /dev/block/mtdblock3 /system
cp /sdcard/magic /system/bin
cd /
rwsystem
magic
4. Choose MyTouch.
5. Edit user.conf for desired settings.
6. Use reboot command to reboot phone.
I would also like to qualify this by saying this worked for me, and this is my first share of this sort with this forum. So, please use this at your own risk.
Good luck.
Hello,
is there a chance for a 32A version of your latest rom?
regards
endebe
Thanks, ill try later
Yeah man ! Thx for the trick Works fine !
I'm still wondering what s best... compcache with backing swap, or linux swap alone ?
What's your opinion ?
on my 32b the g-sensor doenst work.. ist there a fix?!
psxx said:
on my 32b the g-sensor doenst work.. ist there a fix?!
Click to expand...
Click to collapse
You're right, doesn't work anymore on my 32B too
just run the shell script
su
rwsystem
magic
-then press M for mytouch
wifi and gsensor both work after
Very nice.
I'm just waiting for someone to package the JACxHeroSki 2.1 kernel so I can apply it directly over my MCR 2.2e from Paul @ MoDaCo! Right now, I'm using Cyanogen's 4.1.8 kernel, which isn't bad...but I hear that the JAC one is far superior.
dills84 said:
just run the shell script
su
rwsystem
magic
-then press M for mytouch
wifi and gsensor both work after
Click to expand...
Click to collapse
i already did this... but gsensort wont work after... i tried... no autorote... no apps with gsenor are working
compcache is working naow with this script, but no wifi and gsensor, without this scrips works g sensors and wifi
well this script is relativ simple... the first just remounts the fs to rw and the "2nd" part just replayces 3 libs..
i checked twice... but gsensor doenst work with my phone... i had tha same issue on 1.7r2... later i used the port from setenza01 which had a working g-sensor.
so please if someone know how to fix the G-sensor let me know!
jacko6969 said:
This is for those who have a Sapphire 32B who had issues running Compcache in the 2.0/1 JACxHEROSki.
The problem is that the Magic convert script included copies a 32A .img file to the boot flash. I removed the lines that do this and things seem to work fine. This must be done after flashing the new image, but before running the script.
Here are the steps to be done immediately after booting to new image, but BEFORE running MAGIC script:
1. Download the modified MAGIC script attached to this message and rename it to remove the .TXT extension (should be just "MAGIC")
2. Use ADB Push to push the modified MAGIC script to /sdcard
3. Use ADB Shell and enter the following:
su
mount -o remount,rw /dev/block/mtdblock3 /system
cp /sdcard/magic /system/bin
cd /
rwsystem
magic
4. Choose MyTouch.
5. Edit user.conf for desired settings.
6. Use reboot command to reboot phone.
I would also like to qualify this by saying this worked for me, and this is my first share of this sort with this forum. So, please use this at your own risk.
Good luck.
Click to expand...
Click to collapse
To be honest, you don't have to use this script at all, the script is already in there you just need to run this command.
rwsystem
magic
m
reboot
Hi... By stripping the sapphire.img from the script, you're only solving part of the problem (the compcache part).
Actually sapphire.img is important for you to be able to turn on g-sensors.
Here's the solution I posted on the T-Mobile Android forums. ( http://forums.t-mobile.com/tmbl/board/message?board.id=AndroidDev&thread.id=13826 )
It replaces the some of the files with the ones found in ZeroXd's Hero.
-----
Download the following file, that I put together: http://www.megaupload.com/?d=Q759VAG2
This file fixes the compcache problem found in JACxHeroSki v.2.0 and v.2.1. I don't know if this will work for any later versions of the ROM because they didn't exist when I tried it all.
I take no credit for any of this. I just put everything together and zipped it up. All the included files and the knowledge it took to put all this together came from the wonderful people at the Dream forums on xda-developers.com. --eatabagel
Thanks especially to the following awesome devs:
For the ROMs -
JustAnotherCrowd
CCyrowski
For the 32B files (from ZeroXd 5.2r4) -
Twistedumbrella
For the instructions -
Setenza01
============
Instructions
============
Run all of this after flashing JACxHeroSki 2.0 or 2.1, but before running the "magic" command. I assume that your install went well (that means you did everything you needed to do: wipe, clean out ext2/3, etc.). At the stage you run the following commands, you should have a working install of JACxHeroSki 2.0 or 2.1 that hasn't yet been 'fixed' for 32B. That means no WiFi yet.
1. Copy file onto /sdcard
2. Either from a terminal emulator (i.e., Better Terminal Emulator) or from adb shell, type the following:
cd /sdcard
unzip sapphire32bfix.zip
su
rwsystem
cp /sdcard/sapphire32bfix/sapphire/* /system/bin/sapphire
cp /sdcard/sapphire32bfix/sensors.sapphire.so /system/lib/hw
cd /
magic
3. Type 'm' for magic
4. Reboot. Compcache and Wifi should all run perfectly now. No more home screen loads!!!!
I was going to suggest the same solution but you beat me to it.
I dont know if I like the comp cache with vm... it seems slower...
I really like the ZeroXd 5.2rX it seems to be the most responsive...
zambezy said:
I was going to suggest the same solution but you beat me to it.
I dont know if I like the comp cache with vm... it seems slower...
I really like the ZeroXd 5.2rX it seems to be the most responsive...
Click to expand...
Click to collapse
Yea, I agree, having Compcache is definately slower, I don't know about the VM part though.
They did a comparison btwn Linux-Swap and Compcache and Linux-Swap is the winner for speed and I think so too. As for VM I don't think it does anything, I might turn it off to see what happens.
Sweetness! Did the fix and it worked. I finally have landscape and wifi works! Haven't tested bluetooth yet. But other than the messed up screen wake my phone runs flawlessly. I'd have to say that JACxHeroSki 2.1 is the best Hero rom out right now.
solved! thank your for there these files
eatabagel said:
Hi... By stripping the sapphire.img from the script, you're only solving part of the problem (the compcache part).
Actually sapphire.img is important for you to be able to turn on g-sensors.
Here's the solution I posted on the T-Mobile Android forums. ( http://forums.t-mobile.com/tmbl/board/message?board.id=AndroidDev&thread.id=13826 )
It replaces the some of the files with the ones found in ZeroXd's Hero.
-----
Download the following file, that I put together: http://www.megaupload.com/?d=Q759VAG2
This file fixes the compcache problem found in JACxHeroSki v.2.0 and v.2.1. I don't know if this will work for any later versions of the ROM because they didn't exist when I tried it all.
I take no credit for any of this. I just put everything together and zipped it up. All the included files and the knowledge it took to put all this together came from the wonderful people at the Dream forums on xda-developers.com. --eatabagel
Thanks especially to the following awesome devs:
For the ROMs -
JustAnotherCrowd
CCyrowski
For the 32B files (from ZeroXd 5.2r4) -
Twistedumbrella
For the instructions -
Setenza01
============
Instructions
============
Run all of this after flashing JACxHeroSki 2.0 or 2.1, but before running the "magic" command. I assume that your install went well (that means you did everything you needed to do: wipe, clean out ext2/3, etc.). At the stage you run the following commands, you should have a working install of JACxHeroSki 2.0 or 2.1 that hasn't yet been 'fixed' for 32B. That means no WiFi yet.
1. Copy file onto /sdcard
2. Either from a terminal emulator (i.e., Better Terminal Emulator) or from adb shell, type the following:
cd /sdcard
unzip sapphire32bfix.zip
su
rwsystem
cp /sdcard/sapphire32bfix/sapphire/* /system/bin/sapphire
cp /sdcard/sapphire32bfix/sensors.sapphire.so /system/lib/hw
cd /
magic
3. Type 'm' for magic
4. Reboot. Compcache and Wifi should all run perfectly now. No more home screen loads!!!!
Click to expand...
Click to collapse
Thanks you, its really works fine
Hi guys, could someone please host the fix file on mediafire or filehosting as i can't download it from megaupload nor rapidshare . Would be really nice
Thx in advance

[TUTORIAL] Jit hack for beginners - please move to G1 General

Note: This guide is for beginners who might have barely been able to get a custom rom running on their phone, who might not know how to unzip a file on their android phone, and who are not comfortable navigating a linux file system, but who are daring enough to try a simple hack to get significantly more speed out of their phone. Before reading this, please read the thread in the first reply below this post, and if that works for you - use it! If you want to know more, find out what its doing, or if the other Jit hack technique does not work, you can try this. Or you can tell me I fail. Maybe a moderator could move this thread to the basic G1 subforum?
Hello,
I really enjoy both Super D rom and the Jit hack posted by xda member licknuts in the post called [HACK] JIT enabled Dalvik VM on Android 1.6 (Dusted Donuts) [Hack] - the link to this post can be found in the first reply here, if you scroll down.
So, I thought id post a guide on how to accomplish this hack using Amon_Ra's recovery, Super D or Cyanogen rom (probably works on other roms listed in first post of above thread), and a couple apps available from the android market. I'm not trying to take any credit for this hack - I'm just trying to explain it step-by-step for people who have barely managed to get a rom running on their phone but can't get the hack working using the instructions in the above thread and might not be very experienced with navigating around a linux filesystem.
Please read all of this before beginning - you'll need to write some of it down for when you're in the recovery console doing some file copying/moving/renaming. Especially take note of the instructions at the end for restoring in case of a disaster, although if you're really afraid even after following these instructions, you probably shouldn't try this.
1. Download and install AndroZip File Manager app from android market.
(this is so we can un-zip or decompress a .zip file we will download later containing a modified libdvm.so file, which we will use to replace the original libdvm.so file, enabling Jit)
2. Download and install Linpack For Android app from android market.
(this is so we can benchmark or test our phone to make sure this hack actually works. we can measure the MFLOPS score, or basically how many calculations the cpu is able to perform in a set amount of time)
3. Run Linpack For Android and press "Run Benchmark" - remember the MFLOPS value.
(it should be around 2.5 or so - when we enable Jit, we should get more like 3.5 MFLOPS which means more speed)
4. Download a specific file from the original thread listed above, BUT get the file from alldroid by t3hsteve... its in the first post of the above-mentioned thread about halfway down.
(if this link goes down, the point is that you need to obtain the new modified jit-enabled libdvm.so file from somewhere, either in a zip file or by itself, and download it to your phone so you can use it to replace the original libdvm.so - the instructions that follow apply only to the specific file above. If you get a different file you'll have to navigate through the unzipping process differently based on where the libdvm.so file is inside the zip file, and the result being the modified libdvm.so file in the root directory of your sdcard (/sdcard) - if you download the correct file from that post you can follow the instructions below exactly. I would post the link but I'm not allowed to post outside links.)
5. Run AndroZip app, and navigate to your download folder. This should just require clicking the "download" folder, since you should already be in the ./sdcard folder which will be listed as your current directory when you start AndroZip.
(If you're not in this directory, navigate back as far as you can by scrollng up in the app and tapping the blue/left arrow to go "up" or back a direcory. You aren't done with this step until you see ./sdcard/download/ at the top of AndroZip and you can scroll down to see the file "dusted-donuts.zip" - this is the .zip dile we downloaded that contains the libdvm.so (and some other files). If you downloaded a jit-enabled/hacked/modified libdvm.so from a different source, you don't need to be doing any of these unzipping steps.)
6. In AndroZip, click "dusted-donuts.zip" and click "extract to." Then click the back arrow in AndroZip, which should take you to the ./sdcard directory. Click "extract here."
(you will see ./sdcard at the top of AndroZip indicating this is the directory you changed to. When the "successfully unzipped file" message has appeared, you have extracted the libdvm.so and possibly some other harmless files which can't do any damage since they're just in your download folder and not one of your android system folders.)
7. In AndroZip, click the "dusted-donuts" folder, which will have appeared after you extracted the above zip file, and then click the "lib" folder (this is all part of the zip file you extrated) - this is where the modified libdvm.so file is. Click AND HOLD the libdvm.so file, and a menu will appear. Click "copy." Click the back arrow (scroll up in the AndroZip app if you can't see it) until you have reached ./sdcard again (you will have to click it twice, once to go from /sdcard/dusted-donuts/lib/ to /sdcard/dusted-donuts/, and a second time to go from /sdcard/dusted-donuts/ to /sdcard, which is where we want to paste the libdvm.so file. Click "copy here" in the upper right - the "copy action successful" message should appear. If you scroll down, you should see libdvm.so and at the top of AndroZip you should see that you're in the ./sdcard folder.
8. Reboot into recovery console.
(the place you go to flash a custom rom and do other low-level operations, by rebooting your phone, or powering it off and then starting it back up and holding Home key and Power key at the same time. Don't hold them when your phone is still shutting down or rebooting, wait until the screen has turned black. You only need to hold them until the G1 screen shows up with white text and the phone vibrates briefly. Then you can let go and you will enter recovery. If the system boots normally, pull the battery and try again.
9. Click "go to console"
(Slide your screen so you can use your hardware keyboard if you haven't opened it already. At the console you might see the message "press enter" - if you do, press enter to get a command prompt. Pressing enter even if you don't see this message won't hurt anything. You should see a command prompt, which is a character or set of characters at the start of a line prompting you for or waiting for a command to be entered. It should look like / or # or # / or > or anything like that. It might also have a flashing cursor, or underscore character that looks like _ or something similar.)
Now we are going to back up the old libdvm.so file and put the new modified one in its place, enabling Jit for a speed improvement.
10. Type these commands, pressing enter after each line:
mount /sdcard
mount /system
(You have now enabled access to or "mounted" your sdcard directory (where the new libdvm.so file is) and your system directory (where the current libdvm.so is) so you can do file operations on them such as copying/pasting and moving/renaming.)
11. Type these commands, pressing enter after each line:
cd /system
cd lib
(You have changed directory (cd command) to the system folder you have just mounted in step 11, and then you have changed directory again to the lib subfolder of the system folder which contains various library files like libdvm.so - optionally, you could just type cd /system/lib and press enter.)
12. Type the following command, and press enter:
mv libdvm.so libdvm.old
(You have used the mv command (move) to rename a file, by "moving" it from one file name to another. This command can also be used in linux to move a file to a new directory sort of like cut and paste. Instead, you could choose a different extension at the end of that command, maybe .bak or something (mv libdvm.so libdvm.bak) - the point is you're renaming this file so its still available if you ever need to restore it (if this process doesn't work or you just want to go back to the way it was).)
13. Type the following command, and then press enter:
cd /sdcard
(This changes directory (cd) to the sdcard folder, where your libdvm.so file should be if you followed the steps above. We have to use a leading slash / before sdcard because we are telling linux or the terminal to change to a new main directory and not a subdirecory in the /system/lib directory, because that doesn't (well, shouldn't...) exist.)
14. Type the following command, and press enter (note that the first letter is lower case L):
ls libd*
(This will list (ls) all files (or folders too i think) that start with libd, such as libdvm.so file. I if there are no results, or you just see another command prompt, try typing ls by itself and pressing enter. This will show you all files and folders. Hopefully you see the libdvm.so file as a result of doing this ls command. If not, and you're scared and want to go back to the way things were, type: cd /system/lib ...then type: mv libdvm.old libdvm.so - Do Not do that if you are continuing on, it basically undoes what we did in step 13.)
15. Type the following, then press enter:
cp libdvm.so /system/lib/libdvm.so
(This will copy (cp) the modified/hacked/jit-enabled libdvm.so from the current directory (/sdcard) to /system/lib/ so it is in the correct system folder so Android can see it.
You might also try cp /sdcard/dusted-donuts/lib/libdvm.so /system/lib/libdvm.so if you extracted the zip file correctly in one of the steps above but did not move it to the proper place, if the above command doesn't work.)
16. Type the following, and press enter after each line (note that in the 2nd line, the first character is a lower-case L):
cd /system/lib
ls libdv*
(This will change directory (cd) to /system/lib, the libdvm.so folder which will now contain the libdvm.so file you copied there in the last step as well as the libdvm.old file which is the original libdvm in case you need to remove this hack and restore it. The ls command lists files starting with the letters libdv...)
Now you have finished, you can type reboot and press enter. This time, don't worry about holding home and power, because we just want Android to boot normally. This might take a while, but don't worry. Worst case scenario you can pull the battery and reboot into recovery (hold home + power) after you put the battery back in. Then you could do something like this to restore your original backed-up libdvm.so:
ONLY DO THE FOLLOWING IF... you want to restore your system back to normal and remove the modified libdvm.so file:
mount /system
cd /system/lib
ls libd* (confirm you have both libdvm.so and libdvm.old)
rm libdvm.so (removes libdvm.so, like delete command)
mv libdvm.old libdvm.so (moves libdvm.old to libdvm.so, like rename command)
If this doesn't work to restore, I'm sorry but you'll have to re-flash your custom rom from recovery.
You can check that this hack is working by using Linpack app and clicking the Run Test button, you should see approximately 3.5 MFLOPS. Click Run Test a few times and that number might grow a little if it is less than 3.5.
Thanks to the original poster licknuts mentioned above - all credit goes to him and the original people who figured out this hack in the first place.
[HACK] JIT enabled Dalvik VM on Android 1.6 (Dusted Donuts) [Hack]
the original post by licknuts, it is a more informative read and instructions are a lot more concise
licknuts said:
Primer: Read this about Dalvik VM http://en.wikipedia.org/wiki/Dalvik_virtual_machine
Read this to: Google Groups post about JIT compiler for Dalvik VM from Android-Platform Link
From the post we see that this particular compiled library is ALPHA, so results can vary, but from reading most posts in this thread the results are right near the talked about 3x faster code, stability is going to vary on what apps and or widgets are running. More Widgets = slower performance as these have processes that are eating cycles. When testing with Linpack wait for the advertisement to load first then tap the benchmark button and remove your finger from the touch screen. Background process such that interrupt or having auto-rotate enabled while testing is going to give you slower benchmarks.
In short your apps should load faster and run faster, particularly 3D games. The web browser is faster and you can actually scroll through pages even while graphics are still loading.
The reboot when enabling it is long even appearing to hang at the G1 Screen for 5 minutes or more but once it starts booting past this you will know that your ROM is compatible. The cause is that the dex files are being optimized, after about a third reboot, your ROM should feel pretty snappy and launching apps should be quicker as well as switching apps. The snappiness lasts as well and as some may have said that it's a placebo effect are wrong. Bench mark readings prove it and more importantly a few ROM builders have included this in their 2.1 ROMs as experimental.
The libdvm.so that t3steve cross compiled for the DROID at the time was for Android 2.0, the library works for with newer ROMs Android 1.6 that have some eclair pieces built into the kernel, CyanogenMOD has been using bits and pieces for a while now, if other ROM builders have been using his kernel and framework than a good chance it will work for your phone as well.
I have nothing to do with the compiling of this or the exact functions of enabling JIT except that I had a hunch that the combo might work and it did, so I'm sharing it.
If you aren't good at typing in commands, or don't know how to extract a zip file and understand that a sub folder may or may not exist where you have extracted said zip file to, well.... you may run into some issues, maybe a video tutorial for basic command line on youtube would be a good place to learn.
I wanted to make a very detailed post on www.andoidonroids.com about how to mash the JIT enabled Dalvik VM library into Android 1.6 Donuts I'm calling the hack "Dusted Donuts" and take from the name for what you will. I have been using the JIT enabled Dalvik VM for about two weeks and i runs decent but not perfect. Anyhow a death in the family Sunday has kept me from making a decent post and haven't had the time to get to the website and post and cross post and give credit where due.
No doubt that aaraya1516 broke the news on http://forum.xda-developers.com/showpost.php?p=5703076&postcount=193 as he was first to break the hack on FastTest, not taking anything away from him on that.
My testing goes back two weeks or more even during the 580mhz & 780mhz hack, I was waiting for someone to compile a boot.img with some 2.x stuff and sure enough the carlospants boot.img from ctso worked with enabling JIT for Dalvik VM, but as we know now the overclocking doesn't work at the moment.
Thank Cyanogen and t3hSteve of which may not know that this was entirely possible. Cyanogen mixed in enough Eclair into his Donuts (he's like Willy Wonka) that makes it possible to use the cross compiled JIT enabled Dalvik VM library from 2.1 for the Motorola DROID 2.0.1 libdvm.so that t3hSteve of www.alldroid.com compiled for the custom roms on Droid.
WARNING: Using other methods supplied from other forum members that include replacing the build.prop may cause problems, using the build.prop from the original VMLIBS.ZIP (which is here for reference and original source for libdvm.so) is definitely going to cause ROM and application problems. Hello....use your head here... the VMLIBS.ZIP is for Motorola DROIDS, why would you put the build.prop file for a DROID on your G1 and expect your apps or ROM to work afterwards? It's so simple, you need 1 file, it's called libdvm.so it goes in /system/lib a file by the same name already exists there and it's in your best interest to at least back it up before overwriting it and gives you the ability in the event that your system doesn't boot up you can restore it through recovery console and get your phone to boot past the G1 screen.
FYI: Some ROMs have the option dalvik.vm.execution-mode=int:fast in the /system/build.prop file, this would need to be changed to dalvik.vm.execution-mode=int:jit or commented out or deleted. If you want to play with advanced options create /data/local.prop and fiddle in there with options available from typing dalvikvm -h in your console or terminal app.
Required:
1. Android 1.6 ROMS with a bit Eclair stuff in the Kernel and framework such as Cyanogen ROM 4.2.x, Super D 1.8 - 1.92, WG Y2.6, FastTest, KingKlick Eclair and more.. This libdvm.so works on Android 2.1 as well as it seems it should.. 1 st bootup is slow and I recommend you let it sit even when desktops are up for a couple of minutes and then reboot it, 2nd and 3rd bootups are faster and smoother response overall even for long durations, days.
FIX YOUR FILE SYSTEM FIRST !!!!!! Got to do it from Recovery Console, It's partly the cause of poorly running ROMS and takes seriously longer to type the command than to fix your unknowingly faulty file system. EXT2 is the worst offender and the built in function to repair falls short, even more so when checking EXT4.
Code:
#e2fsck -fcpDC0 /dev/block/mmcblk0p2
#reboot recovery
For the lazy fingers
#e2fsck -fcpDC0 /*/*/*0p2
#reboot recovery
1. Download www.androidonroids.com/dusted-donuts (File has 3 scripts backup, install, restore, 2 folders, 1 libdvm.so)
2. Extract zip to root of /sdcard or where ever you like (the zip has a folder containing the files named dusted-donuts)
3. Open Terminal or go to Recovery Console
FYI when running the install through Terminal your system may freeze or reboot and if it does I highly recommend that you prepare to enter Recovery Mode and check your file system. EXT2 corrupts quickly choosing this for apps2sd to use is not the best option especially if you are using custom ROMs that may lockup or reboot, basically that's a crash.
Code:
$su
#mount -o rw,remount auto /sdcard
#cd /sdcard/dusted-donuts
#sh backup
#sh install
#sync
#reboot
Check the Dalvik VM execution mode. look at the bottom line with_jit means the it is installed , and look at all of those options that can be jammed into your build.prop and local.prop files
Code:
$su
#dalvikvm -h
Phone won't boot past G1 screen? Go to recovery console and restore libdvm.so (give it at least 5 minutes first before giving up)
Code:
#mount -o rw,remount auto /sdcard
#cd /sdcard/dusted-donuts
#sh restore
#sync
#reboot
---------------------------------------------------------------------------------------------------------------------
prefer to use VMLIBS.ZIP from t3hSteve? This is how you can install using that.
Required:
1. Android 1.6 ROMS with a bit Eclair stuff in the Kernel and framework such as Cyanogen ROM 4.2.x, Super D 1.8 - 19.2, WG Y2.6, FastTest, KingKlick Eclair and more.. This libdvm.so works on Android 2.1 as well as it seems it should..
How to install: (easier to go in recovery mode but can be done through terminal)
1. Download the VMLIBS.ZIP from t3hSteve of allroid.com http://alldroid.org/download/file.php?id=1374
2. You only need the libdvm.so file of which appears to be JIT enabled by default.
3. Backup the original libdvm.so #cp /system/lib/libdvm.so /sdcard/libdvm.so
4. Copy the JIT enabled libdvm.so #cp -f /sdcard/vmlibs/libdvm.so /system/lib/libdvm.so
5. Set permissions on the file #chmod 644 /system/lib/libdvm.so
Optional for disabling: (easier to do vi through recovery console, since the back key escapes out of terminal)
To disable JIT MODE but want to keep the libdvm.so create a local.prop in /data and add dalvik.vm.execution-mode=int:fast
#vi /data/local.prop
press the i key to enter vi interactive mode
type dalvik.vm.execution-mode=int:fast
press back key to exit vi interactive mode
to write the file out and quit vi type :wq
or
restore your backed libdvm.so file from the sdcard.
-----------------------------------------------------------------------------------------------------------------------
Enjoi! the dusted donuts,
-Licknuts (me? I'm like Varuca Salt, I want another pony)
Vendor G1 roms around 1.2 Mflops, Custom G1 roms are around 2.4 MFlops/s and with JIT compiled Dalvik VM 3.6 MFlops/s. At most you will see 3.5 MFlops/s fairly consistently with a minimal load on your system and highs at 3.7 Mflops/s. Test before and after using Linpack from the Market, it's free.
The 13.236 Mflops/s is not normal and you will probably not see with your testing, I have seen 5.x & 7.x but these are far and few between and this took a while with tweaked configurations/settings with a persistent app to kill processes, it is attainable and I hope a ROM developer finds the sweet spot to exploit.
Click to expand...
Click to collapse
You fail...
Jerzeeloon said:
You fail...
Click to expand...
Click to collapse
Could you please explain how I fail? The title of this thread specifies it's for beginners, so if it's too detailed or basic for you why don't you just ignore it rather than being insulting. I took the time to elaborate on all the steps hoping this would be helpful to the many people in the original thread who are unable to execute the batch method posted there or don't know how this works or what it's doing (how simple it is). If someone wants to delete it or move it to a different subforum, go ahead, but don't be an asshole.
jeez you kids are a-holes. he's trying his best to help the community and all you have are insults -.-
@OP Good Job dude hopefully someone likes this
Jerzeeloon said:
You fail...
Click to expand...
Click to collapse
seems that you ment yourself...
@wrb123: I also think thats a great guide for beginners =)
Is there any way to get this working with 1.5 hero roms?? That could be a big improvement.
Jerzeeloon said:
You fail...
Click to expand...
Click to collapse
Hey dude don't be a nob - Good going at least you bothered to help beginners out
To make this thread easier to read, it may be worthwile posting all the console commands in quote boxes. This just improves the overall look of the guide. You might want to try making it a bit less wordy, as the length might actually daunt some beginners, but overall, it is a good guide
goofyog said:
Is there any way to get this working with 1.5 hero roms?? That could be a big improvement.
Click to expand...
Click to collapse
I have no idea if this does or does not work on 1.5 Hero roms... from the original post it seems to work on 1.6 roms with "a bit of eclair" so cyanogen, super d, other non-hero types. If you want to try it, I really don't think you'll brick your phone - it probably just either won't do anything or it'll cause a bunch of instability and crashes, in which case you can pull your battery and restore the original libdvo.so file you've backed up, using the steps above. Maybe someone much more knowledgable than me (like, basically anyone...) can answer, or you could try asking in the original thread found in the 2nd post in this thread.
I think i will do that thnx
I personally think those that cant get Dusted-Donuts JIT enabled shouldn't be running it anyways. JIT is experimental, and hasnt been mainstreamed yet.
Maybe those that find it too complicated shouldnt mess around w/ experimental enhancement till they are built into some ROMs first. Will make things easier for everyone........

[TOOL] DEXO – universal odex tool | HOW-TO move lib to /system/lib without reflash

DISCLAIMER: I am not the author of this tool!
All credits goes to tommytomatoe and you can press thanks in this thread because there is no dedicated thread for DEXO @xda (at least I found none)​
theking_13 said:
thiagomme said:
Why does it give better battery life? Thank you.
Click to expand...
Click to collapse
Because it splits the .apk (app package) into two parts, the .apk and a .odex file. Usually, for the phone to use an app, it has to decompile the .apk and get the parts it needs to run the app. With the odex files, which stands for "Optimized Dex" the startup time is much faster since the phone doesn't have to perform any optimizing at startup/runtime, and because of that, it also uses less CPU power, and thus makes it faster, smoother, and battery life is increased.
Click to expand...
Click to collapse
OK. So what is this tool?
This tool doesn’t deal with partially odexed ROMs. This tool is for odexing a ROM that is completely DEODEX.
The benefits? Faster boot, smaller imprint on /data/ partition, overall faster feeling
The myths? I can’t theme ODEX! WRONG! You can theme odex just fine! Just use baksmali and smali.
Click to expand...
Click to collapse
Requirements:Of the author:
adb
Linux, Mac OS X, Windows
Android device with busybox
Four minutes of your day
Added by me:
You have finally settled on a ROM that you want to use for some time without an intention to modify it further
You will need about 100 MB free space on system (my free space decreased from 160 MB to 96 MB after the completion of the process) To free some you can delete some apps from /system/app or move them to /data/app with a root file explorer (do not forget to set the correct permissions afterwards) or even better: to move your /system/lib folder to the lib partition without reflashing the ROM (see below for details)
Tested on Fallout 5.0 and Virtuous Infinity 1.35 with my Tweaked3 8.6 kernel. If you are using this it is at your own will and risk
NOT WORKING on CoolDroid and Sabsa Prime 6.5, probably because they have mixed framework from different Sense versions! Do not do on other similar ROMs only on ones with an original (even modded) framework!
Procedure:Go here and read carefully. It is basically some adb commands.
Out of respect to the author I will not mirror his link nor the instructions​----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------How to free about 120 MB space on /system by moving the lib folder to its dedicated partition without reflashing the ROM
This is only for ICS Sense ROMs. AOSP ROMs have enough free space to run the script without issues. I am not sure about the GB Sense ROMs, but if I remember correct they have enough free space on /system too. (if I am wrong please PM me to add GB Sense boot.img)
Requirements:
Bootloader with /system/lib support: 2.xx or 7.xx
150 MB free space on your SDcard
adb drivers installed (link in my signature)
4EXT Recovery (or any other recovery that has a menu entry for mounting /system/lib partition)
good attention while copy/paste the commands from here. One typo will lead to a bootloop
Download Tweaked3: XI_lib_bootimg.zip
md5sum: 1bc1d645b8212cdb2e4e949c6b7b3312
Download Patched: 3089_lib_bootimg.zip
md5sum: f1ae0228eb4057b4e4c4934a1e8a0515​The zips contain boot images of my Tweaked3 and Patched kernels with /system/lib support (I am not advertising them but this are the files I have ready, you can use a Stock kernel as well). There are 4 of them:
Sense4_lib_boot.img - for ALL Sense 4 ROMs (except VIrtuous Infinity)
Sense36_exp_lib_boot.img - for custom Sense 3.6 ROMs with experimental WiFi driver (Experimental kernel)
Sense36_lib_boot.img - for custom Sense 3.6 ROMs with stock WiFi driver (Stable kernel)
Virtuous_lib_boot.img - the name speaks for itself
Extract the archive in the folder where your fastboot executable is. This is not a flashable zip!​orDownload 2: b2b_lib_bootimg.zip
md5sum: 4bb4d44506eae5f247b69f9c5663e3a8​The zip contains boot images of my B2B kernel with /system/lib support (I am not advertising it but this are the files I have ready, you can use a Stock kernel as well). There are 2 of them:
Sense4_lib_boot.img - for ALL Sense 4 ROMs (except VIrtuous Infinity)
Sense36_lib_boot.img - for custom Sense 3.6 ROMs
Extract the archive in the folder where your fastboot executable is. This is not a flashable zip!​NOTE: your ROM has to be on the same version of the kernel before the procedure, otherwise your WiFi will stop working. Or you will need to download the zip from the kernel thread and copy the modules to /system/lib/modules manually giving them right permissions (644 or -rw-r--r--)​Procedure:# Connect the device to PC, open Command Prompt (cmd) and browse to the folder where are your adb and fastboot executables are (example: cd C:\android-tools)
# Reboot to Recovery (4EXT recommended)
Code:
adb reboot recovery
# Make a Nandroid backup
# Mount manually /system and /sdcard from the "mounts | storage" menu of the Recovery
# Copy the content of /system/lib to the SDcard
Code:
adb shell
mkdir /sdcard/system
cp -r /system/lib /sdcard/system
# Clean /system/lib
Code:
rm -r /system/lib
# Recreate empty /system/lib and set permissions
Code:
mkdir /system/lib
chmod 755 /system/lib
# Unmount manually /system from the "mounts | storage" menu of the Recovery
# Mount manually /system_lib from the "mounts | storage" menu of the Recovery
# Copy the lib contents to /system/lib
Code:
cp -r /sdcard/system/lib/* /system_lib
# Set permissions to /system/lib
Code:
cd /system_lib
find . -type d -exec chmod 755 {} \;
find . -type f -exec chmod 644 {} \;
[I]# Creating symlinks [COLOR=Red]Only for Virtuous Infinity![/COLOR][/I]
ln -s libhtc_ril.so librilswitch.so
cd hw
ln -s copybit.msm8660.so copybit.msm7x30.so
ln -s gralloc.msm8660.so gralloc.msm7x30.so
ln -s lights.msm8660.so lights.msm7x30.so
# Remove the SDcard /system/lib folder
Code:
rm -r /sdcard/system
exit
# Unmount manually /system_lib and /sdcard from the "mounts | storage" menu of the Recovery
# Reboot to bootloader
Code:
adb reboot bootloader
# Flash the boot.img and reboot
Code:
fastboot erase boot
fastboot flash boot XXX_lib_boot.img
fastboot reboot
Now you can use the tool above without concerns about free space
Enjoy!
amidabuddha, thanks for sharing. Have you tried this?
old.splatterhand said:
amidabuddha, thanks for sharing. Have you tried this?
Click to expand...
Click to collapse
Yes of course. Read the Requirements part
Sent from my HTC Desire S
Ok, i need help, cause i don't do this things often:
Fifth step, run it!
Click to expand...
Click to collapse
What and how?
old.splatterhand said:
Ok, i need help, cause i don't do this things often:
What and how?
Click to expand...
Click to collapse
Read further in the instructions, Theres a complete usage example with all the commands
Sent from my Desire S using xda app-developers app
Gonna try it today on CM10.
Tapatalked from Desire S running Andromadus
teadrinker said:
Read further in the instructions, Theres a complete usage example with all the commands
Click to expand...
Click to collapse
Sorry, my fault! I thought this come after the 5 steps.
if a rom is zipaligned, doesn't this mean that there's no need being odexed - kind of same thing? (same performance, battery life...)
i've read that, but i'm no expert...
toxic-hero said:
if a rom is zipaligned, doesn't this mean that there's no need being odexed - kind of same thing? (same performance, battery life...)
Click to expand...
Click to collapse
Zipaligning is about better RAM utilization. Odexing is about reducing the Dalvik VM which in theory should reduce CPU use and make the system run smoothly. You can watch the video, it is made by one of the Elite Recognized Developers of XDA so this guy probably knows what he is talking about. Moreover ALL Stock ROMs are odexed and I am sure that the companies developers are not just too lame to use it for nothing
tried the above...pasted something wrong and now phone stuck on htc screen and can't get into recovery
mackhenri said:
tried the above...pasted something wrong and now phone stuck on htc screen and can't get into recovery
Click to expand...
Click to collapse
Have you provided enough free space on your system partition? Try with a factory reset.
And once again:
If you are using this it is at your own will and risk
Click to expand...
Click to collapse
i think it was due to less space but still will try it once again after making space
Was a hard task to get enough space free.
Let's see how it works now.
old.splatterhand said:
Was a hard task to get enough space free.
Let's see how it works now.
Click to expand...
Click to collapse
Yes this may be an issue with the bigger ROMs. The easiest way is to move some app that you use rarely to /data/apps
The other way is to use the lib partition but this needs ramdisk modification and a hboot that supports it. It is not hard I may add a small how-to if more users want to use this tool
Sent from my HTC Desire S
amidabuddha said:
Yes this may be an issue with the bigger ROMs. The easiest way is to move some app that you use rarely to /data/apps
The other way is to use the lib partition but this needs ramdisk modification and a hboot that supports it. It is not hard I may add a small how-to if more users want to use this tool
Sent from my HTC Desire S
Click to expand...
Click to collapse
Get it on buddy.....I am ready to try whatever u make as you seem to give life to my phone once again and all the devs here and I am become a flashaholic...
Sent from my HTC Desire S using xda premium
amidabuddha said:
The other way is to use the lib partition but this needs ramdisk modification and a hboot that supports it. It is not hard I may add a small how-to if more users want to use this tool
Click to expand...
Click to collapse
This would b great, I did it once for Fallout with one of your kernel ramdisks, but it was not so trivial and a pain in the a** doing this all by hand. Though it worked perfectly, I don't remember every step I did, and mayb I didn't do it the elegant way, as I'm not very experienced.
As far as I remember the complicated part was unpacking kernel+ramdisk, modifing ramdisk, repacking everything and signing it. But this has to be done only once (by one idividual) for every kernel (+ramdisk). The rest ist more or less flashing and copying from /system to /system/lib partition (can be done in recovery easily). The latter mayb realised with one single script installer for every kernel (and rom) I guess. But here I also lack the experince with script installers, elsewise I would have shared the info.
I did it on Windows with bootimg-tools via Cygwin (unpacking, repacking), with SignApk on cmd (signing), in recovery (flashing, copying). For flashing I guess fastboot is more elegant (reflashed whole rom with mod boot.img). For the rest I didn't found something more convinient, but maybe soemone can enlighten me.
HOW-TO move your /system/lib folder to the dedicated partition added to the first post. Tested and verified working. Just copy the commands carefully
Enjoy!
Thx, the new guide worked like a charm for me on Fallout v5.0.0 with your kernel v8.5. I think it is more or less what I did, when it worked for me before. Also the odexing stuff worked well. What I am just wondering about, as this is odexing Rosie, will this affect the Fallout Tweaks for Rosie? And I tended to use Titanium Backup to merge updated system apps (like Facebook) into rom (essentially moving to system I guess), are there any drawbacks doing it with odexed apps?
kwisatz79 said:
Thx, the new guide worked like a charm for me on Fallout v5.0.0 with your kernel v8.5. I think it is more or less what I did, when it worked for me before. Also the odexing stuff worked well. What I am just wondering about, as this is odexing Rosie, will this affect the Fallout Tweaks for Rosie? And I tended to use Titanium Backup to merge updated system apps (like Facebook) into rom (essentially moving to system I guess), are there any drawbacks doing it with odexed apps?
Click to expand...
Click to collapse
All apps will work the same way after odexing. I can confirm all Rosie tweaks in Fallout working.
As per the Titanium stuff I have no idea try it and let us know
Sent from my HTC Desire S
when I am trying to copy /sdcard/system/lib to /system_lib it is showing not enough space....
Also in 4extrecovery - two system_lib are showing...
Any ideas?
BTW I am on Fallout 5.0...

Categories

Resources