我正试图创建一个yocto配方,在我的raspberrypi 4上添加gnu radio,但在生成图像时遇到了以下错误:
| ERROR: ExecutionError('/home/norian/Yocto/build-rpi/tmp/work/cortexa72-poky-linux/boost/1.75.0-r0/temp/run.do_compile.503884', 1, None, None)
ERROR: Task (/home/norian/Yocto/poky/meta/recipes-support/boost/boost_1.75.0.bb:do_compile) failed with exit code '1'
这就是bitbake-layers show-layers
命令返回给我的内容:
layer path priority
==========================================================================
meta /home/norian/Yocto/poky/meta 5
meta-poky /home/norian/Yocto/poky/meta-poky 5
meta-yocto-bsp /home/norian/Yocto/poky/meta-yocto-bsp 5
meta-raspberrypi /home/norian/Yocto/poky/meta-raspberrypi 9
meta-oe /home/norian/Yocto/meta-openembedded/meta-oe 6
meta-python /home/norian/Yocto/meta-openembedded/meta-python 7
meta-filesystems /home/norian/Yocto/meta-openembedded/meta-filesystems 6
meta-networking /home/norian/Yocto/meta-openembedded/meta-networking 5
meta-qt5 /home/norian/Yocto/meta-openembedded/meta-qt5 7
meta-sdr /home/norian/Yocto/meta-openembedded/meta-sdr 5
meta-my-layer /home/norian/Yocto/meta-my-layer 6
我的食谱在meta-my层中,被称为radio-image.bb
以下是其内容:
SUMMARY = "A small image just capable of allowing a device to boot."
IMAGE_LINGUAS = " "
LICENSE = "MIT"
inherit core-image
CORE_IMAGE_EXTRA_INSTALL = "
packagegroup-sdr-base-extended
packagegroup-sdr-base-debug
packagegroup-sdr-base-devel
packagegroup-sdr-base-python
packagegroup-sdr-python-extended
packagegroup-sdr-gnuradio-base
packagegroup-core-eclipse-debug
"
IMAGE_INSTALL += "nano"
CONF_VERSION = "1"
ENABLE_UART="1"
我复制了gnradio-image.bb配方的内容,它来自meta sdr。我还将文件夹分组复制到我的食谱中。
我使用的是Ubuntu 20.04。
我的poky版本是:
DISTRO_VERSION = "3.3.4"
DISTRO_CODENAME = "hardknott"
你能向我解释一下boost的用途以及如何更正它的编译吗?
编辑:我在boost编译日志文件中发现以下错误:
{standard input}: Assembler messages:
{standard input}:4183: Warning: end of file not at end of a line; newline inserted
{standard input}:4801: Error: unknown pseudo-op: `.l'
{standard input}: Error: open CFI at the end of file; missing .cfi_endproc directive
aarch64-poky-linux-g++: fatal error: Killed signal terminated program cc1plus
compilation terminated.
{standard input}: Assembler messages:
{standard input}: Error: open CFI at the end of file; missing .cfi_endproc directive
aarch64-poky-linux-g++: fatal error: Killed signal terminated program cc1plus
compilation terminated.
gcc.compile.c++ /home/norian/Yocto/build-rpi/tmp/work/cortexa72-poky-linux/boost/1.75.0-r0/build/boost/bin.v2/libs/log/build/f79941b6f0ebe85fc9fba0b2ec31feac/syslog_backend.o
"aarch64-poky-linux-g++" "-mcpu=cortex-a72" "-march=armv8-a+crc+crypto" "-Wl,-O1" "-Wl,--hash-style=gnu" "-Wl,--as-needed" "-Wl,-z,relro,-z,now" "-fstack-protector-strong" "-O2" "-D_FORTIFY_SOURCE=2" "-Wformat" "-Wformat-security" "-Werror=format-security" "--sysroot=/home/norian/Yocto/build-rpi/tmp/work/cortexa72-poky-linux/boost/1.75.0-r0/recipe-sysroot" -ftemplate-depth-1024 -fvisibility-inlines-hidden -O2 -pipe -g -feliminate-unused-debug-types -fmacro-prefix-map=/home/norian/Yocto/build-rpi/tmp/work/cortexa72-poky-linux/boost/1.75.0-r0=/usr/src/debug/boost/1.75.0-r0 -fdebug-prefix-map=/home/norian/Yocto/build-rpi/tmp/work/cortexa72-poky-linux/boost/1.75.0-r0=/usr/src/debug/boost/1.75.0-r0 -fdebug-prefix-map=/home/norian/Yocto/build-rpi/tmp/work/cortexa72-poky-linux/boost/1.75.0-r0/recipe-sysroot= -fdebug-prefix-map=/home/norian/Yocto/build-rpi/tmp/work/cortexa72-poky-linux/boost/1.75.0-r0/recipe-sysroot-native= -fvisibility-inlines-hidden -fPIC -pthread -O3 -finline-functions -Wno-inline -Wall -fvisibility=hidden -fno-strict-aliasing -DBOOST_ALL_NO_LIB=1 -DBOOST_ATOMIC_DYN_LINK=1 -DBOOST_CHRONO_DYN_LINK=1 -DBOOST_FILESYSTEM_DYN_LINK=1 -DBOOST_LOG_BUILDING_THE_LIB=1 -DBOOST_LOG_DLL -DBOOST_LOG_HAS_PTHREAD_MUTEX_ROBUST -DBOOST_LOG_USE_NATIVE_SYSLOG -DBOOST_LOG_WITHOUT_DEBUG_OUTPUT -DBOOST_LOG_WITHOUT_EVENT_LOG -DBOOST_SPIRIT_USE_PHOENIX_V3=1 -DBOOST_THREAD_BUILD_DLL=1 -DBOOST_THREAD_DONT_USE_CHRONO=1 -DBOOST_THREAD_POSIX -DBOOST_THREAD_USE_DLL=1 -DNDEBUG -D_XOPEN_SOURCE=600 -D__STDC_CONSTANT_MACROS -I"." -I"libs/log/src" -c -o "/home/norian/Yocto/build-rpi/tmp/work/cortexa72-poky-linux/boost/1.75.0-r0/build/boost/bin.v2/libs/log/build/f79941b6f0ebe85fc9fba0b2ec31feac/syslog_backend.o" "libs/log/src/syslog_backend.cpp"
...skipped <p/home/norian/Yocto/build-rpi/tmp/work/cortexa72-poky-linux/boost/1.75.0-r0/build/boost/bin.v2/libs/log/build/f79941b6f0ebe85fc9fba0b2ec31feac>libboost_log.so.1.75.0 for lack of <p/home/norian/Yocto/build-rpi/tmp/work/cortexa72-poky-linux/boost/1.75.0-r0/build/boost/bin.v2/libs/log/build/f79941b6f0ebe85fc9fba0b2ec31feac>text_file_backend.o...
...skipped <p/home/norian/Yocto/build-rpi/tmp/work/cortexa72-poky-linux/boost/1.75.0-r0/boost_1_75_0/stage/lib>libboost_log.so.1.75.0 for lack of <p/home/norian/Yocto/build-rpi/tmp/work/cortexa72-poky-linux/boost/1.75.0-r0/build/boost/bin.v2/libs/log/build/f79941b6f0ebe85fc9fba0b2ec31feac>libboost_log.so.1.75.0...
...failed updating 2 targets...
WARNING: exit code 1 from a shell command.
ERROR: ExecutionError('/home/norian/Yocto/build-rpi/tmp/work/cortexa72-poky-linux/boost/1.75.0-r0/temp/run.do_compile.503884', 1, None, None)
我认为这是RAM问题,请检查此处和此处。
我建议你先单独编译boost:
bitbake boost -c compile
或者减少构建线程和并行编译进程的数量:
- local.conf
BB_NUMBER_THREADS = "2"
PARALLEL_MAKE = "-j 1"
你可以根据自己的喜好更改数字(对于线程,它的最大值是你的cpu内核(
尝试在local.conf
和:中添加PARALLEL_MAKE = "-j 1"
bitbake boost -c compile