Openembedded Core Discussions
 help / color / mirror / Atom feed
* [PATCH] classes/image-live.bbclass: Don't hardcode cpio.gz
@ 2019-09-26  9:05 Böszörményi Zoltán
  2019-09-26 15:45 ` Richard Purdie
  0 siblings, 1 reply; 7+ messages in thread
From: Böszörményi Zoltán @ 2019-09-26  9:05 UTC (permalink / raw)
  To: openembedded-core

There's INITRAMFS_FSTYPES that can be set differently.

Signed-off-by: Böszörményi Zoltán <zboszor@pr.hu>
---

With the hardcoded initrd filename suffix but INITRAMFS_FSTYPES
set to cpio.lzma, this error occurs:

ERROR: sicom-pos-image-1.0-r0 do_bootimg: .../deploy/glibc/images/intel-core2-32/core-image-minimal-initramfs-intel-core2-32.cpio.lzma is invalid. initrd image creation failed.
ERROR: sicom-pos-image-1.0-r0 do_bootimg: Function failed: build_hddimg (log file is located at .../tmp-sicom-glibc/work/intel_core2_32-sicom-linux/sicom-pos-image/1.0-r0/temp/log.do_bootimg.32210)
ERROR: Logfile of failure stored in: .../tmp-sicom-glibc/work/intel_core2_32-sicom-linux/sicom-pos-image/1.0-r0/temp/log.do_bootimg.32210
ERROR: Task (.../layers/meta-sicom/images/sicom-pos-image.bb:do_bootimg) failed with exit code '1'

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

diff --git a/meta/classes/image-live.bbclass b/meta/classes/image-live.bbclass
index af71be5093..54058b350d 100644
--- a/meta/classes/image-live.bbclass
+++ b/meta/classes/image-live.bbclass
@@ -37,7 +37,7 @@ do_bootimg[depends] += "dosfstools-native:do_populate_sysroot \
 LABELS_LIVE ?= "boot install"
 ROOT_LIVE ?= "root=/dev/ram0"
 INITRD_IMAGE_LIVE ?= "${MLPREFIX}core-image-minimal-initramfs"
-INITRD_LIVE ?= "${DEPLOY_DIR_IMAGE}/${INITRD_IMAGE_LIVE}-${MACHINE}.cpio.gz"
+INITRD_LIVE ?= "${DEPLOY_DIR_IMAGE}/${INITRD_IMAGE_LIVE}-${MACHINE}.${INITRAMFS_FSTYPES}"
 
 LIVE_ROOTFS_TYPE ?= "ext4"
 ROOTFS ?= "${IMGDEPLOYDIR}/${IMAGE_LINK_NAME}.${LIVE_ROOTFS_TYPE}"
-- 
2.21.0



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

* Re: [PATCH] classes/image-live.bbclass: Don't hardcode cpio.gz
  2019-09-26  9:05 [PATCH] classes/image-live.bbclass: Don't hardcode cpio.gz Böszörményi Zoltán
@ 2019-09-26 15:45 ` Richard Purdie
  2019-09-26 16:50   ` Böszörményi Zoltán
  0 siblings, 1 reply; 7+ messages in thread
From: Richard Purdie @ 2019-09-26 15:45 UTC (permalink / raw)
  To: Böszörményi Zoltán, openembedded-core

On Thu, 2019-09-26 at 11:05 +0200, Böszörményi Zoltán via Openembedded-
core wrote:
> There's INITRAMFS_FSTYPES that can be set differently.
> 
> Signed-off-by: Böszörményi Zoltán <zboszor@pr.hu>
> ---
> 
> With the hardcoded initrd filename suffix but INITRAMFS_FSTYPES
> set to cpio.lzma, this error occurs:
> 
> ERROR: sicom-pos-image-1.0-r0 do_bootimg:
> .../deploy/glibc/images/intel-core2-32/core-image-minimal-initramfs-
> intel-core2-32.cpio.lzma is invalid. initrd image creation failed.
> ERROR: sicom-pos-image-1.0-r0 do_bootimg: Function failed:
> build_hddimg (log file is located at .../tmp-sicom-
> glibc/work/intel_core2_32-sicom-linux/sicom-pos-image/1.0-
> r0/temp/log.do_bootimg.32210)
> ERROR: Logfile of failure stored in: .../tmp-sicom-
> glibc/work/intel_core2_32-sicom-linux/sicom-pos-image/1.0-
> r0/temp/log.do_bootimg.32210
> ERROR: Task (.../layers/meta-sicom/images/sicom-pos-
> image.bb:do_bootimg) failed with exit code '1'
> 
>  meta/classes/image-live.bbclass | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/meta/classes/image-live.bbclass b/meta/classes/image-
> live.bbclass
> index af71be5093..54058b350d 100644
> --- a/meta/classes/image-live.bbclass
> +++ b/meta/classes/image-live.bbclass
> @@ -37,7 +37,7 @@ do_bootimg[depends] += "dosfstools-
> native:do_populate_sysroot \
>  LABELS_LIVE ?= "boot install"
>  ROOT_LIVE ?= "root=/dev/ram0"
>  INITRD_IMAGE_LIVE ?= "${MLPREFIX}core-image-minimal-initramfs"
> -INITRD_LIVE ?= "${DEPLOY_DIR_IMAGE}/${INITRD_IMAGE_LIVE}-
> ${MACHINE}.cpio.gz"
> +INITRD_LIVE ?= "${DEPLOY_DIR_IMAGE}/${INITRD_IMAGE_LIVE}-
> ${MACHINE}.${INITRAMFS_FSTYPES}"
>  
>  LIVE_ROOTFS_TYPE ?= "ext4"
>  ROOTFS ?= "${IMGDEPLOYDIR}/${IMAGE_LINK_NAME}.${LIVE_ROOTFS_TYPE}"

I'm a little worried that INITRAMFS_FSTYPES can contain multiple values
by the sounds of its name...

Cheers,

Richard



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

* Re: [PATCH] classes/image-live.bbclass: Don't hardcode cpio.gz
  2019-09-26 15:45 ` Richard Purdie
@ 2019-09-26 16:50   ` Böszörményi Zoltán
  2019-09-26 17:02     ` Böszörményi Zoltán
  0 siblings, 1 reply; 7+ messages in thread
From: Böszörményi Zoltán @ 2019-09-26 16:50 UTC (permalink / raw)
  To: Richard Purdie, openembedded-core

2019. 09. 26. 17:45 keltezéssel, Richard Purdie írta:
> On Thu, 2019-09-26 at 11:05 +0200, Böszörményi Zoltán via Openembedded-
> core wrote:
>> There's INITRAMFS_FSTYPES that can be set differently.
>>
>> Signed-off-by: Böszörményi Zoltán <zboszor@pr.hu>
>> ---
>>
>> With the hardcoded initrd filename suffix but INITRAMFS_FSTYPES
>> set to cpio.lzma, this error occurs:
>>
>> ERROR: sicom-pos-image-1.0-r0 do_bootimg:
>> .../deploy/glibc/images/intel-core2-32/core-image-minimal-initramfs-
>> intel-core2-32.cpio.lzma is invalid. initrd image creation failed.
>> ERROR: sicom-pos-image-1.0-r0 do_bootimg: Function failed:
>> build_hddimg (log file is located at .../tmp-sicom-
>> glibc/work/intel_core2_32-sicom-linux/sicom-pos-image/1.0-
>> r0/temp/log.do_bootimg.32210)
>> ERROR: Logfile of failure stored in: .../tmp-sicom-
>> glibc/work/intel_core2_32-sicom-linux/sicom-pos-image/1.0-
>> r0/temp/log.do_bootimg.32210
>> ERROR: Task (.../layers/meta-sicom/images/sicom-pos-
>> image.bb:do_bootimg) failed with exit code '1'
>>
>>   meta/classes/image-live.bbclass | 2 +-
>>   1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/meta/classes/image-live.bbclass b/meta/classes/image-
>> live.bbclass
>> index af71be5093..54058b350d 100644
>> --- a/meta/classes/image-live.bbclass
>> +++ b/meta/classes/image-live.bbclass
>> @@ -37,7 +37,7 @@ do_bootimg[depends] += "dosfstools-
>> native:do_populate_sysroot \
>>   LABELS_LIVE ?= "boot install"
>>   ROOT_LIVE ?= "root=/dev/ram0"
>>   INITRD_IMAGE_LIVE ?= "${MLPREFIX}core-image-minimal-initramfs"
>> -INITRD_LIVE ?= "${DEPLOY_DIR_IMAGE}/${INITRD_IMAGE_LIVE}-
>> ${MACHINE}.cpio.gz"
>> +INITRD_LIVE ?= "${DEPLOY_DIR_IMAGE}/${INITRD_IMAGE_LIVE}-
>> ${MACHINE}.${INITRAMFS_FSTYPES}"
>>   
>>   LIVE_ROOTFS_TYPE ?= "ext4"
>>   ROOTFS ?= "${IMGDEPLOYDIR}/${IMAGE_LINK_NAME}.${LIVE_ROOTFS_TYPE}"
> 
> I'm a little worried that INITRAMFS_FSTYPES can contain multiple values
> by the sounds of its name...

 From the looks of the current value, it's already contains multiple values
delimited by that dot. "cpio" + "gz".

Also, according to meta/conf/documentation.conf, line 228:

INITRAMFS_FSTYPES[doc] = "Defines the format for the output image of an initial RAM disk 
(initramfs), which is used during boot."

Defines the "format", singular. Maybe the variable is a slight misnomer.

Cheers,
Zoltán Böszörményi


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

* Re: [PATCH] classes/image-live.bbclass: Don't hardcode cpio.gz
  2019-09-26 16:50   ` Böszörményi Zoltán
@ 2019-09-26 17:02     ` Böszörményi Zoltán
  2019-09-26 17:09       ` Böszörményi Zoltán
  0 siblings, 1 reply; 7+ messages in thread
From: Böszörményi Zoltán @ 2019-09-26 17:02 UTC (permalink / raw)
  To: Richard Purdie, openembedded-core

2019. 09. 26. 18:50 keltezéssel, Böszörményi Zoltán via Openembedded-core írta:
> 2019. 09. 26. 17:45 keltezéssel, Richard Purdie írta:
>> On Thu, 2019-09-26 at 11:05 +0200, Böszörményi Zoltán via Openembedded-
>> core wrote:
>>> There's INITRAMFS_FSTYPES that can be set differently.
>>>
>>> Signed-off-by: Böszörményi Zoltán <zboszor@pr.hu>
>>> ---
>>>
>>> With the hardcoded initrd filename suffix but INITRAMFS_FSTYPES
>>> set to cpio.lzma, this error occurs:
>>>
>>> ERROR: sicom-pos-image-1.0-r0 do_bootimg:
>>> .../deploy/glibc/images/intel-core2-32/core-image-minimal-initramfs-
>>> intel-core2-32.cpio.lzma is invalid. initrd image creation failed.
>>> ERROR: sicom-pos-image-1.0-r0 do_bootimg: Function failed:
>>> build_hddimg (log file is located at .../tmp-sicom-
>>> glibc/work/intel_core2_32-sicom-linux/sicom-pos-image/1.0-
>>> r0/temp/log.do_bootimg.32210)
>>> ERROR: Logfile of failure stored in: .../tmp-sicom-
>>> glibc/work/intel_core2_32-sicom-linux/sicom-pos-image/1.0-
>>> r0/temp/log.do_bootimg.32210
>>> ERROR: Task (.../layers/meta-sicom/images/sicom-pos-
>>> image.bb:do_bootimg) failed with exit code '1'
>>>
>>>   meta/classes/image-live.bbclass | 2 +-
>>>   1 file changed, 1 insertion(+), 1 deletion(-)
>>>
>>> diff --git a/meta/classes/image-live.bbclass b/meta/classes/image-
>>> live.bbclass
>>> index af71be5093..54058b350d 100644
>>> --- a/meta/classes/image-live.bbclass
>>> +++ b/meta/classes/image-live.bbclass
>>> @@ -37,7 +37,7 @@ do_bootimg[depends] += "dosfstools-
>>> native:do_populate_sysroot \
>>>   LABELS_LIVE ?= "boot install"
>>>   ROOT_LIVE ?= "root=/dev/ram0"
>>>   INITRD_IMAGE_LIVE ?= "${MLPREFIX}core-image-minimal-initramfs"
>>> -INITRD_LIVE ?= "${DEPLOY_DIR_IMAGE}/${INITRD_IMAGE_LIVE}-
>>> ${MACHINE}.cpio.gz"
>>> +INITRD_LIVE ?= "${DEPLOY_DIR_IMAGE}/${INITRD_IMAGE_LIVE}-
>>> ${MACHINE}.${INITRAMFS_FSTYPES}"
>>>   LIVE_ROOTFS_TYPE ?= "ext4"
>>>   ROOTFS ?= "${IMGDEPLOYDIR}/${IMAGE_LINK_NAME}.${LIVE_ROOTFS_TYPE}"
>>
>> I'm a little worried that INITRAMFS_FSTYPES can contain multiple values
>> by the sounds of its name...
> 
>  From the looks of the current value, it's already contains multiple values
> delimited by that dot. "cpio" + "gz".
> 
> Also, according to meta/conf/documentation.conf, line 228:
> 
> INITRAMFS_FSTYPES[doc] = "Defines the format for the output image of an initial RAM disk 
> (initramfs), which is used during boot."

Also, image-live.bbclass uses this variable this way:

INITRD_LIVE ?= "${DEPLOY_DIR_IMAGE}/${INITRD_IMAGE_LIVE}-${MACHINE}.${INITRAMFS_FSTYPES}"

The initrd/initramfs file name would definitely look strange if
this variable could contain multiple space delimited settings.

> 
> Defines the "format", singular. Maybe the variable is a slight misnomer.
> 
> Cheers,
> Zoltán Böszörményi



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

* Re: [PATCH] classes/image-live.bbclass: Don't hardcode cpio.gz
  2019-09-26 17:02     ` Böszörményi Zoltán
