Attempting a Yocto Project build leads to the following build error:
⬢[user@toolbox build-xwayland-imx8mpevk]$ bitbake fsl-image-validation-imx
...
ERROR: nxp-wlan-sdk-git-r0 do_compile: oe_runmake failed
ERROR: nxp-wlan-sdk-git-r0 do_compile: Execution of '/home/user/imx-yocto-bsp_5.4.47-2.2.0/build-xwayland-imx8mpevk/tmp/work/aarch64-poky-linux/nxp-wlan-sdk/git-r0/temp/run.do_compile.3941835' failed with exit code 1:
/bin/sh: bc: command not found
make -C /lib/modules/5.9.11-100.fc32.x86_64/build M=/home/user/imx-yocto-bsp_5.4.47-2.2.0/build-xwayland-imx8mpevk/tmp/work/aarch64-poky-linux/nxp-wlan-sdk/git-r0/git/mxm_wifiex/wlan_src modules
make[1]: *** /lib/modules/5.9.11-100.fc32.x86_64/build: No such file or directory. Stop.
make: *** [Makefile:412: default] Error 2
WARNING: /home/user/imx-yocto-bsp_5.4.47-2.2.0/build-xwayland-imx8mpevk/tmp/work/aarch64-poky-linux/nxp-wlan-sdk/git-r0/temp/run.do_compile.3941835:1 exit 1 from 'exit 1'
ERROR: Logfile of failure stored in: /home/user/imx-yocto-bsp_5.4.47-2.2.0/build-xwayland-imx8mpevk/tmp/work/aarch64-poky-linux/nxp-wlan-sdk/git-r0/temp/log.do_compile.3941835
Log data follows:
| DEBUG: Executing shell function do_compile
| NOTE: make -j 56 build
| /bin/sh: bc: command not found
| make -C /lib/modules/5.9.11-100.fc32.x86_64/build M=/home/user/imx-yocto-bsp_5.4.47-2.2.0/build-xwayland-imx8mpevk/tmp/work/aarch64-poky-linux/nxp-wlan-sdk/git-r0/git/mxm_wifiex/wlan_src modules
| make[1]: *** /lib/modules/5.9.11-100.fc32.x86_64/build: No such file or directory. Stop.
| make: *** [Makefile:412: default] Error 2
| ERROR: oe_runmake failed
| WARNING: /home/user/imx-yocto-bsp_5.4.47-2.2.0/build-xwayland-imx8mpevk/tmp/work/aarch64-poky-linux/nxp-wlan-sdk/git-r0/temp/run.do_compile.3941835:1 exit 1 from 'exit 1'
| ERROR: Execution of '/home/user/imx-yocto-bsp_5.4.47-2.2.0/build-xwayland-imx8mpevk/tmp/work/aarch64-poky-linux/nxp-wlan-sdk/git-r0/temp/run.do_compile.3941835' failed with exit code 1:
| /bin/sh: bc: command not found
| make -C /lib/modules/5.9.11-100.fc32.x86_64/build M=/home/user/imx-yocto-bsp_5.4.47-2.2.0/build-xwayland-imx8mpevk/tmp/work/aarch64-poky-linux/nxp-wlan-sdk/git-r0/git/mxm_wifiex/wlan_src modules
| make[1]: *** /lib/modules/5.9.11-100.fc32.x86_64/build: No such file or directory. Stop.
| make: *** [Makefile:412: default] Error 2
| WARNING: /home/user/imx-yocto-bsp_5.4.47-2.2.0/build-xwayland-imx8mpevk/tmp/work/aarch64-poky-linux/nxp-wlan-sdk/git-r0/temp/run.do_compile.3941835:1 exit 1 from 'exit 1'
|
ERROR: Task (/home/user/imx-yocto-bsp_5.4.47-2.2.0/sources/meta-imx/meta-bsp/recipes-connectivity/nxp-wlan-sdk/nxp-wlan-sdk_git.bb:do_compile) failed with exit code '1'
NOTE: Tasks Summary: Attempted 4029 tasks of which 0 didn't need to be rerun and 1 failed.
Summary: 1 task failed:
/home/user/imx-yocto-bsp_5.4.47-2.2.0/sources/meta-imx/meta-bsp/recipes-connectivity/nxp-wlan-sdk/nxp-wlan-sdk_git.bb:do_compile
Summary: There were 10 WARNING messages shown.
Summary: There were 2 ERROR messages shown, returning a non-zero exit code.
OK, fixed it. Use this how-to for modifying nxp-wlan-sdk_git.bb: https://www.yoctoproject.org/docs/1.6.1/kernel-dev/kernel-dev.html#incorporating-out-of-tree-modules
This patch works for me.
This is the real error:
make[1]: *** /lib/modules/5.9.11-100.fc32.x86_64/build: No such file or directory. Stop.
The Makefile tries to use the host machine's Linux sources while it ought to build against the target Linux. I'm in the middle of finding out what needs to be added to the recipe to use the target kernel.
I never got any further comments from NXP. However, as stated earlier:
> The correct way to achieve this would be to properly add bc-native to the DEPENDS of any and all recipes requiring any such.
OK?
Anybody from NXP dear to comment?
Hi marcelziswiler,
You need install all needed packages as yocto build user guide.
/bin/sh: bc: command not found
It shows that you did not install bc package.
Best Regards
Zhiming
No, bc is not and never was a build host requirement. Please refer to section 21.2. Required Packages for the Build Host of the Yocto Project Reference Manual aka Mega-Manual:
The correct way to achieve this would be to properly add bc-native to the DEPENDS of any and all recipes requiring any such. Thanks!