overlay profiles: Don't complain when rm_masked_debug_files does nothing

Signed-off-by: James Le Cuirot <jlecuirot@microsoft.com>
This commit is contained in:
James Le Cuirot 2026-04-15 16:50:23 +01:00
parent ad886d8959
commit d85bbc31a1
No known key found for this signature in database
GPG Key ID: 1226415D00DD3137

View File

@ -128,7 +128,7 @@ cros_pre_pkg_setup_sysroot_build_bin_dir() {
# and also remove their associated debug files to avoid wasting space.
cros_post_pkg_preinst_rm_masked_debug_files() {
local link debug dir=${ED}/usr/lib/debug
[[ -d ${dir}/.build-id ]] || return
[[ -d ${dir}/.build-id ]] || return 0
while read -d $'\n' -r link; do
debug=$(realpath "${link}.debug") || die
rm -f -- "${link}" "${link}.debug" "${debug}" || die