运行 petalinux-build 时未找到版本“GLIBC_2.32”错误
Posted
技术标签:
【中文标题】运行 petalinux-build 时未找到版本“GLIBC_2.32”错误【英文标题】:version `GLIBC_2.32' not found error when running petalinux-build 【发布时间】:2022-01-10 13:01:30 【问题描述】:我正在尝试构建 PetaLinux 映像,如下所述:tutorial。
为了构建它,我使用的是 Fedora 33,它不受官方支持,但通常有解决方法。
我在使用命令 petalinux-build
(第 3 步)时遇到问题,经过一些计算后,它会在终端上打印一个很长的日志,特别说明:
Subprocess output:
/home/MY_USER/path/Project/xilinx-zc702-2018.2/build/tmp/work/cortexa9hf-neon-xilinx-linux-gnueabi/linux-libc-headers/4.12-r0/recipe-sysroot-native/usr/lib/rpm/rpmdeps:
/home/MY_USER/path/Project/xilinx-zc702-2018.2/build/tmp/sysroots-uninative/x86_64-linux/lib/libc.so.6: version `GLIBC_2.32' not found (required by /lib64/libgomp.so.1)
但是,如果我运行 ldd --version
,我会得到:
ldd (GNU libc) 2.32
Copyright (C) 2020 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
Written by Roland McGrath and Ulrich Drepper.
如果我运行/lib/libc.so.6
,我会得到:
GNU C Library (GNU libc) stable release version 2.32.
Copyright (C) 2020 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.
There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A
PARTICULAR PURPOSE.
Compiled by GNU CC version 10.3.1 20210422 (Red Hat 10.3.1-1).
libc ABIs: UNIQUE IFUNC ABSOLUTE
For bug reporting instructions, please see:
<https://www.gnu.org/software/libc/bugs.html>.
所以在我看来,我确实安装了正确版本的 glibc,所以有什么问题?
这是完整的错误输出,glibc 部分在“子进程输出”下:
ERROR: xtrans-1_1.3.5-r0 do_fetch: Taskhash mismatch 5ee34dd31a0dd2a70bfb8dddb8e1777f versus e43051180f334754f374d0bd97e81203 for /home/MY_USER/path/Project/PetaLinux/components/yocto/source/arm/layers/core/meta/recipes-graphics/xorg-lib/xtrans_1.3.5.bb.do_fetch
ERROR: Taskhash mismatch 5ee34dd31a0dd2a70bfb8dddb8e1777f versus e43051180f334754f374d0bd97e81203 for /home/MY_USER/path/Project/PetaLinux/components/yocto/source/arm/layers/core/meta/recipes-graphics/xorg-lib/xtrans_1.3.5.bb.do_fetch
ERROR: base-passwd-3.5.29-r0 do_fetch: Taskhash mismatch c3837ed788613b3e1c7d4861734cdb8a versus a4b211e338ce900b232a6e2c185111c3 for /home/MY_USER/path/Project/PetaLinux/components/yocto/source/arm/layers/core/meta/recipes-core/base-passwd/base-passwd_3.5.29.bb.do_fetch
ERROR: Taskhash mismatch c3837ed788613b3e1c7d4861734cdb8a versus a4b211e338ce900b232a6e2c185111c3 for /home/MY_USER/path/Project/PetaLinux/components/yocto/source/arm/layers/core/meta/recipes-core/base-passwd/base-passwd_3.5.29.bb.do_fetch
ERROR: gdbm-1.13-r0 do_fetch: Taskhash mismatch b922a2087e73e51e9d01436c1e4e248e versus 1aef7bb409901a0048b90eba2479eede for /home/MY_USER/path/Project/PetaLinux/components/yocto/source/arm/layers/core/meta/recipes-support/gdbm/gdbm_1.13.bb.do_fetch
ERROR: Taskhash mismatch b922a2087e73e51e9d01436c1e4e248e versus 1aef7bb409901a0048b90eba2479eede for /home/MY_USER/path/Project/PetaLinux/components/yocto/source/arm/layers/core/meta/recipes-support/gdbm/gdbm_1.13.bb.do_fetch
ERROR: cryptodev-linux-1.9-r0 do_fetch: Taskhash mismatch 1cdcdec957d1856fea3457e369648880 versus 9b17b155f770ac0aa825eada166aa161 for /home/MY_USER/path/Project/PetaLinux/components/yocto/source/arm/layers/core/meta/recipes-kernel/cryptodev/cryptodev-linux_1.9.bb.do_fetch
ERROR: Taskhash mismatch 1cdcdec957d1856fea3457e369648880 versus 9b17b155f770ac0aa825eada166aa161 for /home/MY_USER/path/Project/PetaLinux/components/yocto/source/arm/layers/core/meta/recipes-kernel/cryptodev/cryptodev-linux_1.9.bb.do_fetch
ERROR: openssl-1.0.2l-r0 do_fetch: Taskhash mismatch ab1dbe098c8359940e77710633acbd94 versus f58213bd7e2f3020d2d90df2b2a5c60d for /home/MY_USER/path/Project/PetaLinux/components/yocto/source/arm/layers/core/meta/recipes-connectivity/openssl/openssl_1.0.2l.bb.do_fetch
ERROR: Taskhash mismatch ab1dbe098c8359940e77710633acbd94 versus f58213bd7e2f3020d2d90df2b2a5c60d for /home/MY_USER/path/Project/PetaLinux/components/yocto/source/arm/layers/core/meta/recipes-connectivity/openssl/openssl_1.0.2l.bb.do_fetch
ERROR: initscripts-1.0-r155 do_fetch: Taskhash mismatch 3edb04d402fa6d3395b4bd260a6cf005 versus 09f36ade6285df676e1c6231ea5d4e46 for /home/MY_USER/path/Project/PetaLinux/components/yocto/source/arm/layers/core/meta/recipes-core/initscripts/initscripts_1.0.bb.do_fetch
ERROR: Taskhash mismatch 3edb04d402fa6d3395b4bd260a6cf005 versus 09f36ade6285df676e1c6231ea5d4e46 for /home/MY_USER/path/Project/PetaLinux/components/yocto/source/arm/layers/core/meta/recipes-core/initscripts/initscripts_1.0.bb.do_fetch
ERROR: initscripts-1.0-r155 do_unpack: Taskhash mismatch cec2ffc0af098e6b656f3a4e10cf8bac versus 6d9ef0dccf4a30521b5b89ecad5de347 for /home/MY_USER/path/Project/PetaLinux/components/yocto/source/arm/layers/core/meta/recipes-core/initscripts/initscripts_1.0.bb.do_unpack
ERROR: Taskhash mismatch cec2ffc0af098e6b656f3a4e10cf8bac versus 6d9ef0dccf4a30521b5b89ecad5de347 for /home/MY_USER/path/Project/PetaLinux/components/yocto/source/arm/layers/core/meta/recipes-core/initscripts/initscripts_1.0.bb.do_unpack
ERROR: xcb-proto-1.12-r0 do_fetch: Taskhash mismatch 061b329f97e940c0d8ec4a2b3d7c9f77 versus e767d8d505fde7d26fc7a73b1f76dc91 for /home/MY_USER/path/Project/PetaLinux/components/yocto/source/arm/layers/core/meta/recipes-graphics/xorg-proto/xcb-proto_1.12.bb.do_fetch
ERROR: Taskhash mismatch 061b329f97e940c0d8ec4a2b3d7c9f77 versus e767d8d505fde7d26fc7a73b1f76dc91 for /home/MY_USER/path/Project/PetaLinux/components/yocto/source/arm/layers/core/meta/recipes-graphics/xorg-proto/xcb-proto_1.12.bb.do_fetch
ERROR: libpthread-stubs-0.4-r0 do_fetch: Taskhash mismatch 4c847cd7da4e14c81d7661edcffb2d16 versus ba33c70d08a20f071d5cd39e166467f4 for /home/MY_USER/path/Project/PetaLinux/components/yocto/source/arm/layers/core/meta/recipes-graphics/xorg-lib/libpthread-stubs_0.4.bb.do_fetch
ERROR: Taskhash mismatch 4c847cd7da4e14c81d7661edcffb2d16 versus ba33c70d08a20f071d5cd39e166467f4 for /home/MY_USER/path/Project/PetaLinux/components/yocto/source/arm/layers/core/meta/recipes-graphics/xorg-lib/libpthread-stubs_0.4.bb.do_fetch
ERROR: libxdmcp-1_1.1.2-r0 do_fetch: Taskhash mismatch 40aab1d9821aeb05e85d8c92094741f5 versus 77bed6e51edda4307a4524745cf94609 for /home/MY_USER/path/Project/PetaLinux/components/yocto/source/arm/layers/core/meta/recipes-graphics/xorg-lib/libxdmcp_1.1.2.bb.do_fetch
ERROR: Taskhash mismatch 40aab1d9821aeb05e85d8c92094741f5 versus 77bed6e51edda4307a4524745cf94609 for /home/MY_USER/path/Project/PetaLinux/components/yocto/source/arm/layers/core/meta/recipes-graphics/xorg-lib/libxdmcp_1.1.2.bb.do_fetch
ERROR: libxau-1_1.0.8-r0 do_fetch: Taskhash mismatch 7e6bb150c02427b0ea8816f2d835748a versus e01f44ab47147ed68c5e698beebb7f77 for /home/MY_USER/path/Project/PetaLinux/components/yocto/source/arm/layers/core/meta/recipes-graphics/xorg-lib/libxau_1.0.8.bb.do_fetch
ERROR: Taskhash mismatch 7e6bb150c02427b0ea8816f2d835748a versus e01f44ab47147ed68c5e698beebb7f77 for /home/MY_USER/path/Project/PetaLinux/components/yocto/source/arm/layers/core/meta/recipes-graphics/xorg-lib/libxau_1.0.8.bb.do_fetch
ERROR: linux-libc-headers-4.12-r0 do_package: Error executing a python function in exec_python_func() autogenerated:
The stack trace of python calls that resulted in this exception/failure was:
File: 'exec_python_func() autogenerated', lineno: 2, function: <module>
0001:
*** 0002:package_do_filedeps(d)
0003:
File: '/home/MY_USER/path/Project/PetaLinux/components/yocto/source/arm/layers/core/meta/classes/package.bbclass', lineno: 1484, function: package_do_filedeps
1480: continue
1481: for files in chunks(pkgfiles[pkg], 100):
1482: pkglist.append((pkg, files, rpmdeps, pkgdest))
1483:
*** 1484: processed = oe.utils.multiprocess_exec( pkglist, oe.package.filedeprunner)
1485:
1486: provides_files =
1487: requires_files =
1488:
File: '/home/MY_USER/path/Project/PetaLinux/components/yocto/source/arm/layers/core/meta/lib/oe/utils.py', lineno: 240, function: multiprocess_exec
0236: mapresult = pool.map_async(function, commands, error_callback=failures)
0237:
0238: pool.close()
0239: pool.join()
*** 0240: results = mapresult.get()
0241: except KeyboardInterrupt:
0242: pool.terminate()
0243: pool.join()
0244: raise
File: '/usr/lib64/python3.9/multiprocessing/pool.py', lineno: 771, function: get
0767: raise TimeoutError
0768: if self._success:
0769: return self._value
0770: else:
*** 0771: raise self._value
0772:
0773: def _set(self, i, obj):
0774: self._success, self._value = obj
0775: if self._callback and self._success:
Exception: subprocess.CalledProcessError: Command '['/home/MY_USER/path/Project/xilinx-zc702-2018.2/build/tmp/work/cortexa9hf-neon-xilinx-linux-gnueabi/linux-libc-headers/4.12-r0/recipe-sysroot-native/usr/lib/rpm/rpmdeps', '--alldeps', '/home/MY_USER/path/Project/xilinx-zc702-2018.2/build/tmp/work/cortexa9hf-neon-xilinx-linux-gnueabi/linux-libc-headers/4.12-r0/packages-split/linux-libc-headers-lic/usr/share/licenses/linux-libc-headers/generic_GPLv2', '/home/MY_USER/path/Project/xilinx-zc702-2018.2/build/tmp/work/cortexa9hf-neon-xilinx-linux-gnueabi/linux-libc-headers/4.12-r0/packages-split/linux-libc-headers-lic/usr/share/licenses/linux-libc-headers/COPYING']' returned non-zero exit status 1.
Subprocess output:
/home/MY_USER/path/Project/xilinx-zc702-2018.2/build/tmp/work/cortexa9hf-neon-xilinx-linux-gnueabi/linux-libc-headers/4.12-r0/recipe-sysroot-native/usr/lib/rpm/rpmdeps: /home/MY_USER/path/Project/xilinx-zc702-2018.2/build/tmp/sysroots-uninative/x86_64-linux/lib/libc.so.6: version `GLIBC_2.32' not found (required by /lib64/libgomp.so.1)
ERROR: linux-libc-headers-4.12-r0 do_package: Function failed: package_do_filedeps
ERROR: Logfile of failure stored in: /home/MY_USER/path/Project/xilinx-zc702-2018.2/build/tmp/work/cortexa9hf-neon-xilinx-linux-gnueabi/linux-libc-headers/4.12-r0/temp/log.do_package.227243
ERROR: Task (/home/MY_USER/path/Project/PetaLinux/components/yocto/source/arm/layers/core/meta/recipes-kernel/linux-libc-headers/linux-libc-headers_4.12.bb:do_package) failed with exit code '1'
ERROR: libffi-3.2.1-r0 do_fetch: Taskhash mismatch ca914d97dfb9f8448699567a97575997 versus 1e247b18753a9f2165aee681b9a87c8e for /home/MY_USER/path/Project/PetaLinux/components/yocto/source/arm/layers/core/meta/recipes-support/libffi/libffi_3.2.1.bb.do_fetch
ERROR: Taskhash mismatch ca914d97dfb9f8448699567a97575997 versus 1e247b18753a9f2165aee681b9a87c8e for /home/MY_USER/path/Project/PetaLinux/components/yocto/source/arm/layers/core/meta/recipes-support/libffi/libffi_3.2.1.bb.do_fetch
NOTE: Tasks Summary: Attempted 794 tasks of which 743 didn't need to be rerun and 1 failed.
Summary: 1 task failed:
/home/MY_USER/path/Project/PetaLinux/components/yocto/source/arm/layers/core/meta/recipes-kernel/linux-libc-headers/linux-libc-headers_4.12.bb:do_package
Summary: There were 3 WARNING messages shown.
Summary: There were 26 ERROR messages shown, returning a non-zero exit code.
ERROR: Failed to build project
如果需要任何其他信息,请询问,我会提供。 谢谢!
【问题讨论】:
猜测:你的默认 glibc-2.32 是错误的架构?是 x86_64 吗? .....而赛灵思拱门是aarch, arm64
? .......你应该使用aarch glibc ........
是的,我的 glibc 是 x86_64,我认为我的 xilinx 是 arm。
【参考方案1】:
/home/MY_USER/.../sysroots-uninative/x86_64-linux/lib/libc.so.6: version 'GLIBC_2.32' not found (required by /lib64/libgomp.so.1)
您将 system libgomp.so.1
与 sysroot libc.so.6
混合在一起——这将永远不会结束。您可能还需要在 sysroot 中构建 libgomp.so.1
。
如果我运行
/lib/libc.so.6
,我会得到:
那是不相关的——你的链接不是那个库失败,而是 sysroot 那个。
如果您运行/home/MY_USER/path/Project/xilinx-zc702-2018.2/build/tmp/sysroots-uninative/x86_64-linux/lib/libc.so.6
,您会发现它实际上太旧了(比2.32
更早)。
【讨论】:
感谢您为我指出正确的方向,我现在时间不多,但我设法运行了您的建议并返回GNU C Library (GNU libc) development release version 2.25.90
,所以我应该做的是替换这个库用新的?
我尝试以几种方式替换库,但没有成功。所以现在我想尝试在我的项目中构建libgomp.so.1
,我该怎么做?
@overmach 这个答案回答了你的“问题是什么?”题。您应该接受它并提出一个新问题:“为什么我的 petalinux 构建使用系统 libgomp”或“如何在 petalinux 构建中使用更新的 GLIBC”,或类似的。我不知道 petalinux 是什么,对此我无能为力。
我已经打开另一个问题来解决这个问题:***.com/questions/70243564/…
@EmployedRussian 你能回答我的问题吗?***.com/questions/70481326/…以上是关于运行 petalinux-build 时未找到版本“GLIBC_2.32”错误的主要内容,如果未能解决你的问题,请参考以下文章
构建 iOS 框架时未找到 Ktor 和 kotlinx 依赖项
运行 Xcode 测试时未找到 FBSnapshotTestCase 图像
sh: 1: tailwind: 运行 npm start 时未找到