Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.debian.kernel > #67196
| From | Helge Deller <deller@gmx.de> |
|---|---|
| Newsgroups | linux.debian.bugs.dist, linux.debian.kernel |
| Subject | Bug#959768: [PATCH] initramfs-tools/hook-functions: Fix libgcc_s.so.1 dependency |
| Date | 2020-05-28 00:20 +0200 |
| Message-ID | <AbcyZ-4l1-1@gated-at.bofh.it> (permalink) |
| References | <A2Y09-4e1-1@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
Cross-posted to 2 groups.
Due to Debian bug #950254 the hook-functions copies libgcc_s.so.1 into
the initramfs image. But this breaks architectures which ship other
versions of libgcc_s, e.g. hppa (libgcc_s.so.4) or m68k (libgcc_s.so.2).
Fix it by searching the relevant libgcc_so files.
The fix is modelled after the btrfs hook functions in
/usr/share/initramfs-tools/hooks/btrfs.
Tested on hppa.
Signed-off-by: Helge Deller <deller@gmx.de>
Noticed-by: John Paul Adrian Glaubitz <glaubitz@physik.fu-berlin.de>
Bug: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=959768
Fixes: f2ac13e8881f ("hook-functions: copy_exec: Copy libgcc_s.so.0 along with libpthread.so")
diff -up ./hook-functions.org ./hook-functions
--- ./hook-functions.org 2020-05-27 21:57:26.994595173 +0000
+++ ./hook-functions 2020-05-27 21:57:30.182574623 +0000
@@ -182,7 +182,7 @@ copy_file() {
# Location of the image dir is assumed to be $DESTDIR
# We never overwrite the target if it exists.
copy_exec() {
- local src target x nonoptlib ret
+ local src target x nonoptlib ret libgcc
src="${1}"
target="${2:-$1}"
@@ -209,7 +209,10 @@ copy_exec() {
# Handle common dlopen() dependency (Debian bug #950254)
case "${x}" in
*/libpthread.so.*)
- copy_exec "${x%/*}/libgcc_s.so.1" || return
+ LIBC_DIR=$(dirname "${x}")
+ find -L "$LIBC_DIR" -maxdepth 1 -name 'libgcc_s.*' -type f | while read -r libgcc; do
+ copy_exec "${libgcc}" || return
+ done
;;
esac
Back to linux.debian.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Bug#959768: initramfs-tools: Does not account for different so versions of libgcc_s John Paul Adrian Glaubitz <glaubitz@physik.fu-berlin.de> - 2020-05-05 07:10 +0200 Processed: Re: Bug#959768: initramfs-tools: Does not account for different so versions of libgcc_s "Debian Bug Tracking System" <owner@bugs.debian.org> - 2020-05-14 08:30 +0200 Bug#959768: [PATCH] initramfs-tools/hook-functions: Fix libgcc_s.so.1 dependency Helge Deller <deller@gmx.de> - 2020-05-28 00:20 +0200 Bug#959768: [PATCH] initramfs-tools/hook-functions: Fix libgcc_s.so.1 dependency Ben Hutchings <ben@decadent.org.uk> - 2020-06-11 15:00 +0200 Bug#959768: marked as done (initramfs-tools: Does not account for different so versions of libgcc_s) "Debian Bug Tracking System" <owner@bugs.debian.org> - 2020-09-11 22:40 +0200
csiph-web