Boyd Stephen Smith Jr. posted <[EMAIL PROTECTED]>, excerpted below, on Tue, 13 Dec 2005 23:19:26 -0500:
> On Tuesday 13 December 2005 10:46 pm, maillists wrote: >> I unmerged gcc. (long story never mind) >> >> How do I get out of the corner that I painted myself into? > > Get a binary package and install that. I believe the binary package > repository at chinstrap.alternating.net is still in operation. Also note that the stages and/or liveCD should have it available. I just confirmed here with the stage-3 686 tarball. I'd tend to prefer this, because it's official Gentoo, over something at some random URL, which might or might not be perfectly fine. You'd unpack the stage tarball somewhere suitable (preferrably NOT directly over your running system, that is, NOT to / itself), then chroot into the new root dir location, and do a /usr/sbin/quickpkg gcc to create a binary package out of the existing stage installation. Back out of the chroot, you could then emerge -K /path/to/unpack/location/usr/portage/package/All/gcc<tab>, the tab (twice if necessary) to get the specific ebuild file. That should restore a working gcc, at which point you can remerge your own version with your own selected USE flags and the like. .... After you have recovered, do a man make.conf, and check out FEATURES=buildpkg. You can use that to automatically build a binary package each time you emerge something, so if your toolchain ever gets broken again, all you have to do is emerge -K the offending package, and it'll remerge from the binary created at original merge time, without taking the time to recompile! Total additional disk space required to store a complete system's worth of binary packages will be 2-4 gigs. Note that you'll want to clean out old versions of packages once in awhile. There's a tool called eclean that helps with this, in at least the latest ~arch versions of gentoolkit. tho I'm not sure it has made its way into stable just yet. Of course, if you hose portage itself, emerging the binary portage package becomes rather difficult. However, for such situations, one can use the procedure found in $PORTDIR/sys-apps/portage/files/README.RESCUE, only you'll already have the binary package from when you merged it, so you be able to skip the suggested download step. A problem with your installed python would be similar, since portage requires python to run correctly. Using these techniques on a system that has been running FEATURES=buildpkg for long enough to have binpkg versions of all your critical packages, you should be able to recover from a problem with any package, as long as you have a liveCD rescue boot disk handy in case you can't boot. If you want to jumpstart the binpkg collection, you can use quickpkg to create a binary package for anything currently merged. Naturally, I'd suggest you start with the packages in the list you get with emerge --pretend --emptytree system, or if you don't want to do that, at least do gcc, glibc, binutils, portage, python, etc. You may also want to preemptively quickpkg anything that takes quite a while to merge, such as xorg, and especially OOo, if you have it merged and used the from-source version. -- 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 in http://www.linuxdevcenter.com/pub/a/linux/2004/12/22/rms_interview.html -- [email protected] mailing list
