[Android Software/Hacking General [Developers Only]] HotrodHarry:
I've managed to get autopatcherv2.8.6.zip to work on:

''cm-10.1-20130315-NIGHTLY-galaxysmtd.zip'' :D

But I'm getting the follwing on:

"Slim-I9000-4.2.2.build.2-OFFICIAL.zip" :crying:

Running autopatcher with the following arguments:

ROM_PATH: /cygdrive/e/Roms/Slim/4.2.2/build.1.1/Slim-I9000-4.2.2.build.1.1-OFFICIAL.zip

PATCH_TYPE: openpdroid

ROM_TYPE: cm

The Auto-Patcher v2.8.6

### verify tools ###

### verify ROM ###

### unzip patch tools ###

### unzip patch patches ###

inflated: system/build.prop

... result of ROM check: RIL= SamsungExynos3RIL

### probe rom type ###

... result of ROM check: version= 4.2.2 rom= aosp ...

... Using cm patches ...

... openpdroid patch date has been set to: 20130219 ...

### unzip rom ###

inflated: system/app/Mms.apk

inflated: system/framework/core.jar

inflated: system/framework/framework.jar

inflated: system/framework/services.jar

inflated: system/framework/telephony-common.jar

### create updater script ###

inflated: META-INF/com/google/android/update-binary

inflated: META-INF/com/google/android/updater-script

... using Clockworkmod installer ...

### create restore.zip ###

### decompile system files ###

... decompile framework.jar ...

... extract preloaded-classes ...

... decompile core.jar ...

... decompile services.jar ...

... decompile telephony-common.jar ...

... installing framework files ...

I: Framework installed to: C:\Users\Shane\apktool\framework\1.apk

... decompile Mms.apk ...

I: Baksmaling...

I: Loading resource table...

I: Loaded.

I: Decoding AndroidManifest.xml with resources...

I: Loading resource table from file: C:\Users\Shane\apktool\framework\1.apk

I: Loaded.

I: Regular manifest package...

I: Decoding file-resources...

