yashsingh1/xdaforums huggingface dataset:
[Android Software/Hacking General [Developers Only]] leoschabel:
I ran this on my CM9 rom (pdroid_addon), but it failed (Status 6).

It looks like the setup script is incomplete:

mount("ext4", "EMMC", "/dev/block/mmcblk0p9", "/system");
package_extract_dir("system", "/system");
unmount("/system");
assert(package_extract_file("boot.img", "/tmp/boot.img"),

Removing the last line fixed this for me, but I guess this breaks the unsecure boot.img patch ;)
[Android Software/Hacking General [Developers Only]] pastime1971:
indeed it is incomplete.

boot.img part is generated by taking one line containing "boot.img", but it looks like yours is more than one line.

it should have looked like

package_extract_file("boot.img", "/dev/block/platform/omap/omap_hsmmc.0/by-name/boot");

or similar (not exactly same, since it is device-specific)

could you post a link to the rom ?

---------- Post added at 08:30 AM ---------- Previous post was at 08:28 AM ----------

also the same issue, i guess.

can you post a link to the rom ?

i only need to see META-INF/com/google/android/updater-script
[Android Software/Hacking General [Developers Only]] mateorod:
Thanks for the error report. Your post is a thing of beauty. Your problem with the boot.img is that the unpackboot.img binary isn't working for you. I will look into that, it may be that you need another dependency to run those binaries, or even that I may need to track down and include a different version of that tool for 32 bit OS.

But a bigger problem for you is that the patches just aren't going to work for that ROM. I haven't even begun to look at HTC aosp. Touchwiz is next on my list with sense hopefully to follow. Although I a, not sure we will ever be able to support those. We will see.

I will look into getting a working binary for you in the event you want to try on a CM10 unofficial build.
[Android Software/Hacking General [Developers Only]] thibz:
same probleme here, even after installing cpio for windows, andre-installing cygwin

http://gnuwin32.sourceforge.net/packages/cpio.htm
[Android Software/Hacking General [Developers Only]] pastime1971:
thanks,

try to edit the line # 368 in auto_patcher script file from

[B][ -n $BOOTIMG ][/B] && cat META-INF/com/google/android/updater-script | grep "boot.img" [B][COLOR="Red"]| head -n 1[/COLOR][/B] >> updater-script

to

[B][[ -n $BOOTIMG ]][/B] && cat META-INF/com/google/android/updater-script | grep "boot.img" >> updater-script
[Android Software/Hacking General [Developers Only]] CaptHilts:
having the problem with 1.95 test. I'm running ArchLinux (primary system, no VM) and this error occurs for the first time - never had any issues with previous versions of the patcher. I just get the add info:

The Auto-Patcher v1.9.5

### verify tools ###

which: no cpio in (/usr/local/bin:/usr/bin:/bin:/usr/local/sbin:/usr/sbin:/sbin:/usr/bin/core_perl)

!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

!!! error: Missing "cpio (JRE)"

!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

However, I for one didn't install anything additionally. Does the upcoming version(s) of the patcher require cpio? Logfile doesn't show much except for the location of the rom and verifying tools. I use openJDK instead of java
[Android Software/Hacking General [Developers Only]] anomalya:
Ran into similar problem but was addressed for Cygwin; so I tried the Cygwin method and it worked.
[Android Software/Hacking General [Developers Only]] thibz:
Oh OK thanks, i didnt understand that cpio had to be setup with cgwin.

It works now but

... apply preloaded.patch ...

!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

!!! error: failed framework.patch

!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
[Android Software/Hacking General [Developers Only]] karamelos:
Great's, install update.zip work fine

but now :

I/ActivityManager( 2037): Process com.google.process.gapps (pid 4951) has died.

