Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 32780 - [patch] add support for a "MERGE_EXCLUDE" paths list
Summary: [patch] add support for a "MERGE_EXCLUDE" paths list
Status: RESOLVED WONTFIX
Alias: None
Product: Portage Development
Classification: Unclassified
Component: Unclassified (show other bugs)
Hardware: All Linux
: High enhancement (vote)
Assignee: Portage team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 8388
  Show dependency tree
 
Reported: 2003-11-05 02:38 UTC by TGL
Modified: 2011-10-30 22:21 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments
merge-exclude.patch (merge-exclude.patch,6.88 KB, patch)
2003-11-05 02:40 UTC, TGL
Details | Diff
merge-exclude.patch (merge-exclude.patch,6.95 KB, patch)
2003-11-05 06:41 UTC, TGL
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description TGL 2003-11-05 02:38:15 UTC
The following patch allow to define a "MERGE_EXCLUDE" path list in
make.conf to prevent portage from installing files at given locations.
Entries of the path can be both directories or files paths.

Possible uses of this feature are (at least, here is why some people
talked about it this last few days on gentoo-dev):
 - do not install /usr/share/{doc,man} on small size targets
 - do not install an "updated" /etc/fstab
 - do not install a few non vanilla files that some people don't like
 (/etc/cron.daily/updatedb for instance)

Limitations:
 - In a first version of the patch I was also allowing a "MERGE_EXCLUDE_MASK"
(same semantics that CONFIG_PROTECT_MASK regarding CONFIG_PROTECT), but in
fact it was to slow this way. I think this implementation without mask is
far more efficient. 
 - I don't know what would be the right way to deal with symlinks (I mean, 
for instance, when a target excluded path is in fact a symlink to a 
non-excluded real directory for instance, should I merge the files?), so 
I've chosen what was the simpliest (see comments in the patch). But if you
think of a better behavior, tell me.


Reproducible: Always
Steps to Reproduce:
Comment 1 TGL 2003-11-05 02:40:27 UTC
Created attachment 20285 [details, diff]
merge-exclude.patch

patch is against portage.py from 2.0.49-r{15,16}
Comment 2 TGL 2003-11-05 06:41:23 UTC
Created attachment 20289 [details, diff]
merge-exclude.patch

ooops... this one sounds better.
Comment 3 Nicholas Jones (RETIRED) gentoo-dev 2003-12-24 00:56:57 UTC
lambda is on my bad list, btw.
I prefer things written out as functions.
Deeply nested anything isn't a good practice.

I'm not very inclined to add this feature as it doesn't sound like it
would contribute in a positive way to much. fstab doesn't change that
often.
Comment 4 TGL 2003-12-24 11:09:51 UTC
The main target was /usr/share/{doc,man,info}, and there is now an adhoc solution for this ones, so I agree this patch is not really needed anymore. 


I absolutly disagree on lambdas tho... I don't like to define globally (at least class-wise) functions that I use only once in a very specific context and has no meaning anywhere else, as I don't like to do it for variables. But I think it's a matter of culture, and a debate on this would be endless, pointless, useless. Next time I touch portage code, I will try to temporary forget that lambda exists...
Comment 5 Brian Harring (RETIRED) gentoo-dev 2005-02-27 21:54:16 UTC
This functionality has been implemented in various forms so far...
either custom INSTALL_MASK + bashrc trickery, or noman feature (fex).