I: Decoding values */* XMLs...

I: Done.

I: Copying assets and libs...

### copy patch openpdroid/4.2/cm/20130219 ###

... copying system/media/PDroid.jpeg ...

... overwriting ContentResolver.smali ...

### jar patch openpdroid/4.2/cm/20130219 ###

... apply framework.patch ...

... apply preloaded.patch ...

... apply core.patch ...

... apply services.patch ...

156 out of 158 hunks FAILED -- saving rejects to file smali/com/android/server/ServerThread.smali.rej

!!! PATCHING FAILED FOR com/android/server/ServerThread.smali !!!

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

!!! error: failed com/android/server/ServerThread.smali in services.jar cannot be remedied

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

usage: ./auto_patcher <ROM> <MODS> <ROMTYPE>

example: ./auto_patcher CM10.zip openpdroid cm

Use ./auto_patcher -h for the help menu

% Total % Received % Xferd Average Speed Time Time Time Current

Dload Upload Total Spent Left Speed

0 0 0 0 0 0 0 0 --:--:-- 0:00:02 --:--:-- 0

100 8956 100 237 100 8719 72 2653 0:00:03 0:00:03 --:--:-- 8564

100 8956 100 237 100 8719 72 2652 0:00:03 0:00:03 --:--:-- 8556

Running autopatcher with the following arguments:

ROM_PATH: /cygdrive/e/Roms/Slim/4.2.2/build.2/Slim-I9000-4.2.2.build.2-OFFICIAL.zip

PATCH_TYPE: openpdroid

ROM_TYPE: cm

The Auto-Patcher v2.8.6

### verify tools ###

### verify ROM ###

### unzip patch tools ###

### unzip patch patches ###

inflated: system/build.prop

... result of ROM check: RIL= SamsungExynos3RIL

### probe rom type ###

... result of ROM check: version= 4.2.2 rom= aosp ...

... Using cm patches ...

... openpdroid patch date has been set to: 20130219 ...

### unzip rom ###

inflated: system/app/Mms.apk

inflated: system/framework/core.jar

inflated: system/framework/framework.jar

inflated: system/framework/services.jar

inflated: system/framework/telephony-common.jar

### create updater script ###

inflated: META-INF/com/google/android/update-binary

inflated: META-INF/com/google/android/updater-script

... using Clockworkmod installer ...

### create restore.zip ###

### decompile system files ###

... decompile framework.jar ...

... extract preloaded-classes ...

... decompile core.jar ...

... decompile services.jar ...

... decompile telephony-common.jar ...

... installing framework files ...

Exception in thread "main" brut.androlib.AndrolibException: Multiple resources: spec=0x0108006c drawable/progress_horizontal, config=[DEFAULT]

at brut.androlib.res.data.ResConfig.addResource(ResConfig.java:65)

at brut.androlib.res.data.ResConfig.addResource(ResConfig.java:58)

at brut.androlib.res.decoder.ARSCDecoder.readEntry(ARSCDecoder.java:201)

at brut.androlib.res.decoder.ARSCDecoder.readConfig(ARSCDecoder.java:170)

at brut.androlib.res.decoder.ARSCDecoder.readType(ARSCDecoder.java:135)

at brut.androlib.res.decoder.ARSCDecoder.readPackage(ARSCDecoder.java:110)

at brut.androlib.res.decoder.ARSCDecoder.readTable(ARSCDecoder.java:83)

at brut.androlib.res.decoder.ARSCDecoder.decode(ARSCDecoder.java:49)

at brut.androlib.res.decoder.ARSCDecoder.decode(ARSCDecoder.java:40)

at brut.androlib.res.AndrolibResources.installFramework(AndrolibResources.java:562)

at brut.androlib.Androlib.installFramework(Androlib.java:473)

at brut.apktool.Main.cmdInstallFramework(Main.java:250)

at brut.apktool.Main.main(Main.java:81)

... decompile Mms.apk ...

I: Baksmaling...

I: Loading resource table...

Exception in thread "main" brut.androlib.AndrolibException: Multiple resources: spec=0x7f020242 drawable/listitem_background, config=[DEFAULT]

at brut.androlib.res.data.ResConfig.addResource(ResConfig.java:65)

at brut.androlib.res.data.ResConfig.addResource(ResConfig.java:58)

at brut.androlib.res.decoder.ARSCDecoder.readEntry(ARSCDecoder.java:201)

at brut.androlib.res.decoder.ARSCDecoder.readConfig(ARSCDecoder.java:170)

at brut.androlib.res.decoder.ARSCDecoder.readType(ARSCDecoder.java:135)

at brut.androlib.res.decoder.ARSCDecoder.readPackage(ARSCDecoder.java:110)

at brut.androlib.res.decoder.ARSCDecoder.readTable(ARSCDecoder.java:83)

at brut.androlib.res.decoder.ARSCDecoder.decode(ARSCDecoder.java:49)

at brut.androlib.res.AndrolibResources.getResPackagesFromApk(AndrolibResources.java:491)

at brut.androlib.res.AndrolibResources.loadMainPkg(AndrolibResources.java:74)

at brut.androlib.res.AndrolibResources.getResTable(AndrolibResources.java:66)

at brut.androlib.Androlib.getResTable(Androlib.java:50)

at brut.androlib.ApkDecoder.getResTable(ApkDecoder.java:189)

at brut.androlib.ApkDecoder.decode(ApkDecoder.java:114)

at brut.apktool.Main.cmdDecode(Main.java:146)

at brut.apktool.Main.main(Main.java:77)

### copy patch openpdroid/4.2/cm/20130219 ###

... copying system/media/PDroid.jpeg ...

... overwriting ContentResolver.smali ...

### jar patch openpdroid/4.2/cm/20130219 ###

... apply framework.patch ...

1 out of 9 hunks FAILED -- saving rejects to file 'smali/android/provider/Settings$Secure.smali.rej'

... apply preloaded.patch ...

!!! PATCHING FAILED FOR android/provider/Settings$Secure.smali' !!!

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

!!! error: failed android/provider/Settings$Secure.smali' in framework.jar cannot be remedied

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

usage: ./auto_patcher <ROM> <MODS> <ROMTYPE>

example: ./auto_patcher CM10.zip openpdroid cm

Use ./auto_patcher -h for the help menu

curl: (6) Couldn't resolve host 'codepad.org'

Running autopatcher with the following arguments:

ROM_PATH: /cygdrive/e/Roms/CM10.1/4.2.2/cm-10.1-20130315-NIGHTLY-galaxysmtd.zip

PATCH_TYPE: openpdroid

ROM_TYPE: cm

The Auto-Patcher v2.8.6

### verify tools ###

### verify ROM ###

### unzip patch tools ###

### unzip patch patches ###

inflated: system/build.prop

... result of ROM check: RIL= SamsungExynos3RIL

### probe rom type ###

... result of ROM check: version= 4.2.2 rom= cm ...

... Using cm patches ...

... openpdroid patch date has been set to: 20130219 ...

### unzip rom ###

inflated: system/app/Mms.apk

inflated: system/framework/core.jar

inflated: system/framework/framework.jar

inflated: system/framework/services.jar

inflated: system/framework/telephony-common.jar

### create updater script ###

inflated: META-INF/com/google/android/update-binary

inflated: META-INF/com/google/android/updater-script

... using Clockworkmod installer ...

### create restore.zip ###

### decompile system files ###

... decompile framework.jar ...

... extract preloaded-classes ...

... decompile core.jar ...

... decompile services.jar ...

... decompile telephony-common.jar ...

... installing framework files ...

I: Framework installed to: C:\Users\Shane\apktool\framework\1.apk

... decompile Mms.apk ...

I: Baksmaling...

I: Loading resource table...

I: Loaded.

I: Decoding AndroidManifest.xml with resources...

I: Loading resource table from file: C:\Users\Shane\apktool\framework\1.apk

I: Loaded.

I: Regular manifest package...

I: Decoding file-resources...

I: Decoding values */* XMLs...

