Cyanogenmod for mediatek devices

Search This thread

superdragonpt

Recognized Developer
Apr 27, 2013
4,952
19,354
Lisbon / Taiwan / USA
www.caixamagica.pt
Will not be universally sources for mtk-devices, becouse every phone has different board specs ("need check the SA" - like sad chinese developers) : gpio's, power, eint's, and mach workarounds for every one model :mad: And remember - for one model of phone may be used 2-4 supported devices (displays, touchpanels, cameras, others).

Sent from my GT-I8160

---------- Post added at 06:16 PM ---------- Previous post was at 05:54 PM ----------

The chinese vendors, which not officially exported their phones will not send any ansver for request of sources. Only brands. I try do requests for mach vendors and sallers. Only Fly brand decided release the sources, but his vendors give him very bad sources (especially)

Sent from my GT-I8160

if you found the specific drivers for your device, the only thing you need to edit is an new board config, and make the necessary changes on the 2 config files. And change the drivers to be used.

What im having an hard time, is building the correct environment to build, since MTK needs some specific toolchain (linaro 4.6) just use the one from NDK, and some specific programs versions, for java only v 1.6 (u45 is the latest), same goes for pithon, etc , etc
Its an pain in the A##

Regards
 

joelzombie

Senior Member
Jan 24, 2013
100
26
www.joelsedano.com
Ok, since it seems impossible for us to compile a working CM for our phones... can we ask for the makers to compile a version for us? they have all the ingredients!

or I'm just dreaming?
 

KopiJahe

