Bug#454616: dpkg-dev: g++ links -lm by default, and dpkg-shlibdeps complains

2007-12-09 Thread Raphael Hertzog
On Thu, 06 Dec 2007, Colin Watson wrote:
> Perhaps dpkg-shlibdeps should ignore libm.so.6 for binaries also linked
> against libstdc++.so.*?

Yeah, I agree. A fix has been committed to the git repo.

Cheers,
-- 
Raphaël Hertzog

Le best-seller français mis à jour pour Debian Etch :
http://www.ouaza.com/livre/admin-debian/





Bug#454616: dpkg-dev: g++ links -lm by default, and dpkg-shlibdeps complains

2007-12-06 Thread Colin Watson
Package: dpkg-dev
Version: 1.14.12
Severity: normal

I spent a while trying to work out why I was seeing this in groff's
build:

  dpkg-shlibdeps: warning: debian/groff-base/usr/bin/eqn shouldn't be linked 
with libm.so.6 (it uses none of its symbols).
  dpkg-shlibdeps: warning: debian/groff-base/usr/bin/soelim shouldn't be linked 
with libm.so.6 (it uses none of its symbols).
  dpkg-shlibdeps: warning: debian/groff-base/usr/bin/tbl shouldn't be linked 
with libm.so.6 (it uses none of its symbols).
  dpkg-shlibdeps: warning: debian/groff/usr/bin/lookbib shouldn't be linked 
with libm.so.6 (it uses none of its symbols).
  dpkg-shlibdeps: warning: debian/groff/usr/bin/refer shouldn't be linked with 
libm.so.6 (it uses none of its symbols).
  dpkg-shlibdeps: warning: debian/groff/usr/bin/lkbib shouldn't be linked with 
libm.so.6 (it uses none of its symbols).
  dpkg-shlibdeps: warning: debian/groff/usr/bin/pfbtops shouldn't be linked 
with libm.so.6 (it uses none of its symbols).
  dpkg-shlibdeps: warning: debian/groff/usr/bin/addftinfo shouldn't be linked 
with libm.so.6 (it uses none of its symbols).
  dpkg-shlibdeps: warning: debian/groff/usr/bin/indxbib shouldn't be linked 
with libm.so.6 (it uses none of its symbols).

Yet the link line is:

  g++ -O2 -g -Wall  -o eqn eqn.o main.o lex.o box.o limit.o list.o over.o 
text.o script.o mark.o other.o delim.o sqrt.o pile.o special.o 
/home/cjwatson/src/debian/groff/trunk/groff/src/libs/libgroff/libgroff.a

No -lm there, so what's going on? It seems (and I verified this by
looking in gcc-4.2/src/gcc/cp/g++spec.c) that g++ links with -lm by
default. This isn't entirely unreasonable since libstdc++.so.6 has
NEEDED libm.so.6 anyway; it largely seems to be trying to ensure that
-lm comes after -lstdc++ on the link line.

Perhaps dpkg-shlibdeps should ignore libm.so.6 for binaries also linked
against libstdc++.so.*?

Thanks,

-- 
Colin Watson   [EMAIL PROTECTED]




-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]