i look to late this error (i reinstalled gapps (easy way) but it's not the solution ....)

thank's for your solution
[Android Software/Hacking General [Developers Only]] wbedard:
Sorry for the abbreviated post...I was getting pretty tired! Per your's and mateorod's request, I have attached the requested files and am providing the following platform info:

OS: Windows 7 (64-bit)

Java: 1.7.0_05 SDK (64-bit)

I'm downloading some additional ROMs (AOSP JB based...) that I want to test. If I find any other unusual cases, I will post the corresponding info. Thanks again for all your effort with this!
[Android Software/Hacking General [Developers Only]] baka2x:
I tried patching AOKP jb build 1 for the Galaxy Nexus GSM and it failed. I also tried it by manually selecting the date of my patch set and it failed as well.

OS: Ubuntu 12.04 32bit

Java: openjdk-7-jre 7~u3-2.1.1~pre1-1ubuntu3

Log files attached.
[Android Software/Hacking General [Developers Only]] wbedard:
Here's another AOSP-JB ROM (Pure Vanilla AOSP Jelly Bean, http://xdaforums.com/showthread.php?t=1813185) that also makes a clean run before hanging up around the ramdisk. Again, my system is as follows:

OS: Windows 7 (64-bit)

Java: 1.7.0_05 SDK (64-bit)
[Android Software/Hacking General [Developers Only]] wbedard:
In addition to my follow-up posts above, I got around to actually reviewing the log files to see what might be going on. In short, there appears to be something wrong with the "unpackbootimg" executable. Running "file" on it shows that it appears to be a standard 32-bit ELF binary:

$ file patch_tools/boot/unpackbootimg

patch_tools/boot/unpackbootimg: ELF 32-bit LSB executable, Intel 80386, version 1 (SYSV),

dynamically linked (uses shared libs), for GNU/Linux 2.6.9, not stripped

However, reading someone's comments about possible dependency problems, running "ldd" against that file shows:

$ ldd patch_tools/boot/unpackbootimg

ldd: patch_tools/boot/unpackbootimg: Exec format error

Are we simply dealing with a slightly corrupted executable here?
[Android Software/Hacking General [Developers Only]] mateorod:
You are mimicing the exact things I am doing at my computer right now, it is a problem with the binary. I don't think it is corrupted though, although perhaps you are right. There is a package I installed that allows 64 bit machines to run this binary, although since I am not at the computer I ran that on, i don't remember it at the moment.

Edit: I think it is ialibs32. Can you try installing this package, please?

Update: That is, if you can find it..I am not sure if/how to get that package in Cygwin, I am not very experienced with Windows cross-compatibility stuff...

It is installed over the course of building ROMs from source, so some people will hae it already, while others don't.

You can look for a different version of that binary and replace the one in your patch_tools tgz if you are up for some testing...I will also look around. Probably the best solution is for me to divine the dependency to run these 32 bit binaries on 64 bit non-build environment set-ups...I will try and find it and add it to the dependency list.

There are some different options for unpacking boot.img, including some perl scripts that are floating around. But the binary is probably our best bet, because it brings out a real wealth of information that we use to repack boot.img for varying devices.

If you look in the auto_patcher script, you will see that we probe the base, filesize and cmdline variables for each boot.img. Without those, certain devices boot.img won't successfully repack. We were trying to keep the repack working for any device is was needed for.

Thanks to everyone for all their reports! This was a big update for us, and because of all the new features we are trying to incorporate, we knew there could be some hiccups...thanks for the patience, we are doing our best to bang the program into shape.
[Android Software/Hacking General [Developers Only]] scutworker:
Thanks for your help, it's appreciated. I'm going to stick with the ROM that I use at the moment, but will certainly consider anything you can rustle up.

Cheers,
[Android Software/Hacking General [Developers Only]] anomalya:
Here's my experience with the new test build above:

1) Used Cygwin (Windows 7 x86) to patch this custom AOKP 4.0.4 ROM.

2) First error encountered with a "Missing: cpio (JRE)," but is amended with mateorod's fix here. (Thanks!)

3) Patch successful with simultaneous PDroid, V6, and Add-on mods (that is, I got the restore/update zips).

- Had to omit Insecure mod because I was unsure when asked by this:

The text leading up to this was:
--------------------------
|diff -Npru ramdiskstock/default.prop ramdisk/default.prop
|--- ramdiskstock/default.prop 2012-08-17 22:49:47.937611241 -0500
|+++ ramdisk/default.prop 2012-08-17 22:50:54.333940482 -0500
--------------------------
File to patch:

Seems like a straightforward answer but I couldn't take any risks, so I left it out.

In terms of my initial testing with the apps/mods themselves:

1) V6

