为什么yocto scipy食谱需要明确设置python3?怎么样?

问题描述 投票:0回答:2

我有一个构建scipy的方法,可以很好地解析,bitbake开始构建,但是python3不符合版本要求。它以

退出
| DEBUG: Executing shell function do_configure
| Traceback (most recent call last):
|   File "setup.py", line 31, in <module>
|     raise RuntimeError("Python version >= 3.5 required.")
| RuntimeError: Python version >= 3.5 required.
| WARNING: exit code 1 from a shell command.
| ERROR: Function failed: do_configure (log file is located at /home/marius/mender-qemu/build/tmp/work/core2-64-poky-linux/python3-scipy/1.4.1-r0/temp/log.do_configure.30478)

我成功构建了其他python3软件包,可以将它们导入运行映像中。您还可以从路径中看到使用了python3,并且该图像在python3.5上运行。我正在使用thud

为了完整起见,这里是食谱。我也尝试显式添加依赖项(numpy),但这没有任何效果。

SUMMARY = "Scipy summary to be filled"
DESCRIPTION = "Scientific computing"
PYPI_PACKAGE = "scipy"

LICENSE = "BSD"
LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=011ccf01b7e0590d9435a864fc6a4d2b"

SRC_URI[md5sum] = "3a97689656f33f67614000459ec08585"
SRC_URI[sha256sum] = "dee1bbf3a6c8f73b6b218cb28eed8dd13347ea2f87d572ce19b289d6fd3fbc59"

这是python-scipy.inc

inherit setuptools3 distutils
require python-scipy.inc

而且,我试图添加inherit python3native无效。

我的问题是:如何显式设置python3来构建此配方?

python yocto bitbake
2个回答
0
投票

我的猜测是,您在运行主机(构建Yocto的系统)上需要python3的情况下,运行python脚本setup.py作为构建的一部分。

您可以这样安装:

sudo apt-get install python3

0
投票

简单而明显的解决方案是使用inherit distutils3而不是inherit distutils

© www.soinside.com 2019 - 2024. All rights reserved.