Gentoo Archives: gentoo-dev

From: Thomas de Grenier de Latour <degrenier@×××××××××××.fr>
To: gentoo-dev@l.g.o
Subject: Re: [gentoo-dev] Reverse dependency Scanning
Date: Sat, 23 Apr 2005 12:21:14
Message-Id: 20050423142104.47c8494b@eusebe
In Reply to: [gentoo-dev] Reverse dependency Scanning by Spider
1 On Sat, 23 Apr 2005 12:15:32 +0200
2 Spider <spider@g.o> wrote:
3
4 > So, I know it isn't foolproof, don't expect it to be. However,
5 > feedback would be nice, patches and so on.
6
7 I think that for binaries you could filter the ldd output to keep
8 only the libs that are directly linked to, since that's what
9 should really become dependencies. See atttached patch for a
10 possible quick and dirty implementation.
11
12 Example without the patch:
13 % echo /usr/games/bin/abuse.sdl | ./depreverse.orig
14 /lib/libdl.so.2
15 /lib/libncursesw.so.5
16 /lib/libnsl.so.1
17 /lib/tls/libc.so.6
18 /lib/tls/libm.so.6
19 /lib/tls/libpthread.so.0
20 /usr/lib/gcc/i686-pc-linux-gnu/3.4.3-20050110/libgcc_s.so.1
21 /usr/lib/gcc/i686-pc-linux-gnu/3.4.3-20050110/libstdc++.so.6
22 /usr/lib/libaa.so.1
23 /usr/lib/libcaca.so.0
24 /usr/lib/libSDL-1.2.so.0
25 /usr/lib/libslang-utf8.so.1
26 /usr/lib/libvga.so.1
27 /usr/lib/libX11.so.6
28 /usr/lib/libXext.so.6
29 /usr/lib/libXxf86vm.so.1
30 /usr/lib/opengl/xorg-x11/lib/libGL.so.1
31
32 The same with the patch:
33 % echo /usr/games/bin/abuse.sdl | ./depreverse
34 /lib/libnsl.so.1
35 /lib/tls/libc.so.6
36 /lib/tls/libm.so.6
37 /lib/tls/libpthread.so.0
38 /usr/lib/gcc/i686-pc-linux-gnu/3.4.3-20050110/libgcc_s.so.1
39 /usr/lib/gcc/i686-pc-linux-gnu/3.4.3-20050110/libstdc++.so.6
40 /usr/lib/libSDL-1.2.so.0
41 /usr/lib/opengl/xorg-x11/lib/libGL.so.1
42
43 --
44 TGL.

Attachments

File name MIME type
depreverse--filter_libs.patch text/x-patch

Replies

Subject Author
Re: [gentoo-dev] Reverse dependency Scanning Spider <spider@g.o>