[PoC] Project Treble for natrium

Weijianism

Member
Jun 22, 2014
37
36
0
Paris
Code:
#include <std_disclaimer.h>

/*
 * Your warranty is now void.
 *
 * I am not responsible for bricked devices, dead SD cards,
 * thermonuclear war, or you getting fired because the alarm app failed. Please
 * do some research if you have any concerns about features included in it
 * before flashing it! YOU are choosing to make these modifications, and if
 * you point the finger at me for messing up your device, I will laugh at you.
 *
 */
What is Project Treble
Project Treble basically partitions your device into two separate partitions, a system and a vendor: system contains your generic system image, while vendor partition has your device specific files required for booting and running your phone. This way we can easily change the system image and be able to run our device on different system images with the same kernel and vendor partition.

What is NOT working
You tell me

Downloads
Build 0421 (boot.img + vendor.img)
Phh-Treble A-only ARM64 (system.img)

Previous builds

HOWTO
Wipe everything in TWRP 3.2.1-1
Install boot + vendor + system image
Reboot and enjoy

Sources
Kernel for msm8996 (lineage-15.1)
Configuration for natrium (lineage-15.1)
Configuration for msm8996 (lineage-15.1) (Minor patches)
Proprietary vendor (lineage-15.1) (Minor patches, credits MZO)


XDA:DevDB Information
Project Treble for Mi 5s Plus

Contributors
Weijianism
Source Code: https://github.com/wegank/

ROM OS Version: 8.x Oreo
ROM Kernel: Linux 3.x

Version Information
Status: Testing

Created 2018-03-12
Last Updated 2018-04-21
 
Last edited:

Weijianism

Member
Jun 22, 2014
37
36
0
Paris
Reserved

Note that I'm a full-time high school student (with SO MUCH homework), I may not have enough time and knowledge to maintain this thread personally, so I'll write a simple guide for building Treble-enabled LineageOS on your own with ease. Stay tuned.

Since MZO and his team's building Treble images for natrium, let's wait for their official build with patience.
And with this PoC thread suspended I'll focus more on my studies lol :D
 
Last edited:

Weijianism

Member
Jun 22, 2014
37
36
0
Paris
FAQ

Q: How to make BSG's GCam work on AOSP Phh-Treble with GApps?
A: Delete the following files in TWRP File Manager, then reboot.
Code:
/system/etc/permissions/com.google.android.camera.experimental2015.xml
/system/etc/permissions/com.google.android.camera.experimental2016.xml
/system/etc/permissions/com.google.android.camera.experimental2017.xml
/system/framework/com.google.android.camera.experimental2015.jar
/system/framework/com.google.android.camera.experimental2016.jar
/system/framework/com.google.android.camera.experimental2017.jar

Q: How to fix LTE/CDMA (China Telecom etc) on AOSP Phh-Treble?
A: Run the command in ADB Shell or in Terminal Emulator, then reboot.
Code:
settings put global preferred_network_mode 10
settings put global preferred_network_mode1 10
settings put global preferred_network_mode2 10
 
Last edited:

engloa

Senior Moderator
Staff member
Apr 18, 2011
5,575
17,408
263
Here & There ...
厉害了 我的哥 看用户名就知道是国人

通过我的 MIX 2 上的 Tapatalk发言
Kindly edit your post and add English as stated in the forum rules
4. Use the English language.

We understand that with all the different nationalities, not everyone speaks English well, but please try. If you're really unable to post in English, use an online translator. You're free to include your original message in your own language, below the English translation. (This rule covers your posts, profile entries and signature).
Thanks
 

MZO

Senior Member
Jan 5, 2015
1,883
2,190
0
Additionally, since most of the issues are shared with Mi 5s, if MZO manages to solve an issue on Mi 5s, you may also figure out how to solve it on Mi 5s Plus by reviewing his commit. By then, don't hesitate to create a pull request in my repo on GitHub.
I've already solved all the issues with MI 5s, you should sync my code again and rebase my changes.

I was just building the Treble images for natrium when I saw your thread hahaha
 
  • Like
Reactions: Pyruzan

Weijianism

Member
Jun 22, 2014
37
36
0
Paris
I've already solved all the issues with MI 5s, you should sync my code again and rebase my changes.

I was just building the Treble images for natrium when I saw your thread hahaha
Yes I just saw it on board of Mi 5s :good:
Also eagering to switch to your official release!
 

Weijianism

Member
Jun 22, 2014
37
36
0
Paris

theOriginalSuperl2

Senior Member
May 28, 2016
452
657
103
Melbourne
The button backlights aren't working on RR, and the button mapping settings are missing. I have a build environment set up, and I can build treble system images. What can I patch to fix this?

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

Also, I can't enable the OK Google hotword to activate assistant.
 

Weijianism

Member
Jun 22, 2014
37
36
0
Paris
The button backlights aren't working on RR, and the button mapping settings are missing. I have a build environment set up, and I can build treble system images. What can I patch to fix this?

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

Also, I can't enable the OK Google hotword to activate assistant.
For RR Phh-Treble's button backlights' issue check this. Since button mapping support isn't included in GSIs, you can either install button remappers from Play Store (recommended) or put ConfigPanel.apk (from natrium-specific builds) manually in system/priv-app/ConfigPanel folder.

I haven't encountered any problem with Google Assistant or OK Google hotword. Maybe GApps related?