I: Done.

I: Copying assets and libs...

### copy patch openpdroid/4.2/cm/20130219 ###

... copying system/media/PDroid.jpeg ...

... overwriting ContentResolver.smali ...

### jar patch openpdroid/4.2/cm/20130219 ###

... apply framework.patch ...

... apply preloaded.patch ...

... apply core.patch ...

... apply services.patch ...

... apply telephony-common.patch ...

1 out of 78 hunks FAILED -- saving rejects to file smali/com/android/internal/telephony/cdma/CdmaServiceStateTracker.smali.rej

Reversed (or previously applied) patch detected! Skipping patch.

15 out of 15 hunks ignored -- saving rejects to file 'smali/com/android/internal/telephony/RIL$RILSender.smali.rej'

!!! PATCHING FAILED FOR com/android/internal/telephony/cdma/CdmaServiceStateTracker.smali !!!

File for which patching failed:

---------------------------------------------

CdmaServiceStateTracker.smali

---------------------------------------------

We can try to add a premade copy of those files.

This sometimes works.

You only need to report this if running the program gives you problems!!!

Do you want to proceed ? (YES/no) ... replace com/android/internal/telephony/cdma/CdmaServiceStateTracker.smali ...

### apk patch openpdroid/4.2/cm/20130219 ###

... apply Mms.apk.patch ...

### rebuild jar ###

... rebuild framework.jar ...

... rebuild core.jar ...

... rebuild services.jar ...

... rebuild telephony-common.jar ...

### rebuild apk ###

... rebuild Mms.apk ...

### create update-cm-GT-I9000-20130315-openpdroid.zip ###

### finished ###

flash update-cm-GT-I9000-20130315-openpdroid.zip to install the patched files

flash restore-cm-GT-I9000-20130315.zip to restore the original system

Running autopatcher with the following arguments:

ROM_PATH: /cygdrive/e/Roms/Slim/4.2.2/build.2/Slim-I9000-4.2.2.build.2-OFFICIAL.zip

PATCH_TYPE: openpdroid

ROM_TYPE: cm

The Auto-Patcher v2.8.6

### verify tools ###

### verify ROM ###

### unzip patch tools ###

### unzip patch patches ###

inflated: system/build.prop

... result of ROM check: RIL= SamsungExynos3RIL

### probe rom type ###

... result of ROM check: version= 4.2.2 rom= aosp ...

... Using cm patches ...

... openpdroid patch date has been set to: 20130219 ...

### unzip rom ###

inflated: system/app/Mms.apk

inflated: system/framework/core.jar

inflated: system/framework/framework.jar

inflated: system/framework/services.jar

inflated: system/framework/telephony-common.jar

### create updater script ###

inflated: META-INF/com/google/android/update-binary

inflated: META-INF/com/google/android/updater-script

... using Clockworkmod installer ...

### create restore.zip ###

### decompile system files ###

... decompile framework.jar ...

... extract preloaded-classes ...

... decompile core.jar ...

... decompile services.jar ...

... decompile telephony-common.jar ...

... installing framework files ...

Exception in thread "main" brut.androlib.AndrolibException: Multiple resources: spec=0x0108006c drawable/progress_horizontal, config=[DEFAULT]

at brut.androlib.res.data.ResConfig.addResource(ResConfig.java:65)

at brut.androlib.res.data.ResConfig.addResource(ResConfig.java:58)

at brut.androlib.res.decoder.ARSCDecoder.readEntry(ARSCDecoder.java:201)

at brut.androlib.res.decoder.ARSCDecoder.readConfig(ARSCDecoder.java:170)

at brut.androlib.res.decoder.ARSCDecoder.readType(ARSCDecoder.java:135)

at brut.androlib.res.decoder.ARSCDecoder.readPackage(ARSCDecoder.java:110)

