All of lore.kernel.org
 help / color / mirror / Atom feed
* Custom kernel in Yocto/dylan branch.
@ 2013-06-11 14:18 Javi Roman
  2013-06-11 14:23 ` Bruce Ashfield
  0 siblings, 1 reply; 7+ messages in thread
From: Javi Roman @ 2013-06-11 14:18 UTC (permalink / raw)
  To: yocto

Hi!


I few years ago I used to work with OpenEmbedded (the classical
branch). The addition of new kernel recipes was easy for me,
nevertheless I'm unable to do similar things with the current
Yocto-dylan branch.

The current Yocto-dylan is based on Linux kernel 3.x branches, all the
documentation regarding add custom kernels or new kernel features are
based on those 3.x branches. However, I would like to use a 2.6.32
Linux kernel (it's a constraint for my project).

I'm using the following kernel recipe in my bsp:

linux/
      linux-yocto-abacus/
                 defconfig
       linux-yocto-abacus_2.6.32.bb

#####  linux-yocto-abacus_2.6.32.bb ####

inherit kernel
require recipes-kernel/linux/linux-yocto.inc

INHIBIT_PACKAGE_DEBUG_SPLIT =3D "1"

FILESEXTRAPATHS_prepend :=3D "${THISDIR}/${PN}:"
SRC_URI_append =3D "file://defconfig"

PROVIDES =3D "virtual/kernel"

SRC_URI =3D "git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.g=
it;protocol=3Dgit;nocheckout=3D1"

LINUX_VERSION =3D "2.6.32"
LINUX_VERSION_EXTENSION =3D "-abacus"

# tag: v3.4    76e10d158efb6d4516018846f60c2ab5501900bc
# tag: v2.6.32 459b3d520991ec1b8e5ba68fbc4b206d602fee6e
SRCREV=3D"459b3d520991ec1b8e5ba68fbc4b206d602fee6e"

PR =3D "r1"
PV =3D "${LINUX_VERSION}+git${SRCPV}"

COMPATIBLE_MACHINE =3D "romley"

############ end ###################

When I build the kernel with:

# bitbake virtual/kernel

The kernel is downloaded from kernel.org, with the correct git tag
(v2.6.32) and is built with success. Nevertheless, the "defconfig" is
not properly added in the kernel configuration. If I run:

# bitbake virtual/kernel -c menuconfig

The ncurses menuconfig is not using the "defconfig" added by me.

The "defconfig" with all kernel configurations is a deprecated feature?
Which is the correct way to add a new kernel recipe?

Many thanks!
Javi Roman


^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Custom kernel in Yocto/dylan branch.
  2013-06-11 14:18 Custom kernel in Yocto/dylan branch Javi Roman
@ 2013-06-11 14:23 ` Bruce Ashfield
  2013-06-11 14:47   ` Javi Roman
  0 siblings, 1 reply; 7+ messages in thread
From: Bruce Ashfield @ 2013-06-11 14:23 UTC (permalink / raw)
  To: Javi Roman; +Cc: yocto

On 13-06-11 10:18 AM, Javi Roman wrote:
> Hi!
>
>
> I few years ago I used to work with OpenEmbedded (the classical
> branch). The addition of new kernel recipes was easy for me,
> nevertheless I'm unable to do similar things with the current
> Yocto-dylan branch.
>
> The current Yocto-dylan is based on Linux kernel 3.x branches, all the
> documentation regarding add custom kernels or new kernel features are
> based on those 3.x branches. However, I would like to use a 2.6.32
> Linux kernel (it's a constraint for my project).
>
> I'm using the following kernel recipe in my bsp:
>
> linux/
>        linux-yocto-abacus/
>                   defconfig
>         linux-yocto-abacus_2.6.32.bb
>
> #####  linux-yocto-abacus_2.6.32.bb ####
>
> inherit kernel
> require recipes-kernel/linux/linux-yocto.inc
>
> INHIBIT_PACKAGE_DEBUG_SPLIT =3D "1"
>
> FILESEXTRAPATHS_prepend :=3D "${THISDIR}/${PN}:"
> SRC_URI_append =3D "file://defconfig"
>
> PROVIDES =3D "virtual/kernel"
>
> SRC_URI =3D "git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.g=
> it;protocol=3Dgit;nocheckout=3D1"
>
> LINUX_VERSION =3D "2.6.32"
> LINUX_VERSION_EXTENSION =3D "-abacus"
>
> # tag: v3.4    76e10d158efb6d4516018846f60c2ab5501900bc
> # tag: v2.6.32 459b3d520991ec1b8e5ba68fbc4b206d602fee6e
> SRCREV=3D"459b3d520991ec1b8e5ba68fbc4b206d602fee6e"
>
> PR =3D "r1"
> PV =3D "${LINUX_VERSION}+git${SRCPV}"
>
> COMPATIBLE_MACHINE =3D "romley"
>
> ############ end ###################
>
> When I build the kernel with:
>
> # bitbake virtual/kernel
>
> The kernel is downloaded from kernel.org, with the correct git tag
> (v2.6.32) and is built with success. Nevertheless, the "defconfig" is
> not properly added in the kernel configuration. If I run:
>
> # bitbake virtual/kernel -c menuconfig
>
> The ncurses menuconfig is not using the "defconfig" added by me.
>
> The "defconfig" with all kernel configurations is a deprecated feature?
> Which is the correct way to add a new kernel recipe?

It definitely should still be working, we have plenty of defconfig
users (whether right or wong ;) and it is tested daily.

How did you specify your defconfig on the SRC_URI ?

Bruce

>
> Many thanks!
> Javi Roman
> _______________________________________________
> yocto mailing list
> yocto@yoctoproject.org
> https://lists.yoctoproject.org/listinfo/yocto
>



^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Custom kernel in Yocto/dylan branch.
  2013-06-11 14:23 ` Bruce Ashfield
