IMX8M BSP Yocto build error

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

IMX8M BSP Yocto build error

2,307 Views
gehariprasath
Contributor II

Dear all

I am trying to build the BSP for our custom target based on the IMX8M Mini. I am facing the below build error. I have checked the concerned package's bitbake recipe and found that the mentioned dependency is already satisfied. But still the error gets thrown. Also I have tried 'bitbake wic-tools' as suggested in the error thrown but still I get the same error while building the final target image. Any hints ? TIA

My host machine is ubuntu 18.04(Details below)

hari@hari:~/projects/tx-nextgen/linux-yocto-bsp$ uname -a
Linux hari 5.4.0-42-generic #46~18.04.1-Ubuntu SMP Fri Jul 10 07:21:24 UTC 2020 x86_64 x86_64 x86_64 GNU/Linux

Build error Log:

ERROR: nextgen-image-1.0-r0 do_image_wic: Execution of '/home/hari/projects/tx-nextgen/linux-yocto-bsp/build/tmp/work/imx8mmddr4evk-poky-linux/nextgen-image/1.0-r0/temp/run.do_image_wic.2491' failed with exit code 1:
INFO: Creating image(s)...

ERROR: A native program mkfs.ext4 required to build the image was not found (see details above).

Please make sure wic-tools have e2fsprogs-native in its DEPENDS, build it with 'bitbake wic-tools' and try again.


WARNING: exit code 1 from a shell command.

ERROR: Logfile of failure stored in: /home/hari/projects/tx-nextgen/linux-yocto-bsp/build/tmp/work/imx8mmddr4evk-poky-linux/nextgen-image/1.0-r0/temp/log.do_image_wic.2491

Labels (2)
0 Kudos
11 Replies

2,232 Views
gehariprasath
Contributor II

Hello

Even after letting Yocto download the entire source freshly, I am facing the same issue. We have observed that the "mkfs.ext4" binary is available at this location below. Additinally,I have done repo sync few times to ensure download is complete.

"build/tmp/work/imx8mmddr4evk-poky-linux/nextgen-image/1.0-r0/rootfs/sbin/mkfs.ext4"

The same binary is not available at this location below. 

"build/tmp/work/imx8mmddr4evk-poky-linux/nextgen-image/1.0-r0/recipe-sysroot-native/sbin/"

Under 'recipe-sysroot-native' I could only see the following binaries

├── agetty
├── blkid
├── blockdev
├── cfdisk
├── ctrlaltdel
├── fdisk
├── fsck
├── fstrim
├── hwclock
├── losetup
├── makedevs
├── mkswap
├── nologin
├── pivot_root
├── sulogin
├── swapoff
├── swapon
├── switch_root
├── vigr -> vipw.shadow
└── vipw

0 Kudos

2,227 Views
Zhiming_Liu
NXP TechSupport
NXP TechSupport

Hi,

Which BSP version did you use, and attach your build commands.I will test the peocess.

0 Kudos

2,216 Views
gehariprasath
Contributor II

Hello

We are using the version "imx_5.4.24_2.1.0".  Below are the build instructions

IMAGE=nextgen-image
MACHINE=imx8mmddr4evk
DISTRO=fsl-imx-wayland

EULA=1 DISTRO=$DISTRO MACHINE=$MACHINE source imx-setup-release.sh -b build

cp ../sources/meta-tx-nextgen/files/$MACHINE/conf/* conf/

bitbake $IMAGE

I already attached the logs in this thread.

0 Kudos

2,210 Views
Zhiming_Liu
NXP TechSupport
NXP TechSupport

Hello,

You can try to follow the yocto.pdf to build the image.

 

https://www.nxp.com/docs/en/user-guide/IMXLXYOCTOUG.pdf

0 Kudos

2,286 Views
gehariprasath
Contributor II

Hello Zhiming

Thanks for the reply.

1. I have installed all the host machine dependencies by following the Yocto project user's guide from the following link

https://www.nxp.com/docs/en/user-guide/IMXLXYOCTOUG.pdf

2. I have seen the link where another person faced the same issue. The solution given to solve the issue i.e by adding IMAGE_FSTYPES = "ext4 wic.bz2" into the local.conf file. This change is already included in my local.conf file. I have attached my local.conf file in zip file attached.

3. I have attached the complete build log in attached zip file.

0 Kudos

2,267 Views
Zhiming_Liu
NXP TechSupport
NXP TechSupport

Hi,

We tested the build process before.The problem may in the process of repo sync.Some file received may not success.You can try to redo the sync process.

0 Kudos

2,260 Views
gehariprasath
Contributor II

Hello

I have issue 'repo sync' multiple times but I am facing the same issue.However, I could able to see the e2fsprogs-native binaries generated under the below path.

build/tmp/sysroots-components/x86_64/e2fsprogs-native/sbin
 
The PATH variable in the file "build/tmp/work/imx8mmddr4evk-poky-linux/nextgen-image/1.0-r0/temp/run.do_image_wic.21626" is set to the following which doesn't include the above path. 
 
export PATH="/home/hari/projects/tx-nextgen/linux-yocto-bsp/build/tmp/work/imx8mmddr4evk-poky-linux/nextgen-image/1.0-r0/recipe-sysroot/usr/bin/crossscripts:/home/hari/projects/tx-nextgen/linux-yocto-bsp/build/tmp/work/imx8mmddr4evk-poky-linux/nextgen-image/1.0-r0/recipe-sysroot/opt/fsl-imx-wayland/5.4-zeus/sysroots/x86_64-pokysdk-linux/usr/bin/crossscripts:/home/hari/projects/tx-nextgen/linux-yocto-bsp/build/tmp/work/imx8mmddr4evk-poky-linux/nextgen-image/1.0-r0/recipe-sysroot/usr/bin/crossscripts:/home/hari/projects/tx-nextgen/linux-yocto-bsp/build/tmp/work/imx8mmddr4evk-poky-linux/nextgen-image/1.0-r0/recipe-sysroot-native/usr/bin/python3-native:/home/hari/projects/tx-nextgen/linux-yocto-bsp/sources/poky/scripts:/home/hari/projects/tx-nextgen/linux-yocto-bsp/build/tmp/work/imx8mmddr4evk-poky-linux/nextgen-image/1.0-r0/recipe-sysroot-native/usr/bin/aarch64-poky-linux:/home/hari/projects/tx-nextgen/linux-yocto-bsp/build/tmp/work/imx8mmddr4evk-poky-linux/nextgen-image/1.0-r0/recipe-sysroot/usr/bin/crossscripts:/home/hari/projects/tx-nextgen/linux-yocto-bsp/build/tmp/work/imx8mmddr4evk-poky-linux/nextgen-image/1.0-r0/recipe-sysroot-native/usr/sbin:/home/hari/projects/tx-nextgen/linux-yocto-bsp/build/tmp/work/imx8mmddr4evk-poky-linux/nextgen-image/1.0-r0/recipe-sysroot-native/usr/bin:/home/hari/projects/tx-nextgen/linux-yocto-bsp/build/tmp/work/imx8mmddr4evk-poky-linux/nextgen-image/1.0-r0/recipe-sysroot-native/sbin:/home/hari/projects/tx-nextgen/linux-yocto-bsp/build/tmp/work/imx8mmddr4evk-poky-linux/nextgen-image/1.0-r0/recipe-sysroot-native/bin:/home/hari/projects/tx-nextgen/linux-yocto-bsp/sources/poky/bitbake/bin:/home/hari/projects/tx-nextgen/linux-yocto-bsp/build/tmp/hosttools"
 
0 Kudos

2,254 Views
Zhiming_Liu
NXP TechSupport
NXP TechSupport

Hi,

I mean you del the whole source code and download the source code again.Did your sync process had been interrupted?

0 Kudos

2,251 Views
gehariprasath
Contributor II

Hello

Actually I took the download's directory from a colleague to save time in downloading. I can try to delete and let the yocto system download the sources and give a build. 

0 Kudos

2,302 Views
gehariprasath
Contributor II

Update:

If I build bitbake wic-tools separately, the build is completed. If I build the final image though, I keep getting the same error.

0 Kudos

2,298 Views
Zhiming_Liu
NXP TechSupport
NXP TechSupport

Hi,

1.Make sure you have apt-get install all dependencies.(important)

2.You can see this simillar case and may people have this problem: https://community.nxp.com/t5/i-MX-Processors/SOLVED-ERROR-A-native-program-mkfs-ext4-required-to-bui... 

3.Give me your error log file, this error may caused by your bsp  source  incomplete.

Best Regards,

Zhiming