nxp-imx / meta-nxp-connectivity

The layer files for integrate the Matter and OpenThread into i.MX Yocto Linux
Other
33 stars 15 forks source link

bitbake error : meta-matter/recipes-matter/matter/matter.bb:do_unpack #7

Open Vardhman-Modi opened 1 year ago

Vardhman-Modi commented 1 year ago

Hello Team,

I want to build Linux with Matter support. I am following NXP Yocto recipes meta-matter I am using Ubuntu 20.04.5 LTS host machine with kernel version.

uname -a
Linux ahmcpu2255 5.15.0-60-generic #66~20.04.1-Ubuntu SMP Wed Jan 25 09:41:30 UTC 2023 x86_64 x86_64 x86_64 GNU/Linux

I have performed followed following steps :

$ mkdir ~/bin
$ curl http://commondatastorage.googleapis.com/git-repo-downloads/repo > ~/bin/repo
$ chmod a+x ~/bin/repo
$ export PATH=${PATH}:~/bin

$ mkdir ${MY_YOCTO} # this directory will be the top directory of the Yocto source code
$ cd ${MY_YOCTO}
$ repo init -u https://github.com/nxp-imx/imx-manifest -b imx-linux-kirkstone -m imx-5.15.52-2.1.0.xml
$ repo sync

Then integrate the meta-matter recipe into the Yocto code base.

$ cd ${MY_YOCTO}/sources/
$ git clone https://github.com/NXPmicro/meta-matter.git

Verifying: Default Python of the Linux host is Python2.

$ python --version
  Python 2.7.18

Create the build directory for iMX8M Mini EVK.

#For i.MX8M Mini EVK:
$ MACHINE=imx8mmevk DISTRO=fsl-imx-xwayland source sources/meta-matter/tools/imx-iot-setup.sh bld-xwayland-imx8mm

Build Multi Media Yocto image for iMX8M Mini EVK.

bitbake imx-image-multimedia

But I am facing following error:

ERROR: Logfile of failure stored in: /home/einfochips/projects/matter/iMX8/imx8_meta_matter_repo/yocto/bld-xwayland-imx8mm/tmp/work/armv8a-poky-linux/matter/1.0-r0/temp/log.do_unpack.21908
ERROR: Task (/home/einfochips/projects/matter/iMX8/imx8_meta_matter_repo/yocto/sources/meta-matter/recipes-matter/matter/matter.bb:do_unpack) failed with exit code '1'
NOTE: Tasks Summary: Attempted 7025 tasks of which 6645 didn't need to be rerun and 1 failed.

Summary: 1 task failed:
  /home/einfochips/projects/matter/iMX8/imx8_meta_matter_repo/yocto/sources/meta-matter/recipes-matter/matter/matter.bb:do_unpack
Summary: There were 13 WARNING messages.
Summary: There was 1 ERROR message, returning a non-zero exit code.

Kindly help me on this please.

Build_Error_Log.txt

nandra commented 1 year ago

@Vardhman-Modi seems you had some issues with network: dial tcp: lookup github.com: Temporary failure in name resolution

nandra commented 1 year ago

@Vardhman-Modi please add do_unpack[network] = 1 to bbappend file and it should work. Sorry for not realizing that before.

nandra commented 1 year ago

Also what is necessary is to add do_compile[network] = 1 to not fail in compile phase also.

Vardhman-Modi commented 1 year ago

Hello issue resolved with help of https://stackoverflow.com/questions/42019529/how-to-clone-pull-a-git-repository-ignoring-lfs

git config --global filter.lfs.smudge "git-lfs smudge -- %f"
git config --global filter.lfs.process "git-lfs filter-process"

Thank you, Vadhman Modi

Scott31393 commented 1 year ago

Hello :) I'm able to solve this issue with the following steps:

Run the following cmds:

git config --global filter.lfs.smudge "git-lfs smudge -- %f"
git config --global filter.lfs.process "git-lfs filter-process"

Then create a matter.bbappend with the following entries:

do_unpack[network] = "1"
do_compile[network] = "1"

Thanks @Vardhman-Modi / @nandra, Tommaso