【发布时间】:2021-10-19 02:29:40
【问题描述】:
我是 Yocto 的新手,所以我可能有一些错误和误解,如果你能提供帮助,我不胜感激。
所以,我想在我的自定义映像中添加一个新包(tar 文件)。
我已按照手册中的步骤和步骤以及一些在线说明进行操作。运行时:“bitbake mylayer”,图层构建良好,但构建图像时出现此错误,这是日志文件:
DEBUG: Executing python function rootfs_deb_bad_recommendations
DEBUG: Python function rootfs_deb_bad_recommendations finished
DEBUG: Executing python function extend_recipe_sysroot
NOTE: Installed into sysroot: []
NOTE: Skipping as already exists in sysroot: ['depmodwrapper-cross', 'apt-native', 'dpkg-native', 'pseudo-native', 'update-rc.d-native', 'prelink-native', 'makedevs-native', 'ldconfig-native', 'opkg-util$
DEBUG: Python function extend_recipe_sysroot finished
DEBUG: Executing python function do_rootfs
NOTE: ###### Generate rootfs #######
NOTE: Installing the following packages: apt busybox copy-uefiimg-to-sda coreutils dpkg e2fsprogs-resize2fs libfontconfig1 libfreetype6 libglib-2.0-0 gptfdisk libjemalloc2 kernel-module-axi-dma-sensor ku$
ERROR: Unable to install packages.
Reading package lists...
Building dependency tree...
Reading state information...
Package mypackage is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source
E: Package 'mylayer' has no installation candidate
DEBUG: Python function do_rootfs finished
ERROR: Function failed: do_rootfs
这里是 mylayer.bb:
SUMMARY = ""
LICENSE = "CLOSE"
FILESEXTRAPATHS_prepend := "${THISDIR}/files:"
SRC_URI += "file://mypackage.tar"
另外,我已经在 conf/local.conf 中包含了这个包:
IMAGE_INSTALL_append += " mylayer"
所以除了想办法解决这个问题之外,我还有一些问题:
-
我读过一些 .bb 的例子,他们提到了 LIC_FILES_CHKSUM。 mypackage.tar.gz是为设备安装平台的包,对源码了解不多,不知道是否需要包含license?或者如何知道这个包需要许可证才能安装?
-
在我在网上找到的一些答案中,有人说我需要包含
PACKAGE_CLASSES ?= "package_deb"(他们想安装 .deb 文件),所以在我的情况下我可能需要PACKAGE_CLASSES ?= "package.tar"对吗?我试过改变变量,但还是不成功。 -
mypackage.tar 包含一些 deb 文件。如果我无法安装 mypackage.tar,我可以安装这些 .deb 文件吗?我可以把它都放在 mylayer.bb 中吗?
在此先感谢您,我已经尽力研究了很多文件,但我很困惑,还有大量信息需要消化。
【问题讨论】:
标签: yocto yocto-recipe