Gunwant Jain writes: > This week, I started managing the structure for the modified LineageOS > fork we would keep. Namely the modified `repo-manifest` [1] and > `llvm_android` [2], for now. No patches have been applied to them yet > for the reasons discussed below. > > My plan for this week was to start with patching the `llvm_android` > build scripts. Android uses a prebuilt Clang (bundled with the repo) > among other stuff to build the toolchain. So I had to emerge Clang on my > phone. > Emerging Clang turned out not to be a breeze when I have a phone with 3 > gigs of RAM. So for about the longest time, I was busy trying to make up > for it. I tried setting up distcc, increased swap/zram, but still the > OOM killer got me. > Later last night(/day), I came across the tips for building clang/gcc in > an embedded Android environment at [3]. So I followed that and as of > now, me writing the mail, OOM has not got me, Clang is emerging. Did it finally go through? > While I considering the patching part easy, I guess the major bottleneck > in the process of building Android natively would be the compilation. > Essentially I will have to trade time for memory. I will also give > another shot to distcc while I am at this. > > Regardless of problems I faced, I made "TODO" comments in the source and > wrote notes about where to patch the build scripts locally. I avidly > wait for Clang to compile and then start testing the patched build > script. Yes, the compilers are the biggest burden of the building process. You will be facing both the RAM and disk space shortages. Luckily the HPC industry is testing out the arm64 architecture. We could bet our luck with the more powerful arm64 servers. Benda > [1] https://github.com/WantGuns/manifest > [2] https://github.com/WantGuns/toolchain_llvm_android > [3] https://wiki.gentoo.org/wiki/Project:Android/tarball#Out_of_Memory