@ 2019-09-26 17:09       ` Böszörményi Zoltán
  2019-09-26 21:02         ` richard.purdie
  0 siblings, 1 reply; 7+ messages in thread
From: Böszörményi Zoltán @ 2019-09-26 17:09 UTC (permalink / raw)
  To: Richard Purdie, openembedded-core

2019. 09. 26. 19:02 keltezéssel, Böszörményi Zoltán via Openembedded-core írta:
> 2019. 09. 26. 18:50 keltezéssel, Böszörményi Zoltán via Openembedded-core írta:
>> 2019. 09. 26. 17:45 keltezéssel, Richard Purdie írta:
>>> On Thu, 2019-09-26 at 11:05 +0200, Böszörményi Zoltán via Openembedded-
>>> core wrote:
>>>> There's INITRAMFS_FSTYPES that can be set differently.
>>>>
>>>> Signed-off-by: Böszörményi Zoltán <zboszor@pr.hu>
>>>> ---
>>>>
>>>> With the hardcoded initrd filename suffix but INITRAMFS_FSTYPES
>>>> set to cpio.lzma, this error occurs:
>>>>
>>>> ERROR: sicom-pos-image-1.0-r0 do_bootimg:
>>>> .../deploy/glibc/images/intel-core2-32/core-image-minimal-initramfs-
>>>> intel-core2-32.cpio.lzma is invalid. initrd image creation failed.
>>>> ERROR: sicom-pos-image-1.0-r0 do_bootimg: Function failed:
>>>> build_hddimg (log file is located at .../tmp-sicom-
>>>> glibc/work/intel_core2_32-sicom-linux/sicom-pos-image/1.0-
>>>> r0/temp/log.do_bootimg.32210)
>>>> ERROR: Logfile of failure stored in: .../tmp-sicom-
>>>> glibc/work/intel_core2_32-sicom-linux/sicom-pos-image/1.0-
>>>> r0/temp/log.do_bootimg.32210
>>>> ERROR: Task (.../layers/meta-sicom/images/sicom-pos-
>>>> image.bb:do_bootimg) failed with exit code '1'
>>>>
>>>>   meta/classes/image-live.bbclass | 2 +-
>>>>   1 file changed, 1 insertion(+), 1 deletion(-)
>>>>
>>>> diff --git a/meta/classes/image-live.bbclass b/meta/classes/image-
>>>> live.bbclass
>>>> index af71be5093..54058b350d 100644
>>>> --- a/meta/classes/image-live.bbclass
>>>> +++ b/meta/classes/image-live.bbclass
>>>> @@ -37,7 +37,7 @@ do_bootimg[depends] += "dosfstools-
>>>> native:do_populate_sysroot \
>>>>   LABELS_LIVE ?= "boot install"
>>>>   ROOT_LIVE ?= "root=/dev/ram0"
>>>>   INITRD_IMAGE_LIVE ?= "${MLPREFIX}core-image-minimal-initramfs"
>>>> -INITRD_LIVE ?= "${DEPLOY_DIR_IMAGE}/${INITRD_IMAGE_LIVE}-
>>>> ${MACHINE}.cpio.gz"
>>>> +INITRD_LIVE ?= "${DEPLOY_DIR_IMAGE}/${INITRD_IMAGE_LIVE}-
>>>> ${MACHINE}.${INITRAMFS_FSTYPES}"
>>>>   LIVE_ROOTFS_TYPE ?= "ext4"
>>>>   ROOTFS ?= "${IMGDEPLOYDIR}/${IMAGE_LINK_NAME}.${LIVE_ROOTFS_TYPE}"
>>>
>>> I'm a little worried that INITRAMFS_FSTYPES can contain multiple values
>>> by the sounds of its name...
>>
>>  From the looks of the current value, it's already contains multiple values
>> delimited by that dot. "cpio" + "gz".
>>
>> Also, according to meta/conf/documentation.conf, line 228:
>>
>> INITRAMFS_FSTYPES[doc] = "Defines the format for the output image of an initial RAM disk 
>> (initramfs), which is used during boot."
> 
> Also, image-live.bbclass uses this variable this way:
> 
> INITRD_LIVE ?= "${DEPLOY_DIR_IMAGE}/${INITRD_IMAGE_LIVE}-${MACHINE}.${INITRAMFS_FSTYPES}"
> 
> The initrd/initramfs file name would definitely look strange if
> this variable could contain multiple space delimited settings.

Also, openembedded-core/scripts/lib/wic/plugins/source/isoimage-isohybrid.py
has that _build_initramfs_path function from line 143. The usage of
the same variable in this python function also points back to the
documentation line, i.e. it's a filename suffix and not multiple
settings delimited by space.

> 
>>
>> Defines the "format", singular. Maybe the variable is a slight misnomer.
>>
>> Cheers,
>> Zoltán Böszörményi
> 



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

* Re: [PATCH] classes/image-live.bbclass: Don't hardcode cpio.gz
  2019-09-26 17:09       ` Böszörményi Zoltán
@ 2019-09-26 21:02         ` richard.purdie
  2019-09-27  4:31           ` Böszörményi Zoltán
  0 siblings, 1 reply; 7+ messages in thread
From: richard.purdie @ 2019-09-26 21:02 UTC (permalink / raw)
  To: Böszörményi Zoltán, openembedded-core

On Thu, 2019-09-26 at 19:09 +0200, Böszörményi Zoltán wrote:
> 2019. 09. 26. 19:02 keltezéssel, Böszörményi Zoltán via Openembedded-
> core írta:
> > 2019. 09. 26. 18:50 keltezéssel, Böszörményi Zoltán via
> > Openembedded-core írta:
> > > 2019. 09. 26. 17:45 keltezéssel, Richard Purdie írta:
> > > > 
> > > > I'm a little worried that INITRAMFS_FSTYPES can contain
> > > > multiple values
> > > > by the sounds of its name...
> > > 
> > >  From the looks of the current value, it's already contains
> > > multiple values
> > > delimited by that dot. "cpio" + "gz".
> > > 
> > > Also, according to meta/conf/documentation.conf, line 228:
> > > 
> > > INITRAMFS_FSTYPES[doc] = "Defines the format for the output image
> > > of an initial RAM disk 
> > > (initramfs), which is used during boot."
> > 
> > Also, image-live.bbclass uses this variable this way:
> > 
> > INITRD_LIVE ?= "${DEPLOY_DIR_IMAGE}/${INITRD_IMAGE_LIVE}-
> > ${MACHINE}.${INITRAMFS_FSTYPES}"
> > 
> > The initrd/initramfs file name would definitely look strange if
> > this variable could contain multiple space delimited settings.
> 
> Also, openembedded-core/scripts/lib/wic/plugins/source/isoimage-
> isohybrid.py
> has that _build_initramfs_path function from line 143. The usage of
> the same variable in this python function also points back to the
> documentation line, i.e. it's a filename suffix and not multiple
> settings delimited by space.

This does look ok given the above. Thanks for confirming.

Cheers,

Richard




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

* Re: [PATCH] classes/image-live.bbclass: Don't hardcode cpio.gz
  2019-09-26 21:02         ` richard.purdie
@ 2019-09-27  4:31           ` Böszörményi Zoltán
  0 siblings, 0 replies; 7+ messages in thread
From: Böszörményi Zoltán @ 2019-09-27  4:31 UTC (permalink / raw)
  To: richard.purdie, openembedded-core

2019. 09. 26. 23:02 keltezéssel, richard.purdie@linuxfoundation.org írta:
> On Thu, 2019-09-26 at 19:09 +0200, Böszörményi Zoltán wrote:
>> 2019. 09. 26. 19:02 keltezéssel, Böszörményi Zoltán via Openembedded-
>> core írta:
>>> 2019. 09. 26. 18:50 keltezéssel, Böszörményi Zoltán via
>>> Openembedded-core írta:
>>>> 2019. 09. 26. 17:45 keltezéssel, Richard Purdie írta:
>>>>>
>>>>> I'm a little worried that INITRAMFS_FSTYPES can contain
>>>>> multiple values
>>>>> by the sounds of its name...
>>>>
>>>>   From the looks of the current value, it's already contains
>>>> multiple values
>>>> delimited by that dot. "cpio" + "gz".
>>>>
>>>> Also, according to meta/conf/documentation.conf, line 228:
>>>>
>>>> INITRAMFS_FSTYPES[doc] = "Defines the format for the output image
>>>> of an initial RAM disk
>>>> (initramfs), which is used during boot."
>>>
>>> Also, image-live.bbclass uses this variable this way:
>>>
>>> INITRD_LIVE ?= "${DEPLOY_DIR_IMAGE}/${INITRD_IMAGE_LIVE}-
>>> ${MACHINE}.${INITRAMFS_FSTYPES}"
>>>
>>> The initrd/initramfs file name would definitely look strange if
>>> this variable could contain multiple space delimited settings.
>>
>> Also, openembedded-core/scripts/lib/wic/plugins/source/isoimage-
>> isohybrid.py
>> has that _build_initramfs_path function from line 143. The usage of
>> the same variable in this python function also points back to the
>> documentation line, i.e. it's a filename suffix and not multiple
>> settings delimited by space.
> 
> This does look ok given the above. Thanks for confirming.

Thanks for merging it into master-next.

I have also sent a patch for warrior separately with [warrior][PATCH]
yesterday, as I experienced the error there first.
Can you please apply it to warrior-next so I won't have to carry
the patch locally for long?

Thanks in advance,
Zoltán Böszörményi

> 
> Cheers,
> 
> Richard
> 
> 
> 



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

end of thread, other threads:[~2019-09-27  4:31 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-09-26  9:05 [PATCH] classes/image-live.bbclass: Don't hardcode cpio.gz Böszörményi Zoltán
2019-09-26 15:45 ` Richard Purdie
2019-09-26 16:50   ` Böszörményi Zoltán
2019-09-26 17:02     ` Böszörményi Zoltán
2019-09-26 17:09       ` Böszörményi Zoltán
2019-09-26 21:02         ` richard.purdie
2019-09-27  4:31           ` Böszörményi Zoltán

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