如何交叉编译 gobject-introspection?

如何交叉编译 gobject-introspection?

我已在虚拟机(qemu-system-mipsel)中成功编译了 gobject-introspection,但在交叉编译时遇到了问题。

我已经发现本文关于这个主题,我尝试按照说明进行操作,针对我的平台进行修改,我使用为目标平台编译的 Python 并qemu-mipsel作为 INTROSPECTION_LAUNCHER。

最后我收到这样的消息:

g-ir-scanner: link: /bin/bash ./libtool --mode=link --tag=CC mips-linux-gnu-gcc -o /gobject-introspection-1.48.0/tmp-introspectgaac9I/GLib-2.0 -export-dynamic -fno-strict-aliasing -Wsign-compare -Wcast-align -Wpointer-arith -Wnested-externs -Wmissing-prototypes -Wmissing-declarations -Wchar-subscripts -Wall -g -O2 tmp-introspectgaac9I/p/gobject-introspection-1.48.0/tmp-introspectgaac9I/GLib-2.0.o -L/opt/lib -lgio-2.0 -lgobject-2.0 -Wl,--export-dynamic -lgmodule-2.0 -pthread -lrt -lglib-2.0 -lglib-2.0 -lgobject-2.0
libtool: link: mips-linux-gnu-gcc -o /p/gobject-introspection-1.48.0/tmp-introspectgaac9I/GLib-2.0 -fno-strict-aliasing -Wsign-compare -Wcast-align -Wpointer-arith -Wnested-externs -Wmissing-prototypes -Wmissing-declarations -Wchar-subscripts -Wall -g -O2 tmp-introspectgaac9I/p/gobject-introspection-1.48.0/tmp-introspectgaac9I/GLib-2.0.o -Wl,--export-dynamic -pthread -Wl,--export-dynamic  -L/opt/lib /opt/lib/libgio-2.0.so -lz -lresolv /opt/lib/libgmodule-2.0.so -ldl /opt/lib/libgobject-2.0.so /opt/lib/libglib-2.0.so -lpthread -lrt /opt/lib/libffi.so -pthread -Wl,-rpath -Wl,/opt/lib -Wl,-rpath -Wl,/opt/lib
ERROR: can't resolve libraries to shared libraries: gobject-2.0

如果有人曾经交叉编译过 gobject-introspection,请分享一个成功的故事。

相关内容