#!/bin/bash # Final ship candidate: closure pack + wave 4 deblob + hardened_malloc (2 GiB regions). # Compiles libc first; full bacon runs only if that link succeeds. # AVB flags 0 (Magisk track). Queue after any in-flight ninja on the same out/. set -e export AXP_AVB_FLAGS=0 export WITH_AVB=true export AXP_DEBLOB_WAVE4=1 cd /srv/rom/src/lineage export HOME=/home/android-build export CCACHE_DIR=/srv/rom/ccache export USE_CCACHE=1 export PATH=/home/android-build/bin:/usr/local/bin:/usr/bin:/bin:$PATH unset OUT_DIR || true python3 vendor/sunfish-a16/patches/012-hardened-malloc/apply_012_hardened_malloc.py grep -q 'SUNFISH_A16_012_HARDENED_MALLOC' bionic/libc/Android.bp grep -q 'libhardened_malloc' bionic/libc/Android.bp grep -q 'CONFIG_CLASS_REGION_SIZE=2147483648' external/hardened_malloc/Android.bp grep -A1 '__attribute__((noinline))$' bionic/libc/bionic/libc_init_dynamic.cpp | grep -q '__libc_preinit_impl' test -f external/hardened_malloc/h_malloc.c set +u # shellcheck disable=SC1091 source build/envsetup.sh set -e export PRODUCT_DEFAULT_DEV_CERTIFICATE=vendor/lineage-priv/keys/releasekey breakfast sunfish user echo "=== m libc $(date -Is) ===" m libc -j8 echo "=== libc ok, starting bacon $(date -Is) ===" # Same tree as this file (do not depend on a stale copy under artifacts/bin). exec bash "$(cd "$(dirname "$0")" && pwd)/009-bacon-axp-stage1-combo4-cve-hi-releasekeys.sh"