Following discussion at http://archives.gentoo.org/gentoo-portage-dev/msg_734755854771be3eb9e8c4da55489b34.xml, I suggest adding a/m to the "ebuild howto" guide. I suggest the following paragraph: <QUOTE> An ebuild can append to the CONFIG_PROTECT_MASK variable by using portage's env.d mechanism (http://devmanual.gentoo.org/tasks-reference/environment/index.html). The ebuild has to generate an env.d file, then use either newenvd or doenvd to put it in-place. 'emerge' shall call 'env-update' and generate the proper enviroment for proceeding with its merge. The following ebuild snippet (from src_install()) shall cause /etc/test.cfg to be auto-merged w/o needing to call etc-update after the merge: <snip> echo "CONFIG_PROTECT_MASK=\"/etc/test.cfg\"" > 99my-pkg doenvd 99my-pkg </snip> <UNQUOTE> Thanks, Reproducible: Always Steps to Reproduce: n/a
If you feel like submitting a patch for this you can find the sources to devmanual from http://anonsvn.gentoo.org/
This might be a better place for the information: http://devmanual.gentoo.org/general-concepts/config-protect/index.html
Created attachment 207535 [details, diff] appends documentation to suggested devmanual page patch created by: amit0 config-protect # svn di --diff-cmd diff text.xml >& bug_289565.patch
(In reply to amitds from comment #3) > Created attachment 207535 [details, diff] [details, diff] > appends documentation to suggested devmanual page Why hasn't this been merged yet? Now we no longer can, unless we get a sign-off for it: https://www.gentoo.org/glep/glep-0076.html#certificate-of-origin @amitds: If you're still reading, can you post a comment with a "Signed-off-by:" line for your patch?
Actually, this is below the 15 lines threshold, so I've created a pull request: https://github.com/gentoo/devmanual/pull/291
The bug has been closed via the following commit(s): https://gitweb.gentoo.org/proj/devmanual.git/commit/?id=0ef26e79892567f73359629f0cc0c00df3651dd1 commit 0ef26e79892567f73359629f0cc0c00df3651dd1 Author: Amit Dor-Shifer <amitds@oversi.com> AuthorDate: 2009-10-19 07:37:22 +0000 Commit: Ulrich Müller <ulm@gentoo.org> CommitDate: 2022-06-05 21:01:41 +0000 general-concepts/config-protect: Add example for env.d Closes: https://bugs.gentoo.org/289565 [Make the XML validate. Small tweaks to example and wording.] Signed-off-by: Ulrich Müller <ulm@gentoo.org> general-concepts/config-protect/text.xml | 15 +++++++++++++++ 1 file changed, 15 insertions(+)