@ 2013-06-11 14:47   ` Javi Roman
  2013-06-11 15:21     ` Bruce Ashfield
  2013-06-11 15:34     ` Paul Eggleton
  0 siblings, 2 replies; 7+ messages in thread
From: Javi Roman @ 2013-06-11 14:47 UTC (permalink / raw)
  To: Bruce Ashfield; +Cc: yocto

With

SRC_URI_append = "file://defconfig"


Javi Roman


On Tue, Jun 11, 2013 at 4:23 PM, Bruce Ashfield
<bruce.ashfield@windriver.com> wrote:
> On 13-06-11 10:18 AM, Javi Roman wrote:
>>
>> Hi!
>>
>>
>> I few years ago I used to work with OpenEmbedded (the classical
>> branch). The addition of new kernel recipes was easy for me,
>> nevertheless I'm unable to do similar things with the current
>> Yocto-dylan branch.
>>
>> The current Yocto-dylan is based on Linux kernel 3.x branches, all the
>> documentation regarding add custom kernels or new kernel features are
>> based on those 3.x branches. However, I would like to use a 2.6.32
>> Linux kernel (it's a constraint for my project).
>>
>> I'm using the following kernel recipe in my bsp:
>>
>> linux/
>>        linux-yocto-abacus/
>>                   defconfig
>>         linux-yocto-abacus_2.6.32.bb
>>
>> #####  linux-yocto-abacus_2.6.32.bb ####
>>
>> inherit kernel
>> require recipes-kernel/linux/linux-yocto.inc
>>
>> INHIBIT_PACKAGE_DEBUG_SPLIT =3D "1"
>>
>> FILESEXTRAPATHS_prepend :=3D "${THISDIR}/${PN}:"
>> SRC_URI_append =3D "file://defconfig"
>>
>> PROVIDES =3D "virtual/kernel"
>>
>> SRC_URI =3D
>> "git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.g=
>> it;protocol=3Dgit;nocheckout=3D1"
>>
>> LINUX_VERSION =3D "2.6.32"
>> LINUX_VERSION_EXTENSION =3D "-abacus"
>>
>> # tag: v3.4    76e10d158efb6d4516018846f60c2ab5501900bc
>> # tag: v2.6.32 459b3d520991ec1b8e5ba68fbc4b206d602fee6e
>> SRCREV=3D"459b3d520991ec1b8e5ba68fbc4b206d602fee6e"
>>
>> PR =3D "r1"
>> PV =3D "${LINUX_VERSION}+git${SRCPV}"
>>
>> COMPATIBLE_MACHINE =3D "romley"
>>
>> ############ end ###################
>>
>> When I build the kernel with:
>>
>> # bitbake virtual/kernel
>>
>> The kernel is downloaded from kernel.org, with the correct git tag
>> (v2.6.32) and is built with success. Nevertheless, the "defconfig" is
>> not properly added in the kernel configuration. If I run:
>>
>> # bitbake virtual/kernel -c menuconfig
>>
>> The ncurses menuconfig is not using the "defconfig" added by me.
>>
>> The "defconfig" with all kernel configurations is a deprecated feature?
>> Which is the correct way to add a new kernel recipe?
>
>
> It definitely should still be working, we have plenty of defconfig
> users (whether right or wong ;) and it is tested daily.
>
> How did you specify your defconfig on the SRC_URI ?
>
> Bruce
>
>>
>> Many thanks!
>> Javi Roman
>> _______________________________________________
>> yocto mailing list
>> yocto@yoctoproject.org
>> https://lists.yoctoproject.org/listinfo/yocto
>>
>


^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Custom kernel in Yocto/dylan branch.
  2013-06-11 14:47   ` Javi Roman
