Add valgrind-3.17.0-debuginfod.patch

This commit is contained in:
Mark Wielaard 2021-06-03 11:24:45 +02:00
parent 24ec9a0480
commit f0e9e494f7
2 changed files with 36 additions and 1 deletions

View File

@ -0,0 +1,30 @@
commit 93104368952c37268da724231487058ea3eaf1dc
Author: Tom Hughes <tom@compton.nu>
Date: Thu May 20 17:16:06 2021 +0100
Don't look for separate debuginfo if the image has a .debug_info section
Fixes BZ#435908
diff --git a/coregrind/m_debuginfo/readelf.c b/coregrind/m_debuginfo/readelf.c
index b0f062ddc..e424e3e7e 100644
--- a/coregrind/m_debuginfo/readelf.c
+++ b/coregrind/m_debuginfo/readelf.c
@@ -2879,13 +2879,15 @@ Bool ML_(read_elf_debug_info) ( struct _DebugInfo* di )
/* Look for a build-id */
HChar* buildid = find_buildid(mimg, False, False);
- /* Look for a debug image that matches either the build-id or
+ /* If we don't have a .debug_info section in the main image then
+ look for a debug image that matches either the build-id or
the debuglink-CRC32 in the main image. If the main image
doesn't contain either of those then this won't even bother
to try looking. This looks in all known places, including
the --extra-debuginfo-path if specified and on the
--debuginfo-server if specified. */
- if (buildid != NULL || debuglink_escn.img != NULL) {
+ if (debug_info_escn.img == NULL &&
+ (buildid != NULL || debuglink_escn.img != NULL)) {
/* Do have a debuglink section? */
if (debuglink_escn.img != NULL) {
UInt crc_offset

View File

@ -110,6 +110,9 @@ Patch7: valgrind-3.17.0-ppc64-isa-3.1-tests.patch
# s390x: Add missing UNOP insns to s390_insn_as_string # s390x: Add missing UNOP insns to s390_insn_as_string
Patch8: valgrind-3.17.0-s390_insn_as_string.patch Patch8: valgrind-3.17.0-s390_insn_as_string.patch
# KDE#435908 Don't look for separate debuginfo if image already has .debug_info
Patch9: valgrind-3.17.0-debuginfod.patch
BuildRequires: make BuildRequires: make
BuildRequires: glibc-devel BuildRequires: glibc-devel
@ -255,6 +258,7 @@ Valgrind User Manual for details.
%patch7 -p1 %patch7 -p1
%patch8 -p1 %patch8 -p1
%patch9 -p1
%build %build
# LTO triggers undefined symbols in valgrind. Valgrind has a --enable-lto # LTO triggers undefined symbols in valgrind. Valgrind has a --enable-lto
@ -480,8 +484,9 @@ fi
%endif %endif
%changelog %changelog
* Tue May 4 2021 Mark Wielaard <mjw@fedoraproject.org> * Thu Jun 3 2021 Mark Wielaard <mjw@fedoraproject.org>
- Add valgrind-3.17.0-s390_insn_as_string.patch - Add valgrind-3.17.0-s390_insn_as_string.patch
- Add valgrind-3.17.0-debuginfod.patch
* Tue May 4 2021 Mark Wielaard <mjw@fedoraproject.org> - 3.17.0-3 * Tue May 4 2021 Mark Wielaard <mjw@fedoraproject.org> - 3.17.0-3
- Add valgrind-3.17.0-ppc64-isa-3.1{,tests}.patch - Add valgrind-3.17.0-ppc64-isa-3.1{,tests}.patch