yashsingh1/xdaforums huggingface dataset:
[Android Software Development] Jeik:
i

am using miui for x8 cm9 for x8-my phone x8,base cm9,port miui x8

for "other phone" "a ics base rom"-"other phone,...

dont have time to explain,making my own right now

---------- Post added at 09:11 PM ---------- Previous post was at 08:59 PM ----------

where to get updater script on win xp?

---------- Post added at 09:14 PM ---------- Previous post was at 09:11 PM ----------

translate 0, 0, 06755 permission to read,write,execute format,please
[Android Software Development] IdeosDev:
I got the same problem and should i rename to PackageRedirectionMap*.smali ?
[Android Software Development] Lens_flare:
uhm? no need to rename it, just diff AssetManager 's .smali - s to add missing methods to miui.

META-inf folder in base rom.

number-by-number:

uid=0 - root

group=0 - system

folder group(if I'm not wrong)= 06 - something like rw-rwxrwx (should be constant for folders or you won't open them)

755=rwxr-xr-x

I'm bit noob on unix, but seems translated correctly, google to prove me ;p
[Android Software Development] pjgowtham:
How to log during phone boot?
[Android Software Development] Lens_flare:
plug your device in and issue:

adb logcat

I assume you have android sdk or somewhat containing adb binary and you exported its path so could issue adb like any other internal command(or you could just execute it in place by specifying its full path or cd to it).

most mere idea: you have wrong surfaceflinger :p

seems you are porting according your own guide, not OP's ;]
[Android Software Development] Kaze105:
Well, I never ported nor touched any file called surfaceflinger, unless it is in the framework, app or media folder. Also I did follow the OP guide completely.
[Android Software Development] medicjunKie:
http://www.mediafire.com/?17l4wq9qfrgbk8d

Ideas?
[Android Software Development] Lens_flare:
wow, it seems like some of system apps are broken.. but causer could be listed in log earlier, could we see a full log?
[Android Software Development] medicjunKie:
Yeah, i could get you the full log tomorrow morning. Is that fine?
[Android Software Development] Lens_flare:
no problem :D

of course, faster-better, and firstly for you, not for advice makers ;]
[Android Software Development] dhk.-:
where is this smali?
[Android Software Development] montuk:
its in services.jar
[Android Software Development] dhk.-:
hadware keys not working... somebody know hot to solve it?
[Android Software Development] Lens_flare:
maybe it's linked to your replaced smali.. but for me works after replacing.. strange one...
[Android Software Development] dhk.-:
my error... i forgot to copy all the inputmanager$****.smali files....

lens do you know how to make a 4 or 3 way reboot?
[Android Software Development] Lens_flare:
Andy Thomson was doing that, check out his thread on miuiandroid:

miuiandroid.com/community/threads/mod-4-way-reboot-2-1-13.5651/page-22
[Android Software Development] IdeosDev:
Anything can do about this?
[Android Software Development] dhk.-:
help with audio
[Android Software Development] medicjunKie:
Here's the full logcat

http://www.mediafire.com/?686g4q4t6cbfms0

thanks
[Android Software Development] Lens_flare:
oh.. I can't believe it.. they even changed JNI.. damn..

ok, have you tried to add that "JNITest" to framework.jar ?

uhm.. just a minute.. but mediaprofiles.xml are not bound to audio oO oh what a strange ics..

let's check that mediaprofiles..

could you post it to pastebin? ;[

---------- Post added at 11:27 PM ---------- Previous post was at 11:10 PM ----------

sorry, dloaded it now..damn internet ;]

so I see something strange:

maybe that one.. seems like you haven't elliminated all graphics issues..

and that lines:

RPC is a big net, but mostly it's represented by ril libraries, so check rild output also(so type adb shell rild to see it). it's not a gps though.
[Android Software Development] medicjunKie:
http://pastebin.com/krv6kDMQ

Thanks ;)
[Android Software Development] medicjunKie:
Fyi: this is a GB based Miuiv4 from the HTC mytouch I'm trying to port to the LG mytouch.

In case that makes a difference.
[Android Software Development] Lens_flare:
unbelieveable!

have you choosed a miui base by device name? -__-

just a little advice: try to port from nexus s :p
[Android Software Development] Lens_flare:
edwardng

have a look at previous posts, you should add not existing methods to miui' AssetManager.smali that is on framework.jar/smali/android/content/res

Zackconsole

interesting what is item 2900..

if it's not a really missing class, so it might be binaries issue..

