All of lore.kernel.org
 help / color / mirror / Atom feed
* wrong rpm name qt package
@ 2011-05-26  7:31 Gerard van den Bosch
  2011-05-26  9:43 ` Richard Purdie
  0 siblings, 1 reply; 10+ messages in thread
From: Gerard van den Bosch @ 2011-05-26  7:31 UTC (permalink / raw)
  To: poky

[-- Attachment #1: Type: text/plain, Size: 599 bytes --]

Hello,

I have developed a shared library using Qt, it compiles without any 
problems but it goes wrong with rpm packaging.
When it packages it should create a rpm package with the name 
"libxmlpcpqt" but it creates a package with "libxmlpcpqt1".
My question is where does the '1' come from?

The install part from the recipe is as follows:
do_install() {
      install -d ${D}${libdir}
      install -m 0755 ${S}/${PN}.so ${D}${libdir}
}

In the 
/tmp/work/armv7a-poky-linux-gnueabi/libxmlpcpqt-0.1-r1/image/usr/lib the 
libxmlpcpqt.so file correctly exists.

Regards,
Gerard


[-- Attachment #2: Type: text/html, Size: 1083 bytes --]

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

* Re: wrong rpm name qt package
  2011-05-26  7:31 wrong rpm name qt package Gerard van den Bosch
@ 2011-05-26  9:43 ` Richard Purdie
  2011-05-26 11:22   ` Gerard van den Bosch
  0 siblings, 1 reply; 10+ messages in thread
From: Richard Purdie @ 2011-05-26  9:43 UTC (permalink / raw)
  To: Gerard van den Bosch; +Cc: poky

On Thu, 2011-05-26 at 09:31 +0200, Gerard van den Bosch wrote:
> I have developed a shared library using Qt, it compiles without any
> problems but it goes wrong with rpm packaging.
> When it packages it should create a rpm package with the name
> "libxmlpcpqt" but it creates a package with "libxmlpcpqt1".
> My question is where does the '1' come from?
> 
> The install part from the recipe is as follows:
> do_install() {
>      install -d ${D}${libdir}
>      install -m 0755 ${S}/${PN}.so ${D}${libdir}
> }
> 
> In
> the /tmp/work/armv7a-poky-linux-gnueabi/libxmlpcpqt-0.1-r1/image/usr/lib the libxmlpcpqt.so file correctly exists.

This happens as debian style package naming is enabled (debian.bbclass
is inherited).

Cheers,

Richard



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

* Re: wrong rpm name qt package
  2011-05-26  9:43 ` Richard Purdie
@ 2011-05-26 11:22   ` Gerard van den Bosch
  2011-05-26 13:54     ` Richard Purdie
  0 siblings, 1 reply; 10+ messages in thread
From: Gerard van den Bosch @ 2011-05-26 11:22 UTC (permalink / raw)
  To: Richard Purdie; +Cc: poky

On 05/26/2011 11:43 AM, Richard Purdie wrote:
> On Thu, 2011-05-26 at 09:31 +0200, Gerard van den Bosch wrote:
>> I have developed a shared library using Qt, it compiles without any
>> problems but it goes wrong with rpm packaging.
>> When it packages it should create a rpm package with the name
>> "libxmlpcpqt" but it creates a package with "libxmlpcpqt1".
>> My question is where does the '1' come from?
>>
>> The install part from the recipe is as follows:
>> do_install() {
>>       install -d ${D}${libdir}
>>       install -m 0755 ${S}/${PN}.so ${D}${libdir}
>> }
>>
>> In
>> the /tmp/work/armv7a-poky-linux-gnueabi/libxmlpcpqt-0.1-r1/image/usr/lib the libxmlpcpqt.so file correctly exists.
> This happens as debian style package naming is enabled (debian.bbclass
> is inherited).
>
> Cheers,
>
> Richard
>
I tried removing debian from the INHERITS+= variable in the poky.conf but then it printed it couldn't find the function that is inside debian.bbclass and didn't create the package.
Modifying debian.bbclass would be too drastic so I work around it like this:
Added PACKAGES+= ${PN}1 to my recipe
Modified the IMAGE_INSTALL+= variable from libxmlpcpqt to libxmlpcpqt1
This resulted in a working solution.

Regards,
Gerard




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

