Patchwork cpan-base: Don't use immediate expansion

login
register
mail settings
Submitter Tyler Hall
Date Aug. 5, 2013, 2:25 p.m.
Message ID <1375712720-16668-1-git-send-email-tylerwhall@gmail.com>
Download mbox | patch
Permalink /patch/55127/
State New
Headers show

Comments

Tyler Hall - Aug. 5, 2013, 2:25 p.m.
PERLVERSION is derived from installed output in the sysroot, so it
should not be evaluated at parse time.

In an new workspace, the sequence

$ bitbake -S libxml-sax-perl
$ bitbake perl
$ bitbake -S libxml-sax-perl

generates different task hashes for libxml-sax-perl, and the error

ERROR: Bitbake's cached basehash does not match the one we just
generated (/bonus/scratch/tylerh/oe-core/meta/recipes-extended/perl/libxml-sax-perl_0.99.bb.do_package)!

Signed-off-by: Tyler Hall <tylerwhall@gmail.com>
---
 meta/classes/cpan-base.bbclass | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
Saul Wold - Aug. 5, 2013, 9:19 p.m.
On 08/05/2013 07:25 AM, Tyler Hall wrote:
> PERLVERSION is derived from installed output in the sysroot, so it
> should not be evaluated at parse time.
>
> In an new workspace, the sequence
>
> $ bitbake -S libxml-sax-perl
> $ bitbake perl
> $ bitbake -S libxml-sax-perl
>
> generates different task hashes for libxml-sax-perl, and the error
>
> ERROR: Bitbake's cached basehash does not match the one we just
> generated (/bonus/scratch/tylerh/oe-core/meta/recipes-extended/perl/libxml-sax-perl_0.99.bb.do_package)!
>
I could not replicate this, can you provide more details about how you 
setup the failure, was it from a clean sstate?

Are you working with master or 1.4 or something else?


Thanks
	Sau!

> Signed-off-by: Tyler Hall <tylerwhall@gmail.com>
> ---
>   meta/classes/cpan-base.bbclass | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/meta/classes/cpan-base.bbclass b/meta/classes/cpan-base.bbclass
> index 7e1e8d0..d05863e 100644
> --- a/meta/classes/cpan-base.bbclass
> +++ b/meta/classes/cpan-base.bbclass
> @@ -40,7 +40,7 @@ def is_target(d):
>       return "no"
>
>   PERLLIBDIRS := "${@perl_get_libdirs(d)}"
> -PERLVERSION := "${@get_perl_version(d)}"
> +PERLVERSION = "${@get_perl_version(d)}"
>
>   FILES_${PN}-dbg += "${PERLLIBDIRS}/auto/*/.debug \
>                       ${PERLLIBDIRS}/auto/*/*/.debug \
>
Tyler Hall - Aug. 6, 2013, 2:04 p.m.
On Mon, Aug 5, 2013 at 5:19 PM, Saul Wold <sgw@linux.intel.com> wrote:

> I could not replicate this, can you provide more details about how you
> setup the failure, was it from a clean sstate?
>

 It was with clean sstate, but I can switch between libxml-sax-perl task
hashes with a regular clean or setscene of perl. In my existing workspace,
I ran

$ bitbake -c clean perl
$ STAMPS_DIR=perl-stamps bitbake -S libxml-sax-perl
$ bitbake perl # From sstate
$ STAMPS_DIR=perl-stamps bitbake -S libxml-sax-perl

and got the error for several do_package tasks
ERROR: Bitbake's cached basehash does not match the one we just generated
(/.../oe-core/meta/recipes-extended/perl/libxml-sax-base-perl_1.08.bb.do_package)!

I think you have to trigger a re-parse (which -S seems to do) since the
perl files being in the sysroot wouldn't invalidate the cache.

Are you working with master or 1.4 or something else?
>

I first noticed it on 1.4 and reproduced it on master, which was
09deeef20ee5a0c12ad4fd89cace6e0fb832d5b1 at the time.

Thanks,
Tyler

Patch

diff --git a/meta/classes/cpan-base.bbclass b/meta/classes/cpan-base.bbclass
index 7e1e8d0..d05863e 100644
--- a/meta/classes/cpan-base.bbclass
+++ b/meta/classes/cpan-base.bbclass
@@ -40,7 +40,7 @@  def is_target(d):
     return "no"
 
 PERLLIBDIRS := "${@perl_get_libdirs(d)}"
-PERLVERSION := "${@get_perl_version(d)}"
+PERLVERSION = "${@get_perl_version(d)}"
 
 FILES_${PN}-dbg += "${PERLLIBDIRS}/auto/*/.debug \
                     ${PERLLIBDIRS}/auto/*/*/.debug \