3

When I use emerge --sync my older .ebuild files are removed. How to get newer .ebuild-s, but not lose older ?

1
  • 1
    What do you need (or want) the older ebuilds for?
    – David Z
    Aug 18, 2011 at 5:25

1 Answer 1

3

One way to do this should be to override the default portage rsync options excluding the deletion related options. The default options are currently hardcoded in /usr/lib/portage/pym/_emerge/actions.py from line 2039 at my place.

Excluding "--force" and "--delete" you would add

PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --whole-file --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"

to /etc/make.conf. To the effect that no files or directories should get deleted any more.

Edit: Note that usually you would not want to keep any such ebuilds within the portage tree you're syncing to.

If you want to preserve specific ebuilds, there are two typical scenarios:

  • You are using an outdated ebuild that you want to keep.
  • You have written an ebuild yourself, or you found an ebuild somewhere, and added it to the portage tree you're syncing to.

In both these cases the best solution is to copy these ebuilds to a local overlay. You may also have to copy ebuilds they're depending on. Here's how to create a simple local overlay: http://forums.gentoo.org/viewtopic-t-827407.html

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .