Gentoo Archives: gentoo-user

From: Alan McKinnon <alan.mckinnon@×××××.com>
To: gentoo-user@l.g.o
Cc: Kraus Philipp <philipp.kraus@×××××××××.de>
Subject: Re: [gentoo-user] two glibcs with different version
Date: Sat, 01 May 2010 10:55:44
Message-Id: 201005011252.08605.alan.mckinnon@gmail.com
In Reply to: Re: [gentoo-user] two glibcs with different version by Kraus Philipp
1 On Saturday 01 May 2010 10:57:31 Kraus Philipp wrote:
2 > On 01.05.2010 um 10:32 wrote Volker Armin Hemmann:
3 > > On Samstag 01 Mai 2010, Graham Murray wrote:
4 > >> Kraus Philipp <philipp.kraus@×××××××××.de> writes:
5 > >>> Hello,
6 > >>>
7 > >>> I must test a software with a older version of the glibc. I run the
8 > >>> 2.11.1 now but for one tool I need a previous version (2.6.1).
9 > >>> How can I compile the glibc without changing my system glibc. I
10 > >>> would
11 > >>> like to set the previous glibc with the LD_PATH.
12 > >>> Can I run two different versions or is a better solution to
13 > >>> downgrade
14 > >>> the system glib?
15 > >>
16 > >> I think that the only way you can do this is to create a chroot jail,
17 > >> in which you build everything using the old version of glibc (in a
18 > >> very
19 > >> similar way to building a new Gentoo system) and run your
20 > >> application in
21 > >> that.
22 > >
23 > > no, you can install glibc in /usr/local and then tell apps to either
24 > > use the
25 > > libs in /usr/local or /usr.
26 > >
27 > > It is just not easy because it easily breaks stuff in horrrible to
28 > > fix ways.
29 >
30 > Okay, can I downgrade my glibc? My Gentoo isn't a big system, it's a
31 > server
32 > installation, so I can recompile the whole system. I had forgotten to
33 > mask the
34 > glibc on the last update. I have add a line to the portage.mask but
35 > emerge says
36 > that it can't compile the older version, because will damage the system.
37
38 There is a way to downgrade, but it's far from bullet proof. You might end up
39 with mutually incompatible code versions that makes the recompile world freak
40 out.
41
42 First, quickpkg your existing glibc
43 Then read the glibc ebuild. You can bypass the version checks, IIRC its an
44 envvar something like "I_AM_VERY_STUPID_OR_VERY_BRAVE". Failing that, just
45 comment out the version checks, redigest the ebuild and run it.
46 The rebuild world
47
48 Obviously, this is not for the faint of heart.
49
50 --
51 alan dot mckinnon at gmail dot com