* Re: wrong rpm name qt package
  2011-05-26 11:22   ` Gerard van den Bosch
@ 2011-05-26 13:54     ` Richard Purdie
  2011-05-26 14:13       ` Gerard van den Bosch
  2011-05-27  6:10       ` Gerard van den Bosch
  0 siblings, 2 replies; 10+ messages in thread
From: Richard Purdie @ 2011-05-26 13:54 UTC (permalink / raw)
  To: Gerard van den Bosch; +Cc: poky

On Thu, 2011-05-26 at 13:22 +0200, Gerard van den Bosch wrote:
> On 05/26/2011 11:43 AM, Richard Purdie wrote:
> > On Thu, 2011-05-26 at 09:31 +0200, Gerard van den Bosch wrote:
> >> I have developed a shared library using Qt, it compiles without any
> >> problems but it goes wrong with rpm packaging.
> >> When it packages it should create a rpm package with the name
> >> "libxmlpcpqt" but it creates a package with "libxmlpcpqt1".
> >> My question is where does the '1' come from?
> >>
> >> The install part from the recipe is as follows:
> >> do_install() {
> >>       install -d ${D}${libdir}
> >>       install -m 0755 ${S}/${PN}.so ${D}${libdir}
> >> }
> >>
> >> In
> >> the /tmp/work/armv7a-poky-linux-gnueabi/libxmlpcpqt-0.1-r1/image/usr/lib the libxmlpcpqt.so file correctly exists.
> > This happens as debian style package naming is enabled (debian.bbclass
> > is inherited).
> >
> > Cheers,
> >
> > Richard
> >
> I tried removing debian from the INHERITS+= variable in the poky.conf
> but then it printed it couldn't find the function that is inside
> debian.bbclass and didn't create the package.
> Modifying debian.bbclass would be too drastic so I work around it like
> this:
> Added PACKAGES+= ${PN}1 to my recipe
> Modified the IMAGE_INSTALL+= variable from libxmlpcpqt to libxmlpcpqt1
> This resulted in a working solution.

This is a bug and you should never need to do this. IMAGE_INSTALL should
be getting remapped to the new names. The code that is meant to do that
is at the top of image.bbclass:

    # If we don't do this we try and run the mapping hooks while parsing which is slow
    # bitbake should really provide something to let us know this...
    if bb.data.getVar('BB_WORKERCONTEXT', d, True) is not None:
        runtime_mapping_rename("PACKAGE_INSTALL", d)
        runtime_mapping_rename("PACKAGE_INSTALL_ATTEMPTONLY", d)

Can you check that the code is being called? I suspect something to do
with the BB_WORKERCONTEXT variable has been broken. We should be doing
this in a better way anyhow...

Cheers,

Richard






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

