Subject: use of LDD in pkgsrc/mk/bsd.pkg.mk?
To: None <tech-pkg@netbsd.org>
From: Georg Schwarz <georg.schwarz@freenet.de>
List: tech-pkg
Date: 11/29/2005 22:44:52
pkgsrc/mk/bsd.pkg.mk has 

$$ldd $$bins $$libs 2>/dev/null || ${TRUE}) | ${AWK} 'NF == 3 { print
$$3 }' | ${SORT} -u

This means that only output lines of ldd with eactly three items are
considered. On a current Debian Linux system for example I get:

schwarz@kobe:~$ ldd `which lynx`|awk '{print NF}'        
4
4
4
4
4
4
4
4
4
4
4
4
4
4
4

So it should not work there???

On Darwin LDD is set to /usr/bin/otool -L.
I get:

imac:~ schwarz$ /usr/bin/otool -L /usr/bin/make
/usr/bin/make:
        /usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current
version 88.0.0)

does not really fit either???

On IRIX 5.3 I don't have ldd, so I am using a fakeldd script:

/usr/bin/elfdump -Dl $* | $AWK 'NF == 7 || NF == 8 {printf "x x
%s\n",$1}'


What do other non-*BSD platforms do?



On IRIX 5.3 I 

-- 
Georg Schwarz    http://home.pages.de/~schwarz/
 georg.schwarz@freenet.de  +49 178 8545053