Let me begin saying, this is not an a-z explanation on how to build custom ROM, many things can go wrong! I’m just sharing how i build my first working /e/ ROM for a non Lineage OS supported device.
In this howto I’ll use example repo’s for device Moto G5S codename montana. You can check them out and find out where i forked them from
To build /e/ you need vendor, device and kernel files for your device. This how-to assumes you are lucky and can find those on the Internet/ GitHub. For my device, montana i found sources reading a XDA topic. So maybe for your device there are topics on the internet also.
##Let’s get started
Create an GitHub account if you don’t have this.
Find your device, vendor and kernel on GitHub. Click on fork. This will create a “copy” to your own GitHub account.
Create your build script as described here
I suggest you first try to build a supported device to check if everything is ok:
The build system we use “searches” for “lineage-15.1” branches on our forked repo when you build v1-oreo. So the forked repo’s should have a branch name “lineage-15.1”. If they have other names (sometimes they are called “oreo” or “8.1”) we need to rename them. I’m sure this can be done otherwise but i want don’t want to touch the build script because i want 100% /e/ builds.
To rename repo:
First clone your freshly forked GitHub repo’s:
copy the https:// line by clicking the copy button.
Then open a terminal on your computer and type: (the dot at the end means in the current directory)
git clone https://your-forked-repo-name .
git checkout -b lineage-15.1
git push --all
Now the new branch is pushed on your GitHub repo. (Do this for all forked repo’s)
Now we must “tell” the build system we want our forked repo’s synced and included in the build.
Create a file in /srv/local_manifests called roomservice.xml. Add your forked repo’s in this file like this: (Take a close look at the vendor and device code name in the path variables. They must match your’s.)
Set the correct device code and branch in the build script:
When you get “duplicate path” errors, then remove the duplicate in /srv/src/OREO/.repo/local_manifests/proprietary.xml.
And edit the build script:
Now everything is set, and you can run the build script. Hopefully it goes well. As said before a ton of things can go wrong.