From 1e93d7555fe898400980b29987036a83331e0eaa Mon Sep 17 00:00:00 2001 From: Steve Sakoman Date: Thu, 21 Nov 2024 08:55:14 -0800 Subject: llvm: reduce size of -dbg package Unless DEBUG_BUILD is enabled, pass -g1 to massively reduce the size of the debug symbols Level 1 produces minimal information, enough for making backtraces in parts of the program that you don't plan to debug. This includes descriptions of functions and external variables, and line number tables, but no information about local variables. This makes the sstate objects a lot more manageable, and packaging faster. (From OE-Core rev: dac630ab5ee7aa6c5c7c294093adbd11b116c765) Signed-off-by: Steve Sakoman --- meta/recipes-devtools/llvm/llvm_18.1.6.bb | 2 ++ 1 file changed, 2 insertions(+) (limited to 'meta/recipes-devtools') diff --git a/meta/recipes-devtools/llvm/llvm_18.1.6.bb b/meta/recipes-devtools/llvm/llvm_18.1.6.bb index 0496b8ed14..caad611d7a 100644 --- a/meta/recipes-devtools/llvm/llvm_18.1.6.bb +++ b/meta/recipes-devtools/llvm/llvm_18.1.6.bb @@ -93,6 +93,8 @@ EXTRA_OECMAKE:append:class-nativesdk = "\ -DLLVM_TABLEGEN=${STAGING_BINDIR_NATIVE}/llvm-tblgen${PV} \ -DLLVM_CONFIG_PATH=${STAGING_BINDIR_NATIVE}/llvm-config${PV} \ " +# Unless DEBUG_BUILD is enabled, pass -g1 to massively reduce the size of the debug symbols +DEBUG_FLAGS:append = "${@oe.utils.vartrue('DEBUG_BUILD', '', ' -g1', d)}" # patch out build host paths for reproducibility do_compile:prepend:class-target() { -- cgit v1.2.3-54-g00ecf