gpt4 book ai didi

linux - 使用 scons.py 添加配方的 Yocto do_package() 语法

转载 作者:塔克拉玛干 更新时间:2023-11-03 01:35:54 25 4
gpt4 key购买 nike

我正在尝试将 libjsoncpp 包包含到我的 Yocto 构建中,该包当前未包含在 Yocto 的包列表中。我从 http://sourceforge.net/projects/jsoncpp/files/jsoncpp/ 下载了源文件.该软件包不附带 INSTALL 脚本,而是使用 scons.py。我如何将安装脚本写成食谱?

谢谢

最佳答案

我从那个链接下载了 jsoncpp-src-0.6.0-rc2.tar 并没有看到任何 scons.py,尽管 README 说它应该在那里。不过,我确实查看了其中包含的 SConstruct,这是主要的 SCons 构建脚本。

为了能够使用它,您需要(显然 :))安装 Python 和 SCons,如 README 中所示:(我会推荐最新版本的 SCons,即 2.3.0,希望它兼容)

  • Building/Testing: =================

JsonCpp uses Scons (http://www.scons.org) as a build system. Scons requires python to be installed (http://www.python.org).

You download scons-local distribution from the following url: http://sourceforge.net/projects/scons/files/scons-local/1.2.0/

Unzip it in the directory where you found this README file. scons.py Should be at the same level as README.

python scons.py platform=PLTFRM [TARGET]

然后您应该能够从您的脚本中调用 scons,如下所示:

$ scons -f <path to json>/SConstruct platform=linux-gcc

用您的平台替换 linux-gcc。通读 SConstruct 并搜索 platform 以查看所有可能性。

关于linux - 使用 scons.py 添加配方的 Yocto do_package() 语法,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/19060372/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com