Gentoo Archives: gentoo-user

From: Andrew Udvare <audvare@×××××.com>
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] Multilib help
Date: Wed, 04 Jul 2018 06:06:54
Message-Id: CED45DCE-D829-4D02-8FB4-4279EF100504@gmail.com
In Reply to: [gentoo-user] Multilib help by "Zoltán Kócsi"
1 > On 2018-07-04, at 01:51, Zoltán Kócsi <zoltan@××××××××××.au> wrote:
2 >
3 > My problem is that I've installed a multilib-enabled 64-bit system and
4 > realised that /usr/lib32 and /usr/lib64 are vastly of different. There
5 > are around 2200 dynamic and some 130 static libs in lib64 while there
6 > are around 300 dynamic and 15 static libs in lib32. That is, about 85%
7 > of libraries exist in 64-bit version only.
8
9 This is normal.
10 >
11 > Consequently, pretty much any 32-bit binary fails to launch due to
12 > missing libraries. Which is most unfortunate as I have quite a few
13 > of such binaries from EDA tools to productivity tools to games.
14
15 If your (presumably closed source) apps are old enough to not have 64-bit builds available, then they may be too old for Portage to be useful for this. You would be better off building the old version open source libs in 32-bit and set up a prefix to run everything from with things like LD_LIBRARY_PATH set.
16
17 >
18 > I would much appreciate if someone would explain how to tell the system
19 > to build a 32-bit version of *every* library it installs (and have
20 > already installed) so that 32-bit binaries could run (and could also be
21 > built against those libs, actually).
22
23 There's no such feature (yet). You can set up a chroot for a 32-bit system and run things from there.
24
25 https://wiki.gentoo.org/wiki/Project:AMD64/32-bit_Chroot_Guide
26
27 If most of your apps are 32-bit then you are almost better off running a native 32-bit system, especially for games.
28
29 You can also use the chroot for building, but then copy the libraries you need (and only the ones you need) to a path outside of the chroot. Then you can set LD_LIBRARY_PATH to that path and run the binary. This will work for most apps including games. I prefer this way because then I don't have to remember to set up the chroot, nor do I have to do anything as root once this is set up. This is how I ran PCSX2 prior to it running natively on x86-64.
30
31 Otherwise, if graphics performance is not an issue, use a 32-bit Linux within a VM.
32
33 Andrew

Replies

Subject Author
[gentoo-user] Re: Multilib help Ian Zimmerman <itz@××××××××××××.org>