@ 2013-06-11 15:21     ` Bruce Ashfield
  2013-06-11 15:34     ` Paul Eggleton
  1 sibling, 0 replies; 7+ messages in thread
From: Bruce Ashfield @ 2013-06-11 15:21 UTC (permalink / raw)
  To: Javi Roman; +Cc: yocto

On 13-06-11 10:47 AM, Javi Roman wrote:
> With
>
> SRC_URI_append = "file://defconfig"
>

Which is what I expected. And you say that it isn't being applied
at all ? Is that by inspecting the final contents of .config ?
Or something else ?

Since this is on the dylan branches, I know it has been tested
explicitly there.

I'll switch and do some of my own test builds.

Cheers,

Bruce

>
> Javi Roman
>
>
> On Tue, Jun 11, 2013 at 4:23 PM, Bruce Ashfield
> <bruce.ashfield@windriver.com> wrote:
>> On 13-06-11 10:18 AM, Javi Roman wrote:
>>>
>>> Hi!
>>>
>>>
>>> I few years ago I used to work with OpenEmbedded (the classical
>>> branch). The addition of new kernel recipes was easy for me,
>>> nevertheless I'm unable to do similar things with the current
>>> Yocto-dylan branch.
>>>
>>> The current Yocto-dylan is based on Linux kernel 3.x branches, all the
>>> documentation regarding add custom kernels or new kernel features are
>>> based on those 3.x branches. However, I would like to use a 2.6.32
>>> Linux kernel (it's a constraint for my project).
>>>
>>> I'm using the following kernel recipe in my bsp:
>>>
>>> linux/
>>>         linux-yocto-abacus/
>>>                    defconfig
>>>          linux-yocto-abacus_2.6.32.bb
>>>
>>> #####  linux-yocto-abacus_2.6.32.bb ####
>>>
>>> inherit kernel
>>> require recipes-kernel/linux/linux-yocto.inc
>>>
>>> INHIBIT_PACKAGE_DEBUG_SPLIT =3D "1"
>>>
>>> FILESEXTRAPATHS_prepend :=3D "${THISDIR}/${PN}:"
>>> SRC_URI_append =3D "file://defconfig"
>>>
>>> PROVIDES =3D "virtual/kernel"
>>>
>>> SRC_URI =3D
>>> "git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.g=
>>> it;protocol=3Dgit;nocheckout=3D1"
>>>
>>> LINUX_VERSION =3D "2.6.32"
>>> LINUX_VERSION_EXTENSION =3D "-abacus"
>>>
>>> # tag: v3.4    76e10d158efb6d4516018846f60c2ab5501900bc
>>> # tag: v2.6.32 459b3d520991ec1b8e5ba68fbc4b206d602fee6e
>>> SRCREV=3D"459b3d520991ec1b8e5ba68fbc4b206d602fee6e"
>>>
>>> PR =3D "r1"
>>> PV =3D "${LINUX_VERSION}+git${SRCPV}"
>>>
>>> COMPATIBLE_MACHINE =3D "romley"
>>>
>>> ############ end ###################
>>>
>>> When I build the kernel with:
>>>
>>> # bitbake virtual/kernel
>>>
>>> The kernel is downloaded from kernel.org, with the correct git tag
>>> (v2.6.32) and is built with success. Nevertheless, the "defconfig" is
>>> not properly added in the kernel configuration. If I run:
>>>
>>> # bitbake virtual/kernel -c menuconfig
>>>
>>> The ncurses menuconfig is not using the "defconfig" added by me.
>>>
>>> The "defconfig" with all kernel configurations is a deprecated feature?
>>> Which is the correct way to add a new kernel recipe?
>>
>>
>> It definitely should still be working, we have plenty of defconfig
>> users (whether right or wong ;) and it is tested daily.
>>
>> How did you specify your defconfig on the SRC_URI ?
>>
>> Bruce
>>
>>>
>>> Many thanks!
>>> Javi Roman
>>> _______________________________________________
>>> yocto mailing list
>>> yocto@yoctoproject.org
>>> https://lists.yoctoproject.org/listinfo/yocto
>>>
>>



^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Custom kernel in Yocto/dylan branch.
  2013-06-11 14:47   ` Javi Roman
  2013-06-11 15:21     ` Bruce Ashfield
@ 2013-06-11 15:34     ` Paul Eggleton
  2013-06-12 12:37       ` Javi Roman
  1 sibling, 1 reply; 7+ messages in thread
From: Paul Eggleton @ 2013-06-11 15:34 UTC (permalink / raw)
  To: Javi Roman; +Cc: yocto

On Tuesday 11 June 2013 16:47:53 Javi Roman wrote:
> With
> 
> SRC_URI_append = "file://defconfig"

Does your actual recipe have a leading space in the value? _append won't add 
this for you so you have to do it explicitly.

Cheers,
Paul

-- 

Paul Eggleton
Intel Open Source Technology Centre


^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Custom kernel in Yocto/dylan branch.
  2013-06-11 15:34     ` Paul Eggleton
@ 2013-06-12 12:37       ` Javi Roman
  2013-06-12 12:49         ` Bruce Ashfield
  0 siblings, 1 reply; 7+ messages in thread
From: Javi Roman @ 2013-06-12 12:37 UTC (permalink / raw)
  To: Paul Eggleton; +Cc: yocto

Hi!

Thank you for your help.

Finally I've had to change the meta/classes/kernel.bbclass in order to
fix the copy of defconfig to .config:

-  if [ -f "${WORKDIR}/defconfig" ] && [ ! -f "${B}/.config" ]; then
+ if [ -f "${WORKDIR}/defconfig" ]; then
                cp "${WORKDIR}/defconfig" "${B}/.config"
fi

I don't know the exact problem, and I'm trying to find out it.

Cheers.

Javi Roman


On Tue, Jun 11, 2013 at 5:34 PM, Paul Eggleton
<paul.eggleton@linux.intel.com> wrote:
> On Tuesday 11 June 2013 16:47:53 Javi Roman wrote:
>> With
>>
>> SRC_URI_append = "file://defconfig"
>
> Does your actual recipe have a leading space in the value? _append won't add
> this for you so you have to do it explicitly.
>
> Cheers,
> Paul
>
> --
>
> Paul Eggleton
> Intel Open Source Technology Centre


^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Custom kernel in Yocto/dylan branch.
  2013-06-12 12:37       ` Javi Roman
@ 2013-06-12 12:49         ` Bruce Ashfield
  0 siblings, 0 replies; 7+ messages in thread
From: Bruce Ashfield @ 2013-06-12 12:49 UTC (permalink / raw)
  To: Javi Roman; +Cc: Paul Eggleton, yocto

On 13-06-12 08:37 AM, Javi Roman wrote:
> Hi!
>
> Thank you for your help.
>
> Finally I've had to change the meta/classes/kernel.bbclass in order to
> fix the copy of defconfig to .config:
>
> -  if [ -f "${WORKDIR}/defconfig" ] && [ ! -f "${B}/.config" ]; then
> + if [ -f "${WORKDIR}/defconfig" ]; then
>                  cp "${WORKDIR}/defconfig" "${B}/.config"
> fi
>

Right. That check is what prevents the fallback defconfig processing
from clobbering the .config which is generated by a linux-yocto* based
kernel configuration task (which gives you defconfig + fragments).

The point is that in the linux-yocto "configme" task essentially the
same thing that happens. The defconfig is fed into the configuration
as the baseline config, applied after a "allnoconfig" and then has
any fragments layered on top.

Which again leads me to my question about what exactly you were
seeing before that change in the linux build directory as the .config ?

Cheers,

Bruce

> I don't know the exact problem, and I'm trying to find out it.
>
> Cheers.
>
> Javi Roman
>
>
> On Tue, Jun 11, 2013 at 5:34 PM, Paul Eggleton
> <paul.eggleton@linux.intel.com> wrote:
>> On Tuesday 11 June 2013 16:47:53 Javi Roman wrote:
>>> With
>>>
>>> SRC_URI_append = "file://defconfig"
>>
>> Does your actual recipe have a leading space in the value? _append won't add
>> this for you so you have to do it explicitly.
>>
>> Cheers,
>> Paul
>>
>> --
>>
>> Paul Eggleton
>> Intel Open Source Technology Centre



^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2013-06-12 12:50 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-06-11 14:18 Custom kernel in Yocto/dylan branch Javi Roman
2013-06-11 14:23 ` Bruce Ashfield
2013-06-11 14:47   ` Javi Roman
2013-06-11 15:21     ` Bruce Ashfield
2013-06-11 15:34     ` Paul Eggleton
2013-06-12 12:37       ` Javi Roman
2013-06-12 12:49         ` Bruce Ashfield

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.