Openembedded Core Discussions
 help / color / mirror / Atom feed
* [PATCH 0/1] toolchain-script: use immediate expansion for TOOLCHAIN_CONFIGSITE_NOCACHE
@ 2015-10-30  7:50 Chen Qi
  2015-10-30  7:50 ` [PATCH 1/1] " Chen Qi
  0 siblings, 1 reply; 6+ messages in thread
From: Chen Qi @ 2015-10-30  7:50 UTC (permalink / raw)
  To: openembedded-core

The following changes since commit f787b688f2884ce3fa888b4041030538c7d2bf55:

  oeqa/utils/decorators: fix missing keyword arguments on decorators (2015-10-27 07:22:22 +0000)

are available in the git repository at:

  git://git.openembedded.org/openembedded-core-contrib ChenQi/toolchain-site-config
  http://cgit.openembedded.org/cgit.cgi/openembedded-core-contrib/log/?h=ChenQi/toolchain-site-config

Chen Qi (1):
  toolchain-script: use immediate expansion for
    TOOLCHAIN_CONFIGSITE_NOCACHE

 meta/classes/toolchain-scripts.bbclass | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

-- 
1.9.1



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

* [PATCH 1/1] toolchain-script: use immediate expansion for TOOLCHAIN_CONFIGSITE_NOCACHE
  2015-10-30  7:50 [PATCH 0/1] toolchain-script: use immediate expansion for TOOLCHAIN_CONFIGSITE_NOCACHE Chen Qi
@ 2015-10-30  7:50 ` Chen Qi
  2016-03-15  6:53   ` ChenQi
  0 siblings, 1 reply; 6+ messages in thread
From: Chen Qi @ 2015-10-30  7:50 UTC (permalink / raw)
  To: openembedded-core

Use immediate expansion for the assignment to avoid other classes modifying
variables like HOST_ARCH which changes the result. This happens in the
meta-environment recipe. It inherits cross-canadian which changes HOST_ARCH
from TARGET_ARCH to SDK_ARCH, resulting in wrong site config files in the
generated SDK.

Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
---
 meta/classes/toolchain-scripts.bbclass | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/meta/classes/toolchain-scripts.bbclass b/meta/classes/toolchain-scripts.bbclass
index d0b2b91..4427369 100644
--- a/meta/classes/toolchain-scripts.bbclass
+++ b/meta/classes/toolchain-scripts.bbclass
@@ -98,7 +98,7 @@ EOF
 }
 
 #we get the cached site config in the runtime
-TOOLCHAIN_CONFIGSITE_NOCACHE = "${@siteinfo_get_files(d, True)}"
+TOOLCHAIN_CONFIGSITE_NOCACHE := "${@siteinfo_get_files(d, True)}"
 TOOLCHAIN_CONFIGSITE_SYSROOTCACHE = "${STAGING_DIR}/${MLPREFIX}${MACHINE}/${target_datadir}/${TARGET_SYS}_config_site.d"
 TOOLCHAIN_NEED_CONFIGSITE_CACHE ??= "virtual/${MLPREFIX}libc ncurses"
 
-- 
1.9.1



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

* Re: [PATCH 1/1] toolchain-script: use immediate expansion for TOOLCHAIN_CONFIGSITE_NOCACHE
  2015-10-30  7:50 ` [PATCH 1/1] " Chen Qi
@ 2016-03-15  6:53   ` ChenQi
  0 siblings, 0 replies; 6+ messages in thread
From: ChenQi @ 2016-03-15  6:53 UTC (permalink / raw)
  To: openembedded-core

ping

On 10/30/2015 03:50 PM, Chen Qi wrote:
> Use immediate expansion for the assignment to avoid other classes modifying
> variables like HOST_ARCH which changes the result. This happens in the
> meta-environment recipe. It inherits cross-canadian which changes HOST_ARCH
> from TARGET_ARCH to SDK_ARCH, resulting in wrong site config files in the
> generated SDK.
>
> Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
> ---
>   meta/classes/toolchain-scripts.bbclass | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/meta/classes/toolchain-scripts.bbclass b/meta/classes/toolchain-scripts.bbclass
> index d0b2b91..4427369 100644
> --- a/meta/classes/toolchain-scripts.bbclass
> +++ b/meta/classes/toolchain-scripts.bbclass
> @@ -98,7 +98,7 @@ EOF
>   }
>   
>   #we get the cached site config in the runtime
> -TOOLCHAIN_CONFIGSITE_NOCACHE = "${@siteinfo_get_files(d, True)}"
> +TOOLCHAIN_CONFIGSITE_NOCACHE := "${@siteinfo_get_files(d, True)}"
>   TOOLCHAIN_CONFIGSITE_SYSROOTCACHE = "${STAGING_DIR}/${MLPREFIX}${MACHINE}/${target_datadir}/${TARGET_SYS}_config_site.d"
>   TOOLCHAIN_NEED_CONFIGSITE_CACHE ??= "virtual/${MLPREFIX}libc ncurses"
>   



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

* [PATCH 1/1] toolchain-script: use immediate expansion for TOOLCHAIN_CONFIGSITE_NOCACHE
  2016-09-23  8:30 [PATCH 0/1] " Chen Qi
@ 2016-09-23  8:30 ` Chen Qi
  2016-09-23 14:37   ` Richard Purdie
  0 siblings, 1 reply; 6+ messages in thread
From: Chen Qi @ 2016-09-23  8:30 UTC (permalink / raw)
  To: openembedded-core

Use immediate expansion for the assignment to avoid other classes modifying
variables like HOST_ARCH which changes the result. This happens in the
meta-environment recipe. It inherits cross-canadian which changes HOST_ARCH
from TARGET_ARCH to SDK_ARCH, resulting in wrong site config files in the
generated SDK.

[YOCTO #10255]

Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
---
 meta/classes/toolchain-scripts.bbclass | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/meta/classes/toolchain-scripts.bbclass b/meta/classes/toolchain-scripts.bbclass
index 997ff88..8df0967 100644
--- a/meta/classes/toolchain-scripts.bbclass
+++ b/meta/classes/toolchain-scripts.bbclass
@@ -105,7 +105,7 @@ EOF
 }
 
 #we get the cached site config in the runtime
-TOOLCHAIN_CONFIGSITE_NOCACHE = "${@siteinfo_get_files(d)}"
+TOOLCHAIN_CONFIGSITE_NOCACHE := "${@siteinfo_get_files(d)}"
 TOOLCHAIN_CONFIGSITE_SYSROOTCACHE = "${STAGING_DIR}/${MLPREFIX}${MACHINE}/${target_datadir}/${TARGET_SYS}_config_site.d"
 TOOLCHAIN_NEED_CONFIGSITE_CACHE ??= "virtual/${MLPREFIX}libc ncurses"
 
-- 
1.9.1



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

* Re: [PATCH 1/1] toolchain-script: use immediate expansion for TOOLCHAIN_CONFIGSITE_NOCACHE
  2016-09-23  8:30 ` [PATCH 1/1] " Chen Qi
