From 4c6fa526bfbde7e4f5750635d973f329eb57c49c Mon Sep 17 00:00:00 2001 From: Florian Weimer Date: Fri, 23 Sep 2022 10:01:28 +0200 Subject: [PATCH] Do not require .annobin symbols in wrap-find-debuginfo.sh --- wrap-find-debuginfo.sh | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/wrap-find-debuginfo.sh b/wrap-find-debuginfo.sh index 42b3609..d26f8eb 100644 --- a/wrap-find-debuginfo.sh +++ b/wrap-find-debuginfo.sh @@ -136,9 +136,10 @@ done debug_base_name=${last_arg:-$RPM_BUILD_ROOT} $debugedit -b "$debug_base_name" -d "$debug_dest_name" -n $ldso_path # Remove the .annobin* symbols (and only them). -nm --format=just-symbols "$ldso_path" \ - | grep '^\.annobin' > "$ldso_tmp.annobin-symbols" -objcopy --strip-symbols="$ldso_tmp.annobin-symbols" "$ldso_path" +if nm --format=just-symbols "$ldso_path" \ + | grep '^\.annobin' > "$ldso_tmp.annobin-symbols"; then + objcopy --strip-symbols="$ldso_tmp.annobin-symbols" "$ldso_path" +fi # Apply single-file DWARF optimization. dwz $ldso_path