Merge ~mwhudson/finalrd:better-lib-detection into finalrd:master

Proposed by Michael Hudson-Doyle
Status: Merged
Merged at revision: f203066af54204e452c4c8a531ff02d6c2893dcb
Proposed branch: ~mwhudson/finalrd:better-lib-detection
Merge into: finalrd:master
Diff against target: 32 lines (+7/-2)
2 files modified
debian/changelog (+6/-0)
finalrd.sh (+1/-2)
Reviewer Review Type Date Requested Status
Steve Langasek Approve
Review via email: mp+406339@code.launchpad.net

Commit message

 finalrd (8) UNRELEASED; urgency=medium
 .
   * Improve library detection in finalrd.sh.

Description of the change

Turns out accidentally testing my glibc snapshot found something.

To post a comment you must log in.
Revision history for this message
Steve Langasek (vorlon) :
review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1diff --git a/debian/changelog b/debian/changelog
2index 5d560d5..85920d4 100644
3--- a/debian/changelog
4+++ b/debian/changelog
5@@ -1,3 +1,9 @@
6+finalrd (8) UNRELEASED; urgency=medium
7+
8+ * Improve library detection in finalrd.sh.
9+
10+ -- Michael Hudson-Doyle <michael.hudson@ubuntu.com> Thu, 29 Jul 2021 12:45:27 +1200
11+
12 finalrd (7) hirsute; urgency=medium
13
14 * Drop build-dependency on obsolete dh-systemd
15diff --git a/finalrd.sh b/finalrd.sh
16index cffa94b..f623f8c 100755
17--- a/finalrd.sh
18+++ b/finalrd.sh
19@@ -25,12 +25,11 @@ mount -o remount,exec /run
20 # our shutdown sequence is to be controled by systemd-shutdown which
21 # will unmount all the things, and run our hooks
22
23-LD=`grep -Eow '/.*ld-.*.so' /proc/self/maps | head -1`
24 for bin in /bin/sh /lib/systemd/systemd-shutdown
25 do
26 rm -f /run/finalrd-libs.conf
27 touch /run/finalrd-libs.conf
28- for lib in `$LD --list $bin | grep -Eow "/.* "`
29+ for lib in `LD_TRACE_LOADED_OBJECTS=1 $bin | grep -Eow "/.* "`
30 do
31 if [ "$lib" = '=>' ]
32 then

Subscribers

People subscribed via source and target branches