* Re: wrong rpm name qt package
  2011-05-26 13:54     ` Richard Purdie
@ 2011-05-26 14:13       ` Gerard van den Bosch
  2011-05-27  6:10       ` Gerard van den Bosch
  1 sibling, 0 replies; 10+ messages in thread
From: Gerard van den Bosch @ 2011-05-26 14:13 UTC (permalink / raw)
  To: Richard Purdie; +Cc: poky

On 05/26/2011 03:54 PM, Richard Purdie wrote:
> On Thu, 2011-05-26 at 13:22 +0200, Gerard van den Bosch wrote:
>> On 05/26/2011 11:43 AM, Richard Purdie wrote:
>>> On Thu, 2011-05-26 at 09:31 +0200, Gerard van den Bosch wrote:
>>>> I have developed a shared library using Qt, it compiles without any
>>>> problems but it goes wrong with rpm packaging.
>>>> When it packages it should create a rpm package with the name
>>>> "libxmlpcpqt" but it creates a package with "libxmlpcpqt1".
>>>> My question is where does the '1' come from?
>>>>
>>>> The install part from the recipe is as follows:
>>>> do_install() {
>>>>        install -d ${D}${libdir}
>>>>        install -m 0755 ${S}/${PN}.so ${D}${libdir}
>>>> }
>>>>
>>>> In
>>>> the /tmp/work/armv7a-poky-linux-gnueabi/libxmlpcpqt-0.1-r1/image/usr/lib the libxmlpcpqt.so file correctly exists.
>>> This happens as debian style package naming is enabled (debian.bbclass
>>> is inherited).
>>>
>>> Cheers,
>>>
>>> Richard
>>>
>> I tried removing debian from the INHERITS+= variable in the poky.conf
>> but then it printed it couldn't find the function that is inside
>> debian.bbclass and didn't create the package.
>> Modifying debian.bbclass would be too drastic so I work around it like
>> this:
>> Added PACKAGES+= ${PN}1 to my recipe
>> Modified the IMAGE_INSTALL+= variable from libxmlpcpqt to libxmlpcpqt1
>> This resulted in a working solution.
> This is a bug and you should never need to do this. IMAGE_INSTALL should
> be getting remapped to the new names. The code that is meant to do that
> is at the top of image.bbclass:
>
>      # If we don't do this we try and run the mapping hooks while parsing which is slow
>      # bitbake should really provide something to let us know this...
>      if bb.data.getVar('BB_WORKERCONTEXT', d, True) is not None:
>          runtime_mapping_rename("PACKAGE_INSTALL", d)
>          runtime_mapping_rename("PACKAGE_INSTALL_ATTEMPTONLY", d)
>
> Can you check that the code is being called? I suspect something to do
> with the BB_WORKERCONTEXT variable has been broken. We should be doing
> this in a better way anyhow...
>
> Cheers,
>
> Richard
>
Ok, I am still using the Laverne release so maybe that's the problem, I will try to compile it on a system where I have the Bernard release tonight to ensure that the bug isn't fixed already.
If the problem still occurs there, I will check the suggested.
I will send an update as soon as possible.

Regards,
Gerard




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

* Re: wrong rpm name qt package
  2011-05-26 13:54     ` Richard Purdie
  2011-05-26 14:13       ` Gerard van den Bosch
@ 2011-05-27  6:10       ` Gerard van den Bosch
  2011-05-27 12:49         ` Richard Purdie
  1 sibling, 1 reply; 10+ messages in thread
From: Gerard van den Bosch @ 2011-05-27  6:10 UTC (permalink / raw)
  To: Richard Purdie; +Cc: poky

[-- Attachment #1: Type: text/plain, Size: 4337 bytes --]

On 05/26/2011 03:54 PM, Richard Purdie wrote:
> On Thu, 2011-05-26 at 13:22 +0200, Gerard van den Bosch wrote:
>> On 05/26/2011 11:43 AM, Richard Purdie wrote:
>>> On Thu, 2011-05-26 at 09:31 +0200, Gerard van den Bosch wrote:
>>>> I have developed a shared library using Qt, it compiles without any
>>>> problems but it goes wrong with rpm packaging.
>>>> When it packages it should create a rpm package with the name
>>>> "libxmlpcpqt" but it creates a package with "libxmlpcpqt1".
>>>> My question is where does the '1' come from?
>>>>
>>>> The install part from the recipe is as follows:
>>>> do_install() {
>>>>        install -d ${D}${libdir}
>>>>        install -m 0755 ${S}/${PN}.so ${D}${libdir}
>>>> }
>>>>
>>>> In
>>>> the /tmp/work/armv7a-poky-linux-gnueabi/libxmlpcpqt-0.1-r1/image/usr/lib the libxmlpcpqt.so file correctly exists.
>>> This happens as debian style package naming is enabled (debian.bbclass
>>> is inherited).
>>>
>>> Cheers,
>>>
>>> Richard
>>>
>> I tried removing debian from the INHERITS+= variable in the poky.conf
>> but then it printed it couldn't find the function that is inside
>> debian.bbclass and didn't create the package.
>> Modifying debian.bbclass would be too drastic so I work around it like
>> this:
>> Added PACKAGES+= ${PN}1 to my recipe
>> Modified the IMAGE_INSTALL+= variable from libxmlpcpqt to libxmlpcpqt1
>> This resulted in a working solution.
> This is a bug and you should never need to do this. IMAGE_INSTALL should
> be getting remapped to the new names. The code that is meant to do that
> is at the top of image.bbclass:
>
>      # If we don't do this we try and run the mapping hooks while parsing which is slow
>      # bitbake should really provide something to let us know this...
>      if bb.data.getVar('BB_WORKERCONTEXT', d, True) is not None:
>          runtime_mapping_rename("PACKAGE_INSTALL", d)
>          runtime_mapping_rename("PACKAGE_INSTALL_ATTEMPTONLY", d)
>
> Can you check that the code is being called? I suspect something to do
> with the BB_WORKERCONTEXT variable has been broken. We should be doing
> this in a better way anyhow...
>
> Cheers,
>
> Richard
>
Ok, I have tried the following with the Bernard release:

print "hello"
print bb.data.getVar('BB_WORKERCONTEXT', d, True)
if bb.data.getVar('BB_WORKERCONTEXT', d, True) is not None:
	print "hello2"
	runtime_mapping_rename("PACKAGE_INSTALL", d)
	runtime_mapping_rename("PACKAGE_INSTALL_ATTEMPTONLY", d)

The "hello" gets printed, and the variable outputs "None", the "hello2" doesn't get printed because the variable is None.

In the laverne release I use here it checks on something else namely:
if bb.data.getVar('__RUNQUEUE_DO_NOT_USE_EXTERNALLY', d, True) is not None:
I can't add print commands there because it gives ident errors, found that has something todo with spaces but couldn't get it working.

I tried searching some further, I see in this commit that the if is added, that is in the laverne release:
http://git.pokylinux.org/cgit/cgit.cgi/poky/commit/meta/classes/image.bbclass?id=4e0ee648b4c18b770aba11921370258f3e2aaeef

Then a few commits later it is changed to the BB_WORKERCONTEXT:
http://git.pokylinux.org/cgit/cgit.cgi/poky/commit/meta/classes/image.bbclass?id=e427f251a457f3015c4b1cdf1648c53a9acc646d

Thus I tried to figure out what sets the BB_WORKERCONTEXT, I found it in two files in bitbake namely cooker.py and runqueue.py.
Eventually it leads to the loading of the configuration file and something set BB_WORKERCONTEXT then but I couldn't figure out what sets the variable.

I looked up the commits where it is added to bitbake:
http://git.pokylinux.org/cgit/cgit.cgi/poky/commit/bitbake/lib/bb/runqueue.py?id=1f3e313fd5cc5ae8ea838bf8fcdedace3cb72584  <http://git.pokylinux.org/cgit/cgit.cgi/poky/commit/bitbake/lib/bb/runqueue.py?id=1f3e313fd5cc5ae8ea838bf8fcdedace3cb72584>
http://git.pokylinux.org/cgit/cgit.cgi/poky/commit/bitbake/lib/bb/cooker.py?id=ca09a6f08cc29f79f9742058d737deaef9d6d5ef  <http://git.pokylinux.org/cgit/cgit.cgi/poky/commit/bitbake/lib/bb/cooker.py?id=ca09a6f08cc29f79f9742058d737deaef9d6d5ef>

But I couldn't figure out what the changes did and I did not come further than this.
If I need to try something else out, let me know.

Regards,
Gerard



[-- Attachment #2: Type: text/html, Size: 5333 bytes --]

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

* Re: wrong rpm name qt package
  2011-05-27  6:10       ` Gerard van den Bosch
