When using genkernel after installing a new kernel with a new configuration settings, genkernel tries to execute "make prepare" and fails since it cannot provide value for the new settings. Reproducible: Always Steps to Reproduce: 1. Compile your kernel using genkernel. 2. Add an new entry to Kconfig. 3. Try to compile your kernel again with the same config created in 1. Actual Results: Genkernel fails without proper message. Expected Results: 1. Print proper message that prepare failed. 2. If execute with --menuconfig maybe skip the initial prepare?
Please attach a genkernel.log of the failure.
Created attachment 62577 [details] A sample of error I've added the following to init/Kconfig A new options are added by many kernel patches... The config does not have an entry to ALON_A, then you get the error. menu "alon" config ALON_A int "test" default 5 help this is a test endmenu
genkernel 3.2.2 is out and it should fix this issue. The early make prepare has been removed. Please reopen if this is an issue.
Hi! It does not work currectly... You commented the "compile_generic prepare kernel > /dev/null 2>&1", but you still reference to the ${KERNEL_DIR}/include/linux/version.h that should refer to the output of the prepare... This causes CONFIG_LOCALVERSION to be ignored. You can parse the.config file or determine kernel version string only after menuconfig or prepare.
Created attachment 63328 [details, diff] Parse .config to create kernel version This is a suggestion of parsing .config file in place of the version.h.
This will not work as there are multiple places the VERSION can creep into play. The kernel Makefiles may modify it after a prepare is run. IF a localversion-* file is found in the kernel sources tree it will append that as well. So really our solution is better it just needs to execute a bit later after the prepare.
I agree. But you have a loop there... Since you determine kernel version then fetch the config file from /etc/kernels and only then you can prepare... You cannot prepare until you have .config. You cannot copy .config from /etc/kernels until you prepare and get currect version. So what do you do? You can force the user to sepcify config file. This solves the problem... 1. copy the correct .config 2. OPT menuconfig 3. prepare Now you get kernel version and continue...
Solution: Try make prepare Works? Continue as usual. Fails? Try parsing .config. Fixed in my CVS queue.
Fixed in 3.2.3, thanks!
Sorry for reopen... But the last fix was with error. Consider the patch.
Created attachment 63409 [details, diff] gen_determineargs.sh.diff Remove error messages due to variable not set.
Thanks for the patch. This was reported to us via another bug report. It should be included in the next genkernel.
genkernel-3.2.5 is out ..