>>> Preparing source in /var/tmp/portage/net-firewall/ipset-6.17/work/ipset-6.17 ... * Sorry, but you have to patch kernel sources with the following patch: * # cd /usr/src/linux * # patch -i /var/tmp/portage/net-firewall/ipset-6.17/work/ipset-6.17/netlink.patch -p1 * You should recompile and run new kernel to avoid runtime errors. * ERROR: net-firewall/ipset-6.17::gentoo failed (prepare phase): * Unpatched kernel Since the ebuild is already using EAPI-5, it seems better to have this kind of checks in pkg_pretend (possibly also executing it only if we're going to build from source instead of doing binpkg).
No, this cannot be done, because the build_modules variable is set depending on a lot of linux_chkconfig/linux_config tests; and those are very heavy to move to pkg_pretend.