-
-
Save DarkevilPT/a7be7d5f6dd57bb893c1d93403176cf4 to your computer and use it in GitHub Desktop.
Script snippet for building ChromeOS Crostini/Termina kernel
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
RELEASE=release-R114-15437.B-chromeos-5.10 | |
LLVM_VERSION=18 | |
curl -L https://apt.llvm.org/llvm.sh | sudo bash -s "${LLVM_VERSION}" | |
for f in clang clang++ ld.lld llvm-objdump llvm-ar llvm-nm llvm-strip llvm-objcopy llvm-readelf; do | |
sudo ln -sf $f-$LLVM_VERSION /usr/bin/$f | |
done | |
git clone https://chromium.googlesource.com/chromiumos/third_party/kernel.git -b ${RELEASE} --depth=1 | |
cd kernel | |
CHROMEOS_KERNEL_FAMILY=termina ./chromeos/scripts/prepareconfig container-vm-aarch64 | |
make LLVM=1 LLVM_IAS=1 olddefconfig | |
make LLVM=1 LLVM_IAS=1 menuconfig | |
make LLVM=1 LLVM_IAS=1 bzImage -j8 | |
make LLVM=1 LLVM_IAS=1 INSTALL_MOD_PATH="$PWD/out-modules" modules -j$(nproc) | |
make LLVM=1 LLVM_IAS=1 INSTALL_MOD_PATH="$PWD/out-modules" modules_install | |
sudo apt install rsync | |
make LLVM=1 LLVM_IAS=1 INSTALL_HDR_PATH="$PWD/out-headers" headers_install |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment