diff mbox series

[isar-cip-core,1/3] fix: add missing class dependencies in image_uuid

Message ID 20221012100641.2986740-2-felix.moessbauer@siemens.com (mailing list archive)
State Handled Elsewhere
Headers show
Series Simplify integration of swupdate into downstream layers | expand

Commit Message

Felix Moessbauer Oct. 12, 2022, 10:06 a.m. UTC
The image_uuid class references tasks and variables from image and
rootfs. By that, the class has to inherit the other classes to ensure
that the components are available, independent of the overall include /
parse order.

Signed-off-by: Felix Moessbauer <felix.moessbauer@siemens.com>
---
 classes/image_uuid.bbclass | 3 +++
 1 file changed, 3 insertions(+)

Comments

Jan Kiszka Oct. 13, 2022, 10:53 a.m. UTC | #1
On 13.10.22 12:16, Moessbauer, Felix Jonathan (T CED INW-CN) wrote:
>> -----Original Message-----
>> From: Kiszka, Jan (T CED) <jan.kiszka@siemens.com>
>> Sent: Wednesday, October 12, 2022 6:20 PM
>> To: Moessbauer, Felix Jonathan (T CED INW-CN)
>> <felix.moessbauer@siemens.com>; cip-dev@lists.cip-project.org
>> Cc: Gylstorff, Quirin (T CED SES-DE) <quirin.gylstorff@siemens.com>; RC CN SVC
>> Pluto <pluto.svc.chengdu.cn@siemens.com>
>> Subject: Re: [isar-cip-core][PATCH 1/3] fix: add missing class dependencies in
>> image_uuid
>>
>> On 12.10.22 12:06, Felix Moessbauer wrote:
>>> The image_uuid class references tasks and variables from image and
>>> rootfs. By that, the class has to inherit the other classes to ensure
>>> that the components are available, independent of the overall include
>>> / parse order.
>>
>> Just for my understanding: Is this more a theoretical issue, or did you actually
>> saw errors because of where you included the class?
> 
> This depends on how you integrate the components.
> In case use "include" the recipe that uses the class in a recipe that already inherits the mentioned classes, it works.
> If you do it in another recipe, the patch is required.
> 
> During my efforts to integrate, I actually ran into the issue.
> 

Ok, thanks.

I've applied this patch now, waiting for updates of the other 2 only.

Jan
diff mbox series

Patch

diff --git a/classes/image_uuid.bbclass b/classes/image_uuid.bbclass
index 71cc3ad..277941b 100644
--- a/classes/image_uuid.bbclass
+++ b/classes/image_uuid.bbclass
@@ -10,6 +10,9 @@ 
 # SPDX-License-Identifier: MIT
 #
 
+inherit rootfs
+inherit image
+
 def generate_image_uuid(d):
     import uuid