]> git.ipfire.org Git - thirdparty/dracut.git/commitdiff
dracut.sh: add libgcc_s, if libpthread is installed
authorHarald Hoyer <harald@redhat.com>
Fri, 20 Jun 2014 09:19:49 +0000 (11:19 +0200)
committerHarald Hoyer <harald@redhat.com>
Fri, 20 Jun 2014 09:19:49 +0000 (11:19 +0200)
workaround the fact, that pthread_cancel() wants to
dlopen libgcc_s.so.1

dracut.sh

index c4163bcfeca40b5a78cfcff0c215924c34ffe0a6..04bb3398a3f93e6564d5f832c1109d1bf8ce9fd7 100755 (executable)
--- a/dracut.sh
+++ b/dracut.sh
@@ -1348,6 +1348,15 @@ if [[ $kernel_only != yes ]]; then
         | xargs -r -0 $DRACUT_INSTALL ${initdir:+-D "$initdir"} -R ${DRACUT_FIPS_MODE:+-H} --
         dinfo "*** Resolving executable dependencies done***"
     fi
+
+    # libpthread workaround: pthread_cancel wants to dlopen libgcc_s.so
+    for _dir in $libdirs; do
+        for _f in "$_dir/libpthread.so"*; do
+            [[ -e "$_f" ]] || continue
+            inst_libdir_file "libgcc_s.so*"
+            break 2
+        done
+    done
 fi
 
 while pop include_src src && pop include_target tgt; do