[debhelper-devel] [debhelper] 01/02: dh_makeshlibs: Use qx_cmd in c11

Niels Thykier nthykier at moszumanska.debian.org
Sun Aug 6 14:57:54 UTC 2017


This is an automated email from the git hooks/post-receive script.

nthykier pushed a commit to branch master
in repository debhelper.

commit 128e320297653e52bf7c9e9085ff65e66544c22a
Author: Niels Thykier <niels at thykier.net>
Date:   Sun Aug 6 12:19:32 2017 +0000

    dh_makeshlibs: Use qx_cmd in c11
    
    Signed-off-by: Niels Thykier <niels at thykier.net>
---
 debhelper.pod    | 5 +++++
 debian/changelog | 3 ++-
 dh_makeshlibs    | 2 +-
 3 files changed, 8 insertions(+), 2 deletions(-)

diff --git a/debhelper.pod b/debhelper.pod
index 54142da..df36335 100644
--- a/debhelper.pod
+++ b/debhelper.pod
@@ -698,6 +698,11 @@ helpers that rely on the bug to fail with an error.
 In compatibility 11, there is still a detection for this case.  This
 detection will be removed in compatibility level 12.
 
+=item -
+
+The B<dh_makeshlibs> helper will now exit with an error if objdump
+returns failure code from analysing objdump.
+
 =back
 
 =back
diff --git a/debian/changelog b/debian/changelog
index 1a1e4fb..df7cefa 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -2,7 +2,8 @@ debhelper (10.7.3) UNRELEASED; urgency=medium
 
   * Dh_Lib: Introduce a qx_cmd sub to behave like a mix of qx
     and doit (i.e. avoid the shell while capturing stdout).
-  * dh_makeshlibs: Avoid forking a shell when calling objdump.
+  * dh_makeshlibs: Avoid forking a shell when calling objdump in
+    compat 11.
   * dh_shlibdeps: Avoid forking a shell when calling file.
   * dh_shlibdeps: Avoid passing files with "newline" to
     subprocesses.
diff --git a/dh_makeshlibs b/dh_makeshlibs
index 3def321..1ec7ba6 100755
--- a/dh_makeshlibs
+++ b/dh_makeshlibs
@@ -169,7 +169,7 @@ foreach my $package (@{$dh{DOPACKAGES}}) {
 		my ($library, $major);
 		chomp;
 		push @lib_files, $_;
-		my $ret=qx_cmd($objdump, '-p', $_);
+		my $ret = compat(10) ? `$objdump -p "$_"` : qx_cmd($objdump, '-p', $_);
 		if ($ret=~m/\s+SONAME\s+(.*)\.so\.(.*)/) {
 			# proper soname format
 			$library=$1;

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debhelper/debhelper.git




More information about the debhelper-devel mailing list