@ 2011-05-27 12:49         ` Richard Purdie
  2011-05-27 13:24           ` Gerard van den Bosch
  0 siblings, 1 reply; 10+ messages in thread
From: Richard Purdie @ 2011-05-27 12:49 UTC (permalink / raw)
  To: Gerard van den Bosch; +Cc: poky

On Fri, 2011-05-27 at 08:10 +0200, Gerard van den Bosch wrote:
> Ok, I have tried the following with the Bernard release:
> 
> print "hello"
> print bb.data.getVar('BB_WORKERCONTEXT', d, True)
> if bb.data.getVar('BB_WORKERCONTEXT', d, True) is not None:
> 	print "hello2" 
> 	runtime_mapping_rename("PACKAGE_INSTALL", d)
> 	runtime_mapping_rename("PACKAGE_INSTALL_ATTEMPTONLY", d)
> The "hello" gets printed, and the variable outputs "None", the "hello2" doesn't get printed because the variable is None.
> 
> In the laverne release I use here it checks on something else namely:
> if bb.data.getVar('__RUNQUEUE_DO_NOT_USE_EXTERNALLY', d, True) is not None:
> I can't add print commands there because it gives ident errors, found that has something todo with spaces but couldn't get it working.
> 
> I tried searching some further, I see in this commit that the if is added, that is in the laverne release:
> http://git.pokylinux.org/cgit/cgit.cgi/poky/commit/meta/classes/image.bbclass?id=4e0ee648b4c18b770aba11921370258f3e2aaeef
> 
> Then a few commits later it is changed to the BB_WORKERCONTEXT:
> http://git.pokylinux.org/cgit/cgit.cgi/poky/commit/meta/classes/image.bbclass?id=e427f251a457f3015c4b1cdf1648c53a9acc646d
> 
> Thus I tried to figure out what sets the BB_WORKERCONTEXT, I found it in two files in bitbake namely cooker.py and runqueue.py.
> Eventually it leads to the loading of the configuration file and something set BB_WORKERCONTEXT then but I couldn't figure out what sets the variable.
> 
> I looked up the commits where it is added to bitbake:
> http://git.pokylinux.org/cgit/cgit.cgi/poky/commit/bitbake/lib/bb/runqueue.py?id=1f3e313fd5cc5ae8ea838bf8fcdedace3cb72584
> http://git.pokylinux.org/cgit/cgit.cgi/poky/commit/bitbake/lib/bb/cooker.py?id=ca09a6f08cc29f79f9742058d737deaef9d6d5ef
> 
> But I couldn't figure out what the changes did and I did not come further than this.
> If I need to try something else out, let me know.

