[Guide] Easily Build and Install LineageOS 17.1 with or without Gapps replacement

barqs_root

Member
Apr 9, 2020
7
0
0
Salt Lake City
Try some different things

The steps I followed were roughly this:
Flash factory image (QQ2A.200305.002, Mar 2020)
Boot up, enable developer settings, usb debugging, etc.
Reboot into bootloader/fastboot
DON'T erase/wipe user data DON'T specify boot_a or boot_b
fastboot flash boot boot.img
adb sideload lineage-17.1*.zip
It took me a few tries to get this and I'm going off memory here.
Just keep trying you should get it.
If needed I can also upload a ZIP of my build.
 

swagglepuff

Senior Member
Jul 3, 2016
174
35
0
The steps I followed were roughly this:
Flash factory image (QQ2A.200305.002, Mar 2020)
Boot up, enable developer settings, usb debugging, etc.
Reboot into bootloader/fastboot
DON'T erase/wipe user data DON'T specify boot_a or boot_b
fastboot flash boot boot.img
adb sideload lineage-17.1*.zip
It took me a few tries to get this and I'm going off memory here.
Just keep trying you should get it.
If needed I can also upload a ZIP of my build.
Was able to get it installed! Now the phone has been booting for 45 minutes. What was your initial boot time after install?
 

swagglepuff

Senior Member
Jul 3, 2016
174
35
0
Dang. Sorry to hear it.
My boot time was very quick, definitely faster than the factory image maybe 60-120 seconds. Try rebooting a few times and re flashing. If you have issues I'll upload my build.
This thing is booting at all. Even flashing the march update and no such luck. If you want to upload your image that would be awesome. I am in no place to build it my self with my current setup.

Edit: gave it one last go before be on the april firmware and son of ***** it actually worked this time. About crapped my pants when the windows sound for a device plugging in went off lol.
 
Last edited:

reini_from_nl

New member
Sep 30, 2019
1
0
0
Hi,
i followed the easy way and on this point:
Code:
docker build --tag solidhal/docker-lineage-cicd .
I got this Error:
Code:
 Cloning into 'OpenDelta'...
fatal: could not read Username for 'https://github.com': No such device or address.
Does anyone have a idea wy this happens?
 

ptn107

Senior Member
Feb 10, 2012
249
123
0
Hi,
i followed the easy way and on this point:
Code:
docker build --tag solidhal/docker-lineage-cicd .
I got this Error:
Code:
 Cloning into 'OpenDelta'...
fatal: could not read Username for 'https://github.com': No such device or address.
Does anyone have a idea wy this happens?
I get the same error. It's because

android_packages_apps_OpenDelta

does not exist in

https://github.com/omnirom/

Its gone you can see here.

I don't know what to do now other than quit the docker way and try it the manual way this week.
 

gee one

Senior Member
Jul 29, 2010
1,979
865
0
linux command line
Hi,
i followed the easy way and on this point: I got this Error:

I get the same error. It's because

android_packages_apps_OpenDelta

does not exist in

https://github.com/omnirom/

Its gone you can see here.

I don't know what to do now other than quit the docker way and try it the manual way this week.
Are you building omni or lineage?

Never used docker, but maybe there are some leftovers in the fridge.
 

gee one

Senior Member
Jul 29, 2010
1,979
865
0
linux command line
Has anyone made a build with Gapps Pico? I don't have the hardware to make my own
You can build this on a VPS like linode, aws, or google cloud. Linode would probably be a few dollars to build, just be sure to delete the vps when you're done so you get charged any more.

I think google gives you a $300 credit when you sign up... That's plenty to build with.
 

blitzn0r

Member
Jan 26, 2019
7
1
0
I include gapps when I build the ROM. I have a vendor tree that is based off of opengapps pico. I just unpacked this pico zip and mimic'ed what it installed, plus something like pixel migration tool.
Hi could you explain how you mimic'ed what it installed? I'd like to compile lineage with minimal gapps and I'm currently stuck because I don't know how to include the gapps properly.
 

gee one

Senior Member
Jul 29, 2010
1,979
865
0
linux command line
Hi could you explain how you mimic'ed what it installed? I'd like to compile lineage with minimal gapps and I'm currently stuck because I don't know how to include the gapps properly.
Here's an example of how to do it. I think there is an remove packages option too.

The basic steps are download pico gapps, unpack it, create a tree with pico gapps using the structure in shag gapps. Modify for your use case.

https://gitlab.com/shagbag913/vendor_gapps

You could also just add this to your build, if you just want gapps.

I haven't actually used this particular repo, but it'll at least give you some hints.
 

tekhedd

New member
Jan 7, 2014
3
3
0
Easy way comments

Thanks for this heads-up. So hard to find 3a-specific builds, lots of 3aXL builds but ... I'm also a huge fan of Deja-Vu Location service so everything here is apropos.

Build fails hard using the docker build.

First: I assume this error is normal, as it is ignored by the build:

Code:
build/make/core/product_config.mk:223: error: Can not locate config makefile for product "lineage_sargo".
Second: before.sh (I would recommend adding set-e to the top, but it doesn't matter, because the docker build doesn't check the return status of before.sh :eek: ).

Some of the cherry-picks appear to have been merged. The HBM patch cherrypick fails, merged on May 14 (hooray!) Can probably be removed? commit e3b20082e9d797bcff286311637669377f16e55a

The bonito RRO bluetooth patch was also merged: commit 28ba61337f05866d52f84167fcb50156477994a1, probably also hooray?

The CONFIG_HZ patch... cherrypicks but does not appear in the commit history. git is such a labyrinth of features I'm pretty sure I just don't understand how to use it. But at least that appears to merge without problems.

