From: Raphael Hertzog Date: Sat, 8 Dec 2007 20:50:28 +0000 (+0100) Subject: dpkg-shlibdeps.pl: doesn't warn any more about libm.so.6 being unused X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=deaf2e577ca577e89fc2afa31a7d771f310ef246;p=dpkg dpkg-shlibdeps.pl: doesn't warn any more about libm.so.6 being unused If the binary is also linked against libstdc++, the warning is suppressed since g++ always add an implicit -lm. --- diff --git a/ChangeLog b/ChangeLog index b3fb1476..ff9e8507 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2007-12-08 Raphael Hertzog + + * scripts/dpkg-shlibdeps.pl: Doesn't warn any more about libm.so.6 + being unused if the binary is also linked against libstdc++ since + g++ always add an implicit -lm. + 2007-12-08 Raphael Hertzog * scripts/Dpkg/Shlibs.pm (find_library): When it finds a library diff --git a/debian/changelog b/debian/changelog index aa336b2d..54d55a37 100644 --- a/debian/changelog +++ b/debian/changelog @@ -21,6 +21,9 @@ dpkg (1.14.13) UNRELEASED; urgency=low * When dpkg-shlibdeps finds a lib in a directory which is just a symlink to another directory that is also considered, remember the other directory name as the canonical one. Closes: #453885 + * dpkg-shlibdeps doesn't warn any more about libm.so.6 being unused if the + binary is also linked against libstdc++ since g++ always add an implicit + -lm. Closes: #454616 [ Updated man pages translations ] * Swedish (Peter Karlsson) diff --git a/scripts/dpkg-shlibdeps.pl b/scripts/dpkg-shlibdeps.pl index ad88e7e3..c26b7a3b 100755 --- a/scripts/dpkg-shlibdeps.pl +++ b/scripts/dpkg-shlibdeps.pl @@ -255,6 +255,9 @@ foreach my $file (keys %exec) { # Warn about un-NEEDED libraries foreach my $soname (@sonames) { unless ($soname_notfound{$soname} or $used_sonames{$soname}) { + # Ignore warning for libm.so.6 if also linked against libstdc++ + next if ($soname =~ /^libm\.so\.\d+$/ and + scalar grep(/^libstdc\+\+\.so\.\d+/, @sonames)); warning(_g("%s shouldn't be linked with %s (it uses none of its " . "symbols)."), $file, $soname); }