[TOOL] System apps update.zip auto creator - Nexus One Android Development

Hi all
I have created for my first java program a update.zip creator for the nexus one.
This will create a flashable update.zip for updating the system apps on your choice.
I created it for my self to save me time making them every time I wanted to save memory on my phone by moving apps from /data to /system partition (could just of written a script), so thought I would share it.
This is a console tool written in java and only for linux, it will only work on a rooted nexus one running clockwork mod recovery (have not tried any other recovery).
Tested on: nexus one, clockwork mod, CM 7
Programs you can choose to add to the update.zip:
Amazon mp3
Maps
Facebook
Gmail
Rom manager
Android market
Twitter
Youtube
Voice search
Super user
Read the README on how to use it.
Don't forget to run the adb server as root!
Download: http://www.mediafire.com/?pekm9ehswe49x
Any questions,problems,suggestions let me know.
README
Code:
This is a tool I have created for my self to speed up making update.zips for my nexus one and am now sharing.
It is my first java program so it's not perfect but it will improve over time as I learn.
This program will create and sign an update.zip file that will move apps you choose from the /data/app patition to the /system/app partition
It has only been designed to work with the nexus one using Cyanogen mod.
How it works
First it pulls all apps from the /data/app partition on your phone into a created directory with in the PWD
it then scans all the apps for key names of the apps
then if it finds certain apps, it will then ask you if you would like to add it to the update.zip
it then creates the update-script with the commands to delete the apps from the /data/app and copy them to the /system/partition
then it zips the contents and finaly uses the testsign.jar to sign the package.
In the PWD the following programs are needed to run updater-creator:
adb
testsign.jar
update-binary
**** RUNNING THE PROGRAM *****
You must download the apps from the market that you want to update
Leave updater-creator.jar in the directory with ADB and other programs, moving it will prevent the program from finding the programs it needs to run.
You must enable USB debugging on your phone as this program uses ADB.
To run updater creator:
*unzip the file and contents into a directory .
*cd to the dir you unzipped the files to.
*Plug phone in
*Run 'sudo ./adb kill-server' then 'sudo ./adb start-server'
*run the updater-creator.jar file using the following command: java -jar updater-creator.jar
This will create folders and files needed with in the PWD.
Each time you run updater-creator it will over write all previously created files.

I'll give it a try, thank you for sharing your hard work any chance of adding the "read me instructions" to your first post?
Thanks again

Gr8 work,definitely will try it once I get back home
Sent from my Nexus One using XDA App

tina333 said:
I'll give it a try, thank you for sharing your hard work any chance of adding the "read me instructions" to your first post?
Thanks again
Click to expand...
Click to collapse
README now added. Let me know if it works ok or if there are any problems with it, I have tested it my self and had a friend test it with out any problems
If there are any more common apps or features you would like me to add let me know and I will see what I can do.

thank you!! I think this would be pretty useful for myself

Related

[TOOL] Back up custom system files from recovery

This is a tool I made for myself for backing up some of the custom files... Mostly as a result of wanting to expedite the process of backing up some configuration files in /system (such as inadyn.conf or bashrc on synergy rom). It reads a text file to determine what files you want, saves them in a tar on your sdcard (necessary to tar them to keep permissions the same when transferring to fat). Then you flash the restore zip to put them back.
It's set to not backup if there already is a backup (to prevent overwriting your custom files by clicking the wrong zip). The backup.tar is deleted on successful restore.
To use, create a text file in /sdcard/custBackups called custom_files.txt, and put the full pathname of each desired file in there, seperated by a single space (no newlines). While in recovery, run the backup zip to save your custom files, and run the restore zip to restore them after flashing.
An easy way to add the files while using adb shell (with busybox installed) is to cd and ls around to find your file, then while working in the same directory run this command
echo " `realpath myfilename`" >> /sdcard/custBackups/custom_files.txt
(those are backticks, not single quotes, which may be on hackers keyboard but isn't on most android keyboards, that's why I suggested adb shell)
looks long but is pretty quick with bash completion. But only needs to be done once for each file, the text file stays in place.
Thanks to Cyanogen's team and ginger yoshi, as I got the idea from them and learned the updater script reading their files.
A dev can put this in their own updater script so it's all in one (which I do when exporting the svn for synergy). If you can't figure out how to add it reading my script, let me know. And if any devs do use, just shoot me some credit.
If this is used on any other phone, the assert command and mount command in updater script needs to be changed to suit... the rest should be pretty universal.
Is this something like Titanium Backup.apk but in zip format?
No I made this just for synergy for backing up the special configuration files for some of the special tools i'm that ROM, like inadyn and dropbear. Also any special themed files, my fonts..
Basically, catching any system files that titanium and other apps don't get.
Sent from my PG86100 using XDA App

[SCRIPT/TOOL] Convert2Dualboot-SD Tool v1.4[Linux/OSX/Android/DOS][6/8]

