Build LineageOS
This page is about building LineageOS for your mobile device of choice using a Gentoo PC as build-host.
If you want to build Gentoo linux to run on an Android device you can refer to this wiki page.
Gentoo forums post are my source: this one
There are the official LineageOS instructions. The following notes are the changes you need to do on your Gentoo system to be able to build instead of using Ubuntu.
Packages needed
Emerge the following:
#lineage app-arch/lz4 app-arch/lzop media-gfx/imagemagick media-gfx/pngcrush #aosp app-crypt/gnupg app-arch/zip[-natspec] app-arch/unzip dev-libs/libxslt dev-libs/libxml2 dev-util/android-tools dev-util/ccache dev-util/gperf dev-vcs/git media-libs/libsdl media-libs/mesa net-misc/curl net-misc/rsync sys-devel/bc sys-devel/bison sys-devel/flex sys-devel/gcc[cxx] sys-libs/ncurses[abi_x86_32] sys-libs/ncurses-compat[abi_x86_32] sys-libs/readline[abi_x86_32] sys-libs/zlib[abi_x86_32] sys-process/schedtool sys-fs/squashfs-tools x11-base/xorg-proto x11-libs/libX11 x11-libs/wxGTK:3.0
Settings before building
Unset the following before building:
unset JAVAC unset JAVA_HOME unset JDK_HOME unset LEX