[Android Software/Hacking General [Developers Only]] zroice:
Hey guys, I'm trying to get openpdroid on my "stock" (i mean unmodified) AOKP 4.1.2 rom.

I loaded the rom directly from aokp.co - its the Jellybean Milestone 1 for the Samsung Galaxy Note.

I tried quite a few things already but when I apply the patch the com.android.phone process keeps chaincrashing.

---

So far I tried:

1.

autopatching

... apply framework.patch ...
1 out of 77 hunks FAILED -- saving rejects to file smali/com/android/internal/telephony/cdma/CdmaServiceStateTracker.smali.rej
1 out of 5 hunks FAILED -- saving rejects to file smali/com/android/internal/telephony/gsm/GsmServiceStateTracker.smali.rej

There I tried both "yes" and "no" when asked if those files should be replaced with prepatched ones - no help. (com.android.phone chaincrash)

Also: All hunks failing on mms.apk "HttpUtils" (but the patcher says this is alright and the file will get replaced by a prepatched one)

2.

I "fixed" the patches manually by going through the reject files and comparing, there were two constants which had different values than expected by the patch.

For CdmaServiceStateTracker:

(Original code in framework.patch starting at line 44412)

- const v24, 0x1040116
+ const v25, 0x1040116

The original GsmServiceTracker.smali of my rom actually has the value "0x1040115" (1 less) but is exactly as expected by the patch on the rest. So I changed this in all possible ways (both retaining original value and overwriting it with "0x1040116")

For GsmServiceTracker.smali:

(Original code in framework.patch starting at line 48486)

- const v9, 0x1040323
+ const v10, 0x1040323

The original GsmServiceTracker.smali of my rom actually has the value "0x1040322" (1 less) but is exactly as expected by the patch on the rest. So I changed this in all possible ways (both retaining original value and overwriting it with "0x1040323")

---

With those changes the patcher would apply the framework.patch without any hunks failing, but still the com.android.phone keeps crashing when I patch it?!

This is weird - AOKP 4.1.2 should be supported or? The differences between the expected and the actual files where the patching failed is both only 1 digit in a constant... this shouldnt be causing a complete crash of com.android.phone or?

Unfortunately I'm a noob with smali - all the patch fixing I did was done by simple comparing the files by hand where I found this "constant" differences.

I hope someone who has a bit more experience could have a look or has an idea what may cause this behaviour?

---

The absolute funniest thing is that I also tried patching an unofficial AOKP 4.2.2 release for my Note - and there it works np. (1 hunk fails but when using the prepatched files it actually works). But unfortunately I hate those changes they did to AOKP in 4.2.2 so I would love to use openpdroid on AOKP 4.1.2 on my note.

(If you know a prepatched AOKP 4.1.2 rom for the Galaxy Note N7000 I'd also use that - but I didn't find any, and all those custom roms aren't patchable either - like Jellybam or Stunner 2)

--

Sorry for the long post but I had been trying to get openpdroid running on my note for quite a while now - even stepped back from customized rom to unmodified official releases of AOKP in hopes to get it running - but no luck.

Me need Halp!

--------

Here is an already modified version of the framework.patch (which retains the original constant values of the rom)

http://www.multiupload.nl/OSHJL6L7N1

And here the rom I'm trying to patch (JB Milestone 1 - 4.1.2):

http://aokp.co/supported-devices/?id=18&device=n7000