Patchwork [meta-fsl-arm,15/16] mfgtool-initramfs-image.bbclass: Abstracts the MfgTool's initramfs needs

login
register
mail settings
Submitter Otavio Salvador
Date Feb. 24, 2014, 6:52 p.m.
Message ID <1393267973-4034-16-git-send-email-otavio@ossystems.com.br>
Download mbox | patch
Permalink /patch/67357/
State Changes Requested
Delegated to: Otavio Salvador
Headers show

Comments

Otavio Salvador - Feb. 24, 2014, 6:52 p.m.
Manage the initramfs requirements for Manufacturing Tool use and allow
future addition of new filesystem support if needed.

Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
---

 classes/mfgtool-initramfs-image.bbclass | 26 ++++++++++++++++++++++++++
 1 file changed, 26 insertions(+)
 create mode 100644 classes/mfgtool-initramfs-image.bbclass
Daiane Angolini - Feb. 25, 2014, 6:13 p.m.
On Mon, Feb 24, 2014 at 3:52 PM, Otavio Salvador
<otavio@ossystems.com.br> wrote:
> Manage the initramfs requirements for Manufacturing Tool use and allow
> future addition of new filesystem support if needed.
>
> Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
> ---
>
>  classes/mfgtool-initramfs-image.bbclass | 26 ++++++++++++++++++++++++++
>  1 file changed, 26 insertions(+)
>  create mode 100644 classes/mfgtool-initramfs-image.bbclass
>
> diff --git a/classes/mfgtool-initramfs-image.bbclass b/classes/mfgtool-initramfs-image.bbclass
> new file mode 100644
> index 0000000..3c2e445
> --- /dev/null
> +++ b/classes/mfgtool-initramfs-image.bbclass
> @@ -0,0 +1,26 @@

Would be possible to add a DESCRIPTION in a class? In case it´s not
possible, would be nice to add a comment only to inform the goal of
this class?




> +DEPENDS += "u-boot-mfgtool linux-mfgtool"
> +
> +PACKAGE_GROUP_mtd = "packagegroup-fsl-mfgtool-mtd"
> +PACKAGE_GROUP_extfs = "packagegroup-fsl-mfgtool-extfs"
> +
> +IMAGE_FSTYPES = "cpio.gz.u-boot"

Do you intent to not allow IMAGE_FSTYPES to be overridden?


> +IMAGE_ROOTFS_SIZE ?= "8192"
> +IMAGE_CLASSES = "image_types_uboot"
> +
> +IMAGE_FEATURES = " \

When you say future addition of new file system support you mean a
patch to add it on recipe or you mean it being overridden by
local.conf?




Daiane
> +    mtd \
> +    extfs \
> +    read-only-rootfs \
> +"
> +
> +# Avoid installation of syslog
> +BAD_RECOMMENDATIONS += "busybox-syslog"
> +
> +# Avoid static /dev
> +USE_DEVFS = "1"
> +
> +inherit core-image
> +
> +CORE_IMAGE_BASE_INSTALL = " \
> +    ${CORE_IMAGE_EXTRA_INSTALL} \
> +"
> --
> 1.9.0
>
> _______________________________________________
> meta-freescale mailing list
> meta-freescale@yoctoproject.org
> https://lists.yoctoproject.org/listinfo/meta-freescale
Otavio Salvador - Feb. 26, 2014, 12:58 p.m.
Hello Daiane,

On Tue, Feb 25, 2014 at 3:13 PM, Daiane Angolini <daiane.list@gmail.com> wrote:
> On Mon, Feb 24, 2014 at 3:52 PM, Otavio Salvador
> <otavio@ossystems.com.br> wrote:
>> Manage the initramfs requirements for Manufacturing Tool use and allow
>> future addition of new filesystem support if needed.
>>
>> Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
>> ---
>>
>>  classes/mfgtool-initramfs-image.bbclass | 26 ++++++++++++++++++++++++++
>>  1 file changed, 26 insertions(+)
>>  create mode 100644 classes/mfgtool-initramfs-image.bbclass
>>
>> diff --git a/classes/mfgtool-initramfs-image.bbclass b/classes/mfgtool-initramfs-image.bbclass
>> new file mode 100644
>> index 0000000..3c2e445
>> --- /dev/null
>> +++ b/classes/mfgtool-initramfs-image.bbclass
>> @@ -0,0 +1,26 @@
>
> Would be possible to add a DESCRIPTION in a class? In case it´s not
> possible, would be nice to add a comment only to inform the goal of
> this class?

I added a comment block in the class.

>> +DEPENDS += "u-boot-mfgtool linux-mfgtool"
>> +
>> +PACKAGE_GROUP_mtd = "packagegroup-fsl-mfgtool-mtd"
>> +PACKAGE_GROUP_extfs = "packagegroup-fsl-mfgtool-extfs"
>> +
>> +IMAGE_FSTYPES = "cpio.gz.u-boot"
>
> Do you intent to not allow IMAGE_FSTYPES to be overridden?