This code only triggers at rootfs generation time. I've discovered this
broken in master at least. To test I did:

bitbake -b /path/to/some-image.bb -c rootfs

and then saw:

NOTE: Preparing runqueue
NOTE: Executing SetScene Tasks
NOTE: Executing RunQueue Tasks
ERROR: Start package mapping
ERROR: Found package mapping
NOTE: Running task 10 of 10 (ID: 6, /media/build2/builds/rptest/meta/recipes-core/images/core-image-minimal.bb, do_rootfs)
NOTE: package core-image-minimal-1.0-r0: task do_rootfs: Started
^C

with the following in image.bbclass:

    bb.error("Start package mapping")
    if bb.data.getVar('BB_WORKERCONTEXT', d, True) is not None:
        bb.error("Found package mapping")
        runtime_mapping_rename("PACKAGE_INSTALL", d)

when I'd fixed the underlying problem.

Cheers,

Richard




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

* Re: wrong rpm name qt package
  2011-05-27 12:49         ` Richard Purdie
@ 2011-05-27 13:24           ` Gerard van den Bosch
  2011-05-27 14:31             ` Richard Purdie
  0 siblings, 1 reply; 10+ messages in thread
From: Gerard van den Bosch @ 2011-05-27 13:24 UTC (permalink / raw)
  To: Richard Purdie; +Cc: poky

On 05/27/2011 02:49 PM, Richard Purdie wrote:

> On Fri, 2011-05-27 at 08:10 +0200, Gerard van den Bosch wrote:
>> Ok, I have tried the following with the Bernard release:
>>
>> print "hello"
>> print bb.data.getVar('BB_WORKERCONTEXT', d, True)
>> if bb.data.getVar('BB_WORKERCONTEXT', d, True) is not None:
>> 	print "hello2"
>> 	runtime_mapping_rename("PACKAGE_INSTALL", d)
>> 	runtime_mapping_rename("PACKAGE_INSTALL_ATTEMPTONLY", d)
>> The "hello" gets printed, and the variable outputs "None", the "hello2" doesn't get printed because the variable is None.
>>
>> In the laverne release I use here it checks on something else namely:
>> if bb.data.getVar('__RUNQUEUE_DO_NOT_USE_EXTERNALLY', d, True) is not None:
>> I can't add print commands there because it gives ident errors, found that has something todo with spaces but couldn't get it working.
>>
>> I tried searching some further, I see in this commit that the if is added, that is in the laverne release:
>> http://git.pokylinux.org/cgit/cgit.cgi/poky/commit/meta/classes/image.bbclass?id=4e0ee648b4c18b770aba11921370258f3e2aaeef
>>
>> Then a few commits later it is changed to the BB_WORKERCONTEXT:
>> http://git.pokylinux.org/cgit/cgit.cgi/poky/commit/meta/classes/image.bbclass?id=e427f251a457f3015c4b1cdf1648c53a9acc646d
>>
>> Thus I tried to figure out what sets the BB_WORKERCONTEXT, I found it in two files in bitbake namely cooker.py and runqueue.py.
>> Eventually it leads to the loading of the configuration file and something set BB_WORKERCONTEXT then but I couldn't figure out what sets the variable.
>>
>> I looked up the commits where it is added to bitbake:
>> http://git.pokylinux.org/cgit/cgit.cgi/poky/commit/bitbake/lib/bb/runqueue.py?id=1f3e313fd5cc5ae8ea838bf8fcdedace3cb72584
>> http://git.pokylinux.org/cgit/cgit.cgi/poky/commit/bitbake/lib/bb/cooker.py?id=ca09a6f08cc29f79f9742058d737deaef9d6d5ef
>>
>> But I couldn't figure out what the changes did and I did not come further than this.
>> If I need to try something else out, let me know.
> This code only triggers at rootfs generation time. I've discovered this
> broken in master at least. To test I did:
>
> bitbake -b /path/to/some-image.bb -c rootfs
>
> and then saw:
>
> NOTE: Preparing runqueue
> NOTE: Executing SetScene Tasks
> NOTE: Executing RunQueue Tasks
> ERROR: Start package mapping
> ERROR: Found package mapping
> NOTE: Running task 10 of 10 (ID: 6, /media/build2/builds/rptest/meta/recipes-core/images/core-image-minimal.bb, do_rootfs)
> NOTE: package core-image-minimal-1.0-r0: task do_rootfs: Started
> ^C
>
> with the following in image.bbclass:
>
>      bb.error("Start package mapping")
>      if bb.data.getVar('BB_WORKERCONTEXT', d, True) is not None:
>          bb.error("Found package mapping")
>          runtime_mapping_rename("PACKAGE_INSTALL", d)
>
> when I'd fixed the underlying problem.
>
> Cheers,
>
> Richard
>
If I understand correctly, you have fixed something to get it working? or does it work and am I doing something wrong?
Because when I add the bb.error commands I am only seeing the "Start package mapping" with the suggested bitbake command.

Regards,
Gerard




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

* Re: wrong rpm name qt package
  2011-05-27 13:24           ` Gerard van den Bosch
