In this post, we will learn about Custom ROM Porting Guide for Helio P10 MT6755, MT67 & 50MT6738. These Chipsets are the part of Helio P10. Currently, the following processors are built-on Helio P10 hardware:
Custom ROM Porting Guide for Helio P10 MT6738, MT6750 & MT6755:
1. MT6738 = 1.5 GHz + 1.0 GHz (Mali-T860MP2 – 500 MHz)
2. MT6750 = 1.5 GHz + 1.0 GHz (Mali-T860MP2 – 500 MHz)
3. MT6750T = 1.5 GHz + 1.0 GHz (Mali-T860MP2 – 700 MHz)
4. MT6755 = 1.8 or 2.0 GHz + 1.2 GHz (Mali-T860MP2 – 700 MHz)
5. MT6755T (Helio P15) = 2.2 GHz + 1.2 GHz (Mali-T860MP2 – 800 MHz)
Requirements:
- Compatible Chipset: MT6750, MT6735, MT6737, MT6753, MT6755.
- Kernel version: 3.18.35
- Android version: AOSP (based) Nougat (7.0 & 7.1.x)
- Notepad++
- Ubuntu
- Windows (if you like)
- Carliv Image Kitchen
- Lot of time and knowledge of the basics
Steps For Porting:
Step 1: Making the patch
- Download this file Download
- Replace its contents with that from your stock Nougat ROM.
Step 2: Patching the system
1. Download and install Ubuntu.
2. Clone SuperR’s kitchen (use Google)
3. Open SuperR’s Kitchen
4. Select option 1 and give it a name e.g stock
5. Copy your stock boot.img and ystem.img (or Stock ROM’s zip file it’s not SP Flashable)
6. Paste in the folder according to SuperR’s Kitchen
7. Press option 4 in SuperR’s kitchen
8. After extraction, choose option 8 (ROM tools).
9. Press 7 on the next screen.
10. Choose Build ZIP.
11. For Permissions mode, choose “set_metadata”
12. For mount points, choose “From boot/recovery”.
You’ll get a ROM_NAME.zip in the superr_ROM_NAME folder.
13. Repeat the process for port ROM
14. Go back to Windows (if you like)
15. Extract both stock and port
16. Copy the files in the patch that you made earlier
17. Paste them in Port ROM and replace the existing ones
18. Edit build.prop and change these values according to stock build.prop: ro.product.board, ro.mediatek.platform, ro.sf.lcd_density, ro.hw_rotation
Step 3: Making the updater-script
- Download this file Download
- Extract it and copy su.d folder to port’s System folder.
- Open your port rom’s META-INF folder and open its updater script.
- Copy everything from the line: #SYM to the last line of “set_metadata”
- Open the updater script from the extracted TEMP-METAINF folder
- Delete everything starting from line: #SYM to the last line of “set_metadata”
- Paste the lines you copied from port’s updater-script on step 4 of this part.
- From TEMP-METAINF updater-script, delete the lines from “ui_print(“BEGIN UPATING 9. FIRMWARE”);” to the end.
- Save the updater-script.
- Delete the META-INF folder from port ROM.
- Copy paste that of TEMP-METAINF to port ROM
Step 4: Patching the boot.img
USE STOCK BOOT.IMG DIRECTLY (JUMP TO FINISHING UP PART).
But if that fails, you will need to patch the boot.img
1. Unpack port and stock boot files with Carliv Image Kitchen
2. Copy these files from port boot: default.prop, init.environ.rc
3. Paste them in stock ramdisk and replace
4. Open init.rc with Notepad++ in stock ramdisk and find this line:
setprop selinux.reload_policy 1 Replace its value from 1 to 0
5. Open boot.img-cmdline of your stock extracted boot and add this to it:
androidboot.selinux=permissive buildvariant=userdebug It will look something like: bootopt=64S3,32N2,64N2 androidboot.selinux=permissive buildvariant=userdebug
6. If port boot has proprietary files like init.flyme.rc, ini.miui.rc, init.sony-xxxx.rc, you must copy them to stock ramdisk and find the init file in which they should be imported by referring to port’s ramdisk. These are usually init.rc and init.mt67xx.rc
7. Pack the stock boot and copy it back to your port rom.
Step 5: Finishing up
- Select META-INF, system and boot.img from your port ROM
- Zip them
- Boot to TWRP and test.
Bug fixes (all in one place)
So, you’ve booted your ROM?
Awesome! But I’m 100% sure that everything doesn’t work. So, we need to try to fix the things that don’t work.
This part contains fixes for Fingerprint, Audio, Camera, RIL (network) and more.
Fingerprint bug fix
This guide is intended to be used on MT6750 and MT6755 devices. It might work on other MT67xx devices like MT6797, MT6753 and MT6735. You’ll have to try and find out!
THE FIXES
Please follow these steps. All of them!
- Open your stock ROM and port ROM side by side.
- Go to system/lib/hw in both ROMs.
- Compare the files in both hw folders.
Check your stock ROM for these files:
For MT6750
gatekeeper.mt6750.so
gatekeeper.device_name.so
keystore.mt6750.so
libMcGatekeeper.so
For MT6755
gatekeeper.mt6755.so
gatekeeper.device_name.so
keystore.mt6755.so
libMcGatekeeper.so
Note: device_name depends on the device you’re porting the ROM from. For Meizu U10 Flyme ROM, it was gatekeeper.u10.so
- 5. If stock ROM DOES NOT HAVE the above files and Port ROM also DOES NOT HAVE them. Then it’s fine! Move to step 8.
- If your stock ROM DOES HAVE the above files, copy them and paste them in port. If they are in port, replace them. If they are not in port, just add them.
- If Stock ROM DOES NOT HAVE them but Port ROM DOES HAVE them; then remove them from port. THIS IS IMPORTANT.
- Copy fingerprintd from sotck system/bin and paste it in port system/bin. REPLACE when prompted.
- Copy all files from stock system/bin and paste them in port system/bin. DO NOT REPLACE anything when prompted. The goal is to have stock extra files in port ROM.
- Repeat the above step with lib, lib64 (and their subfolders), etc root directory files, permissions, vendor/lib & vendor/lib64 and xbin.
- Repack the ROM and test it!
Notes
- I did not need to patch boot.img. But if you need it, you can do it. I just don’t know how to help you here … The best solution would be to replace mt675x files in port ramdisk with stock ones.
- Common sense is required to properly understand this guide. For instance, if you’re porting an MT6755 rom to an MT6750, you should be looking for files like gatekeeper.mt6755.so in port ROM and gatekeeper.mt6750.so in stock ROM.
- After everything, you MUST remove all mt6750 or mt6755 files from hw folders if you’re doing a crossport (6755 to 6750 or vice-versa).
- Sometimes the fingerprint works but the fingerprint option in settings still force close. So, you might want to set up fingerprint for the first time the ROM boots.
- If everything fails, open Terminal Emulator and type fingerprint. If the terminal then appears to be stuck, then your fingerprint is initialized, something else is wrong. Recheck the steps above then.
- Fingerprint bug is hard to fix. Each device has its own fingerprint drivers. You have to identify your fingerprint drivers and copy them to the appropriate locations. After that, you MUST remove the other fingerprint files for the port device to avoid conflict between the files.
For my device, the fingerprint files are:
bin/fingerprintd
lib64/hw/fingerprint.default.so
lib64/fprint-x64.so
Most of the time, you will need to remove or add all the files that start with fp or goodix or gx from lib, lib64 and bin folders.
RIL (network signal and IMEI issue) fix
Literature
RIL bug is a minor bug that can normally be fixed by using firmware and mddb folders from your stock rom. Sometimes, it doesn’t help. You’ll still face RIL issue like network drop, no 3G/4G/LTE, no VOLTE etc. This happens when you try to port a Chinese ROM. Chinese roms mostly use a different kind of VoLTE called SrLTE (sometimes ViLTE). I’m not sure what’s the difference, but they are apparently not the same. So, this is the report of my research.
FIXES
To fix RIL. You have to try one or all of these methods:
I assume you’ve already replaced firmware and mddb from stock to port! If not, start with that! And then follow one or all of these steps.
Audio Bug fix
Normally Audio works if the ROM is properly ported! But if for some reasons it does, then try these:
- Copy audio.primary.mt6750.so from lib/hw and lib64/hw of your stock ROM and paste them in port one.
- If it still doesn’t, then you can copy libaudio*.so (meaning all files with audio in their names) from your stock rom’s lib and lib64 to port rom. Use with care, some audio files can cause bootloop.
- You might also need to copy all the files starting with audio from etc folder of your stock rom to the port rom. That should fix Bluetooth Headset Audio bug as well.
Camera bug fix
Camera bug is the most irritating of all them, yet the hardest one to fix! The following steps allowed me to fix the camera on various ROMs on my Doogee Y6. It might definitely not work on your phone because each device has its own camera files. Here are the steps:
- Copy camera.mt6750.so and camera.default.so from lib/hw and lib64/hw of your stock ROM to port ROM.
- Copy all camera files from your stock rom’s lib and lib64 folders except libcameraservice.so, libcamera_client.so, libcamera_metadata.so
If camera still doesn’t work, try using another camera app. This is important especially when you crossport a MT67xx ROM to another MT67xx! Due to platform differences, the MT6735/MT6753 camera apps for instance are mostly incompatible with MT6750/MT6755. So, the stock camera apps in these roms will likely not work in your ported ROM. There is no solution to that besides using another camera app.
Settings Force, Security Settings force bugs fix
If you get settings app for close or security settings force close, remove these from port rom’s lib/hw and/or lib64/hw:
gatekeeper.mt67xx.so
gatekeeper.mt67xx.so
gatekeeper.device_name.so (device_name refers to the device codename).
libMcGatekeeper
keystore.mt67xx.so
keystore.mt67xx.so
That’s all for now. Thanks for reading!
The guide here is presented by Nonta72 from XDA Developer Group.
hello, any update for oreo devices, i have kernel 3.18.79+ mt6753 android 8.1
hello androidfit i want to ask something about porting a android 8 to my android 7.1.1 phone is this possible?