Yes; it is possible to override it in the image file, if nee

>> +IMAGE_ROOTFS_SIZE ?= "8192"
>> +IMAGE_CLASSES = "image_types_uboot"
>> +
>> +IMAGE_FEATURES = " \
>
> When you say future addition of new file system support you mean a
> patch to add it on recipe or you mean it being overridden by
> local.conf?
>
>
>
>
> Daiane
>> +    mtd \
>> +    extfs \
>> +    read-only-rootfs \
>> +"
>> +
>> +# Avoid installation of syslog
>> +BAD_RECOMMENDATIONS += "busybox-syslog"
>> +
>> +# Avoid static /dev
>> +USE_DEVFS = "1"
>> +
>> +inherit core-image
>> +
>> +CORE_IMAGE_BASE_INSTALL = " \
>> +    ${CORE_IMAGE_EXTRA_INSTALL} \
>> +"
>> --
>> 1.9.0
>>
>> _______________________________________________
>> meta-freescale mailing list
>> meta-freescale@yoctoproject.org
>> https://lists.yoctoproject.org/listinfo/meta-freescale
Otavio Salvador - Feb. 26, 2014, 1:06 p.m.
Hello,

Pressed sent too soon hehe

On Wed, Feb 26, 2014 at 9:58 AM, Otavio Salvador
<otavio@ossystems.com.br> wrote:
> Hello Daiane,
>
> On Tue, Feb 25, 2014 at 3:13 PM, Daiane Angolini <daiane.list@gmail.com> wrote:
>> On Mon, Feb 24, 2014 at 3:52 PM, Otavio Salvador
>> <otavio@ossystems.com.br> wrote:
>>> Manage the initramfs requirements for Manufacturing Tool use and allow
>>> future addition of new filesystem support if needed.
>>>
>>> Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
>>> ---
>>>
>>>  classes/mfgtool-initramfs-image.bbclass | 26 ++++++++++++++++++++++++++
>>>  1 file changed, 26 insertions(+)
>>>  create mode 100644 classes/mfgtool-initramfs-image.bbclass
>>>
>>> diff --git a/classes/mfgtool-initramfs-image.bbclass b/classes/mfgtool-initramfs-image.bbclass
>>> new file mode 100644
>>> index 0000000..3c2e445
>>> --- /dev/null
>>> +++ b/classes/mfgtool-initramfs-image.bbclass
>>> @@ -0,0 +1,26 @@
>>
>> Would be possible to add a DESCRIPTION in a class? In case it´s not
>> possible, would be nice to add a comment only to inform the goal of
>> this class?
>
> I added a comment block in the class.
>
>>> +DEPENDS += "u-boot-mfgtool linux-mfgtool"
>>> +
>>> +PACKAGE_GROUP_mtd = "packagegroup-fsl-mfgtool-mtd"
>>> +PACKAGE_GROUP_extfs = "packagegroup-fsl-mfgtool-extfs"
>>> +
>>> +IMAGE_FSTYPES = "cpio.gz.u-boot"
>>
>> Do you intent to not allow IMAGE_FSTYPES to be overridden?
>
> Yes; it is possible to override it in the image file, if nee

Yes; it is possible to override it in the image file, if need. For the
goal of the class, the cpio.gz is enough and being a specific propose
image I think it is fine.

>>> +IMAGE_ROOTFS_SIZE ?= "8192"
>>> +IMAGE_CLASSES = "image_types_uboot"
>>> +
>>> +IMAGE_FEATURES = " \
>>
>> When you say future addition of new file system support you mean a
>> patch to add it on recipe or you mean it being overridden by
>> local.conf?

We may add fsfs, btrfs or other; the idea is we may not enable it by
default in the image features but allow it to be upstreamed ;-)

Patch

diff --git a/classes/mfgtool-initramfs-image.bbclass b/classes/mfgtool-initramfs-image.bbclass
new file mode 100644
index 0000000..3c2e445
--- /dev/null
+++ b/classes/mfgtool-initramfs-image.bbclass
@@ -0,0 +1,26 @@ 
+DEPENDS += "u-boot-mfgtool linux-mfgtool"
+
+PACKAGE_GROUP_mtd = "packagegroup-fsl-mfgtool-mtd"
+PACKAGE_GROUP_extfs = "packagegroup-fsl-mfgtool-extfs"
+
+IMAGE_FSTYPES = "cpio.gz.u-boot"
+IMAGE_ROOTFS_SIZE ?= "8192"
+IMAGE_CLASSES = "image_types_uboot"
+
+IMAGE_FEATURES = " \
+    mtd \
+    extfs \
+    read-only-rootfs \
+"
+
+# Avoid installation of syslog
+BAD_RECOMMENDATIONS += "busybox-syslog"
+
+# Avoid static /dev
+USE_DEVFS = "1"
+
+inherit core-image
+
+CORE_IMAGE_BASE_INSTALL = " \
+    ${CORE_IMAGE_EXTRA_INSTALL} \
+"