[meta-arm] arm-bsp/u-boot: fix THISDIR name collision in u-boot_%.bbappend

Submitted by Nathan Dunne on Sept. 17, 2020, 9:58 a.m. | Patch ID: 176603

Details

Message ID 20200917095817.27331-1-Nathan.Dunne@arm.com
State New
Headers show

Commit Message

Nathan Dunne Sept. 17, 2020, 9:58 a.m.
Renamed ${THISDIR} user defined variable to ${THIS_DIR}, to prevent
it from breaking ${THISDIR} macro in subsequent u-boot .bbappend files

Change-Id: I4473ee5c3ac5c0aea9310557294cc9757579bdf1
Issue-Id: SCM-1302
Signed-off-by: Nathan Dunne <Nathan.Dunne@arm.com>
---
 meta-arm-bsp/recipes-bsp/u-boot/u-boot_%.bbappend | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

Patch hide | download patch | download mbox

diff --git a/meta-arm-bsp/recipes-bsp/u-boot/u-boot_%.bbappend b/meta-arm-bsp/recipes-bsp/u-boot/u-boot_%.bbappend
index bf57242..5fc3723 100644
--- a/meta-arm-bsp/recipes-bsp/u-boot/u-boot_%.bbappend
+++ b/meta-arm-bsp/recipes-bsp/u-boot/u-boot_%.bbappend
@@ -1,7 +1,7 @@ 
 # Machine specific u-boot
 
-THISDIR := "${THISDIR}"
-FILESEXTRAPATHS_prepend = "${THISDIR}/files/:${THISDIR}/${BP}:"
+THIS_DIR := "${THISDIR}"
+FILESEXTRAPATHS_prepend = "${THIS_DIR}/files/:${THIS_DIR}/${BP}:"
 FILESEXTRAPATHS_prepend_fvp-base := "${THISDIR}/files/fvp-common:"
 FILESEXTRAPATHS_prepend_foundation-armv8 := "${THISDIR}/files/fvp-common:"
 

Comments

Diego Sueiro Sept. 17, 2020, 10:05 a.m.
On Thu, Sep 17, 2020 at 10:59 AM, Nathan Dunne wrote:

>
> Renamed ${THISDIR} user defined variable to ${THIS_DIR}, to prevent
> it from breaking ${THISDIR} macro in subsequent u-boot .bbappend files
> 
> Change-Id: I4473ee5c3ac5c0aea9310557294cc9757579bdf1
> Issue-Id: SCM-1302
> Signed-off-by: Nathan Dunne <Nathan.Dunne@arm.com>
> ---

Reviewed-by: Diego Sueiro <diego.sueiro@arm.com>

>  meta-arm-bsp/recipes-bsp/u-boot/u-boot_%.bbappend | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/meta-arm-bsp/recipes-bsp/u-boot/u-boot_%.bbappend
> b/meta-arm-bsp/recipes-bsp/u-boot/u-boot_%.bbappend
> index bf57242..5fc3723 100644
> --- a/meta-arm-bsp/recipes-bsp/u-boot/u-boot_%.bbappend
> +++ b/meta-arm-bsp/recipes-bsp/u-boot/u-boot_%.bbappend
> @@ -1,7 +1,7 @@
>  # Machine specific u-boot
>  
> -THISDIR := "${THISDIR}"
> -FILESEXTRAPATHS_prepend = "${THISDIR}/files/:${THISDIR}/${BP}:"
> +THIS_DIR := "${THISDIR}"
> +FILESEXTRAPATHS_prepend = "${THIS_DIR}/files/:${THIS_DIR}/${BP}:"
>  FILESEXTRAPATHS_prepend_fvp-base := "${THISDIR}/files/fvp-common:"
>  FILESEXTRAPATHS_prepend_foundation-armv8 := "${THISDIR}/files/fvp-common:"
>  
> -- 
> 2.17.1
> 
>
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#1125): https://lists.yoctoproject.org/g/meta-arm/message/1125
Mute This Topic: https://lists.yoctoproject.org/mt/76906051/3617530
Group Owner: meta-arm+owner@lists.yoctoproject.org
Unsubscribe: https://lists.yoctoproject.org/g/meta-arm/unsub [oe-patchwork@oe-patch.openembedded.org]
-=-=-=-=-=-=-=-=-=-=-=-
Denys Dmytriyenko Sept. 17, 2020, 4:44 p.m.
On Thu, Sep 17, 2020 at 09:58:17AM +0000, Nathan Dunne wrote:
> Renamed ${THISDIR} user defined variable to ${THIS_DIR}, to prevent
> it from breaking ${THISDIR} macro in subsequent u-boot .bbappend files
> 
> Change-Id: I4473ee5c3ac5c0aea9310557294cc9757579bdf1
> Issue-Id: SCM-1302
> Signed-off-by: Nathan Dunne <Nathan.Dunne@arm.com>
> ---
>  meta-arm-bsp/recipes-bsp/u-boot/u-boot_%.bbappend | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/meta-arm-bsp/recipes-bsp/u-boot/u-boot_%.bbappend b/meta-arm-bsp/recipes-bsp/u-boot/u-boot_%.bbappend
> index bf57242..5fc3723 100644
> --- a/meta-arm-bsp/recipes-bsp/u-boot/u-boot_%.bbappend
> +++ b/meta-arm-bsp/recipes-bsp/u-boot/u-boot_%.bbappend
> @@ -1,7 +1,7 @@
>  # Machine specific u-boot
>  
> -THISDIR := "${THISDIR}"
> -FILESEXTRAPATHS_prepend = "${THISDIR}/files/:${THISDIR}/${BP}:"
> +THIS_DIR := "${THISDIR}"
> +FILESEXTRAPATHS_prepend = "${THIS_DIR}/files/:${THIS_DIR}/${BP}:"
>  FILESEXTRAPATHS_prepend_fvp-base := "${THISDIR}/files/fvp-common:"
>  FILESEXTRAPATHS_prepend_foundation-armv8 := "${THISDIR}/files/fvp-common:"

Why not make these 3 lines above that prepend to FILESEXTRAPATHS consistent?


>  
> -- 
> 2.17.1
> 

> 
> 
>
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#1129): https://lists.yoctoproject.org/g/meta-arm/message/1129
Mute This Topic: https://lists.yoctoproject.org/mt/76906051/3617530
Group Owner: meta-arm+owner@lists.yoctoproject.org
Unsubscribe: https://lists.yoctoproject.org/g/meta-arm/unsub [oe-patchwork@oe-patch.openembedded.org]
-=-=-=-=-=-=-=-=-=-=-=-
Nathan Dunne Sept. 18, 2020, 8:24 a.m.
On Thu, Sep 17, 2020 at 09:44 AM, Denys Dmytriyenko wrote:

> 
> On Thu, Sep 17, 2020 at 09:58:17AM +0000, Nathan Dunne wrote:
> 
>> Renamed ${THISDIR} user defined variable to ${THIS_DIR}, to prevent
>> it from breaking ${THISDIR} macro in subsequent u-boot .bbappend files
>> 
>> Change-Id: I4473ee5c3ac5c0aea9310557294cc9757579bdf1
>> Issue-Id: SCM-1302
>> Signed-off-by: Nathan Dunne <Nathan.Dunne@arm.com>
>> ---
>> meta-arm-bsp/recipes-bsp/u-boot/u-boot_%.bbappend | 4 ++--
>> 1 file changed, 2 insertions(+), 2 deletions(-)
>> 
>> diff --git a/meta-arm-bsp/recipes-bsp/u-boot/u-boot_%.bbappend
>> b/meta-arm-bsp/recipes-bsp/u-boot/u-boot_%.bbappend
>> index bf57242..5fc3723 100644
>> --- a/meta-arm-bsp/recipes-bsp/u-boot/u-boot_%.bbappend
>> +++ b/meta-arm-bsp/recipes-bsp/u-boot/u-boot_%.bbappend
>> @@ -1,7 +1,7 @@
>> # Machine specific u-boot
>> 
>> -THISDIR := "${THISDIR}"
>> -FILESEXTRAPATHS_prepend = "${THISDIR}/files/:${THISDIR}/${BP}:"
>> +THIS_DIR := "${THISDIR}"
>> +FILESEXTRAPATHS_prepend = "${THIS_DIR}/files/:${THIS_DIR}/${BP}:"
>> FILESEXTRAPATHS_prepend_fvp-base := "${THISDIR}/files/fvp-common:"
>> FILESEXTRAPATHS_prepend_foundation-armv8 := "${THISDIR}/files/fvp-common:"
> 
> 
> Why not make these 3 lines above that prepend to FILESEXTRAPATHS
> consistent?

