Le Mercredi 17 Mai 2006 05:32, Rennie deGraaf a écrit : > I am trying to build a number of minimal Gentoo images without portage > installed. The approach I was taking was to build a master image with > all the software that I need according to the standard Gentoo > installation instructions, and then remove portage and create the > minimal images. If I ever decide that I need to install new software or > upgrade something, I'll make the changes to the master and generate new > minimal images. > > My question is, how do I correctly uninstall portage? My main concern > is the several hundred megabytes taken up by /usr/portage, > /var/cache/edb, /var/db/pkg, /var/lib/portage and wherever else portage
/var/lib/portage takes up only 8.0Ko ! Are you sure you can't spare that ? ;-) > stores data; I'm not really concerned with the binaries, but would > prefer to remove them as well, just to be tidy. Will "emerge -C > portage" clean up everything safely, or will I have to clean up some > directories manually? > > For that matter, what are all the directories used for data by portage, > that I could delete on a system that doesn't use portage? > > Thanks, > Rennie deGraaf The portage program itself does not take up that much space. It's only python scripts and most of them are pre-compiled. The main space hoggers linked to portage are : - /usr/portage (739M), including /usr/portage/distfiles (228M) - /var/tmp/portage (should be empty unless you specified keep or interrupted an emerge). - /var/cache/edb (100M) - The overlays if you have any (/usr/local/portage by default), - The PKGDIR, if you have any (/usr/portage/packages by default). Even /var/db/pkg takes up only 80M on my system, and that is, with kde-meta merged. As has been said, emerge -C portage will NOT remove any of those directories as they are not filled during portage's merge to the main tree. However, you can remove them manually. You might want to know that you are going to get errors if you remove the contents of /usr/portage. For example, env-update will not work as an environment variable wants to import the tree. I think it just wants to import the profile, though, so you might be able to remove the various categories. Or, you could edit the file responsible for this in /etc/env.d. Regards, -- Jonathan -- gentoo-user@gentoo.org mailing list