Gentoo Archives: gentoo-alt

From: Steven Trogdon <strogdon@×××××.edu>
To: gentoo-alt@l.g.o
Subject: Re: [gentoo-alt] Gentoo RAP bootstrap script
Date: Wed, 09 Oct 2013 00:29:34
Message-Id: 20131008192925.33e6e22b@ledaig.d.umn.edu
In Reply to: Re: [gentoo-alt] Gentoo RAP bootstrap script by heroxbd@gmail.com
1 Hi Benda,
2
3 I finally got around to looking at this. See below.
4
5 On Wed, 02 Oct 2013 18:33:21 +0900
6 heroxbd@×××××.com wrote:
7
8 > Dear Steven,
9 >
10 > Steven Trogdon <strogdon@×××××.edu> writes:
11 >
12 > > I've seen this sort of thing on other tries to build glibc in prefix.
13 > > Here the host OS is debian and authentication is via a radius server
14 > > over nfs. All user specific info is not stored in /etc/passwd but in a
15 > > user passwd database. On gentoo, glibc sets the location to search for
16 > > this database as under /var/db and I believe this needs to be
17 > > $EPREFIX/var/db. Here on the host the database is stored under
18 > > /var/lib/misc. One cannot simply copy over the debian-provided
19 > > database to $EPREFIX/var/db and get things to work, at least I don't
20 > > thing so. It is possible to get things to work with a little work,
21 > > once the search path is $EPREFIX/var/db. One has to, from the output
22 > > of "/usr/bin/getent passwd" on the host, generate a database for
23 > > gentoo. And then some minor changes have to be made to
24 > > $EPREFIX/etc/nsswitch.conf so that things are database aware. To see
25 > > the problem, from within $EPREFIX
26 > >
27 > > $ id
28 > > uid=105600 gid=925(math) groups=925(math)
29 >
30 > Regarding this issue, I have a prefixified glibc at
31 >
32 > http://git.overlays.gentoo.org/gitweb/?p=dev/heroxbd.git;a=blob;f=sys-libs/glibc/glibc-2.17.ebuild
33 >
34 > It looks for $EPREFIX/etc/{passwd,shadow,group,resolv.conf} and
35 > $EPREFIX/var/db.
36 >
37 > Therefore you can have your $EPREFIX/etc/passwd as
38 >
39 > strogdon:x:105600:925:Steven Trogdon:/home/strogdon:/bin/bash
40 >
41 > and $EPREFIX/etc/group as
42 >
43 > math:x:925:strogdon
44 >
45 > "getent passwd > $EPREFIX/etc/passwd" is also a good starting point.
46 >
47 > This should resolve your problem.
48 >
49 > You can copy the ebuild directly, or use the heroxbd overlay to emerge
50 > the hacked glibc by
51
52 It looks like the prefixified changes are quite significant.
53
54 >
55 > $ layman -a heroxbd
56 >
57 > It's an ugly hack though, need to be refined to submit to upstream.
58 >
59 > Benda
60
61 My build system has changed since I initially tested RAP. The OS has been
62 "upgraded" and I now have to deal with Debian 7 and multiarch! I do have a
63 native glibc installed on Debian 7 that uses
64
65 https://github.com/redlizard/gentoo-prefix-libc
66
67 with numerous nasty patches that works around the passwd/group issue (your
68 approach is much more comprehensive). But that prefix injects rpath/runpath
69 variables into runtime libraries and your patched glibc fails the preinst phase
70 with
71
72 Inconsistency detected by ld.so: get-dynamic-info.h: 133: elf_get_dynamic_info:
73 Assertion `info[29] == ((void *)0)' failed!
74
75 because rpath/runpath are also injected into ld.so. I presume a proper RAP
76 install (which I don't have) will not have this issue. To that end I have tried
77
78 [1.]
79 http://dev.gentoo.org/~heroxbd/bootstrap-rap.sh
80
81 and mpc-1.0.1 fails to find gmp.h
82
83 checking for gmp.h... no
84 configure: error: gmp.h cannot be found or is unusable.
85
86 At this point gmp.h is present in $EPREFIX/usr/include. This same mpc does build
87 in my Debian prefix with native glibc. I have also tried
88
89 [2.]
90 https://github.com/redlizard/prefix-libc/blob/master/scripts/bootstrap-prefix.sh
91
92 but after installing prefix-portage-2.2.01.22124 I get
93
94 * ready to bootstrap stage3
95 !!! Invalid PORTDIR_OVERLAY (not a dir):'/storage/gentoo-glibc/tmp/usr/local/portage'
96 !!! Invalid PORTDIR_OVERLAY (not a dir):'/storage/gentoo-glibc/tmp/usr/local/portage'
97 !!! Invalid host triple , giving up.
98 !!! Invalid PORTDIR_OVERLAY (not a dir):'/storage/gentoo-glibc/usr/local/portage'
99 !!! Invalid PORTDIR_OVERLAY (not a dir):'/storage/gentoo-glibc/tmp/usr/local/portage'
100 !!! Invalid PORTDIR_OVERLAY (not a dir):'/storage/gentoo-glibc/usr/local/portage'
101 !!! Invalid PORTDIR_OVERLAY (not a dir):'/storage/gentoo-glibc/tmp/usr/local/portage'
102
103 and the directories have not been created.
104
105 Steve

Attachments

File name MIME type
signature.asc application/pgp-signature

Replies

Subject Author
Re: [gentoo-alt] Gentoo RAP bootstrap script heroxbd@×××××.com