It seems to work. I can run the latest scripts in terminal per zeppelinrox's thread. However, I can only get it to 50% supercharged because I am missing ADJ entries patch for services.jar.

I understand this test build addresses this specifically:

But for some reason, I am getting inconsistencies. I've even tried every manual fix to update/override the services.jar from zeppelinrox's thread but to no avail. I understand because the services.jar is already patched (as expected) yet it doesn't comply with the V6 script? Am I to assume the V6 is already supercharged as intended despite the 50% rating?

2) PDroid Add_On

Installed app per CollegeDev's thread. Upon use, I get a FC each time I click "Apply rules" for any app. Doesn't this test build apply the required patches automatically or am I missing something else?

3) PDroid/Misc.

Other than the occasional random reboot (this may be more V6-related), I haven't come across any issues directly related to PDroid.

I can't thank you guys enough for your work. This is my first taste with PDroid/V6 on my phone and I am this much closer to a faster, safer, more private experience.
[Android Software/Hacking General [Developers Only]] wbedard:
Cygwin is 32-bit only so there isn't (aka shouldn't...I didn't look beyond a quick Google search) such a package for it. Although I have a 64-bit Linux build VM just for building AOSP, I seem to be struggling to recall my password atm. If I can get in there though, I'll try to run autopatcher in that environment.
[Android Software/Hacking General [Developers Only]] mateorod:
Thanks for your time, for sure...this cross-compatibility stuff was a nice suprise a user helped us institute, not really either of our forte's.

I am working on a quick and dirty change to the script that will use some different tools for Cygwin users...The shell scripting is not my strong suit, so we'll see how it goes.

I will be interested to see if the program runs in your VM. I DID have to install the ia32libs to use this on a VM my wife's 64 Windows machine, thanks for the info re: Cygwin.
[Android Software/Hacking General [Developers Only]] wbedard:
LOL...I'm in the process of modding your script to use some other boot image tools, also! I'll let you know if I have success (it looks pretty straightforward...:>)

[Update] Finished up the mods to your script (current status = hackjob...) but it does run to completion generating the update and restore zip files. I'm getting pretty tired again so I'm going to call it quits tonight. Tomorrow, I'll have one more go through it (maybe pretty-up my changes...) and "sanity check" the zip files before I flash one. I hope to have good news...:>)
[Android Software/Hacking General [Developers Only]] pastime1971:
thanks for the detailed follow up.

i get the following in fedora 14 64 bit

$ file unpackbootimg
unpackbootimg: ELF 32-bit LSB executable, Intel 80386, version 1 (SYSV), dynamically linked (uses shared libs), for GNU/Linux 2.6.32, not stripped

$ ldd unpackbootimg
linux-gate.so.1 => (0x00324000)
libstdc++.so.6 => /usr/lib/libstdc++.so.6 (0x003dd000)
libm.so.6 => /lib/libm.so.6 (0x00a9f000)
libgcc_s.so.1 => /lib/libgcc_s.so.1 (0x005b0000)
libc.so.6 => /lib/libc.so.6 (0x4877a000)
/lib/ld-linux.so.2 (0x48759000)

to me, it sounds like you are missing some dependency, but i don't know why ldd fails.

edit: could you manually(?) check the existence of those dependency ? they are all 32 bit libraries.

edit: mateo, maybe we should think about compiling unpackbootimg and others as standalone ?
[Android Software/Hacking General [Developers Only]] wbedard:
Sorry for the confusion...the errors I reported were from a Cygwin environment. Haven't been able to test in a Linux VM, yet.
[Android Software/Hacking General [Developers Only]] pastime1971:
no confusion here.

cygwin must have those libraries somewhere, possibly very similar places such as /lib and /usr/lib

it would help me to figure out which shared lib is missing in cygwin.

i was able to static-link most of them, except libz.i686 on fedora 14.
[Android Software/Hacking General [Developers Only]] biglsd:
Have anybody working in 4.1.1 application?

I've CM10 on my SGSII and application shows me "BAD News: Your Android version is not supported"
[Android Software/Hacking General [Developers Only]] mateorod:
I ommitted a big bunch of your post, but thank you so much for the details. It is good to know that some thing are workig, we are mostly pleased with the update, but there is still work to do before it goes stable...