@ 2016-09-23 14:37   ` Richard Purdie
  2016-09-26  3:20     ` ChenQi
  0 siblings, 1 reply; 6+ messages in thread
From: Richard Purdie @ 2016-09-23 14:37 UTC (permalink / raw)
  To: Chen Qi, openembedded-core

On Fri, 2016-09-23 at 16:30 +0800, Chen Qi wrote:
> Use immediate expansion for the assignment to avoid other classes
> modifying
> variables like HOST_ARCH which changes the result. This happens in
> the
> meta-environment recipe. It inherits cross-canadian which changes
> HOST_ARCH
> from TARGET_ARCH to SDK_ARCH, resulting in wrong site config files in
> the
> generated SDK.
> 
> [YOCTO #10255]
> 
> Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
> ---
>  meta/classes/toolchain-scripts.bbclass | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)

I've not merged this as yet since I worry that this is something we'd
easily break again. It all depends which order classes are included and
moving the cross-canadian inherit in meta-environment would break this
even with immediate expansion.

I think the best way to fix this might be to change the meta-
environment to add:

# Need to expand here before cross-candian changes HOST_ARCH -> SDK_ARCH
TOOLCHAIN_CONFIGSITE_NOCACHE := "${TOOLCHAIN_CONFIGSITE_NOCACHE}"

before it inherits cross-candian, then the problem is explicitly
recorded and worked around.

Cheers,

Richard


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

* Re: [PATCH 1/1] toolchain-script: use immediate expansion for TOOLCHAIN_CONFIGSITE_NOCACHE
  2016-09-23 14:37   ` Richard Purdie
@ 2016-09-26  3:20     ` ChenQi
  0 siblings, 0 replies; 6+ messages in thread
From: ChenQi @ 2016-09-26  3:20 UTC (permalink / raw)
  To: Richard Purdie, openembedded-core

On 09/23/2016 10:37 PM, Richard Purdie wrote:
> On Fri, 2016-09-23 at 16:30 +0800, Chen Qi wrote:
>> Use immediate expansion for the assignment to avoid other classes
>> modifying
>> variables like HOST_ARCH which changes the result. This happens in
>> the
>> meta-environment recipe. It inherits cross-canadian which changes
>> HOST_ARCH
>> from TARGET_ARCH to SDK_ARCH, resulting in wrong site config files in
>> the
>> generated SDK.
>>
>> [YOCTO #10255]
>>
>> Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
>> ---
>>   meta/classes/toolchain-scripts.bbclass | 2 +-
>>   1 file changed, 1 insertion(+), 1 deletion(-)
> I've not merged this as yet since I worry that this is something we'd
> easily break again. It all depends which order classes are included and
> moving the cross-canadian inherit in meta-environment would break this
> even with immediate expansion.
>
> I think the best way to fix this might be to change the meta-
> environment to add:
>
> # Need to expand here before cross-candian changes HOST_ARCH -> SDK_ARCH
> TOOLCHAIN_CONFIGSITE_NOCACHE := "${TOOLCHAIN_CONFIGSITE_NOCACHE}"
>
> before it inherits cross-candian, then the problem is explicitly
> recorded and worked around.
>
> Cheers,
>
> Richard
>

Thanks a lot.
I've verified this solution.
A new patch has been sent out.

Best Regards,
Chen Qi



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

end of thread, other threads:[~2016-09-26  3:20 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-10-30  7:50 [PATCH 0/1] toolchain-script: use immediate expansion for TOOLCHAIN_CONFIGSITE_NOCACHE Chen Qi
2015-10-30  7:50 ` [PATCH 1/1] " Chen Qi
2016-03-15  6:53   ` ChenQi
  -- strict thread matches above, loose matches on Subject: below --
2016-09-23  8:30 [PATCH 0/1] " Chen Qi
2016-09-23  8:30 ` [PATCH 1/1] " Chen Qi
2016-09-23 14:37   ` Richard Purdie
2016-09-26  3:20     ` ChenQi

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox