Gentoo Archives: gentoo-dev

From: Eray Aslan <eray.aslan@×××××××.tr>
To: gentoo-dev@l.g.o
Subject: [gentoo-dev] /bin and /sbin to /usr
Date: Tue, 10 Aug 2010 11:22:52
Message-Id: 20100810112230.GA12155@zptr-nb01.caf.local
1 [Following a similar discussion in another mailing list]
2
3 As you know, only a few directories can be assumed to be available after
4 boot[1]. Notably, /usr and /var are not among them. Binaries in /bin
5 and /sbin should be enough to do basic maintanence/repair and to mount
6 other volumes. Since we are using the binaries in /bin and /sbin to
7 potentially mount /usr, they should not depend on them. Or can they?
8
9 On my laptop:
10 # for f in /bin/* /sbin/*; do if [ "$(file $f | grep ELF)" != "" ] ;
11 then if [ "$(ldd $f | grep /usr)" != "" ] ; then echo $(equery belongs
12 $f) $f; ldd $f; fi; fi; done
13 net-firewall/iptables-1.4.6 /sbin/iptables-multi
14 linux-vdso.so.1 => (0x00007fffc77e8000)
15 libip4tc.so.0 => /usr/lib/libip4tc.so.0 (0x00007f27e4781000)
16 libxtables.so.4 => /usr/lib/libxtables.so.4 (0x00007f27e4579000)
17 libm.so.6 => /lib/libm.so.6 (0x00007f27e42f8000)
18 libc.so.6 => /lib/libc.so.6 (0x00007f27e3f9f000)
19 libdl.so.2 => /lib/libdl.so.2 (0x00007f27e3d9b000)
20 /lib64/ld-linux-x86-64.so.2 (0x00007f27e4988000)
21 sys-apps/hal-0.5.14-r2 /sbin/umount.hal
22 linux-vdso.so.1 => (0x00007fff6b5f3000)
23 libhal.so.1 => /usr/lib/libhal.so.1 (0x00007fd52e637000)
24 libhal-storage.so.1 => /usr/lib/libhal-storage.so.1 (0x00007fd52e42c000)
25 libdbus-1.so.3 => /usr/lib/libdbus-1.so.3 (0x00007fd52e1ec000)
26 libc.so.6 => /lib/libc.so.6 (0x00007fd52de93000)
27 libpthread.so.0 => /lib/libpthread.so.0 (0x00007fd52dc77000)
28 librt.so.1 => /lib/librt.so.1 (0x00007fd52da6e000)
29 /lib64/ld-linux-x86-64.so.2 (0x00007fd52e848000)
30
31 Questions:
32 1. Is this OK or should we file bugs against binaries in {/bin,/sbin} linking
33 against libraries in /usr/lib? Fix is relatively easy in general (give
34 --libdir=/lib against the config script)
35
36 2. Is the below acceptable? (symlinking from /bin to /usr/bin)
37 # ls -l $(find {/bin,/sbin}/ -type l)|grep /usr
38 lrwxrwxrwx 1 root root 20 Oct 28 2008 /bin/igawk ->
39 /usr/bin/igawk-3.1.6
40 lrwxrwxrwx 1 root root 14 Aug 10 13:29 /bin/mail -> /usr/bin/mailx
41 lrwxrwxrwx 1 root root 20 Oct 28 2008 /bin/pgawk ->
42 /usr/bin/pgawk-3.1.6
43
44 Corollary to both: If yes, tinderbox/buildbot against other packages
45 are probably in order as well.
46
47 Thanks
48 --
49 Eray
50
51 [1]
52 /dev
53 /etc
54 /lib
55 /bin
56 /sbin
57 /proc (Linux)
58 /sys (Linux-2.6)
59 /libexec (*BSD)

Replies

Subject Author
Re: [gentoo-dev] /bin and /sbin to /usr "Paweł Hajdan
Re: [gentoo-dev] /bin and /sbin to /usr Mike Frysinger <vapier@g.o>