[edit] I have submitted a ticket in github for this.

Note: My builds were failing because of a leftover docker process. Beware! The docker build process does not respond to command line ctrl-c; if you want to kill the build do a docker ps and kill the process.

[edit2] Swap!

I have 24G of ram and normally don't run swap; without swap, the build runs out of memory and oom-killer will eventually kill the build. (Suspect the compile is writing large numbers of tempfiles to "disk" or generating an enormous memory mapped file -- and in docker "disk" is RAM.) This is expected behavior, but I thought I'd mention it, in case anyone is trying the build based just on the instructions here. I added a swapfile and am still waiting to see if it needs to be larger--the build is currently using 19G and still climbing. This build is quite impressively memory-intensive!

[edit3] Success!

The build was successful, and yes took a very long time. It's up and running on my phone in slot a. I'm running a gapps-free setup (no microG) so of course the camera doesn't work, but the rest is absolutely great. Definitely recommend this method as long as you have a lot of CPU cores and a swap file. :>

[edit4] "Carrier Services keeps stopping"

Based on one Reddit conversation, this is not a bug in your build. Don't panic. This appears to be a bug with the carrier services APK currently bundled with LineageOS 17.1. In a no-google setup, going to the Play Store to update Carrier Services is not an option, and I'm not even sure if this will fix the issue. Appears to be a Pixel-specific problem with Lineage, not limited to just the 3a. Workaround: I disabled Carrier Services , and have not noticed any degraded functionality (T-Mo). However, I use Signal instead of Messaging, which may lose some MMS and rich-messaging features (maybe this is a benefit for some?); and, we will eventually need Carrier Services as it is intended to manage things like LTE, so this is not a permanent solution. YMMV.

Editorial note: Google is gradually moving things out of the Android core so you are dependent on their cloud services (Play store) for core features like Camera and Messaging. :p
 
Last edited:
  • Like
Reactions: kkjb

ur_blocked

New member
Jun 13, 2020
2
0
0
Oops i accidentally posted this already, but to the wrong thread >_<

I tried to build lineage for my phone (sargo) using the hard way instructions, but, sadly it did not build due to this:

Code:
FAILED: out/soong/.intermediates/system/netd/resolv/dnsresolver_aidl_interface-api/checkapi_2.timestamp (out/soong/host/linux-x86/bin/aidl --checkapi system/netd/resolv/aidl/dnsresolver/1 system/netd/resolv/aidl/dnsresolver/2 && touch out/soong/.intermediates/system/netd/resolv/dnsresolver_aidl_interface-api/checkapi_2.timestamp) || (cat system/tools/aidl/build/message_check_compatibility.txt && exit 1)
ERROR: system/netd/resolv/aidl/dnsresolver/1: No API file exist

ERROR: Backward incompatible change detected on AIDL API
Above AIDL file(s) has changed in a backward-incompatible way, e.g. removing a method from an interface or a field from a parcelable. If a device is shipped with this change by ignoring this message, it has a high risk of breaking later when a module using the interface is updated, e.g., Maineline modules.
I'm not clear on what the problem is; those files do exist at least:

Code:
$ tree system/netd/resolv/aidl/dnsresolver/ system/netd/resolv/aidl/dnsresolver/
├── 1
│   └── android
│       └── net
│           ├── IDnsResolver.aidl
│           └── ResolverParamsParcel.aidl
└── 2
    └── android
        └── net
            ├── IDnsResolver.aidl
            └── ResolverParamsParcel.aidl

6 directories, 4 files
However, I am not familiar with AIDL enough to know if they're supposed to be in a specific format or something; all I did was follow the directions.

Any clues what to do about this?
 

Pogo

Senior Member
Mar 19, 2007
126
42
0
If you include gapps in your build, the esim manager should stop crashing. If running gappless, I remove esim and hotword enrollment from the proprietary files.
I'm using this build since February and is rock solid and I am wondering do you or someone else on forum have some up to date build? My PC need more RAM for successful build and I have hard time finding right components :(. I prefer no Gapps or MicroG version, if possible.
 

gee one

Senior Member
Jul 29, 2010
1,979
865
0
linux command line
I'm using this build since February and is rock solid and I am wondering do you or someone else on forum have some up to date build? My PC need more RAM for successful build and I have hard time finding right components :(. I prefer no Gapps or MicroG version, if possible.
I switched to an aosp build recently, but before that, I was using lineage on a gappless build, and then a microg build.

I'll see about updating and pushing my repos. Probably after the July update and sources get pushed out.
 
  • Like
Reactions: kkjb

pauliusval99

Senior Member
Dec 4, 2011
112
25
28
Vilnius
The stock camera doesn't work at all in my build, but I found a Gcam port that works.
And I have a question: where does the rounded screen corners overlay come from? I don't think it comes from AOSP, as setting sysui_rounded_size in secure settings doesn't change anything. Is there a patch I can revert to remove the overlay?
And I know it won't remove the roundedness altogether, I just want to remove the overlay. I've already reduced the display height with "wm size" but the corners are still rounded.
 

sahim82

Member
Sep 9, 2017
19
7
0
failed to verify whole-file signature

Thank you for that great guide to build sargo!
I created the first build half easy docker build (which failed after some time) and "resuming" that build the hard way (brunch sargo). It works great.
Now i made a new build the hard way and it also build successfully .
But when i want to sideload the zip i get the error "
Code:
failed  to verify whole-file signature
". Installing anyway (there is a prompt) fails immediatelly with
Code:
Error applying update: 26 (ErrorCode:: kDownloadMetadataSignatureMismatch
Solution: the problem is that i did not sign the later build with the releasekey. Signing the build with the right keys should make sideloading possible
 
Last edited: