且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

buildroot文件系统和交叉编译:动态链接的应用程序失败,但静态确定。如何链接到uClibc

更新时间:2023-09-15 20:28:34

要构建应用程序,必须使用Buildroot生成的交叉编译器,该交叉编译器位于 output / host / usr / bin /< -of-architecture>中。 -gcc

To build your application, you have to use the cross-compiler that Buildroot has generated, located in output/host/usr/bin/<name-of-architecture>-gcc.

在这里,您使用的是Ubuntu ARM交叉编译器,该编译器针对使用 eglibc C库。但是用Buildroot生成的系统使用 uClibc C库。因此,使用Ubuntu ARM交叉编译器生成的二进制文件绝对不可能在此Buildroot生成的系统上运行。

Here, you're using the Ubuntu ARM cross-compiler, that targets a system that uses the eglibc C library. But the system generated with Buildroot uses the uClibc C library. Therefore, there is absolutely no chance for a binary built with the Ubuntu ARM cross-compiler to run on this Buildroot generated system.

只需使用生成的交叉编译器Buildroot为你。

Just use the cross-compiler Buildroot has generated for you.