Senior Member
Jun 25, 2010
768
452
Pasuruan
If universal kernel wouldn't work, how about universal-ish rom? There's some devs that uses same source for different devices with different boards and different screen sizes and resolutions, User is only need to install a "compatibility zip" (contains device's specific kernel, config, etc)
 

Dr-Shadow

Inactive Recognized Developer
Sep 15, 2013
454
560
NANTES
If universal kernel wouldn't work, how about universal-ish rom? There's some devs that uses same source for different devices with different boards and different screen sizes and resolutions, User is only need to install a "compatibility zip" (contains device's specific kernel, config, etc)

It works for custom recovery but I don't know about system part
 
  • Like
Reactions: Bhg73

Chrizzly92

Senior Member
Jul 18, 2012
444
232
Dresden
www.generationblood.de
If universal kernel wouldn't work, how about universal-ish rom? There's some devs that uses same source for different devices with different boards and different screen sizes and resolutions, User is only need to install a "compatibility zip" (contains device's specific kernel, config, etc)


this is exactly what i would do. we got compilable sources for different chipsets, so compiling a "stockbased" Rom, wich will run with your stock libs/binarys and kernel shouldn't be that hard, instead of trying to port a specific ROM to a specific device. frameworksources are available, so merging some tweaks or features into is surely possible.
Doing it that way, you can port over these Roms to any device with the same chipset, as we do now. tweaking the CM tree to work with mtk-based devices will most likely result in custom libs and modules, running on a specific device, but not on others.
thats why i'm asking myself all the time, why everybody wants to compile CM for mtk based devices. much much work for a -maybe bugy- version for one particular device. Doesn't make sense at all.
I would start my own project, but i abandoned work for mediatek devices few month ago.
 
Last edited:

luckasfb

Senior Member
Oct 7, 2012
168
110
if you found the specific drivers for your device, the only thing you need to edit is an new board config, and make the necessary changes on the 2 config files. And change the drivers to be used.

What im having an hard time, is building the correct environment to build, since MTK needs some specific toolchain (linaro 4.6) just use the one from NDK, and some specific programs versions, for java only v 1.6 (u45 is the latest), same goes for pithon, etc , etc
Its an pain in the A##

Regards
Now I'm not looking for general tips on building kernel and platform MTK. I khow 95% of tricks and hacks for build mediatek custom kernel and platform. But serious workarounds in the source code for a particular models will not let me finish porting multiple kernels and firmwares.
Like as: power+clksrc for accelerometr and als/ps, touchpanel, sd-card, BCM4330 sdio-host; many defines for cameras at 3 revisions of one device.

---------- Post added at 10:44 AM ---------- Previous post was at 10:36 AM ----------

this is exactly what i would do. we got compilable sources for different chipsets, so compiling a "stockbased" Rom, wich will run with your stock libs/binarys and kernel shouldn't be that hard, instead of trying to port a specific ROM to a specific device. frameworksources are available, so merging some tweaks or features into is surely possible.
Doing it that way, you can port over these Roms to any device with the same chipset, as we do now. tweaking the CM tree to work with mtk-based devices will most likely result in custom libs and modules, running on a specific device, but not on others.
thats why i'm asking myself all the time, why everybody wants to compile CM for mtk based devices. much much work for a -maybe bugy- version for one particular device. Doesn't make sense at all.
I would start my own project, but i abandoned work for mediatek devices few month ago.
Yes, the proccess of build mtk ROM need to include all parts (kernel+hal). And not support for more that one phones. Else will not work some devices in custom firmware (WIFI, BT, FM, GPS, cameras, als_ps, accel, magnet), becouse the kernel devices drivers must be same as HAL drivers (corespond to his).
 

syserr

Senior Member
Aug 16, 2012
459
365
Idaho
I would start my own project, but i abandoned work for mediatek devices few month ago.

"I'd start, but I already quit." ;)


(I understand and I don't blame you, it just struck me as funny.)

---------- Post added at 10:30 AM ---------- Previous post was at 10:16 AM ----------

Now I'm not looking for general tips on building kernel and platform MTK. I khow 95% of tricks and hacks for build mediatek custom kernel and platform. But serious workarounds in the source code for a particular models will not let me finish porting multiple kernels and firmwares.
Like as: power+clksrc for accelerometr and als/ps, touchpanel, sd-card, BCM4330 sdio-host; many defines for cameras at 3 revisions of one device.

---------- Post added at 10:44 AM ---------- Previous post was at 10:36 AM ----------


Yes, the proccess of build mtk ROM need to include all parts (kernel+hal). And not support for more that one phones. Else will not work some devices in custom firmware (WIFI, BT, FM, GPS, cameras, als_ps, accel, magnet), becouse the kernel devices drivers must be same as HAL drivers (corespond to his).

luckasfb, I would also like to ride on your coat-tails and document all this well, even setup a watering hole were all the mtk devs can drink and share.

I agree, that a build probably needs to be from the ground up for a specific phone. There is too much tight coupling and not enough abstraction to do a ROM that works on many kernels. For example, I tried to move additional FM Radio drivers into an existing kernel. I was able to load the kernel module/driver (with insmod), checked dmesg seemed to be ok... But the framework above the driver didn't exist for the FM App to talk to, logcat was going crazy.
 

luckasfb

Senior Member
Oct 7, 2012
168
110
"I'd start, but I already quit." ;)
luckasfb, I would also like to ride on your coat-tails and document all this well, even setup a watering hole were all the mtk devs can drink and share.

I agree, that a build probably needs to be from the ground up for a specific phone. There is too much tight coupling and not enough abstraction to do a ROM that works on many kernels. For example, I tried to move additional FM Radio drivers into an existing kernel. I was able to load the kernel module/driver (with insmod), checked dmesg seemed to be ok... But the framework above the driver didn't exist for the FM App to talk to, logcat was going crazy.
YEP, FM module also direction from HAL libs and ... logcat going crazy :eek:

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

Hey Lucas
I know you know the env config, but im sure other users here dont.
And since kernel config /build is an inportant step on building CM's im sure the info is usefull enought to be share.

Regards
More docs about build env in my Git (do you like chinese? :laugh: )
But need to try build, read scripts for get expirience for MTK
 

ts_firehawk

Senior Member
Sep 27, 2011
1,122
310
Colombo
Samsung Galaxy S10+
'Sup guys!

I've sent a email to motorola asking about sources of Razr D3 (MTK6577), here is the response:

Boa tarde, Renan!

A informação ao qual deseja, infelizmente, não possuímos por se tratar de dados técnicos que não são repassados ao nosso suporte por acarretar na perda de garantia do produto, pedimos sinceras desculpas por não pode auxiliar nesta questão.

Permanecemos à sua disposição.

Atenciosamente,
Motorola Brasil

In english:

Good afternoon, Renan!

The information about what you want, sadly, we don't have since they are from technical data that aren't repassed to our support because they may lead to the void of the warranty, we sincerely apologise for not being able to help you on this matter.

We remain at your disposal.

Regards,
Motorola Brazil

In other words: they don't want to help.
 

superdragonpt

Recognized Developer
Apr 27, 2013
4,952
19,354
Lisbon / Taiwan / USA
www.caixamagica.pt
'Sup guys!

I've sent a email to motorola asking about sources of Razr D3 (MTK6577), here is the response:



In english:



In other words: they don't want to help.

Ola Renan (sou Portugues :) )
*Hi

Well you may tell Moto that kernel is under the GPL license, and they are forced to provided those sources.

The problem is: Even on kernel sources some files are proprietary...
I.e: on MT 6577 the ./Mediatek folder is not GPL.
Lucas know what im talking about...

Changing the subject:
WDF is Samsung Source Code, being used on MT6589 sources?

Lol Mediatek, BUSTED !

Regards
 

voetbalremco

Inactive Recognized Developer
Ola Renan (sou Portugues :) )

