meson 无法从源代码构建 systemd:"getent" 未找到
meson can't build systemd from source: "getent" not found
我正在交叉编译环境 (yocto sumo
) 中从源代码编译 systemd
版本 237。
根据 bitbake 配方,systemd 是由 meson 构建的。
我将介子版本升级到 0.49.2(从 warrior
复制),因为我的其他食谱需要该版本。
当我执行 bitbake systemd
时,出现此错误:
meson.build:678:0: ERROR: Program or command 'getent' not found or not executable
我打开了 meson.build
,它有:
getent_result = run_command('getent', 'passwd', '65534')
if getent_result.returncode() == 0
...
endif
我搜索了一下,好像getent
是标准命令,在我的building host(Ubuntu 16)中,可以运行:
getent --version
getent (Ubuntu GLIBC 2.23-0ubuntu11.2) 2.23
所以 getent
确实存在,至少在我的主机中 Ubuntu。
那mison问题怎么解决呢?
谢谢
您可以通过以下方式从主机添加它:
HOSTTOOLS += "getent"
然而,OE-Core 并没有将其作为标准,而 systemd 构建看起来可以正常工作,所以我有点困惑为什么您会达到要求。
我正在交叉编译环境 (yocto sumo
) 中从源代码编译 systemd
版本 237。
根据 bitbake 配方,systemd 是由 meson 构建的。
我将介子版本升级到 0.49.2(从 warrior
复制),因为我的其他食谱需要该版本。
当我执行 bitbake systemd
时,出现此错误:
meson.build:678:0: ERROR: Program or command 'getent' not found or not executable
我打开了 meson.build
,它有:
getent_result = run_command('getent', 'passwd', '65534')
if getent_result.returncode() == 0
...
endif
我搜索了一下,好像getent
是标准命令,在我的building host(Ubuntu 16)中,可以运行:
getent --version
getent (Ubuntu GLIBC 2.23-0ubuntu11.2) 2.23
所以 getent
确实存在,至少在我的主机中 Ubuntu。
那mison问题怎么解决呢?
谢谢
您可以通过以下方式从主机添加它:
HOSTTOOLS += "getent"
然而,OE-Core 并没有将其作为标准,而 systemd 构建看起来可以正常工作,所以我有点困惑为什么您会达到要求。