ok, maybe is somewhat linked to native libs with regexp libjni*.so?
[Android Software Development] edwardng:
can u explain in details? *sorry for being a noob*
[Android Software Development] Lens_flare:
grab any diff tool like beyond compare or total commander or if you are on linux - meld.

Decompile framework.jar from miui base and your base rom with apktool (google google and google it, there are bunch of articles about how it works)

then in path I specified above (so framework.jar.out/smali/android/content/res) you will find AssetManager.smali.

grab that 2 smali-s(from base rom and miui) and go to diff them with tools above. Diff should show you lines that are not present in miui AssetManager.smali, so copy these lines to it. =>

Done? - repack ready framework.jar with apktool.

Ah yes, you also have to replace/add something that log will show you as "couldn't find native" error. That error contains useful info where exactly find a replacement (don't mess with first "L" in path ;] )
[Android Software Development] edwardng:
1. Do i need to replace .linexxx ?

2. "have to replace/add something that log will show you as "couldn't find native" error." How? :confused:

Updated: I have recompilation error after merging

I: Smaling...
Exception in thread "main" brut.androlib.AndrolibException: Could not smali file
: java.io.FileInputStream@5ad1e727
at brut.androlib.src.DexFileBuilder.addSmaliFile(DexFileBuilder.java:45)

at brut.androlib.src.DexFileBuilder.addSmaliFile(DexFileBuilder.java:33)

at brut.androlib.src.SmaliBuilder.buildFile(SmaliBuilder.java:64)
at brut.androlib.src.SmaliBuilder.build(SmaliBuilder.java:48)
at brut.androlib.src.SmaliBuilder.build(SmaliBuilder.java:35)
at brut.androlib.Androlib.buildSourcesSmali(Androlib.java:222)
at brut.androlib.Androlib.buildSources(Androlib.java:179)
at brut.androlib.Androlib.build(Androlib.java:170)
at brut.androlib.Androlib.build(Androlib.java:154)
at brut.apktool.Main.cmdBuild(Main.java:182)
at brut.apktool.Main.main(Main.java:67)

framework.jar (ori AOSP)

framework02.jar(ori MIUI)

May someone pls help me to merge and recompile for me?

Thanks。
[Android Software Development] Lens_flare:
nope, only add missing lines.

for exmaple:

you have that code on logcat:

E/dalvikvm( 2698): ERROR: couldn't find native method
E/dalvikvm( 2698): Requested: Landroid/content/res/AssetManager;.splitThemePacka
ge:(Ljava/lang/String;Ljava/lang/String;[Ljava/lang/String;)I

so first find a causer:

Landroid/content/res/AssetManager

then truncate first "L" to read it; we've got a path to it ( android/content/res/ plus we know that all of them are in smali folder of decompiled framework part ) and file set(mostly you also have to replace all tree with the same name and "$" after): AssetManager*.smali that represents part of erroneous code.

Mostly causers are in framework.jar and services.jar [to identify that it is services.jar there is a path: com/android/server]

so find a causer' tree smalis on your base rom' frameworks and place them to miui framework with the same path.

AssetManager is a bad example, as mentioned above :p

If you are lazy to parse logcat, you could find a consider list of necessary smalis in this thread, I'm updating it weekly if needed in my posts.
[Android Software Development] sahibunlimited:
Hi!

i am a n00b at porting but here is the logcat(i followed the process in OP)

I get bootloop

This is where i tried with stock CM9 libandroid_runtime.so which gets stuck at bootanimation : http://pastebin.com/L8QGX4SH

This is with Nexus S libandroidruntime.so which gets stuck at initial SGS2 i9100 logo : http://pastebin.com/dmMNTGp7

I was trying to port from nexus s

The reason i was trying to port it to SGS2 is that official MIUI is based on samsung ics rom and i want to have MIUI based on CM9
[Android Software Development] Lens_flare:
what a strange logs.. amazon, usb tool.. huh.. seems like something wrong with them, especially with usb tool..

no difference though.. without cm frameworks. If you choose as miui base official galaxy s2 release, you'll get what you want, additionaly spare some time on understanding logs ;]
[Android Software Development] sahibunlimited:
Lol I read their amazon app and all and I was totally confused

I tool the nexus s official miui and latest cm9 nightly

Their are samsung stuff like buttons in pop up and much more samsung looking stuff in official miui

Will check tomorrow about that amazon thing
[Android Software Development] Lens_flare:
that ones?

it's official even on nexus s :p
[Android Software Development] medicjunKie:
I made it boot, i tried with ICS 4.0.4 and it booted.

Some bugs though, the screen flicks and the screen comes and goes.

And i think there's no data.

Ideas?
[Android Software Development] Lens_flare:
congrats! with nexus s base though?

again a hw acceleration-related.. maybe you haven't replaced something like hardwarerenderer.smali (at android/view, framework.jar)

Are you using custom ril class right?

So, make it work:

replace RIL*.smali, LGEQulacommRIL.smali(or one you use, right name is in build.prop, ends with RIL), and QualcommSharedRIL.smali(base class for all qualcomm rils in newest CM sources) at path: com/android/internal/telephony ín framework.jar. You also need to patch PhoneFactory.smali to construct your class instead of RIL: find RIL (there will be 2 entries) and replace them to LGEQulacommRIL or somewhat you are using. that's it though.
[Android Software Development] medicjunKie:
I used a MIUIv4 for the LG SOL.

Because my device and the SOL are basically identical.

what i want to fix primarily is the screen flicking.

So what do i do with framework.jar?

Oh, and basically the rom is based on miui and not cm9.
[Android Software Development] edwardng:
May anyone lend me his hands and reupload for me?

As I posted before,

framework.jar (AOSP)

framework02.jar (MIUI)

Ladies and Gentlemen, pls help me to merge and upload back for me... Im worrying to mess up every single thing.... :(

A big thanks for your contribution thru' xda community service
[Android Software Development] IdeosDev:
Well i hit another trouble again..this time is mess
[Android Software Development] Kaze105:
I had the same problem of the person you quoted:

E/dalvikvm( 2698): ERROR: couldn't find native method
E/dalvikvm( 2698): Requested: Landroid/content/res/AssetManager;.splitThemePacka
geLjava/lang/String;Ljava/lang/String;[Ljava/lang/StringI

I then decompiled the framework.jar, used a program to compare the code of assetmanager.smali and added lines that were missing in the miui framework that had to do with themepackage. I recompiled, put it into the zip again and installed. I am still stuck with a bootloop. This time its a different error:

E/dalvikvm( 1871): ERROR: couldn't find native method
E/dalvikvm( 1871): Requested: Landroid/content/res/AssetManager;.detachThemePath:(Ljava/lang/String;I)Z
E/JNIHelp ( 1871): RegisterNatives failed for 'android/content/res/AssetManager', aborting
F/libc ( 1871): Fatal signal 11 (SIGSEGV) at 0xdeadbaad (code=1)

I cant find anything in the assetmanager.smali regarding theme path. Hopefully I can get some help on this. I would also like to ask if I should copy every line missing in the MIUI assetmanager.smali from the CM9 one.
[Android Software Development] Lens_flare:
I faced something like that when tried to port from desire S to my liquid mt, was about base frameworks incompatibility(I haven't resolved it and went to nexus s base).

add all missing (not only that "splitthemepackage"), don't touch nothing else and you will succeed.

could be external method that have been obfuscated by java compiler.
[Android Software Development] ronak.super:
when i try port miui v4 to android 4.0.4 it doesnt bootup, but 4.0.3 does boot up

anyone can help me out with this?

please!!
[Android Software Development] Lens_flare:
yes, but without logcat it would be extraordinally hard..
[Android Software Development] Kaze105:
Thanks for the help.

edit2: Got it booting for the i9100. Lots of problems still, but at least I can play around on the homescreen at last.
[Android Software Development] :
Hey guys, I hope you can help me (I read many pages of this thread sorry if the solution was already posted but I missed it)

I tried to port MIUI 4 to my SGS2G. I used CM9 as base and I used a i9100 MIUI build for the first try to get MIUI working and for the second a Kindle fire miui rom, because it has the same chipset.

Both tries the same, they dont boot. If I use the miui libandroid_runtime.so I stuck on bootscreen, when I use the cm9 one I stuck at bootanimation.

The weired thing is that I can´t get the logcat its always saying "waiting for the device" and this for 15+ minutes
[Android Software Development] Lens_flare:
have you even tried to use adb in linux? some miui bases are inccompatible and won't provide you a log, so try the most universal nexus s base.

without logcat only your device model owner could help..
[Android Software Development] :
Ok, thanks for your reply, using a Nexus S build and CM9 libandroid_runtime.so I also stuck at bootanimation but I could gain the logcat. I think the problem is there:

But how to fix this? I attached the full logcat if this one is not the main problem

EDIT: I saw another person with this problem lets see how he fixed it..

EDIT2: Ok I added many CM files from framework.jar to my ports one but still not booting
[Android Software Development] Lens_flare:
what are you waiting for? Get new log and we'll see what's wrong.
[Android Software Development] chillzz81:
I've ported MIUI Nexus S build to SGS2 based on CM9. Everything works fine, only the keyboard doesn't pop up. Any ideas? Thanks in advance!
[Android Software Development] :
Here it is:
[Android Software Development] Lens_flare:
fuss132

binary: services.jar

path: com/android/server/wm/

smali to replace: InputManager*.smali

chillzz81

explanation above could be also your soulution: replace all InputManager smalis in services.jar.
[Android Software Development] :
Thanks already done :)

I only copyed the InputManager.smali, should I copy InputManager$1 etc, too?

The keys are shining and screen brightness is reduced but still not full boot but very close :D

EDIT: Sorry I have to read when you write a * behind InputManager you mean all
[Android Software Development] Lens_flare:
yes, copy them too.
[Android Software Development] :
Ok all done now maybe the last thing is the following:
[Android Software Development] Lens_flare:
oh.. it might be hard.. you should find in cm9'framework-res.apk recource by that ID and add to miui framework-res.apk..

damnely strange, I thought my device is unlucky in that samsung world.. how I was wrong :d
[Android Software Development] :
Hm where should that resource id be? I searched in decompiled id.xml, strings.xml and public.xml but theres no such id
[Android Software Development] Lens_flare:
if it's not present in resources then it is.. weird, what is it? :D

ok, I'm denying my last suggestion..

as you changed inputmanager, maybe there are some miui defines are depends on that, so try old kind procedure: add all missing methods and don't replace/delete anything, hope it helps.
[Android Software Development] :
Ok thanks for your help I will try it later :D
[Android Software Development] chillzz81:
It doesn't help. Maybe my booting log can help to find something out.
[Android Software Development] Lens_flare:
ah again that issue with cache:

05-30 14:15:15.970: E/NetworkLocationRealOs(2304): no android ID; can't access encrypted cache
05-30 14:15:15.970: E/NetworkLocationRealOs(2304): java.io.IOException: no android ID; can't access encrypted cache

this seems haven't resolved yet..
[Android Software Development] chillzz81:
I've tried again and it seems this error appears only on first boot. Don't know why!? :rolleyes:
[Android Software Development] Lens_flare:
so or android ID not created, or something that android id accessing (secure cache) not created... or it could be something else not bound to android ID :D
[Android Software Development] yonzz:
Hello, could somebody help me to fix this. :)

I'm new in developing android and not too much know about it. :D

Here is the logcat

I/ServiceManager( 355): Waiting for service media.player...

I/ServiceManager( 355): Waiting for service media.audio_policy...

W/IMediaDeathNotifier( 355): Media player service not published, waiting...

I/ServiceManager( 355): Waiting for service media.audio_policy...

I/ServiceManager( 355): Waiting for service media.player...

I/ServiceManager( 355): Waiting for service media.audio_policy...

I/ServiceManager( 355): Waiting for service media.player...

I/ServiceManager( 355): Waiting for service media.audio_policy...

I/ServiceManager( 355): Waiting for service media.player...

I/ ( 1285): ServiceManager: 0xf958

here's the full logcat

http://tinypaste.com/d11b1630
[Android Software Development] Lens_flare:
what libaudioflinger/a2dp.[*].so do you use? Seems there are problems with them.

And let's be exact: what rom you are using as base and what as miui source?
[Android Software Development] IdeosDev:
I solve other mistery already except there's some problem getting fc's on my build

android.phone.com keep spamming fc's
[Android Software Development] Lens_flare:
something about ril though, check a logcat for exceptions..
[Android Software Development] IdeosDev:
I have sorted out some part of it..now main part unresolve from previous test ...any clue about the mic?
[Android Software Development] resac:
Help

some one please provide guide to fix mic problem in MIUI port.. i successfully ported miui to x10 mini pro but mic doesnt work..

Thanks you:)
[Android Software Development] :
Maybe you can help me another time :D Do you know what´s causing this problem?

and I still have that resource problem, but the requested resource is not available in cmframework. In no file

Full logcat here: http://pastebin.com/G2gzc4U3

And how to fix this? ^^
[Android Software Development] medicjunKie:
That didn't fix the glitch with the screen.

Any other idea?

Thanks
[Android Software Development] Lens_flare:
permissions log you provided is common for ports.

in full log I have found smth strange:

I/dalvikvm( 530): DexOpt: mismatch dep signature for '/cache/dalvik-cache/system@framework@core.jar@classes.dex'@core.jar@classes.dex'

I think it fixed itself at 2nd boot so you could boot.. but strange, nothing to be done with core.jar..

have you guys tried to patch Audiomanager?
[Android Software Development] dhk.-:
Is tried... Don't work

Enviado desde mi LG-P500 usando Tapatalk 2
[Android Software Development] :
Because of the fact that I tried everything and nothing helped to fixed this and everybody I asked don´t knew the answer I started another port with the MIUI from the S2.

I fixed many nosuchmethod errors but now I´ḿ stuck here:

http://pastebin.com/1fUA9UaE

When you look in this line it says (after successfully preloading all frameworks)

And when I replace the Config.smali one error appears but the following happens :/

http://pastebin.com/L1Re65Nf

How could you all boot your ports?! :D
[Android Software Development] Lens_flare:
some of that methods should be added instead of replacing all smali, you have started a deadly error chain..

and I'm curious what framework2.jar is?

most of us are qualcomm users ;]
[Android Software Development] medicjunKie:
Any reply towards the screen flickering?
[Android Software Development] :
I also noticed framework2.jar for the first time yesterday in the stock ics rom from samsung.. its strange because theres nothing in it just a META-INF folder

I´vd done what you said and did all old operations by not copying the whole file buit the single methods.. Now I don´t have this error salad :D

BUTTT as last time

and I only copied methods not files :(
[Android Software Development] shubhamchamaria:
will this work if i am porting dianxin os?
[Android Software Development] excellentnuke:
Does this work if I port using a Sense ROM as a base if it's the same Android version?
[Android Software Development] dinesh690:
Is it essential to change the ringtones. message tones etc in build.prop, and do we use the kernel for the base rom as the kernel for the ported ROM? Thank you
[Android Software Development] nuuits:
Is there any way at all to do it without ICS? My poor Slider has not gotten much love yet...
[Android Software Development] Ron G:
thanks proxuser your guide realy help me to port miui 4 rom on optimus me. With some modifications. For modifications thanks to gannon5197. And can i use this guide to port miui android 2.3.5 rom?

thanks again proxuser you are very great dev.
[Android Software Development] pikachukaki:
Great post...but will it work for U8800+ we don't have any ics working rom just taking the u8800 aurora and port it but its full with bugs!!
[Android Software Development] nuuits:
probably not. I followed the guide exactly but with a gingerbread base ROM and it just stayed at the LG screen...
[Android Software Development] pikachukaki:
if you take ics from an other phone like desire hd like 2.3 ports maybe??i really want ics to u8800+ :P
[Android Software Development] proxuser:
yes it will work on dianxin ics version too.

just skip miui parts. i mean

"invoke-as"

"telocation.db"

"content-types.properties"

"liblbesec.so"

and these lines. just take them from dianxin os build.prop
[Android Software Development] thejaimes111:
thanks :)

Mensaje enviado desde mi Vodafone 858 Smart, ROM Cyanogenmod 7.2 RC1 ported by @subspike (V. 0.9), perdonen las faltas de ortografía :P
[Android Software Development] Jmaserang:
going to try this now
[Android Software Development] Peteragent5:
Remember that booting takes long time...
[Android Software Development] proxuser:
I heard from some people they got bootloop. If that happens try use original libandroid_runtime. so
[Android Software Development] Peteragent5:
You mean the one from CM9 base?
[Android Software Development] SpaceCaker:
is it bad if i dont have invoka as in the miui i want to port?
[Android Software Development] Peteragent5:
What the Frick? How'd you get here? ROFL
[Android Software Development] rukin5197:
I can't get 3g to work in my port.. is there something I'm missing? 3g is working in the MIUI and CM9 base
[Android Software Development] proxuser:
Yes from base rom

Check apn-**. xml in etc folder
[Android Software Development] DJBhardwaj:
Now if anyone could guide a little bit, i am an optimus one user. We already got a port of MIUI based on CM 9 port; CM9 base port has got data working but the MIUI ported on the same CM9 base in not running data, guess its apn problem. Anyone got any idea to fix this?
[Android Software Development] nuuits:
Please help me. I have an LG Optimus Slider and was wondering if there was any way AT ALL to do this without CM9 or ICS.
[Android Software Development] IdeosDev:
Any tips of patching audiomanager..sorry cause i am a lil blur on this part.

Thanks