NEW VERSION! Less hackish!
Commenting out some code that limits how much heap-memory an application can allocate + adding one dummy JNI function , JIT-enabled Dalvik is now working very stable (i haven't had one crash so far for some hours).
EDIT: this version is not just a hack based on commenting out some code. The only code that needed hacking was dalvik/vm/native/dalvik_system_VMRuntime.c and dalvik/vm/alloc/HeapSource.c . The other fix is just a change you need to make in /system/build.prop - This is important
Instructions:
0. BACKUP ALL THE FILES THAT YOU ARE OVERWRITING HERE !!!
1. Copy libdvm.so and libnativehelper.so to /system/lib/
2. Copy dalvikvm to /system/bin
3. chmod 0755 /system/bin/dalvikvm
4. chmod 0644 /system/lib/libnativehelper.so /system/lib/libdvm.so
5. Optionally clear dalvik-cache (?) I didn't have to though
6. Append the line "dalvik.vm.execution-mode=int:jit" to /system/build.prop
7. Change line in /system/build.prop: dalvik.vm.heapsize=24m to dalvik.vm.heapsize=38m (38 megs should be more than sufficient so far. The problem is, as someone also pointed out in this thread, that JIT increases the memory usage
Remember you have to mount the /system partition in recovery mode.
1 gr0gmint/Copenhagen 8.774 HTC Desire 998.4MHz htc_wwe/htc_bravo/bravo/bravo:2.1-update1/ERE27/155070:user/release-keys
Gratz on linpack record with that
biebi said:
1 gr0gmint/Copenhagen 8.774 HTC Desire 998.4MHz htc_wwe/htc_bravo/bravo/bravo:2.1-update1/ERE27/155070:user/release-keys
Gratz on linpack record with that
Click to expand...
Click to collapse
Thaaank you
Wouldn't mind giving this a spin, but how does one remove it if it doesn't work out? Assume you can just remove the files and the line in build.prop?
not working for me
Loccy said:
Wouldn't mind giving this a spin, but how does one remove it if it doesn't work out? Assume you can just remove the files and the line in build.prop?
Click to expand...
Click to collapse
Backup the files beforehand. I'll edit OP
gr0gmint said:
Backup the files beforehand. I'll edit OP
Click to expand...
Click to collapse
I figured that out and went ahead anyway Getting 9.3-ish on Linpack. How're you getting 10+?
Is it compatible with the cm506 for desire?
Loccy said:
I figured that out and went ahead anyway Getting 9.3-ish on Linpack. How're you getting 10+?
Click to expand...
Click to collapse
hmm, good question, it might be because i'm using a BFS kernel
DocRambone said:
Is it compatible with the cm506 for desire?
Click to expand...
Click to collapse
It should theoretically work with any rom.
gr0gmint said:
It should theoretically work with any rom.
Click to expand...
Click to collapse
Tested but got fc's... but running nicely on Evils rom
Have you found any bugs yet?
[[email protected] desiroot]# adb shell chmod 0775 /system/bin/dalvikvm
- exec '/system/bin/sh' failed: No such file or directory (2) -
What am I doing wrong?
Also my /system/build.prop doesn't seem to exist. Should I create it?
Did you do : adb shell mount /system
?
Re: Dalvik JIT working on Desire with Sense UI! (ugly hack)
[[email protected] desiroot]# adb shell chmod 0775 /system/bin/dalvikvm
- exec '/system/bin/sh' failed: No such file or directory (2) -
What am I doing wrong?
Also my /system/build.prop doesn't seem to exist. Should I create it?
Click to expand...
Click to collapse
mount /system
radiosilence said:
[[email protected] desiroot]# adb shell chmod 0775 /system/bin/dalvikvm
- exec '/system/bin/sh' failed: No such file or directory (2) -
What am I doing wrong?
Also my /system/build.prop doesn't seem to exist. Should I create it?
Click to expand...
Click to collapse
Did you run the recovery-linux.sh script that Paul made? I think you need it to get busybox
richardtrip said:
mount /system
Click to expand...
Click to collapse
[[email protected] desiroot]# adb shell mount /system
- exec '/system/bin/sh' failed: No such file or directory (2) -
Do I have to do the CRI first?
11.003 @ Linpack with jit and OC
gr0gmint said:
Did you run the recovery-linux.sh script that Paul made? I think you need it to get busybox
Click to expand...
Click to collapse
Ah yeah, just figured that out. All should in theory be working now.
Edit Yep, getting 9.5 or so on Linpack
Which mod are you guys using to OC? And which app to set the clock speeds? - Does it have that awful purple/low contrast screen problem still?
awesome, thanks gr0gmint
Related
Hi All,
The Ash shell provides a few advantages over the Android default sh shell such as command history and cursor handling at the prompt. There are other benefits, but these are the first that come in most handy (to me).
The following tutorial will get you ash as the login shell with as yet no ill effects:
Note: that in my case, I'm using my android2sd construct and thus this modification is being done to my active overlay profile setup, thus to undo it I can simply boot into "safe\\normal" mode and undo the changes without possibly locking me out of the console should it have failed (which it didn't) But you can edit the Android /system/bin/sh file in this manner directly.
Ash as Login Shell:
OK, make the /system fs read-write:
mount -o remount,rw /system
Click to expand...
Click to collapse
Note: that the fs type is not needed, and in my case is not yaffs but ext3, Android will figure it out proper.
Next,
cp -a /system/bin/sh /system/bin/sh0
Click to expand...
Click to collapse
(this is for backup purposes and allows us to undo the change if so desired, or delete it if no longer needed).
Note: I'm using JF1.51 roms, so busybox ash is available as /system/xbin/bb/ash, so that is what I am using here; use ash however you are able to access it.
echo "#!/system/xbin/bb/ash">/system/bin/sh
echo "/system/xbin/bb/ash \[email protected]">>/system/bin/sh
Click to expand...
Click to collapse
Please note the use of (redirect\\overwrite)> and (redirect\\append)>>.
This will overwrite sh with a script to load the desired shell, executing any command-line arguments passed, and preserve the permissions of the original sh file. You can manually set the permissions the same as they are for our sh0 backup if the permissions (root.shell)(0755) don't seem to keep.
Finally reset the read-only state of /system:
mount -o remount,ro /system
Click to expand...
Click to collapse
Now if you shell-in\\telnet-in you should get the ash prompt which unlike the Android sh default prompt, includes the present working directory(pwd) ie: '/#' instead of just '#'.
Note: A reboot should not cause the loss of the modification, but if does, copy the new sh script to your /data/local/bin location or something and copy it back via boot script or something.
Shell Scripts:
If you're like me, you discovered that Android didn't need the interpreter declaration comment in scripts, and thus may not have used them...Well, you will need to update your scripts to include them by adding something similar to the following as the first line of your scripts:
#!/system/xbin/bb/ash
Click to expand...
Click to collapse
Again, please note that I am using JF1.51 roms and the location of the busybox ash shell is what I'm listing; put the full location to the shell you intend to use as this location.
Without the interpreter declaration, ash simply complains 'not found' at the first command, as ash doesn't know how to interpret the script, and doesn't seem to default to the login shell.
Hope someone finds this helpful!
sweet. This is going to be very useful
BAM. thats sexy. i just did this on CM3.6.7.1. works like a charm.
scratches head. i'm lost. what does this do and how does this make my g1 better?
temporizer said:
scratches head. i'm lost. what does this do and how does this make my g1 better?
Click to expand...
Click to collapse
im not sure about the other features, but the one i installed it for is to have your working directory in front of ur prompt. ex:
Code:
/# cd /sdcard
/sdcard # cd /system/sd
/system/sd #
etc...
EDIT: Also, if you use ConnectBot, you'll notice with the regular sh, if u scroll up with tracball, you get BS characters on the prompt. with THIS one, when you scroll up, you get last command entered. VERY handy for when you mistype one character on a long-ass command.
I love you
Couldn't you do this?
Code:
mv /system/bin/sh /system/bin/sh0
ln -s /system/xbin/bb/ash /system/bin/sh
great job, i'm going to get ash working on my G1 (CM-3.6.7.1)
Thanks.
kanstin said:
Couldn't you do this?
Code:
mv /system/bin/sh /system/bin/sh0
ln -s /system/xbin/bb/ash /system/bin/sh
Click to expand...
Click to collapse
I tried this and it worked even after a reboot...
Sweet, I love the scroll back with trackball in the terminal!!! Me thinks this should get absorbed into the next Cyan release.
kanstin said:
Couldn't you do this?
Code:
mv /system/bin/sh /system/bin/sh0
ln -s /system/xbin/bb/ash /system/bin/sh
Click to expand...
Click to collapse
Yes, I reckon you could. Though I had done a few experiments where the symlink failed, but I'm fairly sure it was do to the link: /system/xbin/bb/ash -->../busybox and /system/bin/../busybox not existing...so I did it via script. Many ways to skin a cat they say.
Thank you all... this is fricken awesome!!
temporizer said:
scratches head. i'm lost. what does this do and how does this make my g1 better?
Click to expand...
Click to collapse
It gives a more advanced shell for when you use the command line interface or telnet into your G1. If you don't use the command line a lot, it won't help you.
As for specific benefits to the advanced version, it was listed in the first post.
Hi,
imho this is rather a hack that exposes you to the risk at least on CM to loose your
shell during boot as xbin.sqf the compressed squashfs filesystem containing
busybox is mounted rather late in the boot process. A cleaner solution would be to
move busybox to system/bin and link it to sh. That way you ensure that sh will
always be accessible during boot and also later on, thus not interfering with
further developments. A alternative could be to compile a standalone version
of busybox containing only ash (for size reasons, as size in /system/bin is precious)
copy that to /system/bin and link sh to it.
Seems to work fine on Dude's. Not really sure how it should open, but I type "ash" at the prompt and I get the /$ and /# if superuser. I also get the command history by rolling the trackball, which is a very nice feature.
Can i install this without using my PC?
temporizer said:
Can i install this without using my PC?
Click to expand...
Click to collapse
Should work using terminal.
Tried it on JACHero 2.7.1
I tried the hard link one and I get a read only fs error on the first move command. What should I chmod to get past that?
mugafuga said:
I tried the hard link one and I get a read only fs error on the first move command. What should I chmod to get past that?
Click to expand...
Click to collapse
Do this first before the mv and the symlink.
mount -o remount,rw /system
farmatito said:
Hi,
imho this is rather a hack that exposes you to the risk at least on CM to loose your
shell during boot as xbin.sqf the compressed squashfs filesystem containing
busybox is mounted rather late in the boot process. A cleaner solution would be to
move busybox to system/bin and link it to sh. That way you ensure that sh will
always be accessible during boot and also later on, thus not interfering with
further developments. A alternative could be to compile a standalone version
of busybox containing only ash (for size reasons, as size in /system/bin is precious)
copy that to /system/bin and link sh to it.
Click to expand...
Click to collapse
Is this in any way accurate? I dedicate my g1 to cyan's roms and wouldn't want anything to hinder any of the goodness that is cyanogenMod. Advice?
Load ash when terminal is started?
temporizer said:
Is this in any way accurate? I dedicate my g1 to cyan's roms and wouldn't want anything to hinder any of the goodness that is cyanogenMod. Advice?
Click to expand...
Click to collapse
Safest method will be to change to ash shell once terminal app is started (same as typing "ash" to switch shell from sh to ash). I don't know how to do it in android (in linux you could add it to your login script).
So if someone knows how to execute a command when we login using the terminal app, then switching to ash shell would work without fear of breaking any other functionality.
Thanks to FollowingInsanity for editing the build.prop file to get it working corectly, and thanks to Maxisma for the Droid dump. Thanks to everyone else who pitched in on this whole thing. Really all I did was realize the exact line that needed to be changed....everyone else did the rest
Here are instructions on how I got the new maps w/ Navigation to work via adb. I'm running the official rooted 1.6 build, but this should work for anyone.
(if you don't know how you use adb, go to the here
Next, you need to uninstall the old maps.apk file and here's how I personally did it since you can't just go to "uninstall" from the Application Settings(these instructions start already in the ADB shell):
# mount -o rw,remount /dev/block/mtdblock3 /system
# cd system
# cd app
# rm xxxxxxx (this is whatever your maps.apk is titled. sometimes is just maps.apk, but it could also be com.android.google.maps.apk or somethin like that)
# exit
Click to expand...
Click to collapse
Now you've uninstalled the google maps. You can then do these next steps outside of adb.(for instructions purposes i'm using my own Android location):
C:\android\tools> adb pull /system/build.prop C:\Android
C:\android\tools> adb pull /system/build.sapphire.prop C:\Android
The 2nd may not be may be build.trout.prop or something to that effect...build.xxxx.prop
Click to expand...
Click to collapse
Next, change those 2 file names on your PC from build.prop to build-backup.prop and build.xxxx-backup.prop(if you have one) so that you don't lose those files in case anything stupid happens in the mean time lol.
Make a 2nd copy of build.xxxx-backup.prop and rename it is build.xxxx.prop. So now you should have a build.xxxx.prop AND a build.xxxx-backup.prop
Now you'll need the build.prop file to use
build.prop
(IF you are running a sapphire build, you can also use the build.sapphire.prop file located there and skip down to "re-loading prop files")
I saved that file to the same location that I saved my original files.
open build.xxxx.prop in notepad. look for where it says:
ro.build.description=kila-user 1.6 DRC83 14721 ota-rel-keys,release-keys
ro.build.fingerprint=xxxxxxxxxx:user/ota-rel-keys,release-keys
# end build properties
Click to expand...
Click to collapse
you'll need to delete the line that says ro.build.fingerprint=xxxxxxxxxx:user/ota-rel-keys,release-keys but DO NOT delete the line that says #end build properties
replace the line you deleted with the following:
ro.build.fingerprint=verizon/voles/sholes/sholes:2.0/ESD20/17572:user/ota-rel-keys,release-keys
Reloading Prop Files
next, back in your command line window do the following:
c:\android\tools> adb push c:\android\build.prop /system/
c:\android\tools> adb push c:\android\build.xxxx.prop /system/
Click to expand...
Click to collapse
then restart your phone
while the phone is restarting, go back and rename your build.prop and build.xxxx.prop files to build-update.prop and build.xxxx-update.prop, then change your build-backup.prop and build.xxxx-backup.prop to build.prop and build.xxxx.prop
After it restarts you'll want to locate your maps.apk file(the new one) and go back into your command line and type:
c:\android\tools> adb shell
# mount -o rw,remount /dev/block/mtdblock3 /system
# exit
c:\android\tools> adb install c:\android\maps.apk
(install crap...if it doesn't install correctly then don't do whats below)
Click to expand...
Click to collapse
Go check your google maps, type in two locations and click "go" and on the next screen you should see a button that says "Navigate"
go back to your command line screen and type:
Sorry if this is confusing, anyone who could make it more simple, please feel free to give it a try, but this is the best I could offer so people wouldn't have to go looking though the whole think tank thread to get everything they need to get it working
IF THE INSTALL GAVE YOU AND INVALID_UPGRADE ERROR THEN TRY THIS:
(again these instructions are using my own android sdk location, replace the
c:\android\tools with YOUR sdk location
from the command line type the following:
c:\android\tools> adb shell
# mount -o rw,remount /dev/block/mtdblock3 /system
# exit
c:\android\tools> adb pull /data/system/packages.xml c:\android\
Click to expand...
Click to collapse
BACK UP THIS FILE BEFORE EDITING IT
Once that's done, open that xml file in a text editor hit ctrl+f and search for maps, the first one will probably say auth.sitemaps, ignore that, keep searching untile you get to something to the effect of com.android.google.maps.apk or something like that. when you see that, you'll want to delete everything from "<packagename=" to "</package>" for the google maps app. BE VERY CAREFUL!!!! you don't want to accidentally delete something else, thus the reason for the back up.
after you've done that, go back to your command prompt and type:
c:\android\tools> adb push c:\android\ /data/system/packages.xml
c:\android\tools> adb install c:\android\maps.apk
Click to expand...
Click to collapse
it should then install perfectly fine. thats what I had to do to get it to work for me
I love you guys! will try this when I get home from work!
it does not appear to be 100% working....yet...
as posted by dwang, http://forum.xda-developers.com/showpost.php?p=4921655&postcount=275
dwang said:
If you push the old build.prop files back, after a while, the nav option disappears.
Click to expand...
Click to collapse
which I can confirm. About midnight last night it was working okay, and this morning it was gone.
followinginsanity says he will work on it today. http://forum.xda-developers.com/showpost.php?p=4921665&postcount=278
followinginsanity said:
Confirmed... will work on it tomorrow.....
Click to expand...
Click to collapse
may not want to rush to get it working only for it to not work a few hours later...but ..like most people here...that probably won't stop many
I edited the build.prop file...and now it will only work with Sapphire builds. For CM builds, build.prop file that FollowingInsanity created
Code:
c:\android\tools> abd push c:\android\build.prop /system/
c:\android\tools> abd push c:\android\build.xxxx.prop /system/
Should be
Code:
c:\android\tools> adb push c:\android\build.prop /system/
c:\android\tools> adb push c:\android\build.xxxx.prop /system/
Takenover83 said:
Code:
c:\android\tools> abd push c:\android\build.prop /system/
c:\android\tools> abd push c:\android\build.xxxx.prop /system/
Should be
Code:
c:\android\tools> adb push c:\android\build.prop /system/
c:\android\tools> adb push c:\android\build.xxxx.prop /system/
Click to expand...
Click to collapse
Changed lol. thanks
where can i get the new maps apk? the old one fails to install
i get error
Failure [INSTALL_FAILED_UPDATE_INCOMPATIBLE]
ahronzombi said:
where can i get the new maps apk? the old one fails to install
Click to expand...
Click to collapse
http://forum.xda-developers.com/showpost.php?p=4921092&postcount=196
That's the one I did, it also has all the needed files just grab the files from there and you should be able to use them for these instructions
ahronzombi said:
i get error
Failure [INSTALL_FAILED_UPDATE_INCOMPATIBLE]
Click to expand...
Click to collapse
When that happens you need to:
adb push <path to>/Maps.apk /system/app
adb shell
# install /system/app/Maps.apk
# exit
hey hey hey
could you or somone who got this to work try to make a video tuturiol on this so we can all clearly see how it works!!! please someone make an post it on youtube if possible thanks!!!!!!!!!
navigation doesn't work outside of the US at the moment right?
I was able to get the new maps.apk to install - and it is clearly a different application (with the new layers), but no navigate button. : (
seaweeduk said:
navigation doesn't work outside of the US at the moment right?
Click to expand...
Click to collapse
Nope, not until the big G says so.
mianosm said:
I was able to get the new maps.apk to install - and it is clearly a different application (with the new layers), but no navigate button. : (
Click to expand...
Click to collapse
what rom are you using?
mianosm said:
I was able to get the new maps.apk to install - and it is clearly a different application (with the new layers), but no navigate button. : (
Click to expand...
Click to collapse
You might have to try editing your packages.xml file even though it didn't give you an install error. Also, if you push your original build.prop's back, you lose navigation after a few hours. I guess the quick solution to that would be to keep the new build.prop's, but I'm not sure what the problems that might or might not create for other apps.
I'm using CM-4.2.3.1 with the edited build.prop and the build.sapphire.prop files.
# mount -o rw,remount /dev/block/mtdblock3 /system
Click to expand...
Click to collapse
A quick shortcut is to drop the device from this command. As you're re-mounting, the kernel knows the device name. Like this:
# mount -o rw,remount /system
Click to expand...
Click to collapse
Wow dude your the bomb, I did it a different way but it worked perfect. I just took a dount rom extracted it, deleted the maps.apk, then I took the droid dump maps app and put it into the donut rom. Then I made the changes to the build.trout.prop so that it recognized the g1 as the verizon phone, used your downloadable build.prop, of course I just deleted the original build.prop in the donut build, I resigned the donut rom, flashed it like it was brand new, and bingo everything worked perfectly. Wow good job dude. I would upload my rom but I dont want to get into any trouble.
I am using "AOSP1.6_r1.4+ADP DRD20 ROM". Maps on here is called "GoogleMaps.apk". I also do not have just a build.prop. I have a build.sapphire.prop and build.trout.prop. I modified both and replaced according to the first post. When I rebooted, GoogleMaps.apk was reinstalled, so I had to uninstall it again.
I did get the error described in post #8, but was able to get around it with the help of post #10.
But for some reason my network is completely down so I can't do nothing. Wifi and Cellular network. Hmmmm.
Edit: Replacing the files I backed up with the originals, brought my networks back.
Hey everyone,
wesgarner said:
Zip Align reduces the amount of RAM used during processing running for a major speed increase in running the apps: http://developer.android.com/guide/developing/tools/zipalign.html
Click to expand...
Click to collapse
I had been messing about with a script to pull apks off my phone, zipalign them and then push them back, but then I saw wesgarner's CM build with a binary and script for use on your phone. I don't really want to mess round with flashing a ROM just for that though, so I've ripped them out and uploaded them below. Another reason is I want to run this manually (with GScript) rather than on boot (as it does in wesgarner's ROM).
I take no credit for this, the binary and script were both taken from wesgarner's CM buiild.
To "install" this, just adb push the two files in the zip below onto your phone with:
Code:
adb shell mount -o remount,rw /system
adb push zipalign /system/bin
adb push zipalign_apks /system/sd/zipalign_apks.sh
adb shell chmod 755 /system/bin/zipalign /system/sd/zipalign_apks.sh
adb shell mount -o remount,ro /system
Then anytime you want to run the script just do:
Code:
adb shell sh /system/sd/zipalign_apks.sh
Or in terminal:
Code:
su
sh /system/sd/zipalign_apks.sh
Has been tested on CM 4.2.7.1
ZipAlign
senab said:
Hey everyone,
I had been messing about with a script to pull apks off my phone, zipalign them and then push them back, but then I saw wesgarner's CM build with a binary and script for use on your phone. I don't really want to mess round with flashing a ROM just for that though, so I've ripped them out and uploaded them below. Another reason is I want to run this manually (with GScript) rather than on boot (as it does in wesgarner's ROM).
I take no credit for this, the binary and script were both taken from wesgarner's CM buiild.
To "install" this, just adb push the two files in the zip below onto your phone with:
Code:
adb shell mount -o remount,rw /system
adb push zipalign /system/bin
adb push zipalign_apks.sh /system/sd
adb shell chmod 755 /system/bin/zipalign /system/sd/zipalign_apks.sh
adb shell mount -o remount,ro /system
Then anytime you want to run the script just do:
Code:
adb shell /system/sd/zipalign_apks.sh
Or in terminal:
Code:
su
sh /system/sd/zipalign_apks.sh
Has been tested on CM 4.2.7.1
Click to expand...
Click to collapse
i do not even know what zipalign does .. but i did add this to my script
# lucid -z
so .. what does it do exactly?
Sweet... Thanks...
I was surprised that more than half of the Apps I have were already ZipAligned...
LucidREM said:
i do not even know what zipalign does .. but i did add this to my script
# lucid -z
so .. what does it do exactly?
Click to expand...
Click to collapse
APKs (as you probably already know) are just zip files. zipalign simply aligns the APK on 4-byte boundaries which Android is more efficient wrt memory access.
You can read more from Jean-Baptiste Queru at http://android-developers.blogspot.com/2009/09/zipalign-easy-optimization.html
Vermithrax said:
Sweet... Thanks...
I was surprised that more than half of the Apps I have were already ZipAligned...
Click to expand...
Click to collapse
Since the 1.6 SDK was released, the ADT does this automatically on APK export. Therefore any app which has been updated since ~September (and was developed using the ADT Eclipse plugin) will be zipalign'd. I was more surprised that 12 out of the 43 apps on my phone weren't aligned!
ZipAlign
senab said:
APKs (as you probably already know) are just zip files. zipalign simply aligns the APK on 4-byte boundaries which Android is more much efficient wrt memory access.
You can read more from Jean-Baptiste Queru at http://android-developers.blogspot.com/2009/09/zipalign-easy-optimization.html
Click to expand...
Click to collapse
that's awesome .. thanks for the link .. i hadn't read about that
Thanks much for this!
Here is a simple gscript to install zipalign after a wipe or new build flash.
You must first create directory /sdcard/zipalign and place zipalign from the zip in the OP there. Path to the file should now be /sdcard/zipalign/zipalign.
Place this script in your gscript folder (after removing .txt from the name) and load it in gscript with su permissions.
I also find it easier to run the script in the zip from the OP in Gscript as well. Instead of placing it in /system/sd run this (assumes zipalign_apks.sh is at root of C:\)
Code:
adb remount
adb push C:\zipalign_apks.sh /sdcard/gscript/zipalign_apks.sh
Then just load it into Gsrcipt with su permissions as with the other script.
Easiest of all may just be to use the commands within Lucid's script. But, I'm comfortable with Gscript, and I can make it 2 clicks away.
EDIT: First execution, you may want to run the original way, because guess what? Gscript isn't zipaligned. But it worked fine just the same.
worked great thanks.
Thanks. I didn't want to flash whole ROM to zipalign apps, so script was very handy.
Actually I've zipaligned only 2 apps, one of them was everybody loved Linda
so anyone wanna bless me with a terminal code to install the script?
garz said:
so anyone wanna bless me with a terminal code to install the script?
Click to expand...
Click to collapse
Read, its on the first post....xD
ZipAlign
garz said:
so anyone wanna bless me with a terminal code to install the script?
Click to expand...
Click to collapse
# lucid -z
yeah so su? then #lucid -z? cause that did nothing for me...
LucidREM said:
i do not even know what zipalign does .. but i did add this to my script
# lucid -z
so .. what does it do exactly?
Click to expand...
Click to collapse
I put a quick explanation of my script on my ROM page: here ya go (rough explanation)
Zip Align reduces the amount of RAM used during processing running for a major speed increase in dex-opt and running the apps, along with the RAM hack and a CC (or your userinit) boots speeds incredibly and better usability of apps (boot and system) in Android: http://developer.android.com/guide/d.../zipalign.html
Most developers have not used this yet (CM does ZipAlign his apps), but this does for the system apps provided from the now old Google Apps
Click to expand...
Click to collapse
senab said:
Since the 1.6 SDK was released, the ADT does this automatically on APK export. Therefore any app which has been updated since ~September (and was developed using the ADT Eclipse plugin) will be zipalign'd. I was more surprised that 12 out of the 43 apps on my phone weren't aligned!
Click to expand...
Click to collapse
Agreed. The Market won't let non-zipaligned apps be uploaded.
AndroidAppCritic said:
Agreed. The Market won't let non-zipaligned apps be uploaded.
Click to expand...
Click to collapse
it will really, it doesn't detect the diff
Also, SDK4 didn't really include an enforced ZipAlign like SDK5 (eclair) does
Plus I built the ZipAlign from source from eclair - so this script may not update them all perfectly
garz said:
yeah so su? then #lucid -z? cause that did nothing for me...
Click to expand...
Click to collapse
Unzip the files to your SD Card, then:
Code:
su
mount -o remount,rw /system
mv /sdcard/zipalign /system/bin
mv /sdcard/zipalign_apks /system/sd/zipalign_apks.sh
chmod 755 /system/bin/zipalign /system/sd/zipalign_apks.sh
mount -o remount,ro /system
Post deleted becoz it was redundant
can someone make a script for windows or a bat file that can zipalign a batch of apks? I am not that ofay with line commands and when i create a new theme (which i often do), i then have to go and zipalign every single apk i have altered 1 at a time..... i do:
Code:
zipalign -f -v 4 E:\app\theapp.apk E:\app\theapp.apk.out
senab said:
Unzip the files to your SD Card, then:
Code:
su
mount -o remount,rw /system
cp /sdcard/zipalign /system/bin
cp /sdcard/zipalign_apks.sh /system/sd
chmod 755 /system/bin/zipalign /system/sd/zipalign_apks.sh
mount -o remount,ro /system
Click to expand...
Click to collapse
This isnt working for me bc of the .sh after zipalign_apks .. do i rename the zipalign_apks to zipalign_apks.sh after unzipping?
edit:that worked THANKS!
The guide for deodexing SGSII (http://forum.xda-developers.com/showthread.php?t=1113937) works also for SGS+ (rooted of course).
I used xUltimate version v.2.3.1 for successful deodexing of rooted I9001XXKP4 ROM.
Hello
I only know deodexing merge *.apk and *.odex files.. What will i get if i deodex my rom ? Run faster ?
XER0123 said:
Hello
I only know deodexing merge *.apk and *.odex files.. What will i get if i deodex my rom ? Run faster ?
Click to expand...
Click to collapse
Deodexing actually makes the ROM a bit slower (at least on the first boot). The main advantage is that it makes customization (themes, icons etc.) easier.
The UOT Kitchen claims to support also odexed stock ROMs (and now also TouchWiz ROMs), has anyone tried it with SGS+? (worked fine with my deoxeded ROM).
Maigel said:
Deodexing actually makes the ROM a bit slower (at least on the first boot). The main advantage is that it makes customization (themes, icons etc.) easier.
The UOT Kitchen claims to support also odexed stock ROMs (and now also TouchWiz ROMs), has anyone tried it with SGS+? (worked fine with my deoxeded ROM).
Click to expand...
Click to collapse
I tried with my odexed rom and it works.
I'm stuck on
* Checking Phone ROM Build.... *
* Waiting for Phone... *
I have Android SDK and JDK installed. Ideas?
Thanks
karo_96 said:
I'm stuck on
* Checking Phone ROM Build.... *
* Waiting for Phone... *
I have Android SDK and JDK installed. Ideas?
Thanks
Click to expand...
Click to collapse
Oh, I forgot to enable USB Debugging. Now all is okey, but I can't copy folders to internal sd
Thanks in advance
karo_96 said:
Oh, I forgot to enable USB Debugging. Now all is okey, but I can't copy folders to internal sd
Thanks in advance
Click to expand...
Click to collapse
The phone is connected to PC in mass storage mode? You should see (at least in Windows) internal SD mounted as normal removable disk and then you can just copy & paste those folders from your PC.
If you're satisfied with UOT Kitchen possibilities and have no plans for other customization then you don't gain much by deodexing.
Okey, thanks, but when I write "adb shell" in cmd it returns
'adb' is not recognized as an internal or external command,
operable program or batch file.
karo_96 said:
Okey, thanks, but when I write "adb shell" in cmd it returns
'adb' is not recognized as an internal or external command,
operable program or batch file.
Click to expand...
Click to collapse
Locate your adb.exe (you did install Android SDK didn't you) and add it to your PATH (or execute <install dir>\abd.exe).
Maigel said:
Locate your adb.exe (you did install Android SDK didn't you) and add it to your PATH (or execute <install dir>\abd.exe).
Click to expand...
Click to collapse
Oh, Thanks, this step is now ok, but still not working :S
When I write cp /sdcard/done_app/* /system/app/ in cmd, it returns "Permision Denied"
is the UOT kitchen working on galaxy i9001?
awesome, i'm going to check it out now!
karo_96 said:
Oh, Thanks, this step is now ok, but still not working :S
When I write cp /sdcard/done_app/* /system/app/ in cmd, it returns "Permision Denied"
Click to expand...
Click to collapse
You need to execute these commands first as adviced:
su
stop
mount -o remount rw /system
Maigel said:
You need to execute these commands first as adviced:
su
stop
mount -o remount rw /system
Click to expand...
Click to collapse
Yes, but look the screenshot: http://img851.imageshack.us/img851/9163/screenshotpgd.png
karo_96 said:
Yes, but look the screenshot: http://img851.imageshack.us/img851/9163/screenshotpgd.png
Click to expand...
Click to collapse
Can someone help me?
karo_96 said:
Can someone help me?
Click to expand...
Click to collapse
When you enter the 'su' command first time via adb shell, you have to check the phone screen - the Superuser app is requesting permission for the command (and you'll have to grant it of course to continue).
i tried to deodex my device
but somehow i stuck on the last step
Code:
adb shell
$ su
# stop
# mount -o remount rw /system
# rm /system/app/*.odex
# rm /system/framework/*.odex
# cp /sdcard/done_app/* /system/app/
# cp /sdcard/done_frame/* /system/framework/
# mount -o remount ro /system
# reboot
when i try to enter " cp /sdcard/done_app/* /system/app/ "
a message shows up: cp: not found
well after that my phone starts into a bootloop
any suggestions how to solve this cp: not found ??
Blumdum said:
when i try to enter " cp /sdcard/done_app/* /system/app/ "
a message shows up: cp: not found
well after that my phone starts into a bootloop
any suggestions how to solve this cp: not found ??
Click to expand...
Click to collapse
Install Busybox first (Busybox installer can be found from Market)?
i had busybox on my phone as far as i know
Blumdum said:
i had busybox on my phone as far as i know
Click to expand...
Click to collapse
Maybe you have installed it in a way that no symbolic links to commands have not been created? Does "/system/xbin/busybox cp" work?
i installed it like 10 min ago
and this " /system/xbin/busybox cp " works
tomorrow i try it again to deodex my device
edit:
thanks not it worked
Bash 4.3.46 for Android
Safe from Shellshock
All right guys im just going to keep this real nice and simple. Purpose of thread:
I compiled this binary from source and patched it get safe from ShellShock bug. It's compiled using arm-linux-gnueabihf toolchain from Linaro (CFLAGS = "-g -Ofast -static -pipe")
[*]You Should Now Have Bash
[*]To run it just type in termial "bash" or "bash --login" if you want to load /etc/profile
Download Link
Click The Text To Download
Flashable ZIP (thanks to Primokorn)
Flashable ZIP md5sum
Shellshock Test (thanks to ronaldteune)
Code:
busybox mount -o remount,rw /
busybox ln -s /system/xbin /bin
# download from browser https://shellshocker.net/shellshock_test.sh and place it in /data
busybox chmod 777 /data/shellshock_test.sh
/data/shellshock_test.sh
rm -f /data/shellshock_test.sh
busybox rm /bin
busybox mount -o remount,ro /
Thanks For Reading :good:
P.S.#1 Bash binary always be updated
P.S.#2 to mount system rw run from terminal
Code:
mount -o remount,rw /system
P.S.#3 if you don't have root put it in /data/local/bin and add it to your PATH
3lo0sh said:
Bash 4.3.30 for Android
Safe from Shellshock
All right guys im just going to keep this real nice and simple. Purpose of thread:
I compiled this binary from source and patched it get safe from ShellShock bug. It's compiled using arm-none-linux-gnueabi toolchain from Mentor Graphics
How To Use:
Download the binary and put it into /system/xbin ( you should mount your system part (r/w)
know run from terminal "chmod 777 /system/xbin/bash"
You Should Now Have Bash
To run it just type in termial "bash" or "bash --login" if you want to load /etc/profile
Download Link
Click The Text To Download
Always lastest Bash
Source Code
Thanks For Reading :good:
P.S. Bash binary always be updated
Click to expand...
Click to collapse
I'm trying to mount my /system using the following commands in Terminal Emulator:
su
mount -rw /system
When I try and type the chmod line above, I keep getting the message:
Usage: mount [-r] [-w] [-o options] [-t type] device directory
What am I doing wrong to mount the /system file in order to perform the chmod command? I've also used ~/system, same result.....it's probably something super simple, but I'm flummoxed. Any assist would be appreciated, thanks!
Joshmccullough said:
I'm trying to mount my /system using the following commands in Terminal Emulator:
su
mount -rw /system
When I try and type the chmod line above, I keep getting the message:
Usage: mount [-r] [-w] [-o options] [-t type] device directory
What am I doing wrong to mount the /system file in order to perform the chmod command? I've also used ~/system, same result.....it's probably something super simple, but I'm flummoxed. Any assist would be appreciated, thanks!
Click to expand...
Click to collapse
The currect syntax is
mount -o remount,rw /system
?
It never even occurred to me that android is vulnerable!! I hope Google patches this in AOSP Android L!!
I have in /system/xbin an old bash file ( coming with the ROM), I must overwrite it or that's enough?
i hope the cm team will include this
nadejo said:
i hope the cm team will include this
Click to expand...
Click to collapse
I'm running CM 11 M11 and I have the bash file but it's different from this one in size.
hp420 said:
It never even occurred to me that android is vulnerable!! I hope Google patches this in AOSP Android L!!
Click to expand...
Click to collapse
Android will never be vulnerable (unless installed unpatched bash)
abidifethi said:
I have in /system/xbin an old bash file ( coming with the ROM), I must overwrite it or that's enough?
Click to expand...
Click to collapse
If the original bash is patched (no need) just copy it as bash-arm
If it's not patched (overwrite it)
nadejo said:
i hope the cm team will include this
Click to expand...
Click to collapse
I don't think they will include it
I think they will just patch theirs
@3lo0sh Getting an error like this 'unable to chmod 777 /system/xbin/bash: Read-only file system. Where i am wrong?
EDIT:- I'm sorry for that. After typing this 'mount -o remount,rw /system' command in terminal I am not getting the above error but when i issue bash command this error returns 'bash: precmd: command not found. Herewith attaching screenshot
abidifethi said:
I'm running CM 11 M11 and I have the bash file but it's different from this one in size.
Click to expand...
Click to collapse
Is it bigger ?
Trilochanaaya said:
Getting an error like this 'unable to chmod 777 /system/xbin/bash: Read-only file system.
Click to expand...
Click to collapse
dude did you read the OP
you must mount your system rw
just run from terminal
"mount -o remount,rw /system"
3lo0sh said:
Is it bigger ?
Click to expand...
Click to collapse
no t's smaller (about 417kb)
abidifethi said:
no t's smaller (about 417kb)
Click to expand...
Click to collapse
It's even include bash_history ??
Sadly it isn't import bash.bashrc by default ?
3lo0sh said:
It's even include bash_history ??
Sadly it isn't import bash.bashrc by default ?
Click to expand...
Click to collapse
So what's your advise?I overwrite it and "Maoulaha RABBI"
3lo0sh said:
dude did you read the OP
you must mount your system rw
just run from terminal
"mount -o remount,rw /system"
Click to expand...
Click to collapse
I did that pls see the post again! I have attached screenshot also.
abidifethi said:
So what's your advise?I overwrite it and "Maoulaha RABBI"
Click to expand...
Click to collapse
Overwrite it
It's smaller,lastest and patched
Trilochanaaya said:
I did that pls see the post again! I have attached screenshot also.
Click to expand...
Click to collapse
I think it's will not work in adb shell ? I am not developer so i think you should wait untel i search for patch to make it work ?
Trilochanaaya said:
I did that pls see the post again! I have attached screenshot also.
Click to expand...
Click to collapse
Pls se the picture
Add this function to your /etc/profile and do "bash --login"