Remove .symtab from libc.so.6 again (#1965374)
Apparently, debugedit changes the build ID, so the separated debuginfo no longer matches the specially crafted copy of libc.so.6 with its minimal .symtab.
This commit is contained in:
parent
b5405a57ad
commit
654f636b32
@ -97,7 +97,7 @@
|
|||||||
Summary: The GNU libc libraries
|
Summary: The GNU libc libraries
|
||||||
Name: glibc
|
Name: glibc
|
||||||
Version: %{glibcversion}
|
Version: %{glibcversion}
|
||||||
Release: 19%{?dist}
|
Release: 20%{?dist}
|
||||||
|
|
||||||
# In general, GPLv2+ is used by programs, LGPLv2+ is used for
|
# In general, GPLv2+ is used by programs, LGPLv2+ is used for
|
||||||
# libraries.
|
# libraries.
|
||||||
@ -2184,6 +2184,9 @@ fi
|
|||||||
%files -f compat-libpthread-nonshared.filelist -n compat-libpthread-nonshared
|
%files -f compat-libpthread-nonshared.filelist -n compat-libpthread-nonshared
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Thu Jun 17 2021 Florian Weimer <fweimer@redhat.com> - 2.33.9000-20
|
||||||
|
- Remove .symtab from libc.so.6 again (#1965374)
|
||||||
|
|
||||||
* Thu Jun 17 2021 Florian Weimer <fweimer@redhat.com> - 2.33.9000-19
|
* Thu Jun 17 2021 Florian Weimer <fweimer@redhat.com> - 2.33.9000-19
|
||||||
- Drop glibc-rh697421.patch: The ISO-10646-UCS-2// alias for UTF-8 is incorrect
|
- Drop glibc-rh697421.patch: The ISO-10646-UCS-2// alias for UTF-8 is incorrect
|
||||||
(#1972520)
|
(#1972520)
|
||||||
|
@ -9,14 +9,10 @@
|
|||||||
# LDSO-PATH file, followed by note merging and DWZ compression.
|
# LDSO-PATH file, followed by note merging and DWZ compression.
|
||||||
# As a result, ld.so has (mostly) unchanged debuginfo even
|
# As a result, ld.so has (mostly) unchanged debuginfo even
|
||||||
# after debuginfo extraction.
|
# after debuginfo extraction.
|
||||||
#
|
|
||||||
# For libc.so.6, a set of strategic symbols is preserved in .symtab
|
|
||||||
# that are frequently used in valgrind suppressions.
|
|
||||||
|
|
||||||
set -ex
|
set -ex
|
||||||
|
|
||||||
ldso_tmp="$(mktemp)"
|
ldso_tmp="$(mktemp)"
|
||||||
libc_tmp="$(mktemp)"
|
|
||||||
|
|
||||||
# Prefer a separately installed debugedit over the RPM-integrated one.
|
# Prefer a separately installed debugedit over the RPM-integrated one.
|
||||||
if command -v debugedit >/dev/null ; then
|
if command -v debugedit >/dev/null ; then
|
||||||
@ -26,7 +22,7 @@ else
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
cleanup () {
|
cleanup () {
|
||||||
rm -f "$ldso_tmp" "$libc_tmp"
|
rm -f "$ldso_tmp"
|
||||||
}
|
}
|
||||||
trap cleanup 0
|
trap cleanup 0
|
||||||
|
|
||||||
@ -47,50 +43,21 @@ for ldso_candidate in `find "$sysroot_path" -regextype posix-extended \
|
|||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
|
|
||||||
# libc.so.6 always uses this name, so it is simpler to locate.
|
# Preserve the original file.
|
||||||
libc_path=
|
|
||||||
for libc_candidate in `find "$sysroot_path" -name libc.so.6`; do
|
|
||||||
if test -z "$libc_path" ; then
|
|
||||||
libc_path="$libc_candidate"
|
|
||||||
else
|
|
||||||
echo "error: multiple libc.so.6 candidates: $libc_path, $libc_candidate"
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
done
|
|
||||||
|
|
||||||
|
|
||||||
# Preserve the original files.
|
|
||||||
cp "$ldso_path" "$ldso_tmp"
|
cp "$ldso_path" "$ldso_tmp"
|
||||||
cp "$libc_path" "$libc_tmp"
|
|
||||||
|
|
||||||
# Run the debuginfo extraction.
|
# Run the debuginfo extraction.
|
||||||
"$script_path" "$@"
|
"$script_path" "$@"
|
||||||
|
|
||||||
# Restore the original files.
|
# Restore the original file.
|
||||||
cp "$ldso_tmp" "$ldso_path"
|
cp "$ldso_tmp" "$ldso_path"
|
||||||
cp "$libc_tmp" "$libc_path"
|
|
||||||
|
|
||||||
# Reduce the size of notes. Primarily for annobin.
|
# Reduce the size of notes. Primarily for annobin.
|
||||||
objcopy --merge-notes "$ldso_path"
|
objcopy --merge-notes "$ldso_path"
|
||||||
objcopy --merge-notes "$libc_path"
|
|
||||||
|
|
||||||
# libc.so.6: Reduce to strategic symbols needed by valgrind.
|
# Rewrite the source file paths to match the extracted locations.
|
||||||
# (Debuginfo is gone after this, so no need to optimize it.)
|
# First compute the arguments for invoking debugedit. See
|
||||||
strip -w \
|
# find-debuginfo.sh.
|
||||||
-K '*vfprintf*' \
|
|
||||||
-K '__bzero*' \
|
|
||||||
-K '__mem*' \
|
|
||||||
-K '__rawmemchr*' \
|
|
||||||
-K '__stp*' \
|
|
||||||
-K '__str*' \
|
|
||||||
-K '__wcs*' \
|
|
||||||
-K '__wmem*' \
|
|
||||||
-K '_nl_make_l10nflist' \
|
|
||||||
"$libc_path"
|
|
||||||
|
|
||||||
# ld.so: Rewrite the source file paths to match the extracted
|
|
||||||
# locations. First compute the arguments for invoking debugedit.
|
|
||||||
# See find-debuginfo.sh.
|
|
||||||
debug_dest_name="/usr/src/debug"
|
debug_dest_name="/usr/src/debug"
|
||||||
last_arg=
|
last_arg=
|
||||||
while true ; do
|
while true ; do
|
||||||
|
Loading…
Reference in New Issue
Block a user