We currently has this message: kernel-2_pkg_postrm() { # This warning only makes sense for kernel sources. [[ ${ETYPE} == headers ]] && return 0 # If there isn't anything left behind, then don't complain. [[ -e ${ROOT}usr/src/linux-${KV_FULL} ]] || return 0 echo ewarn "Note: Even though you have successfully unmerged " ewarn "your kernel package, directories in kernel source location: " ewarn "${ROOT}usr/src/linux-${KV_FULL}" ewarn "with modified files will remain behind. By design, package managers" ewarn "will not remove these modified files and the directories they reside in." echo } But most people run kernels with modules and, hence, they will also have many files left behind there when removing the kernel. Maybe the warning could be extended as a hint for admins to also clean that dir Thanks
Well... and /boot also ;)
(In reply to Pacho Ramos from comment #1) > Well... and /boot also ;) The files left behind in /boot and /lib/modules are of a totally different category than those left behind in /usr/src/linux-${KV_FULL}. The former are the installed vmlinuz image and modules for booting. The later are the object files generated when building. The message is support to alert people to the latter files which are left in /usr/src/linux-${KV_FULL} even after the gentoo-sources of hardened-sources for that ${KV_FULL} are removed. It is not obvious that those files are left behind in /usr/src/linux-${KV_FULL} when everything else is removed on unmerging. So, the message is fine as is. I'll let mgpagano chime in. Maybe we want to clarify the message? I don't know. I don't know in what context this became and issue so I'm not sure how to address it.
I'm OK with clarifying it. Are user's confused why these files still exist after an unmerge? I've never had complaints over the last 8 years, myself but I'm just one sample source.
Other option would be to point to this: https://wiki.gentoo.org/wiki/Kernel/Removal But I don't know if that page is "official" :/
(In reply to Pacho Ramos from comment #4) > Other option would be to point to this: > https://wiki.gentoo.org/wiki/Kernel/Removal > > But I don't know if that page is "official" :/ I like this idea the best. I'll include a link to this in a patch and submit to gentoo-dev.
commit 56f159b0f4eb644f3a7109e66c81d0280e9cf6fd Author: Mike Pagano <mpagano@gentoo.org> Date: Wed Dec 28 19:11:22 2016 -0500 kernel-2.eclass: Point user to addtional kernel removal instructions. See bug #581522.