3. yocto question

关键词: yocto question

记录使用yocto过程中遇到的问题

主要内容:

  • question

文档参考:

最新文档 https://taotaodiy-yocto.readthedocs.io/en/latest/yocto/etc-question.html

yocto-taotaodiy

3.1. 常用命令

install –help

3.2. 常见错误

sh

ERROR: linux-imx-4.14.98-r0 do_package_write_deb: Error executing a python function in exec_python_func() autogenerated:

The stack trace of python calls that resulted in this exception/failure was: File: ‘exec_python_func() autogenerated’, lineno: 2, function: <module>

0001:

*** 0002:do_package_deb(d)

0003:

File: ‘/home/bingbing/yocto/imx-yocto-bsp/sources/poky/meta/classes/package_deb.bbclass’, lineno: 102, function: do_package_deb

0098: 0099: os.chdir(oldcwd) 0100: 0101: if error:

*** 0102: raise error

0103:} 0104:do_package_deb[vardeps] += “deb_write_pkg” 0105:do_package_deb[vardepsexclude] = “BB_NUMBER_THREADS” 0106:

Exception: subprocess.CalledProcessError: Command ‘PATH=”/home/bingbing/yocto/imx-yocto-bsp/sources/poky/scripts:/home/bingbing/yocto/imx-yocto-bsp/build/tmp/work/imx6ull14x14evk-poky-linux-gnueabi/linux-imx/4.14.98-r0/recipe-sysroot-native/usr/bin/arm-poky-linux-gnueabi:/home/bingbing/yocto/imx-yocto-bsp/build/tmp/work/imx6ull14x14evk-poky-linux-gnueabi/linux-imx/4.14.98-r0/recipe-sysroot/usr/bin/crossscripts:/home/bingbing/yocto/imx-yocto-bsp/build/tmp/work/imx6ull14x14evk-poky-linux-gnueabi/linux-imx/4.14.98-r0/recipe-sysroot-native/usr/sbin:/home/bingbing/yocto/imx-yocto-bsp/build/tmp/work/imx6ull14x14evk-poky-linux-gnueabi/linux-imx/4.14.98-r0/recipe-sysroot-native/usr/bin:/home/bingbing/yocto/imx-yocto-bsp/build/tmp/work/imx6ull14x14evk-poky-linux-gnueabi/linux-imx/4.14.98-r0/recipe-sysroot-native/sbin:/home/bingbing/yocto/imx-yocto-bsp/build/tmp/work/imx6ull14x14evk-poky-linux-gnueabi/linux-imx/4.14.98-r0/recipe-sysroot-native/bin:/home/bingbing/yocto/imx-yocto-bsp/sources/poky/bitbake/bin:/home/bingbing/yocto/imx-yocto-bsp/build/tmp/hosttools” dpkg-deb -b /home/bingbing/yocto/imx-yocto-bsp/build/tmp/work/imx6ull14x14evk-poky-linux-gnueabi/linux-imx/4.14.98-r0/packages-split/kernel-module-snd-usbmidi-lib-4.14.98-imx_4.14.98_2.0.0_ga+g5d6cbeafb80c /home/bingbing/yocto/imx-yocto-bsp/build/tmp/work/imx6ull14x14evk-poky-linux-gnueabi/linux-imx/4.14.98-r0/deploy-debs/imx6ull14x14evk’ returned non-zero exit status 2.

Subprocess output: dpkg-deb: error: package name has characters that aren’t lowercase alphanums or ‘-+.’

ERROR: linux-imx-4.14.98-r0 do_package_write_deb: Function failed: do_package_deb ERROR: Logfile of failure stored in: /home/bingbing/yocto/imx-yocto-bsp/build/tmp/work/imx6ull14x14evk-poky-linux-gnueabi/linux-imx/4.14.98-r0/temp/log.do_package_write_deb.21031 ERROR: Task (/home/bingbing/yocto/imx-yocto-bsp/sources/meta-fsl-bsp-release/imx/meta-bsp/recipes-kernel/linux/linux-imx_4.14.98.bb:do_package_write_deb) failed with exit code ‘1’ NOTE: Tasks Summary: Attempted 3464 tasks of which 3463 didn’t need to be rerun and 1 failed.

Summary: 1 task failed: /home/bingbing/yocto/imx-yocto-bsp/sources/meta-fsl-bsp-release/imx/meta-bsp/recipes-kernel/linux/linux-imx_4.14.98.bb:do_package_write_deb Summary: There were 2 WARNING messages shown. Summary: There were 2 ERROR messages shown, returning a non-zero exit code.

参考

https://community.nxp.com/t5/i-MX-Processors/Build-error-after-changing-PACKAGE-CLASSES-to-package-deb/m-p/769751?commentID=1026435

https://community.nxp.com/t5/i-MX-Processors-Knowledge-Base/Yocto-Project-Package-Management-smart/ta-p/1106337

3.3. Either fix the cause of this error or at your own risk disable the checker

ERROR: OE-core’s config sanity checker detected a potential misconfiguration.

Either fix the cause of this error or at your own risk disable the checker (see sanity.conf). Following is the list of potential problems / advisories:

DISTRO ‘fsl-imx-X11’ not found. Please set a valid DISTRO in your local.conf

Summary: There was 1 ERROR message shown, returning a non-zero exit code.

3.4. 依赖某个库,但又不知道这个库属于那个包

ERROR: installnes-1.0.1-r0 do_package_qa: QA Issue: /usr/share/installnes-1.0.1/InfoNes contained in package installnes requires libz.so.1, but no providers found in RDEPENDS_installnes? [file-rdeps] ERROR: installnes-1.0.1-r0 do_package_qa: QA run found fatal errors. Please consider fixing them. ERROR: Logfile of failure stored in: /home/bingbing/RaspberryPi/openstlinux-5.4-dunfell-mp1-20-11-12/build-openstlinuxeglfs-stm32mp1/tmp-glibc/work/cortexa7t2hf-neon-vfpv4-ostl-linux-gnueabi/installnes/1.0.1-r0/temp/log.do_package_qa.3018 ERROR: Task (/home/bingbing/RaspberryPi/openstlinux-5.4-dunfell-mp1-20-11-12/layers/meta-st/meta-st-openstlinux/recipes-qt/qt5/installnes_1.0.1.bb:do_package_qa) failed with exit code ‘1’ NOTE: Tasks Summary: Attempted 6668 tasks of which 6667 didn’t need to be rerun and 1 failed.

https://stackoverflow.com/questions/64404444/tracking-down-missing-rdepends-items

oe-pkgdata-util find-path ‘libz.so’

zlib: /lib/libz.so.1 zlib: /lib/libz.so.1.2.11 zlib-dbg: /lib/.debug/libz.so.1.2.11 zlib-dev: /usr/lib/libz.so …

3.5. do_compile

ERROR: Task (/home/bingbing/yocto-project/poky/meta/recipes-devtools/cmake/cmake-native_3.18.2.bb:do_compile) failed with exit code ‘1’

3.6. max_user_watches

ERROR: No space left on device or exceeds fs.inotify.max_user_watches? | ETA: –:–:– ERROR: To check max_user_watches: sysctl -n fs.inotify.max_user_watches. ERROR: To modify max_user_watches: sysctl -n -w fs.inotify.max_user_watches=<value>. ERROR: Root privilege is required to modify max_user_watches.

修改 /proc/sys/fs/inotify/max_user_watches

sysctl -w fs.inotify.max_user_watches=”99999999”