Hello all you Triple-Booters out there! I would like to introduce to you:
Convert2Dualboot-SD Tool​
What is this you ask?
This is a little tool that I've put together that will convert any standard flashable roms for our Nook Color to be DualbootSD compatible. No more waiting on my lazy arse to update you guys!!! I used APK manager as a base for my script. I've written 3 different versions that will run on Linux, OSX and Android. All neccesary binaries are included with each version.
Click to expand...
Click to collapse
Can I use any kind of flashable zips?
Yes and no. You could use any standard flashable "rom" or "gapps" zips only.
Click to expand...
Click to collapse
How do I use it?
You drop a standard rom .zip into a "rom-to-modify" folder. Then execute a shell script that will give you an option to convert it for flashing to Primary or Alternate boot on the DualbootSD.
Click to expand...
Click to collapse
Can I use any CWM Recovery for flashing?
Absolutely not! Only use the CWM Recovery that was included with the DualbootSD.
Click to expand...
Click to collapse
Will you be updating this to add new features and stuff?
Not sure what features I can add, but you can always check the CHANGE LOG in post 3.
Click to expand...
Click to collapse
Can you give us step by step directions on how to use this?
Of course! See second post for more details.
Click to expand...
Click to collapse
***Disclaimer: Usual disclaimer applies here as well... you use this at your own risk, I am not responsible for anything that happens to any of your devices. You assume all responsibility when using this tool.***​
Credits:
Daneshm90 for the APK Manager Script I used as a base
Pinako/Inportb/Jyio/Boss! - for his Android binaries
DizzyDen - for porting this over to DOS and his many ideas to get the script to where it's at
HacDan - for some bash guidance
If I forgot someone else, please notify me.
Convert2Dualboot-SD Tool-README​
Convert2Dualboot-SD-Linux v1.4
DOWNLOAD
*C2DSD=Convert2Dualboot-SD*
1-Extract the zip file you just downloaded anywhere on your system
2-In the C2DSD folder, there are 2 folders called "modify-for-pri" and "modify-for-alt". Copy your rom.zip and/or gapps.zip file into its respective folder. No need to rename the file as long as it has a .zip extension.
3-Open up terminal and cd into Convert2Dualboot-SD-Linux
4-At the termninal prompt execute the C2DSD script
Code:
$ sh convert*
5-This will give you a menu where you can choose to modify the "rom" and/or "gapps" for either Primary or Alternate boot. It will also give you an option to clear out recently modded zips. Now with option to mod both ROM & GAPPS on the fly. Just place both files inside either "modify-for-pri" or "modify-for-alt" and choose the option to modify both from the menu.
6-Choose your option and wait while it does its thing.
7-Once it's finished you can exit the program by choosing "0"
8-Now browse to the C2DSD folder and you can find your DualbootSD modded rom file either in "Primary-Mod" or "Alternate-Mod" depending on your earlier selection.
9-Copy that file to the /sdcard partition of your DualbootSD
10-Boot to CWM Recovery that is included with the DualbootSD
11-Flash and enjoy!
Click to expand...
Click to collapse
------------------------------------------------------------------------------------------
Convert2Dualboot-SD-OSX v1.4
DOWNLOAD
*C2DSD=Convert2Dualboot-SD*
1-Extract the zip file you just downloaded anywhere on your system
2-In the C2DSD folder, there are 2 folders called "modify-for-pri" and "modify-for-alt". Copy your rom.zip and/or gapps.zip file into its respective folder. No need to rename the file as long as it has a .zip extension.
3-Open up terminal and cd into Convert2Dualboot-SD-OSX
4-At the termninal prompt execute the C2DSD script
Code:
$ ./convert*
5-This will give you a menu where you can choose to modify the "rom" and/or "gapps" for either Primary or Alternate boot. It will also give you an option to clear out recently modded zips. Now with option to mod both ROM & GAPPS on the fly. Just place both files inside either "modify-for-pri" or "modify-for-alt" and choose the option to modify both from the menu.
6-Choose your option and wait while it does its thing.
7-Once it's finished you can exit the program by choosing "0"
8-Copy that file to the /sdcard partition of your DualbootSD
9-Boot to CWM Recovery that is included with the DualbootSD
10-Flash and enjoy!
Click to expand...
Click to collapse
------------------------------------------------------------------------------------------
Convert2Dualboot-SD-Android v1.4
DOWNLOAD
*C2DSD=Convert2Dualboot-SD*
1-This will allow you to modify the zip files directly on your Nook
2-Extract the zip file you just downloaded to the root of your DualbootSD /sdcard partition.
3-The folder should be named c2dsd
4-In the c2dsd folder, there are 2 folders called "modify-for-pri" and "modify-for-alt". Copy your rom.zip or gapps.zip file into its respective folder. No need to rename the file as long as it has a .zip extension.
5-Open up any Terminal Emulator and cd into the c2dsd folder which should be "/sdcard/c2dsd"
6-At the termninal prompt execute the C2DSD script
Code:
$ su
# sh convert*
7-This will give you a menu where you can choose to modify the "rom" and/or "gapps" for either Primary or Alternate boot. It will also give you an option to clear out recently modded zips. Now with option to mod both ROM & GAPPS on the fly. Just place both files inside either "modify-for-pri" or "modify-for-alt" and choose the option to modify both from the menu.
8-Choose your option and wait while it does its thing.
9-Once it's finished you can exit the program by choosing "0"
10-Now you can choose to boot to CWM Recovery that is included with the DualbootSD
11-Choose "install zip from sdcard" and browse to either "Primary-Mod" or "Alternate-Mod" depending on your earlier selection.
12-Flash and enjoy!
Click to expand...
Click to collapse
------------------------------------------------------------------------------------------
Convert2Dualboot-SD-DOS v1.3
DOWNLOAD
*C2DSD=Convert2Dualboot-SD*
1-Extract the zip file you just downloaded anywhere on your system
2-In the C2DSD folder, there are 2 folders called "modify-for-pri" and "modify-for-alt". Copy your rom.zip and/or gapps.zip file into its respective folder. No need to rename the file as long as it has a .zip extension.
3-Open up command window and cd into Convert2Dualboot-SD-DOS or create a shortcut on your desktop
4-At the command prompt execute the C2DSD script
Code:
convert2dualboot-sd-dos
5-This will give you a menu where you can choose to modify the "rom" and/or "gapps" for either Primary or Alternate boot. It will also give you an option to clear out recently modded zips. Now with option to mod both ROM & GAPPS on the fly. Just place both files inside either "modify-for-pri" or "modify-for-alt" and choose the option to modify both from the menu.
6-Choose your option and wait while it does its thing.
7-Once it's finished you can exit the program by choosing "0"
8-Copy that file to the /sdcard partition of your DualbootSD
9-Boot to CWM Recovery that is included with the DualbootSD
10-Flash and enjoy!
Click to expand...
Click to collapse
And that's all she wrote... well he, being me.
If I've helped in anyway. Don't hesitate to hit the thanks button.
Change log:
v1.4 (6/8/2012)
-Fixed gapps being zipped with rom when converting rom & gapps together
-Added SDCacheMount to converted roms (see the SDCacheMount thread for more info)
-Fixed mkimage binary executing error for Linux version
-No DOS update yet.... DizzyDen?????
-Thanks goes to xda user "shumash" for the SDCacheMount addition into the script
v1.3a
-Mkimage error on Android Script fixed.
-Mkimage is dependent on 'libmusl.so' which I did not include and linked in the tools folder. I overlooked this tidbit because I had "BOTBREW" installed on my system so it never complained about linking to it.
v1.3
-I effed up on the script!
-RASTAVIPER kept asking me about issues with his gapps. Apparently the mod for Gapps Alt Boot had the wrong mount points inserted into the updater script. NOW I SEE IT!
-Also in the DOS version. Prep of ROM Alt Boot had the wrong mount points as well. Sorry guys.
-It's been fixed and uploaded. Please don't use v1.2 anymore. Thanks.
v1.2
-Changed up UI layout of script: Please re-read README from post 2 above for edited instructions.
-Edited script to speed up mod process (Thanks DizzyDen!)
-Added option to mod both "ROM & GAPPS" on the fly
-Android version now has a tool.img file. This makes modding quicker and safer.
-Added DOS version ported by DizzyDen! (Thank you sir!)
-Modding for EMMC dualboot version in the works???? (That's if you guys want it)
v1.1
-Added gapps option
-Cleaned up some scripting behaviors
v1.0
-Initial release
Well.. after some thought, it really didn't make sense to release this without an option to mod gapps for the DualbootSD. I mean what good is a rom without gapps?!
Convert2Dualboot-SD v1.1 is up if anyone wants to try.
Check post 3 for all changlogs.
Thanks,
Racks
Taking advantage of the opportunity to try something new, I made a dual-boot card for my sister-in-law.
This is cool. I actually haven't tested the card yet as I have my device flashed to internal and have modded the recovery some. I haven't backed up any of the changes I made (I know, I know) and don't want to have to do it again.
I may try updating the card now that you've included gapps, though. I hadn't made a bootable card since I first rooted this thing, and to be honest it was by accident even that time. So I was wondering how to get gapps, was thinking about setting an alt-recovery just for that.
But anyway, I hadn't looked at how to do the gapps yet, maybe it was easier than that. But this seems even easier.
Cool, man! I bet the dual/triple booters will love being able to make their own updates. The experience I had last night couldn't have been easier. My wife got me and her sister the Nooks at the same time, I am excited for her to see what I have been talking about the last six months.
I will be sure to try this once my NC gets here. Thanks!
Racks,
Works great but there's an odd 0 byte file in the DB zip called ^[email protected] Is that an artifact and can I just delete it?
shumash said:
Racks,
Works great but there's an odd 0 byte file in the DB zip called ^[email protected] Is that an artifact and can I just delete it?
Click to expand...
Click to collapse
DB zip? Sorry, but what are you referring to with that?
And could you also let me know which one you used? OSX, Linux, Android?
Edit: That might just be the stupid __MACOSX hidden folder that osx likes to include Forgot to exclude that and the .gitignore file when zipping. Although they aren't detrimental to running the C2DSD Tool, you can choose to delete them if you wish.
Thanks,
Racks
Thanks a lot Racks... great work... we'll get together and sort out the windows based version... can include it in your work here... or as another feature of the IMEI generator.
DizzyDen said:
Thanks a lot Racks... great work... we'll get together and sort out the windows based version... can include it in your work here... or as another feature of the IMEI generator.
Click to expand...
Click to collapse
Awesome to hear! Was hoping you would jump in.
We'll hook up and get the Windows based version here as well as incorporate it into your IMEI generator.
Thanks!
Racks
racks11479 said:
Awesome to hear! Was hoping you would jump in.
We'll hook up and get the Windows based version here as well as incorporate it into your IMEI generator.
Thanks!
Racks
Click to expand...
Click to collapse
Sounds like a plan... I just got in from work... and am off tomorrow.
DizzyDen said:
Thanks a lot Racks... great work... we'll get together and sort out the windows based version... can include it in your work here... or as another feature of the IMEI generator.
Click to expand...
Click to collapse
racks11479 said:
Awesome to hear! Was hoping you would jump in.
We'll hook up and get the Windows based version here as well as incorporate it into your IMEI generator.
Thanks!
Racks
Click to expand...
Click to collapse
+1 from a meathead windows user here.
Sent from my NookColor racks tripple boot using Tapatalk 2
racks11479 said:
DB zip? Sorry, but what are you referring to with that?
And could you also let me know which one you used? OSX, Linux, Android?
--SNIP--
Thanks,
Racks
Click to expand...
Click to collapse
Sorry for being vague. I meant the modded dualboot sd zip build. But I tried it again and it was fine, so let's say no more about it, eh?
On a related note, since you're so motivated now, how about creating those separate cache1 and cache2 partitions so that we don't have to wait so long to boot between the two?
Anyone who tried the new modding option and that would like to share with us which CM9 rom (nightly) did he convert and is working fine after conversion?
spdsl said:
+1 from a meathead windows user here.
Sent from my NookColor racks tripple boot using Tapatalk 2
Click to expand...
Click to collapse
Was hoping to have something before I had to go to work this morning... didn't get it completed...
to keep as close as Racks' I will have a DOS batch file available sometime tonight...
True Windows GUI version will be available early in the week.
Keeping with Racks' desires... both will be open source and stored on his github... I use AutoIT for windows programming these things.
shumash said:
On a related note, since you're so motivated now, how about creating those separate cache1 and cache2 partitions so that we don't have to wait so long to boot between the two?
Click to expand...
Click to collapse
Racks, I just sent you a PM that might help with this issue.
shumash said:
Racks,
Works great but there's an odd 0 byte file in the DB zip called ^[email protected] Is that an artifact and can I just delete it?
Click to expand...
Click to collapse
UPDATE: I converted the latest Mirage build, and when I tried to flash it, Recovery complained that it wasn't a valid zip file. Checked it and the same weird file was in the converted flashable zip. When I ran the conversion a second time, all was good and it flashed as expected. I had deleted all the extraneous _MACOSX and .gitignore file stuff prior to running it the first time. BTW, the problem in the quoted post was when I converted an ICS build the first time, too. Racks, do you think that there is something that occurs the first time the script is run that is different on subsequent runs that might account for this?
Just installed nightly 28.4 without Opengl and then gapps which appeared in the folder Primary Mod after conversion.
After that I cant get inside shop.I click to open it and it gets me back to main menu.
Any ideas?Reflashing of gapps didnt work.
RASTAVIPER said:
Just installed nightly 28.4 without Opengl and then gapps which appeared in the folder Primary Mod after conversion.
After that I cant get inside shop.I click to open it and it gets me back to main menu.
Any ideas?Reflashing of gapps didnt work.
Click to expand...
Click to collapse
Primary mod is for Primary boot. Default primary boot was CM7, so I'm assuming you formatted /system1 & /data1 before flashing?
Could you also unzip the contents of the converted gapps zip. And check the updater script. All /system variables should be /system1.
-Racks
I didn't format anything before flashing. I thought this as an upgrade, so after conversion I just proceed to flashing.
Finally, I flashed your own gapps that you have at your dualboot topic and now everything is back to normal.
Unfortunately, even after this upgrade, I still continue to deal with FC issues of mail, Facebook and of other random apps.I think there is some problem with my card and CM9, since CM7 runs perfect from emmc or from same mem card.
Unleashed from my Revolutionized Desire HD

RE-Odex your custom ROM (Speed/RAM benefits and more)

Wanted to share this with fellow amaze users. It's a collection of scripts/binaries that will seamlessly reodex your /system/app and /system/framework folders. This will give you a noticeable increased in overall speed/fluidity, boot times, ram usage... I generally prefer to re-odex anything I use. Major downside to re-odexing is that you can't easily modify the APK. But honestly, it's not that difficult to simply deodex the APK in question, mod/theme it, then reodex it. I find the benefits are well worth it.
The original script was created by tommytomatoe. All credit goes to him for the actual creation of this script. I simply made a windows batch file to ease the setup and execution of said script.
Please PLEASE PLEASE make a NANDROID backup before you run this. I've never had it mess anything up, but who knows... just back up and be safe!..
ZIP is attached below. Unzip into any directory (make sure the files stay together) and run Dexo.bat - You MUST HAVE BUSYBOX, WORKING ADB (Wireless ADB support is built into the batch file), and ROOT!
I originally had a quick batch file made for just myself.. but I changed things around and made it a bit more user friendly and other things.... I've only tested it ONCE on my own device once (the modified one).. so just be warned.. and make a backup first!
The batch file will not close on its own, when it's done the device will reboot on its own. You can simply just close the window.
Hope this helps some people! Good luck.
--------------------
[What is Odex?]
During the build process, Android can be built with the flag “WITH_DEXPREOPT=true”. This means that the dex files are preoptimized in the build environment using a dalvikVM on the host, as opposed to optimized during boot on the device. The dex-preopt process results in two files per apk or jar – the jar/apk file and its accompanying .odex file.
----------------------
[What is so tricky about reodexing?]
Due to the nature of the dalvik VM (according to documentation in AOSP), the VM expects the optimization process to follow the strict BOOTCLASSPATH.
/* There are some fragile aspects around bootclasspath entries, owing
* largely to the VM's history of working on whenever it thought it needed
* instead of strictly doing what it was told. If optimizing bootclasspath
* entries, always do them in the order in which they appear in the path.
*/
So that is the dex-preopt during the build time. All the vendors ship devices with Odex, ie, stock ROMs are odex. What about ROMs that have been deodexed? Or how do you go about editing the smali code from the odex files? Thank goodness for JesusFreke, we have baksmali and smali. Using the two in sequence, one can successfully convert the optimized dalvik executable (odex) and dissemble it into a human readable (sorta) language called “smali”, created by JesusFreke and resembles the Jasmin language. Anyways, carrying on. Using the dexopt-wrapper binary, you can re-odex your ROM after it has been deodexed. This sounds pretty simple but as stated above, the VM expects the optimization to follow the BOOTCLASSPATH. You cannot silly nilly deodex android.policy.jar and then re-odex it. Your device will not boot. You must transfer the original “signature” from the original odex file to the newly created (Hint, dd if=original.odex of=new.odex bs=1 count=20 skip=52 seek=52 conv=notrunc). This can be done on a Linux machine or with the busybox binary.
OK. So what is this tool? I just wanted to give a brief (or not so brief) overview of the process. 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 phone will generally just run a little bit faster, system apps will launch quicker..
The myths? I can’t theme ODEX! WRONG! You can theme odex just fine! Just use baksmali and smali.
This requires BUSYBOX.
This requires ADB.
Again HUGE THANKS to tommytomatoe for the original script and his original efforts.
THIS ZIP FILE IS NOT FLASHED IN RECOVERY! You simply extract it to a folder on your hard drive. Then run Dexo.bat, follow on screen instructions. Make sure to nandroid as well as having phone plugged in VIA USB with debugging enabled, or have wireless ADB ready to go.. batch file supports wireless. Just have to follow prompts and enter IP.
ericdjobs said:
Wanted to share this with fellow amaze users. It's a collection of scripts/binaries that will seamlessly reodex your /system/app and /system/framework folders. This will give you a noticeable increased in overall speed/fluidity, boot times, ram usage... I generally prefer to re-odex anything I use. [/B][/SIZE]
Click to expand...
Click to collapse
Tried this on my ICS ROM and it works fine.
Thanks!
Doesn't work for me :/
Sent from my HTC Ruby using xda app-developers app
avenged_sevenfold27 said:
Doesn't work for me :/
Sent from my HTC Ruby using xda app-developers app
Click to expand...
Click to collapse
Oh! It's not supposed to be flashed in recovery!
Sorry if I wasn't clear on that.
It's a script and a batch file. The batch file will make uploading the script, changing permissions, etc etc etc, a lot more intuitive and easier.
You simply need to extract the ZIP anywhere on your harddrive (Have to be using windows for the batch file to work.. if you're running Linux i'm sure you can figure out how to do it manually anyways) Make sure to keep all the files in the same folder.
Then simply execure dexo.bat and follow the prompts. Make sure you have the phone plugged in via USB and USB debugging enabled.. or have Wireless ADB running (batch has built in support for wireless ADB)
You can run it while the phone is on. The phone will reboot itself when the script is finished.
ericdjobs said:
Oh! It's not supposed to be flashed in recovery!
Sorry if I wasn't clear on that.
It's a script and a batch file. The batch file will make uploading the script, changing permissions, etc etc etc, a lot more intuitive and easier.
You simply need to extract the ZIP anywhere on your harddrive (Have to be using windows for the batch file to work.. if you're running Linux i'm sure you can figure out how to do it manually anyways) Make sure to keep all the files in the same folder.
Then simply execure dexo.bat and follow the prompts. Make sure you have the phone plugged in via USB and USB debugging enabled.. or have Wireless ADB running (batch has built in support for wireless ADB)
You can run it while the phone is on. The phone will reboot itself when the script is finished.
Click to expand...
Click to collapse
It goes through all the prompts for me, but then on the final "Press any key to continue" when I press any key, the batch file just closes with nothing being done to my phone.
Guess I should add, I'm using windows xp, and yes, usb debugging is enabled
masondoctorjt said:
It goes through all the prompts for me, but then on the final "Press any key to continue" when I press any key, the batch file just closes with nothing being done to my phone.
Guess I should add, I'm using windows xp, and yes, usb debugging is enabled
Click to expand...
Click to collapse
Hmm strange. I guess I should add instructions to do it manually, just in case something like this happens
Basically just open a command prompt, navigate to wherever you unzipped everything...
adb root
adb remount
(adb connect again here if using wireless)
adb push dexo /system/bin
adb push dexopt-wrapper /system/bin
adb push zip /system/xbin
adb push zipalign /system/xbin
adb shell chmod 755 /system/bin/dexo /system/bin/dexopt-wrapper /system/xbin/zip /system/xbin/zipalign
then the final command
adb shell dexo
let me know where at in this process it's getting snagged if that doesn't work.
ericdjobs said:
Hmm strange. I guess I should add instructions to do it manually, just in case something like this happens
Basically just open a command prompt, navigate to wherever you unzipped everything...
adb root
adb remount
(adb connect again here if using wireless)
adb push dexo /system/bin
adb push dexopt-wrapper /system/bin
adb push zip /system/xbin
adb push zipalign /system/xbin
adb shell chmod 755 /system/bin/dexo /system/bin/dexopt-wrapper /system/xbin/zip /system/xbin/zipalign
then the final command
adb shell dexo
let me know where at in this process it's getting snagged if that doesn't work.
Click to expand...
Click to collapse
Thanks... It might be a couple of days before I have a chance to try this again, but I'll let you know if this way works.
Sent from my HTC_Amaze_4G using xda app-developers app
Just ran the manual instructions since I had the same error noted above and all goes well until after the last adb shell dexo command; I get a message saying everything is installed but I also see this: Please install these binaries to continue: sed cp unzip. What does that mean?
Edit: I went ahead and rebooted anyway and nothing happened, still deodexed.
How can you tell if the custom rom you're on is dedoxed or redoxed? I'm on the ViperA
Sent from my HTC_Amaze_4G using xda app-developers app
kevinrubio1 said:
How can you tell if the custom rom you're on is dedoxed or redoxed? I'm on the ViperA
Sent from my HTC_Amaze_4G using xda app-developers app
Click to expand...
Click to collapse
Use root explorer or some similar app and go into system/apps and if you see any files right next to the app files that say .odex then you are not deodexed.
Also most custom ROM's state right in the OP if the are deodexed or not.
Sent from my HTC_Amaze_4G using Tapatalk 2
I don't have access to computer so can I run commands through terminal emulator?
Sent from my gt-1900 using xda premium
Doesn't work as of yet...
Followed the instructions
BusyBox Rooted S-off on ViperAmaze 1.7.1 ran the script as Admin and phone restarted after completion of script and stuck on bootscreen.
running fix permission and wiping dalvik+cache just in case if it works will report back EDIT: doesn't work had to recover nandroid
Can anyone dumb this thread down to what deodex/odex means to a person with no dev skills or
What can I do with deodex apks?
Is this a significant boost in speed etc?
Dumb and Dumber (remember the movie?)
blindskater39 said:
Can anyone dumb this thread down to what deodex/odex means to a person with no dev skills or
What can I do with deodex apks?
Is this a significant boost in speed etc?
Click to expand...
Click to collapse
When a Carrier releases a version of software it is ODEXED meaning you have an app like camera.apk, and you have a camera.odex
It's a file that contains the libraries and other things to support the apk.
When you DE-ODEX you build all of the stuff into the apk file so you don't need the .odex files.
it reduces the nuber of files in the rom. Meaning you now only have a camera.apk with no .odex file.
RE-ODEXING the apps and files makes it run faster.
That is taking the files back out of the apk file so you have two files again.
It seems easier to take DE-ODEXED files from one rom and use them in another rom, but you cannot just copy an apk that hasn't been DE-ODEXED into another rom without its' associated odex file.
How's that?! Hope it helps!
Looks like.... IT WORKS on Super Sense 3.2 (coming very soon)! This will speed it up big time!
chevycowboyusa said:
When a Carrier releases a version of software it is ODEXED meaning you have an app like camera.apk, and you have a camera.odex
It's a file that contains the libraries and other things to support the apk.
When you DE-ODEX you build all of the stuff into the apk file so you don't need the .odex files.
it reduces the nuber of files in the rom. Meaning you now only have a camera.apk with no .odex file.
RE-ODEXING the apps and files makes it run faster.
That is taking the files back out of the apk file so you have two files again.
It seems easier to take DE-ODEXED files from one rom and use them in another rom, but you cannot just copy an apk that hasn't been DE-ODEXED into another rom without its' associated odex file.
How's that?! Hope it helps!
Click to expand...
Click to collapse
For the most part its much easier to comprehend, thanks! But why can't you copy a de-odexed apk to another rom if it doesnt which doesnt need the .odex files anymore?
blindskater39 said:
For the most part its much easier to comprehend, thanks! But why can't you copy a de-odexed apk to another rom if it doesnt which doesnt need the .odex files anymore?
Click to expand...
Click to collapse
You can. I'm sorry if I complicated that part..
Sent from my HTC_Amaze_4G using xda app-developers app
this may be a stupid question but will this work on cm11?
dtr145r said:
this may be a stupid question but will this work on cm11?
Click to expand...
Click to collapse
No, CM11 is already deodexed.
SuperAfnan said:
No, CM11 is already deodexed.
Click to expand...
Click to collapse
well yea,
i know that.
thats the point, to 'RE-Odex' it....

[GUIDE] Get 48 GB Free promotional Dropbox space

I saw a post in this thread about getting the promotional space on AT&T S4 without flashing TMobile roms. I gave it a try, and it worked just fine. So I thought of sharing the files with you. I pulled them out of a deodexed TMobile rom.
Download the attached file. You need to push Dropbox.apk and DropboxOOBE.apk into system/app and fix permission. Then you need to push com.dropboxpartner into system/framework and again fix permission.
Then, you need to modify the build.prop using a root explorer. Find the following lines and modify them as follow:
ro.product.model=SGH-M919
ro.product.name=jfltetmo
ro.product.device=jfltetmo
Reboot your device, open the Dropbox app, and log in with your existing account, or create a new account. You will receive an email, and after fulfilling 5 of the 7 tasks, you will receive the 48 GB promotional space. After fulfilling the tasks, you can restore your build.prop to its original state.
Attached Files:
http://d-h.st/fZJ
smnfriend said:
I saw a post in this thread about getting the promotional space on AT&T S4 without flashing TMobile roms. I gave it a try, and it worked just fine. So I thought of sharing the files with you. I pulled them out of a deodexed TMobile rom.
Download the attached file. You need to push Dropbox.apk and DropboxOOBE.apk into system/app and fix permission. Then you need to push com.dropboxpartner into system/framework and again fix permission.
Then, you need to modify the build.prop using a root explorer. Find the following lines and modify them as follow:
ro.product.model=SGH-M919
ro.product.name=jfltetmo
ro.product.device=jfltetmo
Reboot your device, open the Dropbox app, and log in with your existing account, or create a new account. You will receive an email, and after fulfilling 5 of the 7 tasks, you will receive the 48 GB promotional space. After fulfilling the tasks, you can restore your build.prop to its original state.
Attached Files:
http://d-h.st/fZJ
Click to expand...
Click to collapse
Worked great for me, thanks! I already had 12GB and had completed the 5 Getting Started steps long ago. When I signed into the DropBox app and got it setup, I suddenly had 60GB for 24months and an email from DropBox.
Here's the instructions I followed:
Cleared cache of, cleared data of, and uninstalled the DropBox app I already had.
Reminder: backup your build.prop
I ended up using this build.prop Editor. When you open it, use the menu key to make a backup before touching anything. Then scroll through and make the changes prescribed in the OP.
Downloaded the file attached in OP.
Extracted files using my computer to my internal sdcard. Possible to do this with apps on your phone (various file explorers or unzip programs), but I found it easier to just do it over USB/MTP.
Fired up ADB Shell - could also use a terminal emulator from the device, but do not use the "stop" command below if you are using an emulator on the device.
Performed the following commands (after running "adb shell" from a command line on the computer):
Code:
$ su
# mount -o rw,remount /system
# stop
# cp /sdcard/Dropbox.apk /system/app
# cp /sdcard/DropboxOOBE.apk /system/app
# cp /sdcard/com.dropboxpartner.jar /system/framework
# reboot recovery
Device rebooted into TWRP, where I used the Advanced menu to Fix Permissions.
Rebooted back into the System like normal.
Opened the DropBox app and signed in. Setup the camera sync again of course (awesome feature).
Checked my mail - Woot.
Used the build.prop editor to restore my build.prop
Closed the build.prop editor and re-opened. For some reason after restoring the backup, the restored changes were not reflected until I restarted the editor. Whatever, but it worked.
Worked for me:thumbup: Thanks! Now what to do after the two year promo period ends...
Sent from my SAMSUNG-SGH-I337 using xda app-developers app
I'm already up to 50GB on doing something like this before. I'm not sure if it'll work again but I'll give it a whirl sometime today. Will report back if I find myself up to 98GB.
Perfectly working.
Followed general instructions (used FX root explorer instead of Android Terminal for dropping apks in designated locations) and this worked just fine without a hitch. I appreciate the straightforward and simple instructions.
All I did was flash Wicked (T-Mobile ROM) then KTOONSEZ touchjizz kernel. After getting my free dropbox space, I flashed back.
Sent from my SGH-I337 using xda premium
lol same here with GOLD3N3Y3 rom; any non-ATT rom works if you DL and activate it. i have my own server so im letting everyone in my family use it for our stuff.
Slade8525 said:
lol same here with GOLD3N3Y3 rom; any non-ATT rom works if you DL and activate it. i have my own server so im letting everyone in my family use it for our stuff.
Click to expand...
Click to collapse
i can confirm that this works on vzw.
Thanks, worked great on my VZW S4.
Aou said:
Worked great for me, thanks! I already had 12GB and had completed the 5 Getting Started steps long ago. When I signed into the DropBox app and got it setup, I suddenly had 60GB for 24months and an email from DropBox.
Here's the instructions I followed:
Cleared cache of, cleared data of, and uninstalled the DropBox app I already had.
Reminder: backup your build.prop
I ended up using this build.prop Editor. When you open it, use the menu key to make a backup before touching anything. Then scroll through and make the changes prescribed in the OP.
Downloaded the file attached in OP.
Extracted files using my computer to my internal sdcard. Possible to do this with apps on your phone (various file explorers or unzip programs), but I found it easier to just do it over USB/MTP.
Fired up ADB Shell - could also use a terminal emulator from the device...
Performed the following commands:
Code:
$ su
# mount -o rw,remount /system
# stop
# cp /sdcard/Dropbox.apk /system/app
# cp /sdcard/DropboxOOBE.apk /system/app
# cp /sdcard/com.dropboxpartner.jar /system/framework
# reboot recovery
Device rebooted into TWRP, where I used the Advanced menu to Fix Permissions.
Rebooted back into the System like normal.
Opened the DropBox app and signed in. Setup the camera sync again of course (awesome feature).
Checked my mail - Woot.
Used the build.prop editor to restore my build.prop
Closed the build.prop editor and re-opened. For some reason after restoring the backup, the restored changes were not reflected until I restarted the editor. Whatever, but it worked.
Click to expand...
Click to collapse
Using terminal emulator, after using #stop, device screen goes black... what do I do, just wait?
Cinosinu said:
Using terminal emulator, after using #stop, device screen goes black... what do I do, just wait?
Click to expand...
Click to collapse
You need to do it from your computer terminal/shell using adb shell command through the USB, not using a terminal emulator on the device. Stop does exactly what it says, it stops the device from running I think , or maybe just pauses.
You should be able to copy the files without stop though, it's probably riskier, and then you need to use reboot. You just need to copy the files into the right locations and then fix the permissions.
Cinosinu said:
Using terminal emulator, after using #stop, device screen goes black... what do I do, just wait?
Click to expand...
Click to collapse
These are linux commands. Stop, stops your device, and you cannot use it unless you reboot it. You can punch in the commands through your computer (this way, you need to install android sdk. Then, open the installed folder, and go to sdk\platform-tools. Here, you should hold shift, right click and select "open command window here", and punch the commands). Also, you can simply use a root explorer, and manually move the files to their folders and fix permissions
Just pull the battery and reboot. It happened to me also.
Sent from my SGH-M919 using xda premium
smnfriend said:
Also, you can simply use a root explorer, and manually move the files to their folders and fix permissions
Click to expand...
Click to collapse
What does this mean? I have ES fie explorer, trying to move the files I get a rewrite error. Do i need to fix the permissions first? What is the adb command?
thanks
I got it!!! :victory:
Why didn't someone tell me you must use the command 'ADB Shell' to start?
I'm no expert with ADB obviously. Knew it was something trivial. Hope someone else finds my comment helpful. :highfive:
Thank you OP and all! XDA rocks!
Thanks for pointing these things out. Yes, "stop" should only be used if doing this from an ADB shell. I've updated my instructions a tad bit to reflect this.
How can i do this for multiple accounts? I logged out and in and no luck.
Sent from my SGH-M919 using xda premium
kalparker said:
How can i do this for multiple accounts? I logged out and in and no luck.
Sent from my SGH-M919 using xda premium
Click to expand...
Click to collapse
did you do a factory reset, re-install of your ROM, then the steps again? that may help by giving you a different device ID (you may have had this warning before in TiBU), which i'm guessing DB is looking for to limit 1 upgrade per device ID.
-rf
xrabbitfootx said:
did you do a factory reset, re-install of your ROM, then the steps again? that may help by giving you a different device ID (you may have had this warning before in TiBU), which i'm guessing DB is looking for to limit 1 upgrade per device ID.
-rf
Click to expand...
Click to collapse
That might work. In TiBu, I have the option to create a new, random device ID - might be a Pro feature only. Check your menu key, and near the bottom you can Manager your Device ID...
I would advise a nandroid backup first - this may screw up some of your other accounts, including Google. I've personally never tried it, but I would imagine it could cause some amount of chaos.
thanks!

[Titanium Backup] Failed to protect backup

Tried every method...but I'm unable you protect my backups in titanium backup
To protect*
How I solved this problem on my Moto G LTE
Shantanu Baviskar said:
Tried every method...but I'm unable you protect my backups in titanium backup
Click to expand...
Click to collapse
I carefully read this thread: [Help] Titanium Backup PRO - protected archive not working.
So I modified file /system/etc/permissions/platform.xml according http://jrummy-apps.com/fix-sdcard-on-kitkat/ and make new file /data/local/userinit.sh with this content:
Code:
#!/system/bin/sh
busybox mount -o remount,rw /
chmod 770 /mnt/media_rw
See the attached archive root.zip which I made for you it is pretty straightforward.
You should have move your TiB backup folder on this path: /mnt/media_rw/sdcard1/TitaniumBackup
You will be able to protect backup archives in Titanium Backup Pro then.
PS: If /data/local/userinit.sh doesn't start automatically in your ROM you can use for example Scripter feature in ROM Toolbox Pro and import userinit.sh script and set it as Start at boot.
_jis_ said:
I carefully read this thread: [Help] Titanium Backup PRO - protected archive not working.
So I modified file /system/etc/permissions/platform.xml according http://jrummy-apps.com/fix-sdcard-on-kitkat/ and make new file /data/local/userinit.sh with this content:
Code:
#!/system/bin/sh
busybox mount -o remount,rw /
chmod 770 /mnt/media_rw
See the attached archive root.zip which I made for you it is pretty straightforward.
You should have move your TiB backup folder on this path: /mnt/media_rw/sdcard1/TitaniumBackup
You will be able to protect backup archives in Titanium Backup Pro then.
PS: If /data/local/userinit.sh doesn't start automatically in your ROM you can use for example Scripter feature in ROM Toolbox Pro and import userinit.sh script and set it as Start at boot.
Click to expand...
Click to collapse
Although in the case of Note 4 it didn't work right off the bat, I made it work a little different thanks to your idea. For some weird reason the script just doesn't get executed at boot (neither the *.sh file, nor as a script, through ROM Toolbox) but I was able to use the 2 lines in the script and made a task (in Tasker) which executes the shell command at boot. Everything else is straight forward and TiBu can now protect backups.
As a mention for those interested in replicating all these: the suggested SD card fix made by rummy applies EXACTLY the same changes as the SDFix so you can use either of them. Again, thanks for your reply and the great idea! :good:
nacos said:
I was able to use the 2 lines in the script and made a task (in Tasker) which executes the shell command at boot. Everything else is straight forward and TiBu can now protect backups.
Click to expand...
Click to collapse
Great, this is another example how to execute script at boot
I solved this problem on all my phones (Moto G LTE and Samsung Galaxy Note 2 and Samsung Galaxy W) but not on my tablet Nexus 7 2013 nor on internal emulated SD card nor on attached OTG USB flash disk. This is example where pure Stock Google Android ROM sucks
_jis_ said:
Great, this is another example how to execute script at boot
I solved this problem on all my phones (Moto G LTE and Samsung Galaxy Note 2 and Samsung Galaxy W) but not on my tablet Nexus 7 2013 nor on internal emulated SD card nor on attached OTG USB flash disk. This is example where pure Stock Google Android ROM sucks
Click to expand...
Click to collapse
This update addresses the issue mentioned before about init'd scripts not executing at boot. OK, here is the issue (specific to Qualcomm's Snapdragon) and the working solution - thanks to alexndr. I've tested it and it's working, however it doesn't work directly with <X.sh> text files, instead the script must be packaged in a flashable zip and flashed from recovery. Once I did that, it worked like a charm! The 98mediarw file in the screenshot uses the same script as previously mentioned; The 98 before the file name assigns a higher execution priority - I used 98 for testing purposes, it clearly doesn't need that. :good:
nacos said:
OK, here is the issue (specific to Qualcomm's Snapdragon) and the working solution - thanks to alexndr.
Click to expand...
Click to collapse
Oh, at first I thought that you post something what helps me with my tablet:
_jis_ said:
I solved this problem on all my phones but not on my tablet Nexus 7 2013 nor on internal emulated SD card nor on attached OTG USB flash disk.
Click to expand...
Click to collapse
But this is just another example how to execute script at boot
none of these methods are working. Is it because I'm using a Custom ROM?
What are you trying to achieve? What exactly is your environment?
nacos said:
What are you trying to achieve? What exactly is your environment?
Click to expand...
Click to collapse
I have Motorola Moto E (CM11 Stable build by percy_g2) and I'm trying to protect my backups in TiB but I'm getting error "Sorry, the operation failed." It used to be the same in stock ROM. And one more question, is this bug fixed in Lollipop versions of Android?
To answer you questions, no, this is not a bug, it's by design, also it's not happening because you're using a custom ROM, but rather because all OEM's (Google being probably the worst of all) are pushing towards more and more restrictive software & hardware environments, also supported by laws meant to discourage the users from modifying original configurations. Why? Dirty politics, I won't get into that but if you keep your eyes wide open you'll see and understand A LOT! Oh, by the way...to expect for Lollipop to be less restrictive and more fun (to customize) would be naive! Nuff said, let's have some fun!
There are multiple parts to this fix/diagnostic. Don't skip any point and follow these instructions rigorously, otherwise it won't work!!! Let's take them one by one:
Is you platform.xml file (under system/etc) modified to allow read/write access to media_rw (mnt/media_rw)? If not, apply the patch using SDFix from Google Store.
TiBu backup folder must be set to mnt/media_rw/externalSD/Titaniumxxx (if you don't have externalSD than use your internal storage instead, pointing to TiBu folder) - but, for right now, you won't be able to set this path because currently TiBu doesn't have access to media_rw, due to media_rw not being given the right permissions by the system. That's exactly what mediarw script does.
In order for init.d to execute the mediarw script at every boot, you need to insure that you do have init.d support AND it's working. This is how you verify:
(3a) Do you see the folder system/etc/init.d? If yes, go to (3b), if no, you don't have init.d support! That's another fix entirely.
(3b) If you see the 00test file in the init.d folder navigate to /data and open up the file called Test.log - that tells you that init.d is installed and working. If you have a Qualcomm's Snapdragon and you do have the init.d folder but it doesn't execute any script at boot, see the fix in post #6.
(3c) If you don't care about setting up init.d support, you can still run the script at boot, as a shell command using Tasker - see post #4
Once you're sure that all the above are set correctly, flash the attached file from recovery. Reboot, navigate to system/etc/init.d and confirm the presence of the mediarw script in the init.d folder
Reboot again, then navigate to mnt/media_rw and check that permissions for media_rw have been set to 770 - :fingers-crossed: mission accomplished, my friend! :fingers-crossed: If, on the other hand, the permissions for media_rw are still set at 700, then something went wrong. Go back and check every step again, otherwise...
Open up TiBu, set the backup folder path as instructed in #2 and verify that your backups can be protected. Voila!!
nacos said:
To answer you questions, no, this is not a bug, it's by design, also it's not happening because you're using a custom ROM, but rather because all OEM's (Google being probably the worst of all) are pushing towards more and more restrictive software & hardware environments, also supported by laws meant to discourage the users from modifying original configurations. Why? Dirty politics, I won't get into that but if you keep your eyes wide open you'll see and understand A LOT! Oh, by the way...to expect for Lollipop to be less restrictive and more fun (to customize) would be naive! Nuff said, let's have some fun!
There are multiple parts to this fix/diagnostic. Don't skip any point and follow these instructions rigorously, otherwise it won't work!!! Let's take them one by one:
Is you platform.xml file (under system/etc) modified to allow read/write access to media_rw (mnt/media_rw)? If not, apply the patch using SDFix from Google Store.
TiBu backup folder must be set to mnt/media_rw/externalSD/Titaniumxxx (if you don't have externalSD than use your internal storage instead, pointing to TiBu folder) - but, for right now, you won't be able to set this path because currently TiBu doesn't have access to media_rw, due to media_rw not being given the right permissions by the system. That's exactly what mediarw script does.
In order for init.d to execute the mediarw script at every boot, you need to insure that you do have init.d support AND it's working. This is how you verify:
(3a) Do you see the folder system/etc/init.d? If yes, go to (3b), if no, you don't have init.d support! That's another fix entirely.
(3b) If you see the 00test file in the init.d folder navigate to /data and open up the file called Test.log - that tells you that init.d is installed and working. If you have a Qualcomm's Snapdragon and you do have the init.d folder but it doesn't execute any script at boot, see the fix in post #6.
(3c) If you don't care about setting up init.d support, you can still run the script at boot, as a shell command using Tasker - see post #4
Once you're sure that all the above are set correctly, flash the attached file from recovery. Reboot, navigate to system/etc/init.d and confirm the presence of the mediarw script in the init.d folder
Reboot again, then navigate to mnt/media_rw and check that permissions for media_rw have been set to 770 - :fingers-crossed: mission accomplished, my friend! :fingers-crossed: If, on the other hand, the permissions for media_rw are still set at 700, then something went wrong. Go back and check every step again, otherwise...
Open up TiBu, set the backup folder path as instructed in #2 and verify that your backups can be protected. Voila!!
Click to expand...
Click to collapse
(Please ignore that screenshot. I didn't properly read your msg in blue text)
I couldn't understand post #4 so can you please describe it more deeply? :crying: btw I don't have 00test but a file named 00banner. And can you tell me how to use tasker properly?
Sorry for butting in on this thread. I found it by searching because I too can no longer protect a backup in my tibu Pro. I used to be able to but not anymore and I'm not sure why.
I'm on a rooted nexus 5 running stock 4.4.4.
Reading your instructions I went looking for platform.xml and found it. When I checked its properties I got, see screenshot. Don't know what to modify to mount it as you say. I'm in ES Explorer.
Can you help?
Thanks.
And here is a screenshot in root Explorer
Update your tb to 7.0.1 and now you can protect backups ? this thread should get closed now
Closed? Why? Just because a shortcut is available doesn't mean there is nothing to learn from wondering around, my friend!
After all, this is exactly what XDA is: a huge data base available to those who are willing to learn and dare to wonder around, wouldn't you agree?

Categories

Resources