I use kernel without any modules and CONFIG_MODULES=n accordingly. genkernel all fails on this configuration with such log: genkernel all * Gentoo Linux Genkernel; Version 3.4.49 * Running with options: all * Using genkernel.conf from /etc/genkernel.conf * Sourcing arch-specific config.sh from /usr/share/genkernel/arch/x86_64/config.sh .. * Sourcing arch-specific modules_load from /usr/share/genkernel/arch/x86_64/modules_load .. * Linux Kernel 3.13.10-hardened for x86_64... * .. with config file /usr/share/genkernel/arch/x86_64/kernel-config * kernel: --mrproper is disabled; not running 'make mrproper'. * kernel: --oldconfig is disabled; not running 'make oldconfig'. * kernel: >> Cleaning... * >> Compiling 3.13.10-hardened bzImage... * >> Installing firmware ('make firmware_install') due to CONFIG_FIRMWARE_IN_KERNEL != y... * >> Compiling 3.13.10-hardened modules... * ERROR: Failed to compile the "modules" target... * * -- Grepping log... -- * * LD drivers/tty/built-in.o * LD drivers/built-in.o * LINK vmlinux * LD vmlinux.o * MODPOST vmlinux.o *WARNING: modpost: Found 1988 section mismatch(es). *-- * Running with options: all * Using genkernel.conf from /etc/genkernel.conf * Sourcing arch-specific config.sh from /usr/share/genkernel/arch/x86_64/config.sh .. * Sourcing arch-specific modules_load from /usr/share/genkernel/arch/x86_64/modules_load .. * * ERROR: Failed to compile the "modules" target... * * -- End log... -- * * Please consult /var/log/genkernel.log for more information and any * errors that were reported above. * * Report any genkernel bugs to bugs.gentoo.org and * assign your bug to genkernel@gentoo.org. Please include * as much information as you can in your bug report; attaching * /var/log/genkernel.log so that your issue can be dealt with effectively. * * Please do *not* report compilation failures as genkernel bugs! *
I can confirm this issue with recent versions of genkernel.
*** Bug 502216 has been marked as a duplicate of this bug. ***
Judging from bug 95993, it seems that the bzImage target (instead of all) is meant for exactly this. But it also seems to enable initramfs generation, and I'm trying to find out why.
Created attachment 493358 [details, diff] no initramfs build for bzImage target
The bug has been closed via the following commit(s): https://gitweb.gentoo.org/proj/genkernel.git/commit/?id=482e2c70b253b9d62fc907d6612d80addd3358c1 commit 482e2c70b253b9d62fc907d6612d80addd3358c1 Author: Robin H. Johnson <robbat2@gentoo.org> AuthorDate: 2017-11-18 21:24:12 +0000 Commit: Robin H. Johnson <robbat2@gentoo.org> CommitDate: 2017-11-18 21:24:12 +0000 gen_cmdline: bzImage target should not create initramfs. Closes: https://bugs.gentoo.org/511964 Signed-off-by: Robin H. Johnson <robbat2@gentoo.org> gen_cmdline.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)