5

我按照 Daiane Anolini 编写的教程安装了 Yocto 1.6 并运行 bitbake 来设置工具链。虽然我在 $SDKTARGETSYSROOT/usr/lib 下看到了大多数 boost 库,但似乎没有 libboost_log.a 或 libboost_log_setup.a。我相信这些是在 Boost 1.55 中引入的,并且 Yocto 1.6 已经迁移到 Boost 1.55。他们不应该在那里,还是我做错了什么?

我的.../fsl-community-bsp/build/conf/local.conf:

BB_NUMBER_THREADS ?= "${@oe.utils.cpu_count()}"
PARALLEL_MAKE ?= "-j ${@oe.utils.cpu_count()}"
MACHINE ??= 'imx6qsabresd'
DISTRO ?= 'poky'
PACKAGE_CLASSES ?= "package_rpm"
EXTRA_IMAGE_FEATURES = "debug-tweaks tools-sdk"
USER_CLASSES ?= "buildstats image-mklibs image-prelink"
PATCHRESOLVE = "noop"
BB_DISKMON_DIRS = "\
STOPTASKS,${TMPDIR},1G,100K \
STOPTASKS,${DL_DIR},1G,100K \
STOPTASKS,${SSTATE_DIR},1G,100K \
ABORT,${TMPDIR},100M,1K \
ABORT,${DL_DIR},100M,1K \
ABORT,${SSTATE_DIR},100M,1K" 
PACKAGECONFIG_pn-qemu-native = "sdl"
PACKAGECONFIG_pn-nativesdk-qemu = "sdl"
ASSUME_PROVIDED += "libsdl-native"
CONF_VERSION = "1"

BB_NUMBER_THREADS = '1'
PARALLEL_MAKE = '-j 1'

DL_DIR ?= "${BSPDIR}/downloads/"
ACCEPT_FSL_EULA = ""


CORE_IMAGE_EXTRA_INSTALL += "boost"
4

2 回答 2

5

正确的方法是扩展现有的配方。事实上,您通常从不直接更改第 3 方配方。这意味着,您正在创建自己的“recipes-support/boost/”文件夹,其中包含一个名为“boost_%.bbappend”的文件。'%' 表示不感兴趣的增强版本。'bbappend' 意味着你扩展了现有的 boost-recipe。该文件仅包含一行:

 BOOST_LIBS += " log"
于 2015-08-10T06:49:25.483 回答
1

为了添加日志库,您应该编辑 boost 配方文件。在例中,您应该编辑 boost.inc。要添加 log、atomic 和 loace 库,请替换

BOOST_LIBS = "\ date_time \ filesystem \ graph \ iostreams \ program_options \ regex \ serialization \ signals \ system \ test \ thread \ "

BOOST_LIBS = "\
date_time \
filesystem \
graph \
iostreams \
program_options \
regex \
serialization \
signals \
system \
test \
thread \
log \
atomic \
locale
"
于 2014-10-29T13:35:38.500 回答