mailarchive of the ptxdist mailing list
 help / color / mirror / Atom feed
* [ptxdist] Generation of additional xz rootfs archive
@ 2015-11-11 14:06 Bruno Thomsen
  2015-11-18 17:42 ` Michael Olbrich
  0 siblings, 1 reply; 2+ messages in thread
From: Bruno Thomsen @ 2015-11-11 14:06 UTC (permalink / raw)
  To: ptxdist; +Cc: Bruno Thomsen


[-- Attachment #1.1: Type: text/plain, Size: 1028 bytes --]

Hi,

I am currently looking into the possibility of adding ptxdist generation of
a xz rootfs archive, as I thought the feature might be useful for others as
well.
Should it be added as a new script like ptxd_make_image_archive_impl
(image/archive) or implemented in C inside genimage (image/genimage)?

The goal is to optimize our firmware upgrade image size.
This could be done by switching from gz to xz rootfs which reduces size with
approx 35%.
The production firmware will still be using a gz rootfs archive.

I basically want to do the following command:
gzip -d < root.tgz | xz -9e > root.tar.xz


Compression level should be configurable so it can be adjusted to target
memory size.
Memory usage is approx 65MB during extraction of a -9 archive on an i.MX28
processor when using xz from Busybox.
In my testing the CompMem/DecMem listed in "man xz" seems to be valid for
embedded ARM Linux systems as well.


Otherwise this will just end as even more clutter in our custom build script
wrapper around ptxdist :)


/Bruno

[-- Attachment #1.2: smime.p7s --]
[-- Type: application/x-pkcs7-signature, Size: 3540 bytes --]

[-- Attachment #2: Type: text/plain, Size: 91 bytes --]

_______________________________________________
ptxdist mailing list
ptxdist@pengutronix.de

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

* Re: [ptxdist] Generation of additional xz rootfs archive
  2015-11-11 14:06 [ptxdist] Generation of additional xz rootfs archive Bruno Thomsen
@ 2015-11-18 17:42 ` Michael Olbrich
  0 siblings, 0 replies; 2+ messages in thread
From: Michael Olbrich @ 2015-11-18 17:42 UTC (permalink / raw)
  To: ptxdist

Hi,

On Wed, Nov 11, 2015 at 02:06:36PM +0000, Bruno Thomsen wrote:
> I am currently looking into the possibility of adding ptxdist generation of
> a xz rootfs archive, as I thought the feature might be useful for others as
> well.
> Should it be added as a new script like ptxd_make_image_archive_impl
> (image/archive) or implemented in C inside genimage (image/genimage)?
> 
> The goal is to optimize our firmware upgrade image size.
> This could be done by switching from gz to xz rootfs which reduces size with
> approx 35%.
> The production firmware will still be using a gz rootfs archive.
> 
> I basically want to do the following command:
> gzip -d < root.tgz | xz -9e > root.tar.xz
> 
> 
> Compression level should be configurable so it can be adjusted to target
> memory size.
> Memory usage is approx 65MB during extraction of a -9 archive on an i.MX28
> processor when using xz from Busybox.
> In my testing the CompMem/DecMem listed in "man xz" seems to be valid for
> embedded ARM Linux systems as well.
> 
> 
> Otherwise this will just end as even more clutter in our custom build script
> wrapper around ptxdist :)

This can be easily done in PTXdist. You just need to use the 'new' image
mechanism:

$ ptxdist newpackage image-genimage

 - remove the .config file
 - select IMAGE_ROOT_TGZ in the .in file and remove select for genimage.
 - remove the _FILES and __CONFIG line the .make file
 - replace the image/genimage line with your recompression command.

We cannot define every possible image within upstream PTXdist. That's why I
created the new image mechanism to make it easy to add new images in a BSP.

Michael

-- 
Pengutronix e.K.                           |                             |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

_______________________________________________
ptxdist mailing list
ptxdist@pengutronix.de

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

end of thread, other threads:[~2015-11-18 17:42 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-11-11 14:06 [ptxdist] Generation of additional xz rootfs archive Bruno Thomsen
2015-11-18 17:42 ` Michael Olbrich

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