@ 2011-05-27 14:31             ` Richard Purdie
  2011-05-27 16:24               ` Gerard van den Bosch
  0 siblings, 1 reply; 10+ messages in thread
From: Richard Purdie @ 2011-05-27 14:31 UTC (permalink / raw)
  To: Gerard van den Bosch; +Cc: poky

On Fri, 2011-05-27 at 15:24 +0200, Gerard van den Bosch wrote:
> On 05/27/2011 02:49 PM, Richard Purdie wrote:
> 
> > On Fri, 2011-05-27 at 08:10 +0200, Gerard van den Bosch wrote:
> >> Ok, I have tried the following with the Bernard release:
> >>
> >> print "hello"
> >> print bb.data.getVar('BB_WORKERCONTEXT', d, True)
> >> if bb.data.getVar('BB_WORKERCONTEXT', d, True) is not None:
> >> 	print "hello2"
> >> 	runtime_mapping_rename("PACKAGE_INSTALL", d)
> >> 	runtime_mapping_rename("PACKAGE_INSTALL_ATTEMPTONLY", d)
> >> The "hello" gets printed, and the variable outputs "None", the "hello2" doesn't get printed because the variable is None.
> >>
> >> In the laverne release I use here it checks on something else namely:
> >> if bb.data.getVar('__RUNQUEUE_DO_NOT_USE_EXTERNALLY', d, True) is not None:
> >> I can't add print commands there because it gives ident errors, found that has something todo with spaces but couldn't get it working.
> >>
> >> I tried searching some further, I see in this commit that the if is added, that is in the laverne release:
> >> http://git.pokylinux.org/cgit/cgit.cgi/poky/commit/meta/classes/image.bbclass?id=4e0ee648b4c18b770aba11921370258f3e2aaeef
> >>
> >> Then a few commits later it is changed to the BB_WORKERCONTEXT:
> >> http://git.pokylinux.org/cgit/cgit.cgi/poky/commit/meta/classes/image.bbclass?id=e427f251a457f3015c4b1cdf1648c53a9acc646d
> >>
> >> Thus I tried to figure out what sets the BB_WORKERCONTEXT, I found it in two files in bitbake namely cooker.py and runqueue.py.
> >> Eventually it leads to the loading of the configuration file and something set BB_WORKERCONTEXT then but I couldn't figure out what sets the variable.
> >>
> >> I looked up the commits where it is added to bitbake:
> >> http://git.pokylinux.org/cgit/cgit.cgi/poky/commit/bitbake/lib/bb/runqueue.py?id=1f3e313fd5cc5ae8ea838bf8fcdedace3cb72584
> >> http://git.pokylinux.org/cgit/cgit.cgi/poky/commit/bitbake/lib/bb/cooker.py?id=ca09a6f08cc29f79f9742058d737deaef9d6d5ef
> >>
> >> But I couldn't figure out what the changes did and I did not come further than this.
> >> If I need to try something else out, let me know.
> > This code only triggers at rootfs generation time. I've discovered this
> > broken in master at least. To test I did:
> >
> > bitbake -b /path/to/some-image.bb -c rootfs
> >
> > and then saw:
> >
> > NOTE: Preparing runqueue
> > NOTE: Executing SetScene Tasks
> > NOTE: Executing RunQueue Tasks
> > ERROR: Start package mapping
> > ERROR: Found package mapping
> > NOTE: Running task 10 of 10 (ID: 6, /media/build2/builds/rptest/meta/recipes-core/images/core-image-minimal.bb, do_rootfs)
> > NOTE: package core-image-minimal-1.0-r0: task do_rootfs: Started
> > ^C
> >
> > with the following in image.bbclass:
> >
> >      bb.error("Start package mapping")
> >      if bb.data.getVar('BB_WORKERCONTEXT', d, True) is not None:
> >          bb.error("Found package mapping")
> >          runtime_mapping_rename("PACKAGE_INSTALL", d)
> >
> > when I'd fixed the underlying problem.
> >
> > Cheers,
> >
> > Richard
> >
> If I understand correctly, you have fixed something to get it working?