at brut.androlib.res.decoder.ARSCDecoder.readTable(ARSCDecoder.java:83)

at brut.androlib.res.decoder.ARSCDecoder.decode(ARSCDecoder.java:49)

at brut.androlib.res.decoder.ARSCDecoder.decode(ARSCDecoder.java:40)

at brut.androlib.res.AndrolibResources.installFramework(AndrolibResources.java:562)

at brut.androlib.Androlib.installFramework(Androlib.java:473)

at brut.apktool.Main.cmdInstallFramework(Main.java:250)

at brut.apktool.Main.main(Main.java:81)

... decompile Mms.apk ...

I: Baksmaling...

I: Loading resource table...

Exception in thread "main" brut.androlib.AndrolibException: Multiple resources: spec=0x7f020242 drawable/listitem_background, config=[DEFAULT]

at brut.androlib.res.data.ResConfig.addResource(ResConfig.java:65)

at brut.androlib.res.data.ResConfig.addResource(ResConfig.java:58)

at brut.androlib.res.decoder.ARSCDecoder.readEntry(ARSCDecoder.java:201)

at brut.androlib.res.decoder.ARSCDecoder.readConfig(ARSCDecoder.java:170)

at brut.androlib.res.decoder.ARSCDecoder.readType(ARSCDecoder.java:135)

at brut.androlib.res.decoder.ARSCDecoder.readPackage(ARSCDecoder.java:110)

at brut.androlib.res.decoder.ARSCDecoder.readTable(ARSCDecoder.java:83)

at brut.androlib.res.decoder.ARSCDecoder.decode(ARSCDecoder.java:49)

at brut.androlib.res.AndrolibResources.getResPackagesFromApk(AndrolibResources.java:491)

at brut.androlib.res.AndrolibResources.loadMainPkg(AndrolibResources.java:74)

at brut.androlib.res.AndrolibResources.getResTable(AndrolibResources.java:66)

at brut.androlib.Androlib.getResTable(Androlib.java:50)

at brut.androlib.ApkDecoder.getResTable(ApkDecoder.java:189)

at brut.androlib.ApkDecoder.decode(ApkDecoder.java:114)

at brut.apktool.Main.cmdDecode(Main.java:146)

at brut.apktool.Main.main(Main.java:77)

### copy patch openpdroid/4.2/cm/20130219 ###

... copying system/media/PDroid.jpeg ...

... overwriting ContentResolver.smali ...

### jar patch openpdroid/4.2/cm/20130219 ###

... apply framework.patch ...

1 out of 9 hunks FAILED -- saving rejects to file 'smali/android/provider/Settings$Secure.smali.rej'

... apply preloaded.patch ...

!!! PATCHING FAILED FOR android/provider/Settings$Secure.smali' !!!

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

!!! error: failed android/provider/Settings$Secure.smali' in framework.jar cannot be remedied

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

usage: ./auto_patcher <ROM> <MODS> <ROMTYPE>

example: ./auto_patcher CM10.zip openpdroid cm

Use ./auto_patcher -h for the help menu

curl: (6) Couldn't resolve host 'codepad.org'

*****AP log*****

ROOT= /cygdrive/e/AutoPatcher/ApG/ApGPackages/ap

TOOL= /cygdrive/e/AutoPatcher/ApG/ApGPackages/ap/patch_tools.tgz

ROM= /cygdrive/e/Roms/Slim/4.2.2/build.2/Slim-I9000-4.2.2.build.2-OFFICIAL.zip

ROMX= E:\Roms\Slim\42DE8F~1.2\build.2\SLIM-I~1.ZIP

### verify tools ###

/cygdrive/e/AutoPatcher/ApG/ApGPackages/cygwin/bin/patch

/cygdrive/e/AutoPatcher/ApG/ApGPackages/cygwin/bin/tar

/cygdrive/e/AutoPatcher/ApG/ApGPackages/Java/bin/jar

/cygdrive/e/AutoPatcher/ApG/ApGPackages/Java/bin/java

/cygdrive/e/AutoPatcher/ApG/ApGPackages/cygwin/bin/cpio

### verify ROM ###

### running ./auto_patcher /cygdrive/e/Roms/Slim/4.2.2/build.2/Slim-I9000-4.2.2.build.2-OFFICIAL.zip openpdroid cm

PATH= /cygdrive/e/AutoPatcher/ApG/ApGPackages/ap/tmp20130320021324:/cygdrive/e/AutoPatcher/ApG/ApGPackages/Java/bin:/cygdrive/e/AutoPatcher/ApG/ApGPackages/cygwin/bin:/cygdrive/e/AutoPatcher/ApG/ApGPackages/cygwin/usr/sbin

