3
0
forked from pool/debugedit

Accepting request 1001121 from home:AndreasStieger:branches:Base:System

- finddebuginfo.patch: convert obsolete egrep to grep -E
  (boo#1203092)

OBS-URL: https://build.opensuse.org/request/show/1001121
OBS-URL: https://build.opensuse.org/package/show/Base:System/debugedit?expand=0&rev=7
This commit is contained in:
Dirk Mueller 2022-09-12 07:39:01 +00:00 committed by Git OBS Bridge
parent 9b56e7910b
commit dc461577f4
2 changed files with 15 additions and 7 deletions

View File

@ -1,3 +1,9 @@
-------------------------------------------------------------------
Sun Sep 4 10:29:29 UTC 2022 - Andreas Stieger <andreas.stieger@gmx.de>
- finddebuginfo.patch: convert obsolete egrep to grep -E
(boo#1203092)
-------------------------------------------------------------------
Wed Jul 6 12:43:49 UTC 2022 - Ludwig Nussel <lnussel@suse.de>

View File

@ -1,6 +1,8 @@
--- ./scripts/find-debuginfo.in.orig 2019-09-09 07:56:53.377788842 +0000
+++ ./scripts/find-debuginfo.in 2019-10-02 11:11:56.878979662 +0000
@@ -348,12 +348,18 @@ trap 'rm -rf "$temp"' EXIT
Index: scripts/find-debuginfo.in
===================================================================
--- scripts/find-debuginfo.in.orig
+++ scripts/find-debuginfo.in
@@ -412,12 +412,18 @@ trap 'rm -rf "$temp"' EXIT
# Build a list of unstripped ELF files and their hardlinks
touch "$temp/primary"
@ -12,7 +14,7 @@
+find "$RPM_BUILD_ROOT" ! -path "${debugdir}/*.debug" -type f \( -perm /111 -or -name "*.so*" -or -name "*.ko" \) ! -name "*.a" -print0 | LC_ALL=C sort -z |
+xargs --no-run-if-empty -0 stat -c '%h %D_%i %n' |
while read nlinks inum f; do
+ case $(objdump -h $f 2>/dev/null | egrep -o '(debug[\.a-z_]*|gnu.version)') in
+ case $(objdump -h $f 2>/dev/null | grep -E -o '(debug[\.a-z_]*|gnu.version)') in
+ *debuglink*) continue ;;
+ *debug*) ;;
+ *gnu.version*)
@ -24,7 +26,7 @@
if [ $nlinks -gt 1 ]; then
var=seen_$inum
if test -n "${!var}"; then
@@ -386,6 +392,8 @@ do_file()
@@ -450,6 +456,8 @@ do_file()
if [ "$no_recompute_build_id" = "true" ]; then
no_recompute="-n"
fi
@ -33,7 +35,7 @@
id=$(${install_dir}/debugedit -b "$debug_base_name" -d "$debug_dest_name" \
$no_recompute -i \
${build_id_seed:+--build-id-seed="$build_id_seed"} \
@@ -413,17 +421,30 @@ do_file()
@@ -477,17 +485,30 @@ do_file()
# just has its file names collected and adjusted.
case "$dn" in
/usr/lib/debug/*)
@ -71,7 +73,7 @@
# strip -g implies we have full symtab, don't add mini symtab in that case.
# It only makes sense to add a minisymtab for executables and shared
@@ -581,12 +602,14 @@ if [ -s "$SOURCEFILE" ]; then
@@ -646,12 +667,14 @@ if [ -s "$SOURCEFILE" ]; then
# and non-standard modes may be inherented from original directories, fixup
find "${RPM_BUILD_ROOT}${debug_dest_name}" -type d -print0 |
xargs --no-run-if-empty -0 chmod 0755