Currently, portage does not list files not being installed due to INSTALL_MASK in vardb, thus making it hard to keep track of which files were lost like that. I'd like to create a nice tool to handle INSTALL_MASK changes, including rebuilding packages for which INSTALL_MASK change would result in installing additional files. Such an information would be crucial for that tool.
The current CONTENTS code generates entries as files are merged. We change it to generate CONTENTS entries from the content of $D just after the pkg_preinst phase and before the INSTALL_MASK code is called. This approach will also be useful to generate CONTENTS entries for cases in which entire directory trees can be moved directly from $D to $ROOT, as requested in bug #364457. If we include the removed files in CONTENTS, and also create /var/db/pkg/*/*/INSTALL_MASK entries to indicate which files have been masked, would that be suitable for your purposes?
(In reply to comment #1) > If we include the removed files in CONTENTS, and also create > /var/db/pkg/*/*/INSTALL_MASK entries to indicate which files have been masked, > would that be suitable for your purposes? Even the first one would be enough. Both will be great.
Should we also account for PKG_INSTALL_MASK? In order to do that, I suppose that we could revert this change from bug #300744 and save the original CONTENTS inside the xpak segment of each binary package: http://git.overlays.gentoo.org/gitweb/?p=proj/portage.git;a=commit;h=11afbedb749a78054d8c3337b1f32e03fd5f8c48
(In reply to comment #3) > Should we also account for PKG_INSTALL_MASK? In order to do that, I suppose > that we could revert this change from bug #300744 and save the original > CONTENTS inside the xpak segment of each binary package: > > http://git.overlays.gentoo.org/gitweb/?p=proj/portage.git;a=commit;h=11afbedb749a78054d8c3337b1f32e03fd5f8c48 I'm not a specialist here and I don't really care about PKG_INSTALL_MASK ATM. I don't think user is supposed to go hacking that deep.
What's the progress here? -9999 seems still not to list masked files in vardb and I'm just about to do first install-mask release.
(In reply to comment #5) > What's the progress here? -9999 seems still not to list masked files in > vardb and I'm just about to do first install-mask release. Not implemented. ;)
I think we need to introduce a separate CONTENTS.INSTALL_MASK file so that we can easily toggle collision-protect behavior to use CONTENTS.INSTALL_MASK when desired.