### unzip patch tools ###

### unzip patch patches ###

... result of ROM check: RIL= SamsungExynos3RIL

### probe rom type ###

#### Standard Build Query ####

# VER= v2.8.6

# OS= cygwin 32bit

# VID= 4.2.2

# PID= openpdroid

# MID= JDQ39

# RID= cm

# ANDR= 4.2

# BDID= 20130315

# DID= GT-I9000

# BID= 20130219

Patches are openpdroid/4.2/cm/20130219

### DELETE FILES=

### COPY FILES= system/media/PDroid.jpeg

### JAR FILES= system/framework/framework.jar system/framework/core.jar system/framework/services.jar system/framework/telephony-common.jar

### APK FILES= system/app/Mms.apk

### IMG FILES=

### TXT FILES=

### unzip rom ###

### create updater script ###

... using Clockworkmod installer ...

# generated updater-script

ui_print("");

ui_print("");

ui_print("~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~");

ui_print("* *");

ui_print("* * The Auto-Patcher * *");

ui_print("* * * * * *");

ui_print("* * by mateor * *");

ui_print("* *");

ui_print("~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~");

ui_print("");

ui_print(" Attention");

ui_print(" ************************************");

ui_print("");

ui_print(" There is nothing that can go wrong here");

ui_print(" that reflashing your ROM won't fix.");

ui_print("");

mount("ext4", "EMMC", "/dev/lvpool/system", "/system");

package_extract_dir("system", "/system");

set_perm_recursive(0, 0, 0755, 0644, "/system");

set_perm_recursive(0, 0, 0755, 0755, "/system/addon.d");

set_perm_recursive(0, 2000, 0755, 0755, "/system/bin");

set_perm(0, 3003, 02750, "/system/bin/netcfg");

set_perm(0, 3004, 02755, "/system/bin/ping");

set_perm(0, 2000, 06750, "/system/bin/run-as");

set_perm(1002, 1002, 0440, "/system/etc/dbus.conf");

set_perm(1014, 2000, 0550, "/system/etc/dhcpcd/dhcpcd-run-hooks");

set_perm_recursive(0, 2000, 0755, 0755, "/system/etc/init.d");

set_perm(0, 0, 0755, "/system/etc/init.d");

set_perm(0, 2000, 0550, "/system/etc/init.goldfish.sh");

set_perm_recursive(0, 0, 0755, 0555, "/system/etc/ppp");

set_perm(0, 2000, 0755, "/system/vendor");

set_perm_recursive(0, 2000, 0755, 0755, "/system/vendor/bin");

set_perm_recursive(0, 2000, 0755, 0644, "/system/vendor/etc");

set_perm(0, 0, 0644, "/system/vendor/etc/gps.xml");

set_perm(0, 2000, 0755, "/system/vendor/firmware");

set_perm(0, 2000, 0755, "/system/vendor/lib");

set_perm(0, 2000, 0755, "/system/vendor/lib/egl");

set_perm(0, 2000, 0755, "/system/vendor/lib/hw");

set_perm_recursive(0, 2000, 0755, 0755, "/system/xbin");

set_perm(0, 0, 06755, "/system/xbin/librank");

set_perm(0, 0, 06755, "/system/xbin/procmem");

set_perm(0, 0, 06755, "/system/xbin/procrank");

set_perm(0, 0, 06755, "/system/xbin/su");

unmount("/system");

ui_print(" .");

ui_print(" .");

ui_print(" done!");

### create restore.zip ###

### decompile system files ###

... decompile framework.jar ...

... extract preloaded-classes ...

inflated: preloaded-classes

... decompile core.jar ...

... decompile services.jar ...

... decompile telephony-common.jar ...

inflated: system/framework/framework-res.apk

... installing framework files ...

... decompile Mms.apk ...

### copy patch openpdroid/4.2/cm/20130219 ###

... copying system/media/PDroid.jpeg ...

`patches/openpdroid/4.2/cm/20130219/system/media/PDroid.jpeg' -> `./system/media/PDroid.jpeg'

... overwriting ContentResolver.smali ...

### delete patch openpdroid/4.2/cm/20130219 ###

### jar patch openpdroid/4.2/cm/20130219 ###

... apply framework.patch ...

1 out of 9 hunks FAILED -- saving rejects to file 'smali/android/provider/Settings$Secure.smali.rej'

... apply preloaded.patch ...

!!! PATCHING FAILED FOR android/provider/Settings$Secure.smali' !!!

!!! patch error for android/provider/Settings$Secure.smali' !!!

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

!!! error: failed android/provider/Settings$Secure.smali' in framework.jar cannot be remedied

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