I haven't personally installed the PDroid Addon, but I think FC's are an issue that shouldn't be there...CollegeDev is on vacation, but we'll check it out.

The problems with your insecure patch are because we are going to have to change how we pack the boot.img tools. The questions about how Cygwin would handle the boot tools was the real reason we went to a test release first...pastime has some ideas as you see, and we should hopefully have a solution soon...it is only an issue for Windows users trying insecure or aosp-jb.

I am suprised by your report of the V6, if your patching went through, you should be able to have those ADJ values adjusted. I will investigate that personally tomorrow.

Thanks again for reporting back, this is how we can make the tool better.

You can use the 1.6 AutoPatcher linked in the OP. At this point, to avoid frustration, try it on an Unofficial build, ideally from 8-18 or earlier...
[Android Software/Hacking General [Developers Only]] Stylez Ray.:
Same error on same build on Windows. Prior builds patched nicely as mateorod mentioned when downloaded from here http://androtransfer.com/?developer=AOKP&folder=maguro.

Even using older Auto-Patcher doesn't work anymore on this build
[Android Software/Hacking General [Developers Only]] SecUpwN:
I've been building the PDroid-Patch for CM 10 Disarmed Toaster 0.1.4 successfully (no errors at all) and would love to share it with the community, but when applying it, my EVO 3D goes into bootloop. What's the solution?
[Android Software/Hacking General [Developers Only]] biglsd:
How abuit patching sources? I use my own build...
[Android Software/Hacking General [Developers Only]] karamelos:
Same here,

yesterday with pdroid_addon on paranoid v0.5 my gapps crash.

Today imilka realease cm10 paranoid i tested 1.5 , 1.6 & 1.9 autopatcher but i've got a great's bootloop .

I'm on ubuntu 12.04 (64)

java 1.7.0_06

framework

updater script
[Android Software/Hacking General [Developers Only]] tonyp:
Get some logcats from your bootloops, then they can narrow it down for you.
[Android Software/Hacking General [Developers Only]] mateorod:
State of the (Update) Union

Okay, everyone..thanks for your patience with all the recent errors...

We released the update to test some expanded functionality, with an eye on some specific operations we felt might have some cross-compatibility issues...Of course, that same day CM and AOKP began releasing official builds, which then broke our existing patches. When we tried to update them, there were problems. Those probelms were mostly unrelated to how the patcher works or how the update was coded..but they were/are still problems

I am releasing a new test_update: auto_patcher20120823v1.9.6.

DEPRECATED! Newer version available at our techerrata page.

This update includes fixes for:

Current Cyanogen10 Official builds can now be patched with the latest patches

If you are trying an Unofficial build, or a custom Rom based on CM sources and it doesn't patch, try the older patches like so:

./auto_patcher <YOUR ROMSNAME>.zip pdroid cm10 20120806

There is also a coding fix for the few of you who may have had a problem with the updater script and a patched boot.img.

These are the problems that still remain to be sorted, and where they currently stand

AOKP Build 1 still has no working patches. I made new patches on the latest source; no joy. I am building some clobber builds now, we will see how that goes.

PDroid_addon is not booting for some, maybe all people. Pastime is probably going to have to take a look at that

Cygwin users cannot successfully patch aosp-jb or insecure mods. This is related to Windows compatibility with the packaged boot tools binaries. Pastime is looking into a static-linked library to overcome this issue. We do have a plan B for this, should it become necessary.

This new test release mainly provides working patches for Pdroid for Official Cyanogen builds. We are hoping that this is helpful to a large number of you reporting problems.

The V6 Supercharger patches are CONFIRMED working.

Obviously there are a bunch of error reports. When we see something we can recomend a quick fix for, we are trying to do so. But as it stands we could run around all day following up on individual problems while never getting anywhere on the big problems we already know about. Be patient, nothing is going unnoticed. We are simply taking a top-down approach here.

For Best results

If you are new to the test release, familiarize yourself with usage/changes here.

For now, since there also seems to possibly be a change to CM/AOKP build.props, please indicate your ROMTYPE on the command-line as you execute the script. Follow the OP or the example above.