Changing the subject:
WDF is Samsung Source Code, being used on MT6589 sources?

Lol Mediatek, BUSTED !

Regards

That's exactly why there are no sources available; mediatek doesn't give out sources for public because it copies third party code of brand that do release the sources, such as samsung and sony, and use that as theirs.
 

DeathArrow

Senior Member
Dec 22, 2011
87
92
Bucharest
Well, people just want the kernel sources, the framework modifications, the device folder, so they can sit on their asses and hit make brunch.

Even on brands like Samsung or LG which released kernel source, porting was required when they released sources for 2.6 kernel and you needed 3.x kernel for a proper CM build. And when they didn't release the framework mods, some people did research and even used libs from stock ROM if needed. Not as easy as hittting make brunch.

Want me to link lots and lots of threads where guys ported the kernel and modified CM source to accomplish the task of building a working CM?
 

syserr

Senior Member
Aug 16, 2012
459
365
Idaho
Well you may tell Moto that kernel is under the GPL license, and they are forced to provided those sources.
...
Changing the subject:
WDF is Samsung Source Code, being used on MT6589 sources?

If they are integrating code into the kernel, it needs to have a license that is compatible with GPL. This is the "Open Source Virus" that FUD spreaders spread, but it is true. That is why we didn't and still don't have ZFS in the Linux Kernel. There is a stub/API in the Linux kernel that can make use of ZFS (Sun/Oracle) if it's present. ZFS is released under CDDL.

That's exactly why there are no sources available; mediatek doesn't give out sources for public because it copies third party code of brand that do release the sources, such as samsung and sony, and use that as theirs.

I don't see any signs of that. What you can see though pretty easily is that the take down notices for MediaTek sources on github were initiated by a third party that makes the compass. This makes sense, I think... MediaTek is restricted by their own licensing of component software. I saw this as Sun tried to open source Solaris and Java in the past.

I think what you can say though, is they aren't working very hard to resolve those third-party licensing issues so that they can open sources as much as possible. For example, the could release almost everything and hand out binary blobs of the compass driver.
 

Top Liked Posts

  • There are no posts matching your filters.
  • 81
    Hey guys, We are going to try something new for our china phones - cyanogenmod.

    But we need some more devs to get everything going.



    For now we have:

    -Github tree for Lenovo P700i(mediatek 6577, android 4.0.4, kernel 3.0.8)

    -Lens_flare - original port author(may work with system folder and configs)

    -some kernel source from other devices like liquid gallant



    The main problem is getting adb to work that could help a lot on remaining development. For now even zygote not starting, but all partitions seems mounted successfully.

    We need more devs (especially that could assemble working kernel for device), working with p700i may lead to following porting for other mtk devices, as sources are nearly the same.
    40
    Lollipop on MT6577

    Hi there .

    Just to let you know, that lollipop is now booting on ZTE v970 [MT6577- w/ ComBo-Chip MT6620]
    With my custom 3.4.67 KK Kernel + some cherry-picks from the new MTK 3.10.54 LL Kernel

    Still very early, baseband is recognized , but still needs a lot more work on Telephony, Platform, etc.


    ;)

    Regards
    39
    More progress on this one: http://xdaforums.com/showthread.php?t=2467400

    I have 3G data and incoming voice calls working now.

    Next: kitkat.

    Chris

    Please hit the thx button. And please thank also dr shadow and xplodwild from omnirom.
    27
    KitKat Sources MT6582 / 6592

    Since my Cloud host, removed the sources,that i uploaded twice

    Using MEGA now, should be on for some days..


    Edit: no more source leaks, noobies will always be noobies
    I won't be sharing more source stuff

    Learn to comply with GPL and respect others



    Regards
    27
    I'm working now since 1 day on CM13 and here the first screenshot on mt6592 :).