From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from pigeon.gentoo.org ([208.92.234.80] helo=lists.gentoo.org) by finch.gentoo.org with esmtp (Exim 4.60) (envelope-from ) id 1N9f8A-0007QS-D7 for garchives@archives.gentoo.org; Sun, 15 Nov 2009 13:27:02 +0000 Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 32FC4E08D6; Sun, 15 Nov 2009 13:25:45 +0000 (UTC) Received: from lo.gmane.org (lo.gmane.org [80.91.229.12]) by pigeon.gentoo.org (Postfix) with ESMTP id B4EF6E08D6 for ; Sun, 15 Nov 2009 13:25:44 +0000 (UTC) Received: from list by lo.gmane.org with local (Exim 4.50) id 1N9f6u-0007jO-40 for gentoo-amd64@lists.gentoo.org; Sun, 15 Nov 2009 14:25:44 +0100 Received: from ip68-231-21-207.ph.ph.cox.net ([68.231.21.207]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sun, 15 Nov 2009 14:25:44 +0100 Received: from 1i5t5.duncan by ip68-231-21-207.ph.ph.cox.net with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sun, 15 Nov 2009 14:25:44 +0100 X-Injected-Via-Gmane: http://gmane.org/ To: gentoo-amd64@lists.gentoo.org From: Duncan <1i5t5.duncan@cox.net> Subject: [gentoo-amd64] Re: How to install multilib'ed version of any library (for real multilib for x86 and x86_64 for every libraries)? Date: Sun, 15 Nov 2009 13:25:21 +0000 (UTC) Message-ID: References: <91b13c310911140345w6fce2bd1r848b72685c7cd999@mail.gmail.com> Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-amd64@lists.gentoo.org Reply-to: gentoo-amd64@lists.gentoo.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: ip68-231-21-207.ph.ph.cox.net User-Agent: Pan/0.133 (House of Butterflies) Sender: news Content-Transfer-Encoding: quoted-printable X-Archives-Salt: 38358e7e-4eb5-4511-bf5d-a3356402be7e X-Archives-Hash: c2d53a26800d7c9aa2f86c162265f85d Nikos Chantziaras posted on Sat, 14 Nov 2009 17:16:35 +0200 as excerpted: > On 11/14/2009 01:45 PM, Cheng Renquan wrote: >>[...] >> Furthermore, if compiling any other 32bit program on gentoo-amd64, it >> may need other more 32bit of libraries, >> >> Comparing other linux distros like fedora-x86_64 and debian-amd64, I >> knew there is simple way to archive this goal, just install both >> binutils.x86_64 and binutils.i686 >> packages, but on gentoo-amd64, how can we do this in a similarly simpl= e >> way? >> >> How about add USE multilib support of every package that contains >> libraries? >=20 > Gentoo doesn't support this yet. Work is underway to enable real > multilib support though. Nikos is correct... as far as he goes, but there are actually ways around= =20 it that he didn't describe. First, for a limited subset of libraries, there are pre-compiled x86_32=20 compatibility versions available. This is the "fast" solution, workable=20 for most mainstream stuff, but in addition to being limited to the=20 mainstream libraries, it isn't really gentoo-like in some ways as the=20 binaries are all precompiled, and for all the reasons that people choose=20 Gentoo, that's just not really satisfying to many Gentooers. Never-the- less, it suffices for many apps and most 32-bit games. The operative hint you need here is app-emulation/emul-linux-x86-*. =20 Those packages are the various more-or-less mainstream pre-compiled=20 x86_32 libraries. FWIW, there's a limited number of executables, as=20 well, normally with the -bin suffix. mozilla-firefox-bin is one=20 example. These aren't as popular (some would say necessary) as they once= =20 were, as there are now various 64-bit binary plugins for stuff such as=20 flash, but for quite some time 64-bit was out in the cold in that regard,= =20 so if you chose to run proprietary-ware at all, you generally found the=20 32-bit versions helpful as they'd run the proprietary 32-bit-only plugins= =20 and codecs, etc. The far less limited (virtually unlimited) and perhaps more Gentoo-ish=20 but also MUCH more complicated and MUCH more work second alternative is=20 to run a 32-bit chroot. The problem is that at this point, none of the=20 package managers (at least not portage, and I don't believe paludis or=20 pkgcore have the feature either) can properly track multiple ABI/bitness=20 versions of the same package. Thus, for amd64, the package manager=20 assumes all the packages are 64-bit, and if you were to merge one as 32- bit, it would replace the 64-bit version of the same package. The way around this is the 32-bit chroot. The idea, basically, is to=20 setup a second instance of Gentoo in a chroot, so the portage (or other=20 PM) running there doesn't know about the main 64-bit system, and the 64- bit system for the most part ignores the 32-bit chroot because it's not=20 in its way. You mount-bind a few subtrees, typically /tmp, often=20 /home, a couple others (I was going to use etc, instead of "a couple=20 others", but then realized that was ambiguous, NOT /etc!), into the=20 chroot, so they're seen by both systems, start from a normal x86 stage=20 tarball, and with some notable exceptions, basically, install an almost=20 complete 32-bit system in the chroot. In theory, you can skip many of=20 the services, syslog, cron, etc, because the main system provides them=20 for both. In fact, since you have a nearly complete 32-bit system=20 anyway, in many cases it's worth it to just do the whole thing (but maybe= =20 without the full X, kde/gnome, whatever, or maybe with it, depending on=20 your goals for the respective sides), and then be able to dual boot to=20 one or the other as desired. There's more documentation, including a nice Gentoo/AMD64 32-bit chroot=20 guide, available. See the documentation section at the Gentoo/AMD64=20 project page. As you're asking about this, you probably haven't read the= =20 FAQ yet, so I'd start with that. You're likely to find a few of your=20 other questions answered there. If after that (and reading the above)=20 you're interested in the 32-bit chroot idea, you can read the 32-bit=20 chroot guide and then decide if it's worth it or if you want to try the=20 emul-linux-x86 stuff first. Here's the Gentoo/AMD64 project page link. Again, check the documentation section. http://amd64.gentoo.org One more possibility. If you only have one or two libraries you need=20 that aren't available as precompiled binaries in the emul-* packages,=20 once you have the 32-bit dependencies installed, you may well be able to=20 compile them manually, outside portage, using -m32. However, once you=20 get more than a couple to worry about, the complexity of trying to handle= =20 all the dependencies manually increases more or less geometrically=20 proportional to the number of packages you're trying to handle, so it=20 very quickly becomes easier to simply do the chroot and let portage's=20 automation handle it. YMMV. Finally, a bit more detail on what Nikos hinted at. There's a couple of=20 experimental projects whereby portage is modified to be able to handle=20 multiple ABI installations in parallel. As a matter of practice, I don't= =20 know if they'll ever get merged, because we've gone this long without it,= =20 and as I mentioned, the worst need was along about 2006 or so, when a lot= =20 of folks had switched already but Flash and etc weren't yet available for= =20 64-bit, and even mainstream FLOSS apps like Open Office hadn't been=20 ported. Since pretty much everything mainstream FLOSS has been ported=20 now, and the proprietaryware folks are coming around to 64-bit as well,=20 there's far less need for multilib in general than there used to be, and=20 the need/demand will be ever weaker with time. If Gentoo/AMD64 got along= =20 this long without it, and since we're well past the hump, now, there's=20 little real practical reason to worry about it -- for Gentoo/AMD64, at=20 least. But of course there's other archs it would benefit as well, some=20 of which have more than two variants, and at least for the devs and arch- testers, it could be very useful to be able to be able to install, test=20 and otherwise work on multiple bitnesses at once. But AMD64 was the big=20 one, and the others too have gone this long without it. So really, what=20 it comes down to is whether enough devs prioritize it high enough to=20 continue pushing it until it's not only working well, but until the other= =20 devs accept it as worth the hassle, an it becomes a part of portage (and/ or the other PMs) and Gentoo in general. Yes, there's a couple devs=20 working on it, but whether their pet project will remain of /enough/=20 interest to them for long enough to be worth pushing into mainline=20 Gentoo, is anyone's guess. --=20 Duncan - List replies preferred. No HTML msgs. "Every nonfree program has a lord, a master -- and if you use the program, he is your master." Richard Stallman