If you encounter issues, please do what you can to provide the info quoted here, and maybe add your build.prop. (excepting KNOWN ISSUES! i.e AOKP build 1, and Cygwin Boot.img patching. We are already working on those...)

If you are encountering boot loops, a logcat would be expecially useful.

Thanks to everyone who is chipping in with error reports and posts.

Nobody said getting your privacy back would be easy...:p
[Android Software/Hacking General [Developers Only]] karamelos:
;) ty
[Android Software/Hacking General [Developers Only]] anomalya:
Unfortunately, there's something that's breaking this for me. I've restored and patched the update twice now (this time with just pdroid,v6supercharger) with same results: the modified ADJ values/services.jar doesn't stick with V6.

Could it be there's something in this custom AOKP rom I'm using with its kernel/performance/boot tweaks and such that messes with the V6 operation?

This is exciting. I'll be looking forward to you and pastime's (relentless) progress soon. In the meantime, I can have this to play around with and see what I come across compared to the previous test build.

Conversely, I don't mind playing tester if you guys have any specific cygwin-related mods/patches/ directly aimed for our environment. :D
[Android Software/Hacking General [Developers Only]] karamelos:
My privacy come back

Pdroid come BACK :good:

the rom patched successfully	[JB:CM10:HYBRD] PARANOIDANDROID [1.991, True HybridMode, Size & UI on Per App Basis]

I rename the package rom with out underscore & point no option after pdroid command:

./auto_patcher pan7000199120AUG2012357189.zip pdroid

I but a "good" log (not see previous post :eek: ) for pdroid_addon when it come back

Great's job if you want good beer come at my home :p or pm me for address exporting
[Android Software/Hacking General [Developers Only]] testman86:
My "Thanks" are over so I wanted to say THANKS in this way :)

You did a REALLY great job. I was using your script with ICS 2 months ago under a linux VM and still following the thread!

It is a really awesome job for privacy what all you Devs did/do, I do not know how to thank you so gratefull I am. Keep the good work up! Really really THANKS a lot! :)

Edit: Sry for "spamming" in your conversation ^^
[Android Software/Hacking General [Developers Only]] mateorod:
OK, another update is up, thanks for the patience and kind words...

autopatcher20120823v1.9.7as been ftp'd to our techerrata page.

Added patches for AOKP Build 1, as aokp-jb latest. If you are patching a kang or unofficial build of aokp-jb or cm10, use the patches from 20120820.

Alll official CM10 builds and Aokp build 1's should patch.

If you flashed an Official CM10 update.zip made by v1.9.6, you should consider flashing a new one made by 1.9.7. I believe the patching process to be superior in 1.9.7 and should make for a more stable experience.

I wanted to keep this as a test build available only to those in the thread, but with the patches failing as soon as we went up, I realize that keeping it as a test was just inviting frustration and confusion. So the updates are now going back up to techerrata.

Known issues with 1.9.7

Pdroid_add on is not working correctly for some, maybe all.

Boot.img patching (aosp-jb and insecure mods) is not available for Cygwin users

The boot.img patching is on it's way to being fixed. Pdroid_addon still needs to be worked on.

So...

Once again, thanks to everyone who has tested/is testing. The troubles with the official builds may end up being a blessing in disguise, as the process of resolving those issues may have given me the clues I needed to widen our supported ROMs. We'll see.

We are slowly plugging the holes in this update, leading up to our release of auto_patcher 2.0!

We have some additional mods coming out and some further improvements to the program. Thanks to everyone who is actively making the autopatcher a better tool.

I have to go hit the sack, so be patient while the techerrata server updates. I put it up around 30 mins ago, so it should be available for download soon.
[Android Software/Hacking General [Developers Only]] nsmart:
Thanks for the quick updates. I am still on codeworkx experimental builds for my Galaxy S2 I9100. Pdroid does not compile for this rom (probably because it is no official nightly). Tried all patch versions with no luck up to now.

When I download and start autopatcher20120823v1.9.7 it still reports as version 1.9.6.

The auto_patcher script is from 2012-08-23 07:14 so I think it only shows the wrong version when starting. May cause confusion when people submit logs.

### apply services.patch ###
1 out of 7 hunks FAILED -- saving rejects to file smali/com/android/server/am/ActivityManagerService.smali.rej