Yes, I need to merge this:

http://git.yoctoproject.org/cgit.cgi/poky-contrib/commit/?h=rpurdie/bb2&id=5b5f6e9d221c7cfcf1b4d9c4c76f38c03203ec49

>  or does it work and am I doing something wrong?
> Because when I add the bb.error commands I am only seeing the "Start
> package mapping" with the suggested bitbake command.

Correct, it is broken until the above fix is applied :(

Cheers,

Richard



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

* Re: wrong rpm name qt package
  2011-05-27 14:31             ` Richard Purdie
@ 2011-05-27 16:24               ` Gerard van den Bosch
  0 siblings, 0 replies; 10+ messages in thread
From: Gerard van den Bosch @ 2011-05-27 16:24 UTC (permalink / raw)
  To: Richard Purdie; +Cc: poky

[-- Attachment #1: Type: text/plain, Size: 4120 bytes --]

On Fri, May 27, 2011 at 4:31 PM, Richard Purdie <
richard.purdie@linuxfoundation.org> wrote:

> On Fri, 2011-05-27 at 15:24 +0200, Gerard van den Bosch wrote:
> > On 05/27/2011 02:49 PM, Richard Purdie wrote:
> >
> > > On Fri, 2011-05-27 at 08:10 +0200, Gerard van den Bosch wrote:
> > >> Ok, I have tried the following with the Bernard release:
> > >>
> > >> print "hello"
> > >> print bb.data.getVar('BB_WORKERCONTEXT', d, True)
> > >> if bb.data.getVar('BB_WORKERCONTEXT', d, True) is not None:
> > >>    print "hello2"
> > >>    runtime_mapping_rename("PACKAGE_INSTALL", d)
> > >>    runtime_mapping_rename("PACKAGE_INSTALL_ATTEMPTONLY", d)
> > >> The "hello" gets printed, and the variable outputs "None", the
> "hello2" doesn't get printed because the variable is None.
> > >>
> > >> In the laverne release I use here it checks on something else namely:
> > >> if bb.data.getVar('__RUNQUEUE_DO_NOT_USE_EXTERNALLY', d, True) is not
> None:
> > >> I can't add print commands there because it gives ident errors, found
> that has something todo with spaces but couldn't get it working.
> > >>
> > >> I tried searching some further, I see in this commit that the if is
> added, that is in the laverne release:
> > >>
> http://git.pokylinux.org/cgit/cgit.cgi/poky/commit/meta/classes/image.bbclass?id=4e0ee648b4c18b770aba11921370258f3e2aaeef
> > >>
> > >> Then a few commits later it is changed to the BB_WORKERCONTEXT:
> > >>
> http://git.pokylinux.org/cgit/cgit.cgi/poky/commit/meta/classes/image.bbclass?id=e427f251a457f3015c4b1cdf1648c53a9acc646d
> > >>
> > >> Thus I tried to figure out what sets the BB_WORKERCONTEXT, I found it
> in two files in bitbake namely cooker.py and runqueue.py.
> > >> Eventually it leads to the loading of the configuration file and
> something set BB_WORKERCONTEXT then but I couldn't figure out what sets the
> variable.
> > >>
> > >> I looked up the commits where it is added to bitbake:
> > >>
> http://git.pokylinux.org/cgit/cgit.cgi/poky/commit/bitbake/lib/bb/runqueue.py?id=1f3e313fd5cc5ae8ea838bf8fcdedace3cb72584
> > >>
> http://git.pokylinux.org/cgit/cgit.cgi/poky/commit/bitbake/lib/bb/cooker.py?id=ca09a6f08cc29f79f9742058d737deaef9d6d5ef
> > >>
> > >> But I couldn't figure out what the changes did and I did not come
> further than this.
> > >> If I need to try something else out, let me know.
> > > This code only triggers at rootfs generation time. I've discovered this
> > > broken in master at least. To test I did:
> > >
> > > bitbake -b /path/to/some-image.bb -c rootfs
> > >
> > > and then saw:
> > >
> > > NOTE: Preparing runqueue
> > > NOTE: Executing SetScene Tasks
> > > NOTE: Executing RunQueue Tasks
> > > ERROR: Start package mapping
> > > ERROR: Found package mapping
> > > NOTE: Running task 10 of 10 (ID: 6,
> /media/build2/builds/rptest/meta/recipes-core/images/core-image-minimal.bb,
> do_rootfs)
> > > NOTE: package core-image-minimal-1.0-r0: task do_rootfs: Started
> > > ^C
> > >
> > > with the following in image.bbclass:
> > >
> > >      bb.error("Start package mapping")
> > >      if bb.data.getVar('BB_WORKERCONTEXT', d, True) is not None:
> > >          bb.error("Found package mapping")
> > >          runtime_mapping_rename("PACKAGE_INSTALL", d)
> > >
> > > when I'd fixed the underlying problem.
> > >
> > > Cheers,
> > >
> > > Richard
> > >
> > If I understand correctly, you have fixed something to get it working?
>
> Yes, I need to merge this:
>
>
> http://git.yoctoproject.org/cgit.cgi/poky-contrib/commit/?h=rpurdie/bb2&id=5b5f6e9d221c7cfcf1b4d9c4c76f38c03203ec49
>
> >  or does it work and am I doing something wrong?
> > Because when I add the bb.error commands I am only seeing the "Start
> > package mapping" with the suggested bitbake command.
>
> Correct, it is broken until the above fix is applied :(
>
> Cheers,
>
> Richard
>
>
Richard, I have manually added your fix into my Bernard release and I am
happy to inform you it works :)
My image builds without problems now, thank you very much for the fix.

Regards,
Gerard

[-- Attachment #2: Type: text/html, Size: 6025 bytes --]

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

end of thread, other threads:[~2011-05-27 16:24 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-05-26  7:31 wrong rpm name qt package Gerard van den Bosch
2011-05-26  9:43 ` Richard Purdie
2011-05-26 11:22   ` Gerard van den Bosch
2011-05-26 13:54     ` Richard Purdie
2011-05-26 14:13       ` Gerard van den Bosch
2011-05-27  6:10       ` Gerard van den Bosch
2011-05-27 12:49         ` Richard Purdie
2011-05-27 13:24           ` Gerard van den Bosch
2011-05-27 14:31             ` Richard Purdie
2011-05-27 16:24               ` Gerard van den Bosch

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.