[poky] Applying a defconfig easily to a kernel
Bruce Ashfield
bruce.ashfield at gmail.com
Sat Feb 4 21:28:30 PST 2012
On Sat, Feb 4, 2012 at 5:51 AM, Bryan O'Donoghue
<magnificopaddy at gmail.com> wrote:
> Greetings list.
>
> I've had a hard time applying a complete - unmodified defconfig to my
> local git kernel config. So rather than dig through the internals of
> the build process, I took the following short-cut.
>
> It works - is it "wrong" though ? I like it because it's
> easy/straightforward. Basically if I define a defconfig - the system
> will trust the file and apply it directly - which I suspect is what
> 99% of people who supply a defconfig will want anyway.
>
> Consider applying.
This isn't what we want. defconfigs are properly handled by the integrated
build rules already. And it does work ... I confirmed that multiple times
on Friday.
You problem is that you are attempting to use the linux-yocto repository
+ a decfonfig and running into some problems. We can work through those
issues and determine what is happening.
We want the integrated defconfig handling, since features can still be appended
and have their own associated kernel config values. With a defconfig clobber,
all that functionality is broken. As are the configuration audit
steps, etc, etc. In
other words, it drops the value that we are trying to promote and nudge away
from defconfigs.
Cheers,
Bruce
>
> diff --git a/meta/classes/kernel-yocto.bbclass
> b/meta/classes/kernel-yocto.bbclass
> index 1b73e6e..f278472 100644
> --- a/meta/classes/kernel-yocto.bbclass
> +++ b/meta/classes/kernel-yocto.bbclass
> @@ -178,8 +178,15 @@ do_kernel_configme() {
> exit 1
> fi
>
> - echo "# Global settings from linux recipe" >> ${B}/.config
> - echo "CONFIG_LOCALVERSION="\"${LINUX_VERSION_EXTENSION}\" >> ${B}/.config
> + if [ -f ${WORKDIR}/defconfig ]; then
> + echo "[INFO] HAVE A DEFCONFIG - copying verbatim"
> + cat ${WORKDIR}/defconfig
> + cp ${WORKDIR}/defconfig ${B}/.config
> + else
> + echo "# Global settings from linux recipe" >> ${B}/.config
> + echo "CONFIG_LOCALVERSION="\"${LINUX_VERSION_EXTENSION}\" >> ${B}/.config
> + fi
> +
> }
>
> python do_kernel_configcheck()
--
"Thou shalt not follow the NULL pointer, for chaos and madness await
thee at its end"
More information about the poky
mailing list