Only the line with ${BP} needs the user defined THIS_DIR because it can't use immediate expansion due to ${BP} containing ${PV}, which is only set after parsing. This is not a problem for the other two lines, hence no need to make use of the ${THIS_DIR} intermediate variable. ${BP} is only being added to FILESEXTRAPATHS because meta-arm master currently needs to support u-boot from oe-core master and dunfell, so once we can drop support for multiple versions there will be less modifications to make if the other two lines aren't touched

The problem is the intermediate variable previously being named "THISDIR", as it should not be manually set and causes subsequent u-boot bbappend files using ${THISDIR} to reference this file's directory instead of their own.
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#1130): https://lists.yoctoproject.org/g/meta-arm/message/1130
Mute This Topic: https://lists.yoctoproject.org/mt/76906051/3617530
Group Owner: meta-arm+owner@lists.yoctoproject.org
Unsubscribe: https://lists.yoctoproject.org/g/meta-arm/unsub [oe-patchwork@oe-patch.openembedded.org]
-=-=-=-=-=-=-=-=-=-=-=-
Jon Mason Sept. 21, 2020, 4:38 p.m.
On Thu, Sep 17, 2020 at 09:58:17AM +0000, Nathan Dunne wrote:
> Renamed ${THISDIR} user defined variable to ${THIS_DIR}, to prevent
> it from breaking ${THISDIR} macro in subsequent u-boot .bbappend files
> 
> Change-Id: I4473ee5c3ac5c0aea9310557294cc9757579bdf1
> Issue-Id: SCM-1302
> Signed-off-by: Nathan Dunne <Nathan.Dunne@arm.com>

Pushed to master.

Thanks,
Jon

> ---
>  meta-arm-bsp/recipes-bsp/u-boot/u-boot_%.bbappend | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/meta-arm-bsp/recipes-bsp/u-boot/u-boot_%.bbappend b/meta-arm-bsp/recipes-bsp/u-boot/u-boot_%.bbappend
> index bf57242..5fc3723 100644
> --- a/meta-arm-bsp/recipes-bsp/u-boot/u-boot_%.bbappend
> +++ b/meta-arm-bsp/recipes-bsp/u-boot/u-boot_%.bbappend
> @@ -1,7 +1,7 @@
>  # Machine specific u-boot
>  
> -THISDIR := "${THISDIR}"
> -FILESEXTRAPATHS_prepend = "${THISDIR}/files/:${THISDIR}/${BP}:"
> +THIS_DIR := "${THISDIR}"
> +FILESEXTRAPATHS_prepend = "${THIS_DIR}/files/:${THIS_DIR}/${BP}:"
>  FILESEXTRAPATHS_prepend_fvp-base := "${THISDIR}/files/fvp-common:"
>  FILESEXTRAPATHS_prepend_foundation-armv8 := "${THISDIR}/files/fvp-common:"
>  
> -- 
> 2.17.1
> 

> 
> 
>
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#1134): https://lists.yoctoproject.org/g/meta-arm/message/1134
Mute This Topic: https://lists.yoctoproject.org/mt/76906051/3617530
Group Owner: meta-arm+owner@lists.yoctoproject.org
Unsubscribe: https://lists.yoctoproject.org/g/meta-arm/unsub [oe-patchwork@oe-patch.openembedded.org]
-=-=-=-=-=-=-=-=-=-=-=-