Extreme tiny image for imx6ul with ramfs

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Extreme tiny image for imx6ul with ramfs

2,369 Views
pietercardoen
Contributor II

Dear

I am trying to build a very tiny image for the imx6ul. The kernel + device tree + rootfs must be smaller than 4Mbyte. I am however noticing some problems.

I first built the mfgtool-initramfs-image but this image has a rootfs size of about 7Mbyte. Distro of this build is poky.

After some searching, I tried to change distro to poky-tiny by adapting this in local.conf and furthermore change PACKAGE_CLASSES to package_ipk. If I build this using yocto, then I get errors like:

| lib/libcoreutils.a(mbrtowc.o): In function `rpl_mbrtowc':
| /home/pic/Documents/Builds/YOCTO/fip-imx6ul/yoctobuild/build/tmp/work/cortexa7hf-vfp-neon-poky-linux-gnueabi/coreutils/8.24-r0/coreutils-8.24/lib/mbrtowc.c:97: undefined reference to `mbtowc'
| /home/pic/Documents/Builds/YOCTO/fip-imx6ul/yoctobuild/build/tmp/work/cortexa7hf-vfp-neon-poky-linux-gnueabi/coreutils/8.24-r0/coreutils-8.24/lib/mbrtowc.c:100: undefined reference to `mbtowc'
| collect2: error: ld returned 1 exit status
| Makefile:8089: recipe for target 'src/users' failed

Afterwards, I also tried to build core-image-minimal-initramfs but then I got the error:

ERROR: Nothing RPROVIDES 'initramfs-live-install' (but /home/pic/Documents/Builds/YOCTO/fip-imx6ul/yoctobuild/sources/poky/meta/recipes-core/images/core-image-minimal-initramfs.bb RDEPENDS on or otherwise requires it)
ERROR: initramfs-live-install was skipped: incompatible with host arm-poky-linux-gnueabi (not in COMPATIBLE_HOST)
NOTE: Runtime target 'initramfs-live-install' is unbuildable, removing...
Missing or unbuildable dependency chain was: ['initramfs-live-install']
ERROR: Required build target 'core-image-minimal-initramfs' has no buildable providers.
Missing or unbuildable dependency chain was: ['core-image-minimal-initramfs', 'initramfs-live-install']

Is it possible to give me any advice with one of these errors or give me advice how to get this build within the required memory?

Thanks

Pieter Cardoen

Labels (1)
0 Kudos
6 Replies

1,232 Views
Carlos_Musich
NXP Employee
NXP Employee

Hi,

you can find simple advice here: Reducing imx6 yocto build size for custom board 


Regards,
Carlos

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

0 Kudos

1,232 Views
igorpadykov
NXP Employee
NXP Employee

Hi Pieter

for procedures of building of very small images one can look

at SCM resources

http://www.nxp.com/products/single-chip-modules/quick-start-board-for-scm-i.mx-6dq:QWKS-SCM-IMX6DQ?f...

Best regards
igor
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

0 Kudos

1,232 Views
matthewbach
Contributor II

This doesn't answer the question. The docs provided for SCM merely spell out core-image-minimal, which is not that small; especially when targeting NOR Flash.

0 Kudos

1,232 Views
igorpadykov
NXP Employee
NXP Employee

please look at mfgtool2-yocto-mx6dqscm-1gb-qwks-rev3-internal-spinor.vbs

in mfgtools_L4.1.15_2.0.0-ga_MX6SCM release, it provides small image fitting in

board spi-nor.

0 Kudos

1,232 Views
matthewbach
Contributor II

I see the vb script you referenced in the MFG Tools download, but where's the image itself? Is there a list of what it includes? The script just seems to be calling a command from mfg tools:

wshShell.run "mfgtool2.exe -c ""linux"" -l ""SCM-Internal-SPI-NOR"" -s ""board=qwks-rev2"" -s ""nor=spi-nor"" -s ""ldo=-ldo"" -s ""memsize=1gb"" -s ""mem-mode=-fix"" "

But what is actually being put into flash? How can we customize it?

0 Kudos

1,232 Views
igorpadykov
NXP Employee
NXP Employee

please look at ucl2.xml, image is in /files folder:

core-image-minimal-rootfs.tar.bz2

for customizations on ecan look at:

i.MX Yocto Project: How can I (quickly) modify the kernel and test it? 

https://community.nxp.com/docs/DOC-95333 

0 Kudos